zhujie
9 天以前 f980c833f832c42094cf78005aab5d0eb014c8ec
app/src/main/java/com/example/firstapp/database/service/ApiService.kt
@@ -14,6 +14,8 @@
import com.example.firstapp.database.response.LoginResponse
import com.example.firstapp.database.response.SecurityResponse
import com.example.firstapp.database.response.UserInfo
import com.example.firstapp.entity.InvitationRecord
import com.example.firstapp.entity.InvitationRecords
import com.example.firstapp.model.CategoryConfig
import com.example.firstapp.model.CategoryConfigSync
import com.example.firstapp.network.AuthInterceptor
@@ -81,13 +83,16 @@
    @POST("api/categoryConfig/saveOrUpdate/")
    suspend fun saveUserCategories(@Body categoryConfigSync: CategoryConfigSync)
    @GET("api/customer/center/invitereward")
    suspend fun getInvitereward(): ApiResponse<InvitationRecords>
}
// 创建Retrofit实例(单例)
object RetrofitClient{
 //   private const val BASE_URL ="http://192.168.1.213:8080/flower/"
    private const val BASE_URL ="http://14.103.144.28:8080/flower/"
    private const val BASE_URL ="http://192.168.1.127:8080/flower/"
    //private const val BASE_URL ="http://14.103.144.28:8080/flower/"
    private lateinit var appContext: Context