编辑排程状态
This commit is contained in:
@@ -31,6 +31,7 @@ public class AddWaterPlanActivity extends BaseActivity<AddWaterPlanLayoutBinding
|
|||||||
private List<Fragment> mFragmentList = new ArrayList<>();
|
private List<Fragment> mFragmentList = new ArrayList<>();
|
||||||
private boolean mIsEditMode = false;
|
private boolean mIsEditMode = false;
|
||||||
private WaterPlanWeekEntity mEditEntity;
|
private WaterPlanWeekEntity mEditEntity;
|
||||||
|
private WaterPlanWeekEntity mNewAddEntity;
|
||||||
// private List<WaterPlanWeekEntity.DeviceEntity> mSelectedDevices = new ArrayList<>();
|
// private List<WaterPlanWeekEntity.DeviceEntity> mSelectedDevices = new ArrayList<>();
|
||||||
//
|
//
|
||||||
// public List<WaterPlanWeekEntity.DeviceEntity> getSelectedDevices() {
|
// public List<WaterPlanWeekEntity.DeviceEntity> getSelectedDevices() {
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
package com.ckkj.water.plan;
|
package com.ckkj.water.plan;
|
||||||
|
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
|
import android.os.Handler;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
|
|
||||||
import com.chad.library.adapter.base.BaseQuickAdapter;
|
import com.chad.library.adapter.base.BaseQuickAdapter;
|
||||||
@@ -48,6 +49,9 @@ public class BindDeviceFragment extends BaseFragment<PlanBindDeviceLayoutBinding
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
if (mPlanEntity != null) {
|
||||||
|
mPresenter.getPlanBindDevices(mPlanEntity);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void initListener() {
|
private void initListener() {
|
||||||
@@ -86,9 +90,7 @@ public class BindDeviceFragment extends BaseFragment<PlanBindDeviceLayoutBinding
|
|||||||
@Override
|
@Override
|
||||||
protected void onResumeInitData() {
|
protected void onResumeInitData() {
|
||||||
super.onResumeInitData();
|
super.onResumeInitData();
|
||||||
if (mPlanEntity != null) {
|
|
||||||
mPresenter.getPlanBindDevices(mPlanEntity);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -119,7 +121,16 @@ public class BindDeviceFragment extends BaseFragment<PlanBindDeviceLayoutBinding
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void planBindDeviceSuccess(BaseBean bean) {
|
public void planBindDeviceSuccess(BaseBean bean) {
|
||||||
|
hideDialogLoading();
|
||||||
|
ToastUtil.showShort(mContext, "绑定成功");
|
||||||
|
new Handler().postDelayed(new Runnable() {
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
if (getActivity() instanceof AddWaterPlanActivity) {
|
||||||
|
((AddWaterPlanActivity) getActivity()).finish();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},800);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
Reference in New Issue
Block a user