lmw
2025-04-24 718f31c92e2029d05260810435a2c70cef6e6ce5
app/src/main/java/com/sinata/xqmuse/network/ApiService.kt
@@ -9,15 +9,11 @@
interface ApiService {
    @GET(Apis.H5_URL)
    fun getH5(@Query("key") type: Int): Flowable<ResultData<H5Bean>>
    fun getH5(@Query("key") type: Int,@Query("apipost_id") apipost_id: String = "2478a330b0e0e3"): Flowable<ResultData<H5Bean>>
    @FormUrlEncoded
    @POST(Apis.queryPhysical)
    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)
@@ -32,110 +28,34 @@
    @POST(Apis.completeInfo)
    fun completeInfo(@Field("courseId") id: String): Flowable<ResultData<FinishBean>>
    @FormUrlEncoded
    @POST(Apis.queryCourseList)
    fun queryCourseList(
        @Field("pageNum") page: Int,
        @Field("difficulty1") difficulty1: String?,
        @Field("positionName1") positionName1: String?,
        @Field("time") time: String?,
        @Field("typeIds1") typeIds1: String?,
        @Field("courseName") search: String?,
        @Field("pageSize") pageSize: Int = 10
    ): Flowable<ResultData<List<Course>>>
        @Query("pageCurr") page: Int,
        @Query("cateId") typeId: String?,
        @Query("courseTitle") search: String?,
        @Query("pageSize") pageSize: Int = 10
    ): Flowable<ResultData<CourseListBean>>
    @FormUrlEncoded
    @POST(Apis.myCourse)
    fun myCourse(
        @Field("pageNum") page: Int,
        @Field("difficulty1") difficulty1: String?,
        @Field("positionName1") positionName1: String?,
        @Field("time") time: String?,
        @Field("typeIds1") typeIds1: String?,
        @Field("courseName") search: String?,
        @Field("pageSize") pageSize: Int = 10
    ): Flowable<ResultData<List<Course>>>
    @POST(Apis.getCoursePageList)
    fun getCoursePageList(): Flowable<ResultData<TeacherBean>>
    @FormUrlEncoded
    @POST(Apis.queryCourseInfo)
    fun queryCourseInfo(
        @Field("courseId") id: String
    @POST(Apis.getPayCourseInfoById)
    fun getPayCourseInfoById(
        @Query("id") id: String,
        @Query("apipost_id") apipost_id: String = "2d2eb9d23993bd"
    ): Flowable<ResultData<CourseDetail>>
    @FormUrlEncoded
    @POST(Apis.collectCourse)
    fun collectCourse(
        @Field("courseId") id: String
        @Query("id") id: String,
        @Query("apipost_id") apipost_id: String = "365e099b799885"
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.collectedCourse)
    fun collectedCourse(
        @Field("pageNum") page: Int,
        @Field("courseName") search: String?,
        @Field("positionName1") position: String?,
        @Field("pageSize") pageSize: Int = 10
    ): Flowable<ResultData<List<Course>>>
    @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)
@@ -150,35 +70,145 @@
        @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>>
    @POST(Apis.getCommissionRule)
    fun shareInfo(
    ): Flowable<ResultData<ShareInfo>>
    @FormUrlEncoded
    @POST(Apis.binding)
    fun binding(
        @Field("code") code: String
    ): Flowable<ResultData<Any>>
    @POST
    fun lookHistory(
        @Url url: String,
        @Query("pageCurr") pageCurr: Int,
        @Query("pageSize") pageSize: Int,
        @Query("state") state: Int,
        @Query("apipost_id") apipost_id: String
    ): Flowable<ResultData<List<CourseBean>>>
    @FormUrlEncoded
    @POST(Apis.getBindingUserName)
    fun getBindingUserName(
        @Field("code") code: String
    @POST(Apis.getVipPrice)
    fun getVipPrice(
        @Query("apipost_id") apipost_id: String = "2fcbf1db399709"
    ): Flowable<ResultData<VipPriceBean>>
    @POST(Apis.getVipContent)
    fun getVipContent(
        @Query("type") type: Int,
        @Query("apipost_id") apipost_id: String = "2fcbf1db399709"
    ): Flowable<ResultData<String>>
    @POST(Apis.getBankInfo)
    fun getBankInfo(
    ): Flowable<ResultData<BankInfo>>
    @POST(Apis.getQrCode)
    fun getQrCode(
        @Query("apipost_id") apipost_id: String = "2fcbf1daf99704"
    ): Flowable<ResultData<String>>
    @POST(Apis.peopleList)
    fun peopleList(
    ): Flowable<ResultData<ShareInfo>>
    @GET(Apis.commonQuestion)
    fun commonQuestion(
        @Query("pageCurr") pageNum: Int,
        @Query("pageSize") size: Int,
        @Query("apipost_id") apipost_id: String = "36618045f991c4"
    ): Flowable<ResultData<QABean>>
    @POST(Apis.healingLevel)
    fun healingLevel(
        @Query("apipost_id") apipost_id: String = "34d924b4b991f0"
    ): Flowable<ResultData<LevelBean>>
    @POST(Apis.queryNotice)
    fun queryNotice(
        @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)
@@ -189,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>
@@ -210,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>>>
@@ -249,21 +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>>
    @POST(Apis.getBanner)
    @GET(Apis.getBanner)
    fun queryBanner(): Flowable<ResultData<ArrayList<Banner>>>
    @POST(Apis.getList)
    fun getList(): Flowable<ResultData<FilterBean>>
    @GET(Apis.getCourseCategoryList)
    fun getCourseCategoryList(@Query("apipost_id")apipost_id:String = "2d2eb9d1f993bb"): Flowable<ResultData<ArrayList<CourseType>>>
    @POST(Apis.getCategoryListByType)
    fun getCategoryListByType(
@@ -272,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(
@@ -286,6 +318,47 @@
        @Query("apipost_id") apipost_id: String = "25c3e3d0b0e157"
    ): Flowable<ResultData<List<HomeListBean>>>
    @GET(Apis.getHomeBackgroun)
    fun getHomeBackgroun(
        @Query("apipost_id") apipost_id: String = "25c3e3d0b0e155"
    ): Flowable<ResultData<List<BGMBean>>>
    @POST(Apis.getMeditationPageByCateId)
    fun getMeditationPageByCateId(
        @Query("cateId") cateId: String,
        @Query("pageCurr") pageCurr: Int,
        @Query("pageSize") pageSize: Int,
        @Query("apipost_id") apipost_id: String = "25c3e3d0b0e15a"
    ): Flowable<ResultData<SearchResult>>
    @GET(Apis.getMeditationDetails)
    fun getMeditationDetails(
        @Query("id") id: String
    ): Flowable<ResultData<VoiceDetail>>
    @POST(Apis.favorite)
    fun favorite(
        @Query("id") id: String
    ): Flowable<ResultData<Any>>
    @GET(Apis.getMeditationQuestionPage)
    fun getMeditationQuestionPage(
        @Query("id") id: String,
        @Query("pageCurr") pageCurr: Int,
        @Query("pageSize") pageSize: Int
    ): Flowable<ResultData<VoiceCommentBean>>
    @POST(Apis.search)
    fun search(
        @Query("condition") condition: String,
        @Query("pageCurr") pageCurr: Int,
        @Query("pageSize") pageSize: Int
    ): Flowable<ResultData<SearchResult>>
    @GET(Apis.getHotWordList)
    fun getHotWordList(
    ): Flowable<ResultData<List<String>>>
    @FormUrlEncoded
    @POST(Apis.queryCouponPackage)
    fun queryCouponPackage(
@@ -294,28 +367,118 @@
        @Field("pageSize") pageSize: Int = Const.PAGE_SIZE
    ): Flowable<ResultData<List<Coupon>>>
    @POST(Apis.getUserByPhone)
    fun getUserByPhone(
        @Query("phone") phone: String
    ): Flowable<ResultData<UserInfo>>
    @POST(Apis.confirmOrder)
    fun confirmOrder(
        @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>>
    @FormUrlEncoded
    @POST(Apis.updateInfo)
    fun updateInfo(
        @Field("headImg") headImg: String?,
        @Field("birthday") birthday: String?,
        @Field("gender") gender: Int?,
        @Field("height") height: Int?,
        @Field("weight") weight: Double?,
        @Field("waistline") waistline: Int?,
        @Field("name") name: String?
        @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>>
@@ -327,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)
@@ -374,12 +511,16 @@
        @Field("pageSize") pageSize: Int = Const.PAGE_SIZE
    ): Flowable<ResultData<List<ReplyComment>>>
    @FormUrlEncoded
    @POST(Apis.report)
    fun report(
        @Field("id") id: String,
        @Field("content") content: String,
        @Field("type") type: Int
        @Query("id") id: String,
        @Query("reason") content: String
    ): Flowable<ResultData<Any>>
    @POST(Apis.addQuestion)
    fun addQuestion(
        @Query("meditationId") id: String,
        @Query("content") content: String
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
@@ -392,12 +533,10 @@
        @Field("replyUserId") replyUserId: String?
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
    @POST(Apis.doLike)
    fun doLike(
        @Field("id") findId: String,
        @Field("type") type: Int,
        @Field("findCommentId") findCommentId: String?
        @Query("id") findId: String,
        @Query("apipost_id") apipost_id: String = "2aa4e14b30e165"
    ): Flowable<ResultData<Any>>
    @FormUrlEncoded
@@ -416,19 +555,30 @@
        @Field("id") id: String
    ): Flowable<ResultData<Dynamic>>
    @FormUrlEncoded
    @POST(Apis.messageList)
    fun messageList(
        @Field("pageNum") page: Int,
        @Field("pageSize") pageSize: Int = Const.PAGE_SIZE): Flowable<ResultData<List<Msg>>>
        @Query("pageCurr") pageCurr: Int,
        @Query("pageSize") pageSize: Int,
        @Query("apipost_id") apipost_id: String = "361bdf123992f9"): Flowable<ResultData<MsgListBean>>
    @FormUrlEncoded
    @POST(Apis.deleteFind)
    fun deleteFind(
        @Field("findId") findId: String): Flowable<ResultData<Any>>
    @POST(Apis.messageCount)
    fun messageCount(): Flowable<ResultData<Int>>
    @GET(Apis.getMeditationPage)
    fun getMeditationPage(
        @Query("name") name: String?,
        @Query("lat") lat: Double?,
        @Query("lon") lon: Double?,
        @Query("pageCurr") pageCurr: Int,
        @Query("pageSize") pageSize: Int,
        @Query("apipost_id") apipost_id: String = "2d2eb5e7f991ab"): Flowable<ResultData<PlaceListBean>>
    @GET(Apis.getMeditationInfo)
    fun getMeditationInfo(
        @Query("id") id: String,
        @Query("apipost_id") apipost_id: String = "2d2eb5e7b991aa"): Flowable<ResultData<Place>>
    @FormUrlEncoded
    @POST
@@ -438,22 +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(): Flowable<ResultData<UserInfo>>
    fun getUserInfo(@Query("apipost_id") apipost_id: String = "300079e039993f"): Flowable<ResultData<MineInfo>>
    @POST(Apis.getNotice)
    fun getNotice(): Flowable<ResultData<Notice>>
    @POST(Apis.getUserDetail)
    fun getUserDetail(@Query("apipost_id") apipost_id: String = "2fc350e9799588"): Flowable<ResultData<UserInfo>>
}