Commit aca42adf93fd48dbbc24821a07500a989c3c2270

Authored by 韩亚云
1 parent f0088f9c

个人记录页面修改,接口修改

moudle_pedometer/build.gradle
... ... @@ -74,6 +74,7 @@ dependencies {
74 74 implementation "com.github.bumptech.glide:glide:$rootProject.glide"
75 75 implementation "jp.wasabeef:glide-transformations:$rootProject.glideTransformations"
76 76 implementation 'com.android.support.constraint:constraint-layout:1.1.3'
  77 + implementation 'com.android.support:support-v4:28.0.0'
77 78 annotationProcessor "com.github.bumptech.glide:compiler:$rootProject.compiler"
78 79  
79 80 //--------------------------------------------------------
... ...
moudle_pedometer/src/main/AndroidManifest.xml
... ... @@ -52,7 +52,8 @@
52 52 android:required="true" />
53 53  
54 54 <application android:persistent="true">
55   - <activity android:name="com.cnlive.moudle.pedometer.ui.activity.SelfRecordActivity"></activity>
  55 + <activity android:name="com.cnlive.moudle.pedometer.ui.activity.LineUpAgainActivity"></activity>
  56 + <activity android:name="com.cnlive.moudle.pedometer.ui.activity.SelfRecordActivity" />
56 57 <activity android:name="com.cnlive.moudle.pedometer.ui.activity.TakePartActivity" />
57 58 <activity android:name="com.cnlive.moudle.pedometer.ui.activity.RunLineActivity" />
58 59 <activity android:name="com.cnlive.moudle.pedometer.ui.activity.MyRecordActivity" />
... ... @@ -93,7 +94,6 @@
93 94 <action android:name="android.service.notification.NotificationListenerService" />
94 95 </intent-filter>
95 96 </service>
96   -
97 97 <service
98 98 android:name="com.cnlive.moudle.pedometer.service.KeepLiveService"
99 99 android:enabled="true"
... ... @@ -125,9 +125,7 @@
125 125 android:process=":step" />
126 126 <activity
127 127 android:name="com.cnlive.moudle.pedometer.ui.activity.RunningFinishActivity"
128   - android:process=":step" />
129   -
130   - <!--路径工具-->
  128 + android:process=":step" /> <!-- 路径工具 -->
131 129 <activity
132 130 android:name="com.cnlive.moudle.collectionTrace.ui.activity.CollPedometerMainActivity"
133 131 android:launchMode="singleTask"
... ...
moudle_pedometer/src/main/java/com/cnlive/moudle/pedometer/frame/presenter/SelfRecordPresenter.java
... ... @@ -24,9 +24,10 @@ import io.reactivex.disposables.Disposable;
24 24 public class SelfRecordPresenter extends MvpBasePresenter<SelfRecordView> {
25 25  
26 26  
27   - public void getData(Context context,String sid, int pageNo, int pageSize){
  27 + public void getData(Context context,String sid,int completeStatus, int pageNo, int pageSize){
28 28 HashMap<String, String> map = new HashMap<>();
29 29 map.put("sid", sid);
  30 + map.put("completeStatus",completeStatus+"");
30 31 map.put("pageNo", pageNo+"");
31 32 map.put("pageSize",pageSize+"");
32 33 getView().showLoading();
... ...
moudle_pedometer/src/main/java/com/cnlive/moudle/pedometer/frame/view/SelfRecordView.java
... ... @@ -11,6 +11,7 @@ import com.cnlive.moudle.pedometer.model.RunningFinishBean;
11 11 import com.cnlive.moudle.pedometer.net.bean.BaseInfo;
12 12 import com.cnlive.moudle.pedometer.net.bean.EventRouteRecordBeanVoListBean;
13 13 import com.cnlive.moudle.pedometer.net.bean.SelfRecordInfo;
  14 +import com.cnlive.moudle.pedometer.ui.activity.LineUpAgainActivity;
14 15 import com.cnlive.moudle.pedometer.ui.activity.RunLineActivity;
15 16 import com.cnlive.moudle.pedometer.ui.adapter.RaceRecordAdapter;
16 17 import com.cnlive.moudle.pedometer.ui.fragment.SelfRecordFragment;
... ... @@ -26,13 +27,14 @@ import java.util.List;
26 27 /**
27 28 * Created by hanyayun 019/06/12.
28 29 */
29   -public class SelfRecordView implements MvpView{
  30 +public class SelfRecordView implements MvpView {
30 31  
31 32 private SelfRecordFragment fragment;
32 33 public QMUITipDialog loadingDiaog;
33 34 private List<EventRouteRecordBeanVoListBean> list = new ArrayList<>();
34 35 private RaceRecordAdapter adapter;
35 36  
  37 +
36 38 public SelfRecordView(SelfRecordFragment fragment) {
37 39 this.fragment = fragment;
38 40 loadingDiaog = new QMUITipDialog.Builder(fragment.getActivity())
... ... @@ -41,59 +43,57 @@ public class SelfRecordView implements MvpView{
41 43 .create();
42 44 }
43 45  
44   - public void setData(BaseInfo<SelfRecordInfo> selfRecordInfoBaseInfo){
  46 + public void setData(BaseInfo<SelfRecordInfo> selfRecordInfoBaseInfo) {
45 47 hideLoading();
46 48 fragment.binding.ryRecord.setVisibility(View.VISIBLE);
47 49 fragment.binding.txAll.setVisibility(View.VISIBLE);
48   - if(selfRecordInfoBaseInfo.getData().getRecordSum() == null){
  50 + if (selfRecordInfoBaseInfo.getData().getRecordSum() == null) {
49 51 showEmpty();
50 52 return;
51 53 }
52 54  
53   - if(fragment.currentPage == 1){
  55 + if (fragment.currentPage == 1) {
54 56 list.clear();
55 57 list.addAll(selfRecordInfoBaseInfo.getData().getEventRouteRecordBeanVoList());
56   - if(adapter == null){
57   - SelfRecordInfo.RecordSumBean recordSumBean = selfRecordInfoBaseInfo.getData().getRecordSum();
58   - fragment.binding.kilometerNum.setText(recordSumBean.getMileage()+"");
59   - fragment.binding.stepNum.setText(recordSumBean.getStep());
60   - fragment.binding.allTime.setText(recordSumBean.getEmployTime());
61   - fragment.binding.finishNum.setText(recordSumBean.getNumber());
  58 + if (adapter == null) {
  59 + SelfRecordInfo.RecordSumBean recordSumBean = selfRecordInfoBaseInfo.getData().getRecordSum();
  60 + fragment.binding.kilometerNum.setText(recordSumBean.getCountMileage() + "");
  61 + fragment.binding.stepNum.setText(recordSumBean.getYetStep());
  62 + fragment.binding.allTime.setText(recordSumBean.getYetEmployTime());
  63 + fragment.binding.finishNum.setText(recordSumBean.getYetNumber());
  64 +
  65 + fragment.binding.stepNumNo.setText(recordSumBean.getNotStep());
  66 + fragment.binding.allTimeNo.setText(recordSumBean.getNotEmployTime());
  67 + fragment.binding.finishNumNo.setText(recordSumBean.getNotNumber());
  68 +
62 69 fragment.binding.recordRecy.setLayoutManager(new LinearLayoutManager(fragment.getActivity()));
63   - adapter = new RaceRecordAdapter(list,fragment.getActivity());
  70 + adapter = new RaceRecordAdapter(list, fragment.getActivity());
64 71 fragment.binding.recordRecy.setAdapter(adapter);
65 72 adapter.setOnClickListener(new RaceRecordAdapter.OnClickListener() {
66 73 @Override
67 74 public void onClickListener(EventRouteRecordBeanVoListBean bean, int position) {
68   - CollRunningFinishActivity.startActivity(fragment.getActivity(),new RunningFinishBean());
  75 + CollRunningFinishActivity.startActivity(fragment.getActivity(), new RunningFinishBean());
69 76 }
70 77 });
71   -// fragment.binding.topbar.addRightImageButton(R.drawable.share_img, R.id.fragment_more)
72   -// .setOnClickListener(v -> {
73   -// //分享
74   -//// ShareRecordActivity.newInstance(fragment.getActivity(),fragment.raceTitle,bestResultBean.getMileage(),bestResultBean.getStep(),
75   -//// bestResultBean.getEmployTime(),bestResultBean.getPace());
76   -// });
77   -
78   - }else {
  78 + } else {
79 79 adapter.notifyDataSetChanged();
80 80 }
81 81 }
82 82  
83   - if(list.size() != 0){
  83 + if (list.size() != 0) {
84 84 fragment.binding.emptyNet.setVisibility(View.GONE);
85 85 fragment.binding.empty.setVisibility(View.GONE);
86 86 fragment.binding.refreshLayout.setVisibility(View.VISIBLE);
87   - }else {
  87 + } else {
88 88 showEmpty();
89 89 }
90 90  
91   - if(selfRecordInfoBaseInfo.getData().getEventRouteRecordBeanVoList().size() < fragment.pageSize){
  91 + if (selfRecordInfoBaseInfo.getData().getEventRouteRecordBeanVoList().size() < fragment.pageSize) {
92 92 fragment.binding.refreshLayout.setEnableLoadMore(false);
93   - }else {
  93 + } else {
94 94 fragment.binding.refreshLayout.setEnableLoadMore(true);
95 95 }
96   - if(fragment.currentPage > 1){
  96 + if (fragment.currentPage > 1) {
97 97 list.addAll(selfRecordInfoBaseInfo.getData().getEventRouteRecordBeanVoList());
98 98 adapter.notifyDataSetChanged();
99 99 }
... ... @@ -101,18 +101,16 @@ public class SelfRecordView implements MvpView{
101 101 fragment.binding.refreshLayout.finishLoadMore();
102 102 }
103 103  
104   - public void initView(){
105   - fragment.binding.topbar.addLeftImageButton(R.drawable.top_back_black, R.id.fragment_back).setOnClickListener(v -> {
106   - fragment.getActivity().finish();
107   - });
108   - fragment.binding.topbar.setTitle("我的记录");
  104 + public void initView() {
  105 + fragment.binding.back.setOnClickListener(v -> fragment.getActivity().finish());
109 106 fragment.binding.refreshLayout.setRefreshHeader(new ClassicsHeader(fragment.getActivity()));
110 107 fragment.binding.refreshLayout.setRefreshFooter(new ClassicsFooter(fragment.getActivity()));
111 108 fragment.binding.recordRecy.setLayoutManager(new LinearLayoutManager(fragment.getActivity()));
  109 + fragment.binding.againUp.setOnClickListener(v -> LineUpAgainActivity.newInstance(fragment.getActivity()));
112 110 }
113 111  
114 112  
115   - public void showEmpty(){
  113 + public void showEmpty() {
116 114 fragment.binding.refreshLayout.setVisibility(View.GONE);
117 115 fragment.binding.empty.setVisibility(View.VISIBLE);
118 116 fragment.binding.emptyNet.setVisibility(View.GONE);
... ... @@ -126,7 +124,7 @@ public class SelfRecordView implements MvpView{
126 124 });
127 125 }
128 126  
129   - public void showError(String msg){
  127 + public void showError(String msg) {
130 128 fragment.binding.refreshLayout.finishRefresh();
131 129 fragment.binding.refreshLayout.finishLoadMore();
132 130 if (list.size() == 0) {
... ... @@ -141,7 +139,7 @@ public class SelfRecordView implements MvpView{
141 139 @Override
142 140 public void onClick(View v) {
143 141 fragment.currentPage = 1;
144   - fragment.getPresenter().getData(fragment.getActivity(),"10514343",fragment.currentPage,fragment.pageSize);
  142 + fragment.getPresenter().getData(fragment.getActivity(), "10514343", fragment.completeStatus, fragment.currentPage, fragment.pageSize);
145 143 }
146 144 });
147 145 fragment.binding.emptyNet.setLoadingShowing(false);
... ...
moudle_pedometer/src/main/java/com/cnlive/moudle/pedometer/net/bean/SelfRecordInfo.java
... ... @@ -8,19 +8,19 @@ import java.util.List;
8 8 public class SelfRecordInfo {
9 9  
10 10 /**
11   - * recordSum : {"number":5,"employTime":0,"step":50000,"mileage":25.5}
  11 + * RecordSum : {"yetEmployTime":"30.0","yetNumber":"30.0","yetStep":"10000.0","yetMileage":"5.0","notNumber":"10000.0","notMileage":"5.0","notEmployTime":"30.0","notStep":"10000.0","countMileage":101.7}
12 12 * eventRouteRecordBeanVoList : [{"createTime":1559722819000,"employTime":"30","eventTitle":"2018国际网络徒步大赛黄金海岸站","mileage":"5.5","pace":"22.33","recordId":2,"roadmap":"http://wjjtest.ys2.cnliveimg.com/802/img/2018/1205/ff80808166c2a45201677ce7aff652e9/000001.jpg","step":"10000"},{"createTime":1559722832000,"employTime":"00:0:55","eventTitle":"2018国际网络徒步大赛黄金海岸站","mileage":"5","pace":"22.33","recordId":3,"roadmap":"http://wjjtest.ys2.cnliveimg.com/802/img/2018/1205/ff80808166c2a45201677ce7aff652e9/000001.jpg","step":"10000"}]
13 13 */
14 14  
15   - private RecordSumBean recordSum;
  15 + private RecordSumBean RecordSum;
16 16 private List<EventRouteRecordBeanVoListBean> eventRouteRecordBeanVoList;
17 17  
18 18 public RecordSumBean getRecordSum() {
19   - return recordSum;
  19 + return RecordSum;
20 20 }
21 21  
22   - public void setRecordSum(RecordSumBean recordSum) {
23   - this.recordSum = recordSum;
  22 + public void setRecordSum(RecordSumBean RecordSum) {
  23 + this.RecordSum = RecordSum;
24 24 }
25 25  
26 26 public List<EventRouteRecordBeanVoListBean> getEventRouteRecordBeanVoList() {
... ... @@ -33,47 +33,97 @@ public class SelfRecordInfo {
33 33  
34 34 public static class RecordSumBean {
35 35 /**
36   - * number : 5
37   - * employTime : 0
38   - * step : 50000
39   - * mileage : 25.5
  36 + * yetEmployTime : 30.0
  37 + * yetNumber : 30.0
  38 + * yetStep : 10000.0
  39 + * yetMileage : 5.0
  40 + * notNumber : 10000.0
  41 + * notMileage : 5.0
  42 + * notEmployTime : 30.0
  43 + * notStep : 10000.0
  44 + * countMileage : 101.7
40 45 */
41 46  
42   - private int number;
43   - private int employTime;
44   - private int step;
45   - private double mileage;
  47 + private String yetEmployTime;
  48 + private String yetNumber;
  49 + private String yetStep;
  50 + private String yetMileage;
  51 + private String notNumber;
  52 + private String notMileage;
  53 + private String notEmployTime;
  54 + private String notStep;
  55 + private double countMileage;
  56 +
  57 + public String getYetEmployTime() {
  58 + return yetEmployTime;
  59 + }
  60 +
  61 + public void setYetEmployTime(String yetEmployTime) {
  62 + this.yetEmployTime = yetEmployTime;
  63 + }
  64 +
  65 + public String getYetNumber() {
  66 + return yetNumber;
  67 + }
  68 +
  69 + public void setYetNumber(String yetNumber) {
  70 + this.yetNumber = yetNumber;
  71 + }
  72 +
  73 + public String getYetStep() {
  74 + return yetStep;
  75 + }
  76 +
  77 + public void setYetStep(String yetStep) {
  78 + this.yetStep = yetStep;
  79 + }
  80 +
  81 + public String getYetMileage() {
  82 + return yetMileage;
  83 + }
  84 +
  85 + public void setYetMileage(String yetMileage) {
  86 + this.yetMileage = yetMileage;
  87 + }
  88 +
  89 + public String getNotNumber() {
  90 + return notNumber;
  91 + }
  92 +
  93 + public void setNotNumber(String notNumber) {
  94 + this.notNumber = notNumber;
  95 + }
46 96  
47   - public int getNumber() {
48   - return number;
  97 + public String getNotMileage() {
  98 + return notMileage;
49 99 }
50 100  
51   - public void setNumber(int number) {
52   - this.number = number;
  101 + public void setNotMileage(String notMileage) {
  102 + this.notMileage = notMileage;
53 103 }
54 104  
55   - public int getEmployTime() {
56   - return employTime;
  105 + public String getNotEmployTime() {
  106 + return notEmployTime;
57 107 }
58 108  
59   - public void setEmployTime(int employTime) {
60   - this.employTime = employTime;
  109 + public void setNotEmployTime(String notEmployTime) {
  110 + this.notEmployTime = notEmployTime;
61 111 }
62 112  
63   - public int getStep() {
64   - return step;
  113 + public String getNotStep() {
  114 + return notStep;
65 115 }
66 116  
67   - public void setStep(int step) {
68   - this.step = step;
  117 + public void setNotStep(String notStep) {
  118 + this.notStep = notStep;
69 119 }
70 120  
71   - public double getMileage() {
72   - return mileage;
  121 + public double getCountMileage() {
  122 + return countMileage;
73 123 }
74 124  
75   - public void setMileage(double mileage) {
76   - this.mileage = mileage;
  125 + public void setCountMileage(double countMileage) {
  126 + this.countMileage = countMileage;
77 127 }
78 128 }
79 129 }
... ...
moudle_pedometer/src/main/java/com/cnlive/moudle/pedometer/ui/activity/LineUpAgainActivity.java 0 → 100644
  1 +package com.cnlive.moudle.pedometer.ui.activity;
  2 +
  3 +import android.content.Context;
  4 +import android.content.Intent;
  5 +import android.support.v7.app.AppCompatActivity;
  6 +import android.os.Bundle;
  7 +
  8 +import com.cnlive.libs.base.util.StatusBarUtil;
  9 +import com.cnlive.libs.base.util.StatusBarUtil2;
  10 +import com.example.moudle_pedometer.R;
  11 +
  12 +/**
  13 + * 重新上传
  14 + * Created by hanyayun 019/06/20.
  15 + */
  16 +public class LineUpAgainActivity extends AppCompatActivity {
  17 +
  18 + public static void newInstance(Context context){
  19 + Intent intent = new Intent();
  20 + intent.setClass(context,LineUpAgainActivity.class);
  21 + context.startActivity(intent);
  22 + }
  23 +
  24 + @Override
  25 + protected void onCreate(Bundle savedInstanceState) {
  26 + super.onCreate(savedInstanceState);
  27 + StatusBarUtil.setStatusBarWrite(this);
  28 + StatusBarUtil2.setColor(this, getResources().getColor(R.color.color_fff), 0);
  29 + setContentView(R.layout.activity_line_up_again);
  30 + }
  31 +}
... ...
moudle_pedometer/src/main/java/com/cnlive/moudle/pedometer/ui/fragment/SelfRecordFragment.java
... ... @@ -23,6 +23,7 @@ public class SelfRecordFragment extends MvpBindingFragment&lt;SelfRecordView, SelfR
23 23  
24 24 public int currentPage = 1;
25 25 public int pageSize = 10;
  26 + public int completeStatus = 0;
26 27 public SelfRecordFragment() {
27 28 // Required empty public constructor
28 29 }
... ... @@ -32,23 +33,47 @@ public class SelfRecordFragment extends MvpBindingFragment&lt;SelfRecordView, SelfR
32 33 public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {
33 34 super.onViewCreated(view, savedInstanceState);
34 35 if(getMvpView() != null) getMvpView().initView();
35   - getPresenter().getData(getActivity(),"10514343",currentPage,pageSize);
  36 + getData(-1);
  37 +
  38 + binding.hasFinish.setOnClickListener(v -> getData(0));
  39 + binding.noFinish.setOnClickListener(v -> getData(1));
36 40 binding.refreshLayout.setOnRefreshListener(new OnRefreshListener() {
37 41 @Override
38 42 public void onRefresh(@NonNull RefreshLayout refreshLayout) {
39 43 currentPage = 1;
40   - getPresenter().getData(getActivity(),"10514343",currentPage,pageSize);
  44 + getData(-1);
41 45 }
42 46 });
43 47 binding.refreshLayout.setOnLoadMoreListener(new OnLoadMoreListener() {
44 48 @Override
45 49 public void onLoadMore(@NonNull RefreshLayout refreshLayout) {
46 50 currentPage++;
47   - getPresenter().getData(getActivity(),"10514343",currentPage,pageSize);
  51 + getData(-1);
48 52 }
49 53 });
50 54 }
51 55  
  56 + private void getData(int completeStatus){
  57 + if(completeStatus == -1){
  58 + getPresenter().getData(getActivity(),"10514343",completeStatus,currentPage,pageSize);
  59 + }else {
  60 + this.completeStatus = currentPage;
  61 + getPresenter().getData(getActivity(),"10514343",completeStatus,currentPage,pageSize);
  62 + if(completeStatus == 0){
  63 + binding.hasFinish.setTextColor(getActivity().getResources().getColor(R.color.green_tx));
  64 + binding.hasFinish.setTextSize(18);
  65 + binding.noFinish.setTextColor(getActivity().getResources().getColor(R.color.text_black));
  66 + binding.noFinish.setTextSize(15);
  67 + }else {
  68 + binding.hasFinish.setTextColor(getActivity().getResources().getColor(R.color.text_black));
  69 + binding.hasFinish.setTextSize(15);
  70 + binding.noFinish.setTextColor(getActivity().getResources().getColor(R.color.green_tx));
  71 + binding.noFinish.setTextSize(18);
  72 + }
  73 + }
  74 + }
  75 +
  76 +
52 77 @Override
53 78 protected int getLayoutId() {
54 79 return R.layout.fragment_self_record;
... ...
moudle_pedometer/src/main/res/layout/activity_line_up_again.xml 0 → 100644
  1 +<?xml version="1.0" encoding="utf-8"?>
  2 +<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3 + xmlns:app="http://schemas.android.com/apk/res-auto"
  4 + xmlns:tools="http://schemas.android.com/tools"
  5 + android:layout_width="match_parent"
  6 + android:layout_height="match_parent"
  7 + tools:context="com.cnlive.moudle.pedometer.ui.activity.LineUpAgainActivity">
  8 +
  9 +</android.support.constraint.ConstraintLayout>
... ...
moudle_pedometer/src/main/res/layout/fragment_self_record.xml
1   -<layout xmlns:android="http://schemas.android.com/apk/res/android">
  1 +<layout xmlns:android="http://schemas.android.com/apk/res/android"
  2 + xmlns:app="http://schemas.android.com/apk/res-auto">
2 3  
3 4 <LinearLayout
4 5 android:layout_width="match_parent"
... ... @@ -6,10 +7,40 @@
6 7 android:background="@color/white"
7 8 android:orientation="vertical">
8 9  
9   - <com.qmuiteam.qmui.widget.QMUITopBar
10   - android:id="@+id/topbar"
  10 + <RelativeLayout
11 11 android:layout_width="match_parent"
12   - android:layout_height="?attr/qmui_topbar_height" />
  12 + android:layout_height="?attr/qmui_topbar_height">
  13 +
  14 + <ImageView
  15 + android:id="@+id/back"
  16 + android:layout_width="wrap_content"
  17 + android:layout_height="wrap_content"
  18 + android:layout_centerVertical="true"
  19 + android:padding="10dp"
  20 + android:src="@drawable/top_back_black"/>
  21 +
  22 + <TextView
  23 + android:layout_width="wrap_content"
  24 + android:layout_height="wrap_content"
  25 + android:layout_centerVertical="true"
  26 + android:textColor="#333333"
  27 + android:textSize="18sp"
  28 + android:layout_centerInParent="true"
  29 + android:text="@string/myrecord"
  30 + />
  31 +
  32 + <TextView
  33 + android:id="@+id/again_up"
  34 + android:layout_width="wrap_content"
  35 + android:layout_height="wrap_content"
  36 + android:layout_centerVertical="true"
  37 + android:padding="10dp"
  38 + android:textColor="#333333"
  39 + android:textSize="15sp"
  40 + android:layout_alignParentRight="true"
  41 + android:text="@string/again_up"
  42 + />
  43 + </RelativeLayout>
13 44  
14 45 <RelativeLayout
15 46 android:id="@+id/ry_record"
... ... @@ -38,19 +69,19 @@
38 69 android:id="@+id/kilometer_num"
39 70 android:layout_width="wrap_content"
40 71 android:layout_height="wrap_content"
41   - android:layout_marginTop="20dp"
42 72 android:layout_centerHorizontal="true"
  73 + android:layout_marginTop="20dp"
43 74 android:text="0.0"
44 75 android:textColor="@color/white"
45   - android:textSize="50sp"
46   - />
  76 + android:textSize="50sp" />
47 77  
48 78 <RelativeLayout
  79 + android:id="@+id/ry_finish"
49 80 android:layout_width="match_parent"
50 81 android:layout_height="wrap_content"
51 82 android:layout_below="@id/kilometer_num"
52   - android:layout_marginTop="10dp"
53 83 android:layout_marginLeft="20dp"
  84 + android:layout_marginTop="10dp"
54 85 android:layout_marginRight="20dp">
55 86  
56 87 <LinearLayout
... ... @@ -61,10 +92,10 @@
61 92 <TextView
62 93 android:layout_width="wrap_content"
63 94 android:layout_height="wrap_content"
64   - android:text="@string/finish_num"
65   - android:textSize="12sp"
66 95 android:layout_gravity="center"
67   - android:textColor="@color/white" />
  96 + android:text="@string/finish_num"
  97 + android:textColor="@color/white"
  98 + android:textSize="12sp" />
68 99  
69 100 <TextView
70 101 android:id="@+id/finish_num"
... ... @@ -72,9 +103,9 @@
72 103 android:layout_height="wrap_content"
73 104 android:layout_gravity="center"
74 105 android:layout_marginTop="5dp"
75   - android:textSize="20sp"
76 106 android:text="0"
77   - android:textColor="@color/white" />
  107 + android:textColor="@color/white"
  108 + android:textSize="20sp" />
78 109 </LinearLayout>
79 110  
80 111  
... ... @@ -87,10 +118,10 @@
87 118 <TextView
88 119 android:layout_width="wrap_content"
89 120 android:layout_height="wrap_content"
90   - android:textSize="12sp"
91 121 android:layout_gravity="center"
92 122 android:text="@string/all_time"
93   - android:textColor="@color/white" />
  123 + android:textColor="@color/white"
  124 + android:textSize="12sp" />
94 125  
95 126 <TextView
96 127 android:id="@+id/all_time"
... ... @@ -98,9 +129,9 @@
98 129 android:layout_height="wrap_content"
99 130 android:layout_gravity="center"
100 131 android:layout_marginTop="5dp"
101   - android:textSize="20sp"
102 132 android:text="00:00:00"
103   - android:textColor="@color/white" />
  133 + android:textColor="@color/white"
  134 + android:textSize="20sp" />
104 135 </LinearLayout>
105 136  
106 137 <LinearLayout
... ... @@ -112,10 +143,10 @@
112 143 <TextView
113 144 android:layout_width="wrap_content"
114 145 android:layout_height="wrap_content"
115   - android:textSize="12sp"
116 146 android:layout_gravity="center"
117 147 android:text="@string/stepnum"
118   - android:textColor="@color/white" />
  148 + android:textColor="@color/white"
  149 + android:textSize="12sp" />
119 150  
120 151 <TextView
121 152 android:id="@+id/step_num"
... ... @@ -123,23 +154,138 @@
123 154 android:layout_height="wrap_content"
124 155 android:layout_gravity="center"
125 156 android:layout_marginTop="5dp"
126   - android:textSize="20sp"
127 157 android:text="--"
128   - android:textColor="@color/white" />
  158 + android:textColor="@color/white"
  159 + android:textSize="20sp" />
  160 + </LinearLayout>
  161 + </RelativeLayout>
  162 +
  163 + <RelativeLayout
  164 + android:layout_width="match_parent"
  165 + android:layout_height="wrap_content"
  166 + android:layout_below="@id/ry_finish"
  167 + android:layout_marginLeft="20dp"
  168 + android:layout_marginTop="10dp"
  169 + android:layout_marginRight="20dp">
  170 +
  171 + <LinearLayout
  172 + android:layout_width="wrap_content"
  173 + android:layout_height="wrap_content"
  174 + android:orientation="vertical">
  175 +
  176 + <TextView
  177 + android:layout_width="wrap_content"
  178 + android:layout_height="wrap_content"
  179 + android:layout_gravity="center"
  180 + android:text="@string/finish_num_no"
  181 + android:textColor="@color/white"
  182 + android:textSize="12sp" />
  183 +
  184 + <TextView
  185 + android:id="@+id/finish_num_no"
  186 + android:layout_width="wrap_content"
  187 + android:layout_height="wrap_content"
  188 + android:layout_gravity="center"
  189 + android:layout_marginTop="5dp"
  190 + android:text="0"
  191 + android:textColor="@color/white"
  192 + android:textSize="20sp" />
  193 + </LinearLayout>
  194 +
  195 +
  196 + <LinearLayout
  197 + android:layout_width="wrap_content"
  198 + android:layout_height="wrap_content"
  199 + android:layout_centerInParent="true"
  200 + android:orientation="vertical">
  201 +
  202 + <TextView
  203 + android:layout_width="wrap_content"
  204 + android:layout_height="wrap_content"
  205 + android:layout_gravity="center"
  206 + android:text="@string/all_time"
  207 + android:textColor="@color/white"
  208 + android:textSize="12sp" />
  209 +
  210 + <TextView
  211 + android:id="@+id/all_time_no"
  212 + android:layout_width="wrap_content"
  213 + android:layout_height="wrap_content"
  214 + android:layout_gravity="center"
  215 + android:layout_marginTop="5dp"
  216 + android:text="00:00:00"
  217 + android:textColor="@color/white"
  218 + android:textSize="20sp" />
  219 + </LinearLayout>
  220 +
  221 + <LinearLayout
  222 + android:layout_width="wrap_content"
  223 + android:layout_height="wrap_content"
  224 + android:layout_alignParentRight="true"
  225 + android:orientation="vertical">
  226 +
  227 + <TextView
  228 + android:layout_width="wrap_content"
  229 + android:layout_height="wrap_content"
  230 + android:layout_gravity="center"
  231 + android:text="@string/stepnum"
  232 + android:textColor="@color/white"
  233 + android:textSize="12sp" />
  234 +
  235 + <TextView
  236 + android:id="@+id/step_num_no"
  237 + android:layout_width="wrap_content"
  238 + android:layout_height="wrap_content"
  239 + android:layout_gravity="center"
  240 + android:layout_marginTop="5dp"
  241 + android:text="--"
  242 + android:textColor="@color/white"
  243 + android:textSize="20sp" />
129 244 </LinearLayout>
130 245 </RelativeLayout>
131 246  
132 247 </RelativeLayout>
133 248  
134   - <TextView
  249 + <RelativeLayout
135 250 android:id="@+id/tx_all"
136   - android:layout_width="wrap_content"
  251 + android:layout_width="match_parent"
137 252 android:layout_height="wrap_content"
138 253 android:layout_marginLeft="10dp"
139 254 android:layout_marginTop="10dp"
140   - android:textSize="18sp"
141   - android:textColor="#333333"
142   - android:text="@string/has_take_part_line" />
  255 + android:layout_marginRight="10dp">
  256 +
  257 + <TextView
  258 + android:layout_width="wrap_content"
  259 + android:layout_height="wrap_content"
  260 + android:text="@string/has_take_part_line"
  261 + android:textColor="#333333"
  262 + android:textSize="18sp" />
  263 +
  264 + <LinearLayout
  265 + android:layout_width="wrap_content"
  266 + android:layout_height="wrap_content"
  267 + android:layout_alignParentRight="true"
  268 + android:orientation="horizontal">
  269 +
  270 + <TextView
  271 + android:id="@+id/has_finish"
  272 + android:layout_width="wrap_content"
  273 + android:layout_height="wrap_content"
  274 + android:textSize="18sp"
  275 + android:textColor="#36C28D"
  276 + android:text="@string/finish" />
  277 +
  278 + <TextView
  279 + android:id="@+id/no_finish"
  280 + android:layout_width="wrap_content"
  281 + android:layout_height="wrap_content"
  282 + android:text="@string/no_finish"
  283 + android:layout_marginLeft="20dp"
  284 + android:textColor="#333333"
  285 + android:textSize="15sp"
  286 + />
  287 + </LinearLayout>
  288 + </RelativeLayout>
143 289  
144 290 <com.scwang.smartrefresh.layout.SmartRefreshLayout
145 291 android:id="@+id/refreshLayout"
... ... @@ -150,16 +296,16 @@
150 296 android:id="@+id/record_recy"
151 297 android:layout_width="match_parent"
152 298 android:layout_height="match_parent"
153   - android:padding="10dp"
154   - android:background="@color/white" />
  299 + android:background="@color/white"
  300 + android:padding="10dp" />
155 301 </com.scwang.smartrefresh.layout.SmartRefreshLayout>
156 302  
157 303 <RelativeLayout
158 304 android:id="@+id/empty"
159 305 android:layout_width="match_parent"
160 306 android:layout_height="match_parent"
161   - android:visibility="gone"
162   - android:background="@color/white">
  307 + android:background="@color/white"
  308 + android:visibility="gone">
163 309  
164 310 <LinearLayout
165 311 android:layout_width="wrap_content"
... ... @@ -175,28 +321,26 @@
175 321 <TextView
176 322 android:layout_width="wrap_content"
177 323 android:layout_height="wrap_content"
  324 + android:layout_gravity="center"
  325 + android:layout_marginTop="15dp"
178 326 android:text="还没有跑过的线路"
179 327 android:textColor="#333333"
180   - android:textSize="15sp"
181   - android:layout_marginTop="15dp"
182   - android:layout_gravity="center"
183   - />
  328 + android:textSize="15sp" />
184 329  
185 330 <TextView
186 331 android:id="@+id/check_all_line"
187 332 android:layout_width="wrap_content"
188 333 android:layout_height="wrap_content"
189 334 android:layout_gravity="center"
190   - android:text="@string/chek_all_line"
191 335 android:layout_marginTop="10dp"
192   - android:textSize="12sp"
193   - android:textColor="#36C28D"
194 336 android:background="@drawable/green_raduis_bg"
195   - android:paddingTop="5dp"
196   - android:paddingBottom="5dp"
197 337 android:paddingLeft="8dp"
  338 + android:paddingTop="5dp"
198 339 android:paddingRight="8dp"
199   - />
  340 + android:paddingBottom="5dp"
  341 + android:text="@string/chek_all_line"
  342 + android:textColor="#36C28D"
  343 + android:textSize="12sp" />
200 344 </LinearLayout>
201 345  
202 346 </RelativeLayout>
... ...
moudle_pedometer/src/main/res/values/colors.xml
... ... @@ -34,6 +34,7 @@
34 34 <color name="bottom_sheet_dialog_race_location_text">#999999</color>
35 35  
36 36 <color name="color_7cbd83">#7cbd83</color>
  37 + <color name="green_tx">#36C28D</color>
37 38 <color name="s_topbar_btn_color">#333333</color>
38 39  
39 40  
... ...
moudle_pedometer/src/main/res/values/strings.xml
... ... @@ -60,6 +60,7 @@
60 60 <string name="has_balence">累计步行距离</string>
61 61 <string name="Kilimanjaro">(公里)</string>
62 62 <string name="finish_num">完成(次)</string>
  63 + <string name="finish_num_no">未完成(次)</string>
63 64 <string name="all_time">累计用时</string>
64 65 <string name="has_take_part_line">我跑过的线路</string>
65 66 <string name="chek_all_line">查看全部路线</string>
... ... @@ -75,6 +76,10 @@
75 76 <string name="later_finish">天后结束</string>
76 77 <string name="layout_collect_bind_trace">绑定轨迹</string>
77 78 <string name="identify_the_start_point">确认开始地点</string>
  79 + <string name="finish">完成</string>
  80 + <string name="no_finish">未完成</string>
  81 + <string name="again_up">重新上传</string>
  82 + <string name="myrecord">我的记录</string>
78 83  
79 84  
80 85 </resources>
... ...