From 40f9ac00ec5e4d6363450d1c8e0b0937cc0b1de4 Mon Sep 17 00:00:00 2001 From: liugl <liugl@sinata.cn> Date: 星期四, 14 一月 2021 10:50:18 +0800 Subject: [PATCH] 1。4:处理预约单导致串单的问题 隐藏预约单 --- app/src/main/java/com/okgoincar/slab/MySlabBaseActivity.java | 40 ++++++++++++++++++++++------------------ 1 files changed, 22 insertions(+), 18 deletions(-) diff --git a/app/src/main/java/com/okgoincar/slab/MySlabBaseActivity.java b/app/src/main/java/com/okgoincar/slab/MySlabBaseActivity.java index afecbb2..00cf734 100644 --- a/app/src/main/java/com/okgoincar/slab/MySlabBaseActivity.java +++ b/app/src/main/java/com/okgoincar/slab/MySlabBaseActivity.java @@ -37,6 +37,7 @@ import com.okgoincar.slab.util.UiUtil; import com.okgoincar.utils.ActivityCollector; import com.okgoincar.utils.EasePopup.EasyPopup; +import com.okgoincar.utils.MyUtils; import org.greenrobot.eventbus.EventBus; import org.greenrobot.eventbus.Subscribe; @@ -84,6 +85,7 @@ protected void onCreate(@Nullable Bundle savedInstanceState) { super.onCreate(savedInstanceState); initParam(); + MyUtils.getInstans().keepScreenLongLight(this,true); EventBus.getDefault().register(this); ActivityCollector.addActivity(this, getClass()); ActivityCollector.getActivityCollector().addActivity(this); @@ -105,6 +107,7 @@ protected void onNetworkConnected(NetUtils.NetType type) { super.onNetworkConnected(type); if (NetUtils.isNetworkConnected(MyApplication.Companion.getInstance())) { + toast("网络重新通畅"); MoneyBroadCastReceiver.Companion.callErrorOrder(this); } } @@ -154,11 +157,11 @@ } - - public void toDorderAct(String orderId, String orderType){ + public void toDorderAct(String orderId, String orderType) { + MyApplication.Companion.getTTsManager().setVideoText("OK出行,有一条新的订单"); Intent intent = new Intent(this, SlabTripActivity.class); - intent.putExtra("orderId",orderId); - intent.putExtra("orderType",orderType); + intent.putExtra("orderId", orderId); + intent.putExtra("orderType", orderType); startActivity(intent); } @@ -169,21 +172,22 @@ * @param time * @param type */ - public void showOrder(String orderId, String orderType,int time,int type) { - UtilKtKt.calldetailOrderIsYy(this, orderId, orderType, b -> { - if (b){ - Intent intent = new Intent(MySlabBaseActivity.this,SlabGetOrderFragment.class); - intent.putExtra("orderId",orderId); - intent.putExtra("orderType",orderType); - intent.putExtra("time",time); - intent.putExtra("type",type); - startActivity(intent); - }else { -// toast("收到预约单"); - } - }); - } + public void showOrder(String orderId, String orderType, int time, int type) { +// UtilKtKt.calldetailOrderIsYy(this, orderId, orderType, b -> { +// if (b) { + MyApplication.Companion.getTTsManager().setVideoText("OK出行,有一条新的订单"); + Intent intent = new Intent(MySlabBaseActivity.this, SlabGetOrderFragment.class); + intent.putExtra("orderId", orderId); + intent.putExtra("orderType", orderType); + intent.putExtra("time", time); + intent.putExtra("type", type); + startActivity(intent); +// } else { +// toast("收到预约单"); +// } +// }); + } @Override -- Gitblit v1.7.1