|
|
@ -1,13 +1,8 @@
|
|
|
|
package fr.iut.sciencequest.model.buisness.Scientifique
|
|
|
|
package fr.iut.sciencequest.model.buisness.Scientifique
|
|
|
|
|
|
|
|
|
|
|
|
import com.jakewharton.retrofit2.converter.kotlinx.serialization.asConverterFactory
|
|
|
|
|
|
|
|
import fr.iut.sciencequest.model.dto.ScientifiqueDTOs.ScientifiqueDTO
|
|
|
|
import fr.iut.sciencequest.model.dto.ScientifiqueDTOs.ScientifiqueDTO
|
|
|
|
import fr.iut.sciencequest.model.dto.ScientifiqueDTOs.ScientifiqueListDTO
|
|
|
|
import fr.iut.sciencequest.model.dto.ScientifiqueDTOs.ScientifiqueListDTO
|
|
|
|
import kotlinx.serialization.json.Json
|
|
|
|
import fr.iut.sciencequest.model.dto.ScientifiqueDTOs.ScientifiqueListInfosDTO
|
|
|
|
import okhttp3.MediaType
|
|
|
|
|
|
|
|
import okhttp3.OkHttpClient
|
|
|
|
|
|
|
|
import retrofit2.Call
|
|
|
|
|
|
|
|
import retrofit2.Retrofit
|
|
|
|
|
|
|
|
import retrofit2.http.GET
|
|
|
|
import retrofit2.http.GET
|
|
|
|
import retrofit2.http.Path
|
|
|
|
import retrofit2.http.Path
|
|
|
|
import retrofit2.http.Query
|
|
|
|
import retrofit2.http.Query
|
|
|
@ -16,6 +11,9 @@ interface ScientifiqueRequestService {
|
|
|
|
@GET("scientifiques?page")
|
|
|
|
@GET("scientifiques?page")
|
|
|
|
suspend fun getScientifiques(@Query("page") index: Int): ScientifiqueListDTO
|
|
|
|
suspend fun getScientifiques(@Query("page") index: Int): ScientifiqueListDTO
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@GET("scientifiques")
|
|
|
|
|
|
|
|
suspend fun getScientifiquesListInfos(): ScientifiqueListInfosDTO
|
|
|
|
|
|
|
|
|
|
|
|
@GET("scientifiques/{id}")
|
|
|
|
@GET("scientifiques/{id}")
|
|
|
|
suspend fun getScientifique(@Path("id") id: Int): ScientifiqueDTO
|
|
|
|
suspend fun getScientifique(@Path("id") id: Int): ScientifiqueDTO
|
|
|
|
}
|
|
|
|
}
|