Commit f2c586c31770f9537040a051c90d60c908883953
1 parent
0291de48
1 修复进行中活动跳转排行榜错误问题
Showing
4 changed files
with
15 additions
and
6 deletions
config.gradle
moudle_pedometer/src/main/java/com/cnlive/moudle/pedometer/frame/view/OnGoingFragmentView.java
| ... | ... | @@ -23,6 +23,7 @@ import com.baidu.mapapi.search.route.RoutePlanSearch; |
| 23 | 23 | import com.baidu.mapapi.utils.DistanceUtil; |
| 24 | 24 | import com.baidu.trace.LBSTraceClient; |
| 25 | 25 | import com.baidu.trace.model.SortType; |
| 26 | +import com.cnlive.libs.base.application.AppConfig; | |
| 26 | 27 | import com.cnlive.libs.base.util.StatusBarUtil2; |
| 27 | 28 | import com.cnlive.moudle.pedometer.commonInfo.CommonInfo; |
| 28 | 29 | import com.cnlive.moudle.pedometer.model.Constant; |
| ... | ... | @@ -363,9 +364,10 @@ public class OnGoingFragmentView implements MvpView { |
| 363 | 364 | fragment.binding.includeRank.tvCatAllRank.setOnClickListener(new View.OnClickListener() { |
| 364 | 365 | @Override |
| 365 | 366 | public void onClick(View view) { |
| 367 | + String baseWebUrl = AppConfig.isDebug() ? "http://wjjh5test.cnlive.com/cnSportListOver.html" : "http://wjjh5.cnlive.com/cnSportListOver.html"; | |
| 366 | 368 | ARouter.getInstance().build("/web/WebViewColorActivity") |
| 367 | - .withString("url", "http://wjjh5test.cnlive.com/cnSportList.html" + "?sid=" + CommonInfo.getUserId(fragment.getActivity()) + "&eventId=" + CommonInfo.getStreetId(fragment.getActivity())) | |
| 368 | - .withString("title", "排行榜") | |
| 369 | + .withString("url", baseWebUrl + "?sid=" + CommonInfo.getUserId(fragment.getActivity()) + "&eventId=" + fragment.eventId) | |
| 370 | + .withString("title", "总排行榜") | |
| 369 | 371 | .navigation(fragment.getActivity()); |
| 370 | 372 | } |
| 371 | 373 | }); | ... | ... |
moudle_pedometer/src/main/java/com/cnlive/moudle/pedometer/ui/adapter/MyRecordAdapter.java
| ... | ... | @@ -95,10 +95,17 @@ public class MyRecordAdapter extends RecyclerView.Adapter<MyRecordAdapter.MyView |
| 95 | 95 | } |
| 96 | 96 | |
| 97 | 97 | private void toRaking(String eventId){ |
| 98 | - String baseWebUrl = AppConfig.isDebug() ? "http://wjjh5test.cnlive.com/cnSportListOver.html" : "http://wjjh5.cnlive.com/cnSportListOver.html"; | |
| 98 | + String baseWebUrl,title; | |
| 99 | + if(state.equals("0")){ | |
| 100 | + title = "排行榜"; | |
| 101 | + baseWebUrl = AppConfig.isDebug() ? "http://wjjh5test.cnlive.com/cnSportList.html" : "http://wjjh5.cnlive.com/cnSportList.html"; | |
| 102 | + }else { | |
| 103 | + title = "总排行榜"; | |
| 104 | + baseWebUrl = AppConfig.isDebug() ? "http://wjjh5test.cnlive.com/cnSportListOver.html" : "http://wjjh5.cnlive.com/cnSportListOver.html"; | |
| 105 | + } | |
| 99 | 106 | ARouter.getInstance().build("/web/WebViewColorActivity") |
| 100 | 107 | .withString("url", baseWebUrl +"?sid="+CommonInfo.getUserId(context)+"&eventId="+eventId) |
| 101 | - .withString("title","总排行榜") | |
| 108 | + .withString("title",title) | |
| 102 | 109 | .navigation(context); |
| 103 | 110 | } |
| 104 | 111 | ... | ... |
moudle_pedometer/src/main/java/com/cnlive/moudle/pedometer/ui/fragment/OnGoingFragment.java
| ... | ... | @@ -15,7 +15,7 @@ import com.example.moudle_pedometer.databinding.FragmentRunRaceDetailBinding; |
| 15 | 15 | import com.qmuiteam.qmui.util.QMUIStatusBarHelper; |
| 16 | 16 | |
| 17 | 17 | public class OnGoingFragment extends QMUIFragment<OnGoingFragmentView, OnGoingFragmentPresenter, FragmentRunRaceDetailBinding> { |
| 18 | - private String eventId; | |
| 18 | + public String eventId; | |
| 19 | 19 | |
| 20 | 20 | public static OnGoingFragment newInstance(String eventId) { |
| 21 | 21 | OnGoingFragment fragment = new OnGoingFragment(); | ... | ... |