[1.0.0] 接驳车乘客屏接口完成

This commit is contained in:
wangmingjun
2023-01-11 10:26:42 +08:00
parent 6fe28c8dab
commit 2e8db449f7
5 changed files with 53 additions and 16 deletions

View File

@@ -0,0 +1,26 @@
package com.mogo.och.bus.passenger.constant
import com.mogo.commons.debug.DebugConfig
/**
* Created on 2021/12/6
*/
class URLConst {
companion object {
private const val BASE_URL_OCH_DEV = "http://tech-dev.zhidaohulian.com"
private const val BASE_URL_OCH_QA = "https://tech-qa.zhidaohulian.com"
private const val BASE_URL_OCH_RELEASE = "https://tech.zhidaohulian.com"
@JvmStatic
fun getBaseUrl(): String {
return when (DebugConfig.getNetMode()) {
DebugConfig.NET_MODE_DEV, DebugConfig.NET_MODE_DEMO -> BASE_URL_OCH_DEV
DebugConfig.NET_MODE_QA -> BASE_URL_OCH_QA
DebugConfig.NET_MODE_RELEASE -> BASE_URL_OCH_RELEASE
else -> BASE_URL_OCH_RELEASE
}
}
}
}

View File

@@ -8,20 +8,6 @@ import com.mogo.commons.debug.DebugConfig
class BusPassengerConst {
companion object {
private const val BASE_URL_OCH_DEV = "http://tech-dev.zhidaohulian.com"
private const val BASE_URL_OCH_QA = "https://tech-qa.zhidaohulian.com"
private const val BASE_URL_OCH_RELEASE = "https://tech.zhidaohulian.com"
@JvmStatic
fun getBaseUrl(): String {
return when (DebugConfig.getNetMode()) {
DebugConfig.NET_MODE_DEV, DebugConfig.NET_MODE_DEMO -> BASE_URL_OCH_DEV
DebugConfig.NET_MODE_QA -> BASE_URL_OCH_QA
DebugConfig.NET_MODE_RELEASE -> BASE_URL_OCH_RELEASE
else -> BASE_URL_OCH_RELEASE
}
}
// OCH arouter 路由path
const val PATH = "/och/api"

View File

@@ -1,13 +1,13 @@
package com.mogo.och.bus.passenger.network
import android.content.Context
import com.mogo.och.bus.passenger.constant.BusPassengerConst.Companion.getBaseUrl
import com.mogo.eagle.core.function.call.telematic.CallerTelematicManager.getServerToken
import com.mogo.och.bus.passenger.bean.BusPassengerRoutesResponse
import com.mogo.cloud.passport.MoGoAiCloudClientConfig
import com.mogo.och.bus.passenger.bean.BusPassengerQueryLineRequest
import com.mogo.och.bus.passenger.bean.BusPassengerOperationStatusResponse
import com.mogo.eagle.core.network.MoGoRetrofitFactory
import com.mogo.och.bus.passenger.constant.URLConst.Companion.getBaseUrl
import com.mogo.och.common.module.biz.network.OchCommonServiceCallback
import com.mogo.och.common.module.biz.network.OchCommonSubscribeImpl
import com.mogo.och.common.module.biz.network.interceptor.transformTry

View File

@@ -0,0 +1,25 @@
package com.mogo.och.bus.passenger.constant
import com.mogo.commons.debug.DebugConfig
/**
* Created on 2021/12/6
*/
class URLConst {
companion object {
private const val BASE_URL_OCH_DEV = "https://och-driver-dev.zhidaozhixing.com"
private const val BASE_URL_OCH_QA = "https://och-driver-qa.zhidaozhixing.com"
private const val BASE_URL_OCH_RELEASE = "https://och-driver.zhidaozhixing.com"
@JvmStatic
fun getBaseUrl(): String {
return when (DebugConfig.getNetMode()) {
DebugConfig.NET_MODE_DEV, DebugConfig.NET_MODE_DEMO -> BASE_URL_OCH_DEV
DebugConfig.NET_MODE_QA -> BASE_URL_OCH_QA
DebugConfig.NET_MODE_RELEASE -> BASE_URL_OCH_RELEASE
else -> BASE_URL_OCH_RELEASE
}
}
}
}

View File

@@ -17,7 +17,7 @@ import retrofit2.http.Query;
*
* Bus乘客端接口定义
*/
interface BusPassengerServiceApi {
interface PassengerServiceApi {
/**
* 查询bus司机端绑定路线
* @return 接口返回数据