From 736c73ea11ba4406e77b73ba574a5834a55cc074 Mon Sep 17 00:00:00 2001 From: lijia Date: Tue, 17 Dec 2024 09:11:30 +0800 Subject: [PATCH] =?UTF-8?q?onstart=E5=88=B7=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ui/home/HomeFragment.java | 26 +++++++++++-------- 1 file changed, 15 insertions(+), 11 deletions(-) diff --git a/app/src/main/java/com/arpa/hndahesudintocctmsdriver/ui/home/HomeFragment.java b/app/src/main/java/com/arpa/hndahesudintocctmsdriver/ui/home/HomeFragment.java index ccfb3be..24ddba3 100644 --- a/app/src/main/java/com/arpa/hndahesudintocctmsdriver/ui/home/HomeFragment.java +++ b/app/src/main/java/com/arpa/hndahesudintocctmsdriver/ui/home/HomeFragment.java @@ -460,6 +460,7 @@ public class HomeFragment extends BaseFragment { }); btn_update.setOnClickListener(v -> { getRequest(); + refreshWaybills(); }); home_top.setOnClickListener(v -> { if (!UiAuxiliary.isLogin(con)) { @@ -520,6 +521,7 @@ public class HomeFragment extends BaseFragment { Log.e("下拉刷新", "pps"); keys = true; getRequest(); + refreshWaybills(); }); } @@ -784,6 +786,7 @@ public class HomeFragment extends BaseFragment { */ public void initMap() { getRequest(); + refreshWaybills(); } private CustomDialog customDialog; @@ -796,18 +799,18 @@ public class HomeFragment extends BaseFragment { // customDialog=new CustomDialog(con,"加载中..."); // customDialog.show(); ur.upApp(); - hyr.getHuoYuan(1, 100); +// hyr.getHuoYuan(1, 100); ur.getImage(1); WalletRequest qr = new WalletRequest(con, hd); if (UiAuxiliary.isLogin(con)) { - int curWaybillId = (int) SPUtils.get(con, "curWaybillId", -1); +// int curWaybillId = (int) SPUtils.get(con, "curWaybillId", -1); ur.User(); // if (!OneDayShowUtils.getInstance().todayIsShow(con)) { // qr.getBankCardList(); // } ur.getDriverExpire(); - hyr.startOrder(curWaybillId == -1 ? 0 : curWaybillId); +// hyr.startOrder(curWaybillId == -1 ? 0 : curWaybillId); // hyr.startOrder(0); //获取权限 应用市场审核不通过 ur.driverAuthData(); @@ -1177,6 +1180,7 @@ public class HomeFragment extends BaseFragment { .permissions(Manifest.permission.WRITE_EXTERNAL_STORAGE, Manifest.permission.READ_EXTERNAL_STORAGE, Manifest.permission.ACCESS_FINE_LOCATION, + Manifest.permission.ACCESS_BACKGROUND_LOCATION, Manifest.permission.CAMERA, Manifest.permission.ACCESS_COARSE_LOCATION) .request((allGranted, grantedList, deniedList) -> { @@ -1315,14 +1319,14 @@ public class HomeFragment extends BaseFragment { @Subscribe public void processResult(HomeWaybillEvent home) { - if (home.getMessage() == 1) { - int curWaybillId = (int) SPUtils.get(con, "curWaybillId", -1); - hyr.startOrder(curWaybillId == -1 ? 0 : curWaybillId); - hyr.getHuoYuan(1, 100); - } else { - int curWaybillId = (int) SPUtils.get(con, "curWaybillId", -1); - hyr.startOrder(curWaybillId == -1 ? 0 : curWaybillId); - } +// if (home.getMessage() == 1) { +// int curWaybillId = (int) SPUtils.get(con, "curWaybillId", -1); +// hyr.startOrder(curWaybillId == -1 ? 0 : curWaybillId); +// hyr.getHuoYuan(1, 100); +// } else { +// int curWaybillId = (int) SPUtils.get(con, "curWaybillId", -1); +// hyr.startOrder(curWaybillId == -1 ? 0 : curWaybillId); +// } }