lmw
2025-04-03 8d72ec1b07a4fe0863b41b1140a8c0e679867b93
app/src/main/java/com/sinata/xqmuse/network/ApiService.kt
@@ -16,10 +16,6 @@
    fun queryPhysical(@Field("stuID") id: String): Flowable<ResultData<Report>>
    @FormUrlEncoded
    @POST(Apis.startTrain)
    fun startTrain(@Field("courseId") id: String): Flowable<ResultData<TrainInfo>>
    @FormUrlEncoded
    @POST(Apis.exit)
    fun exit(@Field("courseId") id: String,@Field("courseVideoId") courseVideoId: String,@Field("beforeTime") beforeTime: Long,
             @Field("realTime") realTime: Int): Flowable<ResultData<Any>>
@@ -37,27 +33,16 @@
        @Query("pageCurr") page: Int,
        @Query("cateId") typeId: String?,
        @Query("courseTitle") search: String?,
        @Query("pageSize") pageSize: Int = 10,
        @Query("apipost_id") apipost_id: String = "2d6f7f04f99813"
        @Query("pageSize") pageSize: Int = 10
    ): Flowable<ResultData<CourseListBean>>
    @POST(Apis.getCoursePageList)
    fun getCoursePageList(
        @Query("apipost_id") apipost_id: String = "2d2eb9d23993c2"
    ): Flowable<ResultData<TeacherBean>>
    fun getCoursePageList(): Flowable<ResultData<TeacherBean>>
    @POST(Apis.getPayCourseInfoById)
    fun getPayCourseInfoById(
        @Query("id") id: String,
        @Query("apipost_id") apipost_id: String = "2d2eb9d23993bd"
    ): Flowable<ResultData<CourseDetail>>
    @FormUrlEncoded
    @POST(Apis.queryCourseInfo)
    fun queryCourseInfo(
        @Field("courseId") id: String
    ): Flowable<ResultData<CourseDetail>>
    @POST(Apis.collectCourse)
@@ -66,66 +51,11 @@
        @Query("apipost_id") apipost_id: String = "365e099b799885"
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.buyCourse)
    fun buyCourseInfo(
        @Field("courseId") id: String
    ): Flowable<ResultData<BuyInfo>>
    @FormUrlEncoded
    @POST(Apis.order)
    fun order(
        @Field("id") id: String?,
        @Field("buyType") buyType: Int,
        @Field("payType") payType : Int,
        @Field("couponId") couponId : String?,
        @Field("orderMoney") orderMoney : Double?
    ): Flowable<ResultData<Order>>
    @FormUrlEncoded
    @POST(Apis.success)
    fun success(
        @Field("orderId") id: String
    ): Flowable<ResultData<Coupon>>
    @POST(Apis.getProvince)
    fun getProvince(
    ): Flowable<ResultData<List<City>>>
    @FormUrlEncoded
    @POST(Apis.getCity)
    fun getCity(
        @Field("id") id: String
    ): Flowable<ResultData<List<City>>>
    @FormUrlEncoded
    @POST(Apis.setAddress)
    fun setAddress(
        @Field("address") address: String,
        @Field("city") city: String,
        @Field("cityCode") cityCode: String,
        @Field("province") province: String,
        @Field("provinceCode") provinceCode: String,
        @Field("recipient") recipient: String,
        @Field("recipientPhone") recipientPhone: String
    ): Flowable<ResultData<Any>>
    @POST(Apis.getAddress)
    fun getAddress(
    ): Flowable<ResultData<ReceiverBean>>
    @POST(Apis.riskInfo)
    fun riskInfo(): Flowable<ResultData<RiskInfo>>
    @FormUrlEncoded
    @POST(Apis.pay)
    fun pay(
        @Field("id") id: String,
        @Field("payType") payType : Int,
        @Field("buyType") buyType: Int
    ): Flowable<ResultData<PayInfo>>
    @FormUrlEncoded
    @POST(Apis.myFind)
@@ -140,32 +70,6 @@
        @Field("money") money: Double
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.updateBankCard)
    fun updateBankCard(
        @Field("accountName") accountName: String,
        @Field("bankCard") bankCard: String,
        @Field("bankCardImg") bankCardImg: String,
        @Field("bankName") bankName: String,
        @Field("bankPhone") bankPhone: String
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.binding)
    fun binding(
        @Field("code") code: String
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.getBindingUserName)
    fun getBindingUserName(
        @Field("code") code: String
    ): Flowable<ResultData<String>>
    @POST(Apis.getBankInfo)
    fun getBankInfo(
    ): Flowable<ResultData<BankInfo>>
    @POST(Apis.getCommissionRule)
    fun shareInfo(
    ): Flowable<ResultData<ShareInfo>>
@@ -177,7 +81,7 @@
        @Query("pageSize") pageSize: Int,
        @Query("state") state: Int,
        @Query("apipost_id") apipost_id: String
    ): Flowable<ResultData<CourseListBean>>
    ): Flowable<ResultData<List<CourseBean>>>
    @POST(Apis.getVipPrice)
    fun getVipPrice(
@@ -195,7 +99,7 @@
        @Query("apipost_id") apipost_id: String = "2fcbf1daf99704"
    ): Flowable<ResultData<String>>
    @POST(Apis.commonQuestion)
    @GET(Apis.commonQuestion)
    fun commonQuestion(
        @Query("pageCurr") pageNum: Int,
        @Query("pageSize") size: Int,
@@ -212,6 +116,100 @@
        @Query("apipost_id") apipost_id: String = "37771d0cf0e312"
    ): Flowable<ResultData<Boolean>>
    @POST(Apis.balanceList)
    fun balanceList(
        @Query("pageCurr") pageNum: Int,
        @Query("state") state: Int,
        @Query("pageSize") size: Int,
        @Query("apipost_id") apipost_id: String = "361bdf11b992d0"
    ): Flowable<ResultData<WalletDetailBean>>
    @POST(Apis.energyDetail)
    fun energyDetail(
        @Query("pageCurr") pageNum: Int,
        @Query("state") state: Int,
        @Query("pageSize") size: Int
    ): Flowable<ResultData<List<PowerDetail>>>
    @POST(Apis.goodsList)
    fun goodsList(
        @Query("pageCurr") pageNum: Int,
        @Query("pageSize") size: Int
    ): Flowable<ResultData<List<Gift>>>
    @POST(Apis.exchangeRecordList)
    fun exchangeRecordList(
        @Query("pageCurr") pageNum: Int,
        @Query("pageSize") size: Int
    ): Flowable<ResultData<List<Gift>>>
    @POST(Apis.restart)
    fun restart(): Flowable<ResultData<Any>>
    @POST(Apis.exchange)
    fun exchange(
        @Query("prizeId") prizeId: String
    ): Flowable<ResultData<String>>
    @POST(Apis.getTotalEnergyValue)
    fun getTotalEnergyValue(
    ): Flowable<ResultData<Int>>
    @POST(Apis.balanceDetail)
    fun balanceDetail(
        @Query("id") id: String,
        @Query("apipost_id") apipost_id: String = "361bdf11b992cf"
    ): Flowable<ResultData<BalanceDetail>>
    @POST(Apis.bankList)
    fun bankList(
        @Query("apipost_id") apipost_id: String = "361bdf11f992d2"
    ): Flowable<ResultData<List<BankInfo>>>
    @POST(Apis.addBank)
    fun addBank(
        @Body body:String
    ): Flowable<ResultData<Any>>
    @POST(Apis.deleteBank)
    fun deleteBank(
        @Query("id") id: String
    ): Flowable<ResultData<Any>>
    @POST(Apis.withdraw)
    fun withdraw(
        @Query("bankId") id: String,
        @Query("money") money: Double
    ): Flowable<ResultData<Any>>
    @POST(Apis.noticeDetail)
    fun noticeDetail(
        @Query("id") id: String,
        @Query("apipost_id") apipost_id: String = "361bdf123992f8"
    ): Flowable<ResultData<MsgDetail>>
    @POST(Apis.changePhone)
    fun changePhone(
        @Query("code") code: String,
        @Query("phone") phone: String
    ): Flowable<ResultData<Any>>
    @POST(Apis.deleteUser)
    fun deleteUser(
        @Query("apipost_id") apipost_id: String = "361bdf11f992e7"
    ): Flowable<ResultData<Any>>
    @GET(Apis.studyPage)
    fun studyPage(): Flowable<ResultData<StudyBean>>
    @GET(Apis.detailVersion)
    fun detailVersion(): Flowable<ResultData<Version>>
    @POST(Apis.bindVx)
    fun bindVx(
        @Query("openId") openId: String,
        @Query("wxName") wxName: String): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.withdrawalRecord)
    fun withdrawalRecord(
@@ -221,7 +219,7 @@
        @Field("pageSize") pageSize : Int = Const.PAGE_SIZE
    ): Flowable<ResultData<List<Detail>>>
    @GET
    @POST
    fun queryString(
        @Url url: String,
        @QueryMap map: HashMap<String, Any>
@@ -242,6 +240,15 @@
    fun saveUserAnswers(
        @Body body: String
    ): Flowable<ResultData<Any>>
    @POST(Apis.getPlan)
    fun getPlan(): Flowable<ResultData<String>>
    @POST(Apis.verifyCellPhone)
    fun verifyCellPhone(
        @Header("Authorization") token: String,
        @Body body: String
    ): Flowable<ResultData<LoginBean>>
    @GET(Apis.getTagList)
    fun getTagList(): Flowable<ResultData<ArrayList<TagBean>>>
@@ -281,24 +288,16 @@
        @Body body: String
    ): Flowable<ResultData<LoginBean>>
    @FormUrlEncoded
    @POST(Apis.wxLogin)
    fun wxLogin(
        @Field("openId") openid: String?,
        @Field("phone") phone: String?,
        @Field("nickname") nickname: String?,
        @Field("headimgurl") headimgurl: String?,
        @Field("sex") sex: Int?
        @Body body: String
    ): Flowable<ResultData<WxLoginBean>>
    @GET(Apis.getBanner)
    fun queryBanner(@Query("apipost_id")apipost_id:String = "2d2eb9d1f993ba"): Flowable<ResultData<ArrayList<Banner>>>
    fun queryBanner(): Flowable<ResultData<ArrayList<Banner>>>
    @GET(Apis.getCourseCategoryList)
    fun getCourseCategoryList(@Query("apipost_id")apipost_id:String = "2d2eb9d1f993bb"): Flowable<ResultData<ArrayList<CourseType>>>
    @POST(Apis.getList)
    fun getList(): Flowable<ResultData<FilterBean>>
    @POST(Apis.getCategoryListByType)
    fun getCategoryListByType(
@@ -307,9 +306,7 @@
    ): Flowable<ResultData<ArrayList<Menu>>>
    @GET(Apis.getTodayMeditation)
    fun getTodayMeditation(
        @Query("apipost_id") apipost_id: String = "25c3e3d0b0e15d"
    ): Flowable<ResultData<HomeItem>>
    fun getTodayMeditation(): Flowable<ResultData<HomeItem>>
    @GET(Apis.getPersonalityPlan)
    fun getPersonalityPlan(
@@ -336,35 +333,30 @@
    @GET(Apis.getMeditationDetails)
    fun getMeditationDetails(
        @Query("id") id: String,
        @Query("apipost_id") apipost_id: String = "25c3e3d0b0e158"
        @Query("id") id: String
    ): Flowable<ResultData<VoiceDetail>>
    @POST(Apis.favorite)
    fun favorite(
        @Query("id") id: String,
        @Query("apipost_id") apipost_id: String = "2aa4e14ab0e159"
        @Query("id") id: String
    ): Flowable<ResultData<Any>>
    @GET(Apis.getMeditationQuestionPage)
    fun getMeditationQuestionPage(
        @Query("id") id: String,
        @Query("pageCurr") pageCurr: Int,
        @Query("pageSize") pageSize: Int,
        @Query("apipost_id") apipost_id: String = "25c3e3d0b0e15b"
        @Query("pageSize") pageSize: Int
    ): Flowable<ResultData<VoiceCommentBean>>
    @GET(Apis.search)
    @POST(Apis.search)
    fun search(
        @Query("condition") condition: String,
        @Query("pageCurr") pageCurr: Int,
        @Query("pageSize") pageSize: Int,
        @Query("apipost_id") apipost_id: String = "25c3e3d0b0e160"
        @Query("pageSize") pageSize: Int
    ): Flowable<ResultData<SearchResult>>
    @GET(Apis.getHotWordList)
    fun getHotWordList(
        @Query("apipost_id") apipost_id: String = "25c3e3d0b0e156"
    ): Flowable<ResultData<List<String>>>
    @FormUrlEncoded
@@ -377,44 +369,116 @@
    @POST(Apis.getUserByPhone)
    fun getUserByPhone(
        @Query("phone") phone: String,
        @Query("apipost_id") apipost_id: String = "2e763463799135"
        @Query("phone") phone: String
    ): Flowable<ResultData<UserInfo>>
    @POST(Apis.confirmOrder)
    fun confirmOrder(
        @Query("courseId") courseId: String,
        @Query("apipost_id") apipost_id: String = "2d2eb9d1f993b9"
        @Query("courseId") courseId: String
    ): Flowable<ResultData<ConfirmOrder>>
    @POST(Apis.payOrder)
    fun payOrder(
        @Query("id") orderId: String,
        @Query("type") type: Int = 1
    ): Flowable<ResultData<ConfirmOrder>>
    @GET(Apis.cancel)
    fun cancel(
        @Query("uid") orderId: String
    ): Flowable<ResultData<Any>>
    @POST(Apis.confirmOrderVoice)
    fun confirmOrderVoice(
        @Query("meditationId") meditationId: String
    ): Flowable<ResultData<ConfirmOrder>>
    @POST(Apis.saveViewingHistory)
    fun saveViewingHistory(
        @Query("timeLook") timeLook: Int,
        @Query("id") id: String
    ): Flowable<ResultData<Any>>
    @POST(Apis.saveUserHomeBackgroundMusic)
    fun saveUserHomeBackgroundMusic(
        @Query("id") id: String
    ): Flowable<ResultData<Any>>
    @GET(Apis.getHomeBackgroundMusicByUserId)
    fun getHomeBackgroundMusicByUserId(): Flowable<ResultData<BGMBean>>
    @POST(Apis.gvieCourse)
    fun gvieCourse(
        @Query("targetId") courseId: String,
        @Query("orderFrom") orderFrom: Int,
        @Query("receiverId") receiverId: String?,
        @Query("payType") payType: Int = 1
    ): Flowable<ResultData<Any>>
    @POST
    fun successOrder(
        @Url url: String,
        @Query("courseId") courseId: String,
        @Query("meditationId") meditationId: String
    ): Flowable<ResultData<List<CourseBean>>>
    @POST(Apis.studyPageByChapterId)
    fun studyPageByChapterId(
        @Query("chapterId") chapterId: String
    ): Flowable<ResultData<List<Chapter>>>
    @POST(Apis.saveCourseStudyHistory)
    fun saveCourseStudyHistory(
        @Query("chapterId") chapterId: String,
        @Query("isOver") isOver: Int,
        @Query("secondLook") secondLook: Int,
        @Query("minuteLook") minuteLook: Int = 0 //用不到分
    ): Flowable<ResultData<Any>>
    @POST(Apis.queryPayment)
    fun queryPayment(
        @Query("orderId") orderId: String
    ): Flowable<ResultData<String>>
    @POST(Apis.isFirst)
    fun isFirst(): Flowable<ResultData<Boolean>>
    @POST(Apis.getUserTree)
    fun getUserTree(): Flowable<ResultData<TreeInfo>>
    @POST(Apis.watering)
    fun watering(): Flowable<ResultData<WaterResult>>
    @POST(Apis.sign)
    fun sign(): Flowable<ResultData<Any>>
    @POST(Apis.cancellation)
    fun cancellation(): Flowable<ResultData<Any>>
    @POST(Apis.updateInfo)
    fun updateInfo(
        @Query("avatar") headImg: String?,
        @Query("birthday") birthday: String?,
        @Query("company") company: String?,
        @Query("education") education: String?,
        @Query("email") email: String?,
        @Query("gender") gender: Int?,
        @Query("hometown") hometown: String?,
        @Query("industry") industry: String?,
        @Query("location") location: String?,
        @Query("nickname") nickname: String?,
        @Query("occupation") occupation: String?,
        @Query("signature") signature: String?,
        @Query("name") name: String?,
        @Query("apipost_id") apipost_id: String = "2fc350e9b99599"
        @Body body: String?
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.placeOrder)
    fun placeOrder(
        @Query("orderFrom") orderFrom: Int,
        @Query("payType") payType: Int,
        @Query("balanceFlag") balanceFlag: Int,
        @Query("amount") amount: Double?,
        @Query("receiverId") receiverId: String?,
        @Query("targetId") targetId: String?,
        @Query("vipType") vipType: Int?,
        @Query("orderId") orderId: String?
    ): Flowable<ResultData<ThirdPayInfo>>
    @POST(Apis.updateUserAvatar)
    fun updateUserAvatar(
        @Query("avatar") avatar: String
    ): Flowable<ResultData<Any>>
    @POST(Apis.wallet)
    fun wallet(
        @Field("pageNum") pageNum: Int,
        @Field("month") month: Int?,
        @Field("year") year: Int?,
        @Field("pageSize") pageSize : Int = Const.PAGE_SIZE
    ): Flowable<ResultData<WalletBean>>
@@ -426,36 +490,10 @@
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.setUnit)
    fun setUnit(
        @Field("type") type: Int
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.updatePhone)
    fun updatePhone(
        @Field("code") code: String,
        @Field("phone") phone: String
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.useGuide)
    fun useGuide(
        @Field("title") search: String?
    ): Flowable<ResultData<List<Guide>>>
    @POST(Apis.getPhone)
    fun getPhone(
    ): Flowable<ResultData<String>>
    @FormUrlEncoded
    @POST(Apis.findList)
    fun findList(
        @Field("pageNum") page: Int,
        @Field("userNameOrTitle") search: String?,
        @Field("pageSize") pageSize: Int = Const.PAGE_SIZE
    ): Flowable<ResultData<List<Dynamic>>>
    @FormUrlEncoded
    @POST(Apis.findCommentList)
@@ -476,8 +514,13 @@
    @POST(Apis.report)
    fun report(
        @Query("id") id: String,
        @Query("reason") content: String,
        @Query("apipost_id") apipost_id: String = "25c3e3d0b0e15e"
        @Query("reason") content: String
    ): Flowable<ResultData<Any>>
    @POST(Apis.addQuestion)
    fun addQuestion(
        @Query("meditationId") id: String,
        @Query("content") content: String
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
@@ -545,25 +588,9 @@
        @Field("quesId") quesId: String
    ): Flowable<ResultData<Notice>>
    @FormUrlEncoded
    @POST(Apis.constellation)
    fun constellation(@Field("consName") consName: String,@Field("type") type:String): Flowable<ResultData<LuckInfo>>
    @FormUrlEncoded
    @POST(Apis.setWeight)
    fun setWeight(@Field("type") type: Int,@Field("weight") weight:String): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.changeConstellation)
    fun changeConstellation(@Field("consName") consName:String): Flowable<ResultData<Any>>
    @POST(Apis.getUserInfo)
    fun getUserInfo(@Query("apipost_id") apipost_id: String = "300079e039993f"): Flowable<ResultData<MineInfo>>
    @POST(Apis.getUserDetail)
    fun getUserDetail(@Query("apipost_id") apipost_id: String = "2fc350e9799588"): Flowable<ResultData<UserInfo>>
    @POST(Apis.getNotice)
    fun getNotice(): Flowable<ResultData<Notice>>
}