[Upload]
移除分享上报模块依赖,代码保留 Signed-off-by: donghongyu <donghongyu@zhidaoauto.com>
This commit is contained in:
@@ -410,11 +410,6 @@ object V2XEventManager : IMoGoMapLocationListener, IMoGoTokenCallback, IV2XCallb
|
||||
// 存储本地,出行动态作展示
|
||||
saveLocalStory(V2XTypeEnum.ALERT_ROAD_WARNING, v2XRoadEventEntity.noveltyInfo)
|
||||
|
||||
//如果poiType是道路拥堵,则调用接口查询拥堵状态
|
||||
val poiType = v2XRoadEventEntity.poiType
|
||||
if (poiType != null && poiType == FOURS_BLOCK_UP.poiType) {
|
||||
BridgeApi.trafficUpload()?.verifyCurrentTrafficStatus()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -193,8 +193,9 @@ public class V2XShareEventAdapter extends RecyclerView.Adapter<RecyclerView.View
|
||||
|
||||
TextView share = itemView.findViewById(R.id.share_event_button);
|
||||
share.setOnClickListener(view -> {
|
||||
V2XEventPanelFragment.Companion.getInstance().hidePanel();
|
||||
mApis.getShareManager().showShareDialog();
|
||||
// TODO
|
||||
// V2XEventPanelFragment.Companion.getInstance().hidePanel();
|
||||
// mApis.getShareManager().showShareDialog();
|
||||
});
|
||||
|
||||
TextView refresh = itemView.findViewById(R.id.refresh_button);
|
||||
|
||||
@@ -11,7 +11,6 @@ import android.widget.TextView;
|
||||
|
||||
import com.mogo.commons.voice.AIAssist;
|
||||
import com.mogo.commons.voice.IMogoVoiceCmdCallBack;
|
||||
import com.mogo.eagle.core.data.map.MogoLatLng;
|
||||
import com.mogo.eagle.core.function.v2x.R;
|
||||
import com.mogo.eagle.core.function.v2x.events.bridge.BridgeApi;
|
||||
import com.mogo.eagle.core.function.v2x.events.consts.V2XConst;
|
||||
@@ -27,8 +26,6 @@ import com.mogo.module.common.entity.V2XRoadEventEntity;
|
||||
import com.mogo.module.common.enums.EventTypeEnum;
|
||||
import com.mogo.module.v2x.voice.V2XVoiceManager;
|
||||
import com.mogo.service.analytics.IMogoAnalytics;
|
||||
import com.mogo.service.share.IMogoTanluProvider;
|
||||
import com.mogo.service.share.TanluUploadParams;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
@@ -181,19 +178,19 @@ public class V2XEventUgcVH extends V2XBaseViewHolder<V2XEventShowEntity> {
|
||||
unRegisterVoice();
|
||||
|
||||
if (status == 1) {
|
||||
// 上报事故
|
||||
TanluUploadParams params =
|
||||
new TanluUploadParams(
|
||||
mNoveltyInfo.getPoiType(),
|
||||
IMogoTanluProvider.UPLOAD_FROM_STRATEGY_UGC,
|
||||
mNoveltyInfo.getInfoIdInt(),
|
||||
new MogoLatLng(mNoveltyInfo.getLocation().getLat(),
|
||||
mNoveltyInfo.getLocation().getLon())
|
||||
);
|
||||
IMogoTanluProvider tanlu = BridgeApi.INSTANCE.tanlu();
|
||||
if (tanlu != null) {
|
||||
tanlu.uploadRoadCondition(params);
|
||||
}
|
||||
// // 上报事故
|
||||
// TanluUploadParams params =
|
||||
// new TanluUploadParams(
|
||||
// mNoveltyInfo.getPoiType(),
|
||||
// IMogoTanluProvider.UPLOAD_FROM_STRATEGY_UGC,
|
||||
// mNoveltyInfo.getInfoIdInt(),
|
||||
// new MogoLatLng(mNoveltyInfo.getLocation().getLat(),
|
||||
// mNoveltyInfo.getLocation().getLon())
|
||||
// );
|
||||
// IMogoTanluProvider tanlu = BridgeApi.INSTANCE.tanlu();
|
||||
// if (tanlu != null) {
|
||||
// tanlu.uploadRoadCondition(params);
|
||||
// }
|
||||
dataStatistics(1);
|
||||
} else if (status == 0) {
|
||||
dataStatistics(2);
|
||||
|
||||
@@ -106,8 +106,6 @@ internal object BridgeApi {
|
||||
|
||||
fun windowManager() = apis?.windowManagerApi
|
||||
|
||||
fun tanlu() = apis?.tanluApi
|
||||
|
||||
fun displayEffects() = apis?.displayEffectsManager
|
||||
|
||||
fun intentManager() = apis?.intentManagerApi
|
||||
@@ -116,9 +114,5 @@ internal object BridgeApi {
|
||||
|
||||
fun locationClient() = apis?.mapServiceApi?.getSingletonLocationClient(context())
|
||||
|
||||
fun share() = apis?.shareManager
|
||||
|
||||
fun markerService() = apis?.markerService
|
||||
|
||||
fun trafficUpload() = apis?.trafficUploadApi
|
||||
}
|
||||
@@ -4,33 +4,31 @@ import android.annotation.SuppressLint
|
||||
import android.content.Context
|
||||
import android.util.Log
|
||||
import android.view.View
|
||||
import com.mogo.eagle.core.function.v2x.events.bridge.BridgeApi.share
|
||||
import com.mogo.eagle.core.function.v2x.events.fragment.V2XEventPanelFragment.Companion.getInstance
|
||||
import com.mogo.eagle.core.function.v2x.events.bridge.BridgeApi.v2xStatus
|
||||
import com.mogo.commons.mvp.MvpFragment
|
||||
import com.mogo.eagle.core.function.v2x.events.fragment.presenter.ScenarioHistoryPresenter
|
||||
import androidx.lifecycle.lifecycleScope
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.mogo.eagle.core.function.v2x.events.adapter.V2XScenarioHistoryAdapter
|
||||
import com.mogo.module.common.entity.V2XHistoryScenarioData
|
||||
import com.mogo.eagle.core.function.v2x.events.manager.IMoGoV2XStatusChangedListener
|
||||
import com.mogo.module.common.view.SpacesItemDecoration
|
||||
import com.mogo.eagle.core.function.v2x.events.view.V2XListEmptyView.OnControlListener
|
||||
import com.mogo.eagle.core.function.v2x.events.manager.V2XStatusDescriptor
|
||||
import com.mogo.eagle.core.function.v2x.events.utils.V2XUtils
|
||||
import com.mogo.commons.mvp.MvpFragment
|
||||
import com.mogo.commons.voice.AIAssist
|
||||
import com.mogo.eagle.core.function.v2x.R.dimen
|
||||
import com.mogo.eagle.core.function.v2x.R.layout
|
||||
import com.mogo.eagle.core.function.v2x.events.adapter.V2XScenarioHistoryAdapter
|
||||
import com.mogo.eagle.core.function.v2x.events.bridge.BridgeApi.v2xStatus
|
||||
import com.mogo.eagle.core.function.v2x.events.fragment.presenter.ScenarioHistoryPresenter
|
||||
import com.mogo.eagle.core.function.v2x.events.manager.IMoGoV2XStatusChangedListener
|
||||
import com.mogo.eagle.core.function.v2x.events.manager.V2XStatusDescriptor
|
||||
import com.mogo.eagle.core.function.v2x.events.manager.V2XStatusDescriptor.EventPanelWindow_UI
|
||||
import com.mogo.eagle.core.function.v2x.events.utils.V2XSQLiteUtils
|
||||
import com.mogo.eagle.core.function.v2x.events.utils.V2XUtils
|
||||
import com.mogo.eagle.core.function.v2x.events.view.V2XListEmptyView.OnControlListener
|
||||
import com.mogo.eagle.core.network.utils.GsonUtil
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.Logger
|
||||
import com.mogo.eagle.core.utilcode.util.ThreadUtils
|
||||
import com.mogo.eagle.core.utilcode.util.Utils
|
||||
import com.mogo.module.common.entity.V2XHistoryScenarioData
|
||||
import com.mogo.module.common.view.SpacesItemDecoration
|
||||
import kotlinx.android.synthetic.main.module_v2x_event_panel_fragment_scenario_history.*
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.launch
|
||||
import java.util.ArrayList
|
||||
import java.util.*
|
||||
|
||||
/**
|
||||
* 出行动态,V2X 提示过的场景历史
|
||||
@@ -71,11 +69,12 @@ class V2XScenarioHistoryFragment : MvpFragment<V2XScenarioHistoryFragment?, Scen
|
||||
private fun initListener() {
|
||||
viewEmpty.setOnControlListener(object : OnControlListener {
|
||||
override fun onShearClick() {
|
||||
val share = share()
|
||||
if (share != null) {
|
||||
share.showShareDialog()
|
||||
getInstance().hidePanel()
|
||||
}
|
||||
// TODO
|
||||
// val share = share()
|
||||
// if (share != null) {
|
||||
// share.showShareDialog()
|
||||
// getInstance().hidePanel()
|
||||
// }
|
||||
}
|
||||
|
||||
override fun onRefreshClick() {}
|
||||
|
||||
@@ -156,9 +156,10 @@ public class V2XSurroundingFragment extends MvpFragment<SurroundingEventView, Su
|
||||
if (id == R.id.tv_main_share) {
|
||||
//弹出框面板消失,出现分享弹框
|
||||
V2XEventPanelFragment.Companion.getInstance().hidePanel();
|
||||
if (mApis != null && mApis.getShareManager() != null) {
|
||||
mApis.getShareManager().showShareDialog();
|
||||
}
|
||||
// TODO
|
||||
// if (mApis != null && mApis.getShareManager() != null) {
|
||||
// mApis.getShareManager().showShareDialog();
|
||||
// }
|
||||
} else if (id == R.id.tv_main_refresh || id == R.id.tv_top_refresh) { //刷新
|
||||
initData();
|
||||
}
|
||||
|
||||
@@ -20,7 +20,6 @@ import com.mogo.module.common.entity.MarkerExploreWay;
|
||||
import com.mogo.module.common.entity.V2XMessageEntity;
|
||||
import com.mogo.module.common.entity.V2XPushMessageEntity;
|
||||
import com.mogo.module.common.entity.V2XRoadEventEntity;
|
||||
import com.mogo.service.share.IMogoTrafficUploadProvider;
|
||||
import com.mogo.service.statusmanager.IMogoStatusManager;
|
||||
import com.zhidao.carchattingprovider.ICarsChattingProvider;
|
||||
import com.zhidao.carchattingprovider.MogoDriverInfo;
|
||||
@@ -151,12 +150,6 @@ public class TestPanelBroadcastReceiver extends BroadcastReceiver {
|
||||
Intent intent = new Intent(V2XConst.BROADCAST_SCENE_HANDLER_ACTION);
|
||||
intent.putExtra(V2XConst.BROADCAST_SCENE_EXTRA_KEY, messageEntity);
|
||||
LocalBroadcastManager.getInstance(mContext).sendBroadcast(intent);
|
||||
} else if (sceneType == 15) {// 交通状况查询
|
||||
|
||||
IMogoTrafficUploadProvider provider = BridgeApi.INSTANCE.trafficUpload();
|
||||
if (provider != null) {
|
||||
provider.verifyCurrentTrafficStatus();
|
||||
}
|
||||
} /*else if (sceneType == 16) {//触发基于目的地预测的线路推荐
|
||||
V2XRefreshModel model = BridgeApi.INSTANCE.refreshModel();
|
||||
model.
|
||||
|
||||
Reference in New Issue
Block a user