[6.5.0][Opt]行程概览UI效果优化
This commit is contained in:
@@ -3,6 +3,8 @@ package com.mogo.eagle.core.function.business.travelreality
|
||||
import com.mogo.commons.constants.HostConst
|
||||
import com.mogo.eagle.core.data.BaseResponse
|
||||
import com.mogo.eagle.core.data.Response
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerChassisLocationWGS84ListenerManager
|
||||
import com.mogo.eagle.core.function.call.map.CallerMapUIServiceManager
|
||||
import com.mogo.eagle.core.network.MoGoRetrofitFactory
|
||||
import com.mogo.eagle.core.network.apiCall
|
||||
import com.mogo.eagle.core.network.apiResponseCall
|
||||
@@ -50,14 +52,15 @@ class TravelRealityModel private constructor() {
|
||||
/**
|
||||
* 查询路口设备
|
||||
*/
|
||||
fun getCrossDevice(lon: Double, lat: Double, cityCode: String?,
|
||||
onSuccess: ((List<CrossDeviceBean>) -> Unit), onError: ((String) -> Unit)) {
|
||||
fun getCrossDevice(onSuccess: ((List<CrossDeviceBean>) -> Unit), onError: ((String) -> Unit)) {
|
||||
request<BaseResponse<List<CrossDeviceBean>?>>{
|
||||
loader {
|
||||
apiCall{
|
||||
val time = System.currentTimeMillis().toString()
|
||||
val md5String = "${CROSS_DEVICE.uppercase(Locale.getDefault())}$time"
|
||||
getNetWorkApi(HostConst.getNDEHost()).getCrossDevice(Md5Util.getMD5Result(md5String), time, "", lon, lat, cityCode)
|
||||
val loc = CallerChassisLocationWGS84ListenerManager.getChassisLocationWGS84()
|
||||
val cityCode = CallerMapUIServiceManager.getCityCode() ?: "0734"
|
||||
getNetWorkApi(HostConst.getNDEHost()).getCrossDevice(Md5Util.getMD5Result(md5String), time, "", loc.longitude, loc.latitude, "0734")
|
||||
}
|
||||
}
|
||||
onSuccess {
|
||||
@@ -72,14 +75,15 @@ class TravelRealityModel private constructor() {
|
||||
/**
|
||||
* 智慧路口路网范围
|
||||
*/
|
||||
fun getCityRoadRange(lon: Double, lat: Double, cityCode: String?,
|
||||
onSuccess: ((List<List<Double>?>?) -> Unit), onError: ((String) -> Unit)) {
|
||||
fun getCityRoadRange(onSuccess: ((List<List<Double>?>?) -> Unit), onError: ((String) -> Unit)) {
|
||||
request<BaseResponse<List<List<Double>?>?>>{
|
||||
loader {
|
||||
apiCall{
|
||||
val time = System.currentTimeMillis().toString()
|
||||
val md5String = "${CITY_ROAD_RANGE.uppercase(Locale.getDefault())}$time"
|
||||
getNetWorkApi(HostConst.getNDEHost()).getCityRoadRange(Md5Util.getMD5Result(md5String), time, lon, lat, cityCode)
|
||||
val loc = CallerChassisLocationWGS84ListenerManager.getChassisLocationWGS84()
|
||||
val cityCode = CallerMapUIServiceManager.getCityCode() ?: "0734"
|
||||
getNetWorkApi(HostConst.getNDEHost()).getCityRoadRange(Md5Util.getMD5Result(md5String), time, loc.longitude, loc.latitude, "0734")
|
||||
}
|
||||
}
|
||||
onSuccess {
|
||||
@@ -94,14 +98,15 @@ class TravelRealityModel private constructor() {
|
||||
/**
|
||||
* 智慧道路轨迹
|
||||
*/
|
||||
fun getCityRoadTrack(lon: Double, lat: Double, cityCode: String?,
|
||||
onSuccess: ((List<List<List<Double>?>?>?) -> Unit), onError: ((String) -> Unit)) {
|
||||
fun getCityRoadTrack(onSuccess: ((List<List<List<Double>?>?>?) -> Unit), onError: ((String) -> Unit)) {
|
||||
request<BaseResponse<List<List<List<Double>?>?>?>>{
|
||||
loader {
|
||||
apiCall{
|
||||
val time = System.currentTimeMillis().toString()
|
||||
val md5String = "${CITY_ROAD_TRACK.uppercase(Locale.getDefault())}$time"
|
||||
getNetWorkApi(HostConst.getNDEHost()).getCityRoadTrack(Md5Util.getMD5Result(md5String), time, lon, lat, cityCode)
|
||||
val loc = CallerChassisLocationWGS84ListenerManager.getChassisLocationWGS84()
|
||||
val cityCode = CallerMapUIServiceManager.getCityCode() ?: "0734"
|
||||
getNetWorkApi(HostConst.getNDEHost()).getCityRoadTrack(Md5Util.getMD5Result(md5String), time, loc.longitude, loc.latitude, "0734")
|
||||
}
|
||||
}
|
||||
onSuccess {
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Binary file not shown.
|
Before Width: | Height: | Size: 3.3 KiB |
@@ -60,6 +60,8 @@
|
||||
<attr name="compassDrawable" />
|
||||
<!-- 智慧道路范围纹理 -->
|
||||
<attr name="roadRangeDrawable" format="reference" />
|
||||
<attr name="globalPathColor" format="color" />
|
||||
<attr name="roadTrajectoryColor" format="color" />
|
||||
<!-- 起点图片 -->
|
||||
<attr name="startPointDrawable" />
|
||||
<!-- 终点图片 -->
|
||||
|
||||
@@ -2,7 +2,7 @@ package com.mogo.eagle.core.data.road
|
||||
|
||||
//路侧直播视频流返回数据
|
||||
data class RoadCameraLive(
|
||||
val ip:String, // ip
|
||||
val liveUrl:String, // 直播地址
|
||||
val imageUrl:String // 首帧封面地址
|
||||
val ip:String?, // ip
|
||||
val liveUrl:String?, // 直播地址
|
||||
val imageUrl:String? // 首帧封面地址
|
||||
)
|
||||
@@ -24,6 +24,7 @@ object CallerTelematicListenerManager: CallerBase<IReceivedMsgListener>() {
|
||||
try {
|
||||
listener.onReceivedMsg(type, byteArray)
|
||||
} catch (e: Exception) {
|
||||
e.printStackTrace()
|
||||
Log.e(TAG, "转发消息出现异常:${e.message}")
|
||||
}
|
||||
}
|
||||
@@ -36,6 +37,7 @@ object CallerTelematicListenerManager: CallerBase<IReceivedMsgListener>() {
|
||||
try {
|
||||
listener.onReceivedServerSn(sn)
|
||||
} catch (e: Exception) {
|
||||
e.printStackTrace()
|
||||
Log.e(TAG, "转发司机屏SN出现异常:${e.message}")
|
||||
}
|
||||
}
|
||||
@@ -49,6 +51,7 @@ object CallerTelematicListenerManager: CallerBase<IReceivedMsgListener>() {
|
||||
try {
|
||||
listener.onDemoMode(isDemoMode)
|
||||
} catch (e: Exception) {
|
||||
e.printStackTrace()
|
||||
Log.e(TAG, "转发美化模式出现异常:${e.message}")
|
||||
}
|
||||
}
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 2.5 KiB |
Reference in New Issue
Block a user