Commit 1a88fe65c462426b8a443d413d44ad8dd1aaa275

Authored by 韩亚云
1 parent 80aaf211

轨迹检查接口修改

moudle_pedometer/src/main/java/com/cnlive/moudle/collectionTrace/frame/presenter/RaceNameListPresenter.java
... ... @@ -172,7 +172,7 @@ public class RaceNameListPresenter extends MvpBasePresenter<RaceNameListView> {
172 172 if (getView() != null) {
173 173 QMUITipDialogUtil.dismessDialog();
174 174 if (null != callBack) {
175   - callBack.onSuccess(baseInfo.getData().getFenceId(), baseInfo.getData().getEntityName());
  175 + callBack.onSuccess(baseInfo.getData().getFenceId(), baseInfo.getData().getEntityName(),baseInfo.getData().getIsDelete());
176 176 }
177 177 }
178 178 }
... ... @@ -180,7 +180,7 @@ public class RaceNameListPresenter extends MvpBasePresenter<RaceNameListView> {
180 180 }
181 181  
182 182 public interface CallBack {
183   - void onSuccess(String fenceId, String entityName);
  183 + void onSuccess(String fenceId, String entityName,String isDelete);
184 184  
185 185 void onFailed();
186 186 }
... ...
moudle_pedometer/src/main/java/com/cnlive/moudle/collectionTrace/frame/view/RaceNameListView.java
... ... @@ -169,10 +169,15 @@ public class RaceNameListView implements MvpView, OnFenceListener {
169 169 //先校验
170 170 fragment.getPresenter().checkShoeLine(fragment.getActivity(), eventShoeLinesBean.getId(), eventShoeLinesBean.getEventId(), new RaceNameListPresenter.CallBack() {
171 171 @Override
172   - public void onSuccess(String fenceId, String entityName) {
  172 + public void onSuccess(String fenceId, String entityName,String isDelete) {
173 173 if (null == fragment.getActivity()) {
174 174 return;
175 175 }
  176 + if(isDelete != null && isDelete.equals("1")){
  177 + delectShoeLine(position);
  178 + AlertUtil.showDeftToast(fragment.getActivity(),"该轨迹已被删除");
  179 + return;
  180 + }
176 181 //判断是否为空
177 182 if (!TextUtils.isEmpty(fenceId) && !TextUtils.isEmpty(entityName)) {
178 183 List<Long> fenceIdList = new ArrayList<>();
... ...
moudle_pedometer/src/main/java/com/cnlive/moudle/collectionTrace/model/CheckShoeLineBean.java
... ... @@ -14,6 +14,7 @@ public class CheckShoeLineBean {
14 14  
15 15 private String fenceId;
16 16 private String entityName;
  17 + private String isDelete;
17 18  
18 19 public String getFenceId() {
19 20 return fenceId;
... ... @@ -30,4 +31,12 @@ public class CheckShoeLineBean {
30 31 public void setEntityName(String entityName) {
31 32 this.entityName = entityName;
32 33 }
  34 +
  35 + public String getIsDelete() {
  36 + return isDelete;
  37 + }
  38 +
  39 + public void setIsDelete(String isDelete) {
  40 + this.isDelete = isDelete;
  41 + }
33 42 }
... ...