|
@@ -167,12 +167,17 @@ public class FzQzFkActivity extends ZkjcBaseActivity<FzQzFkPresenter> implements
|
|
TextView tvFksmCount;
|
|
TextView tvFksmCount;
|
|
@BindView(R.id.tv_jg_bt)
|
|
@BindView(R.id.tv_jg_bt)
|
|
TextView tvJgBt;
|
|
TextView tvJgBt;
|
|
|
|
+ @BindView(R.id.tv_xz_bt)
|
|
|
|
+ TextView tvXzBt;
|
|
|
|
+ @BindView(R.id.tv_dz_bt)
|
|
|
|
+ TextView tvDzBt;
|
|
@BindView(R.id.layout_jmjg)
|
|
@BindView(R.id.layout_jmjg)
|
|
View layoutJmjg;
|
|
View layoutJmjg;
|
|
@BindView(R.id.layout_wfjmfj)
|
|
@BindView(R.id.layout_wfjmfj)
|
|
View layoutWfjmfj;
|
|
View layoutWfjmfj;
|
|
@BindView(R.id.iv_delete)
|
|
@BindView(R.id.iv_delete)
|
|
View ivDelete;
|
|
View ivDelete;
|
|
|
|
+
|
|
private DictionaryPicker mSjszxxPicker;
|
|
private DictionaryPicker mSjszxxPicker;
|
|
private PickerResult mSjszxxResult;
|
|
private PickerResult mSjszxxResult;
|
|
private DictionaryPicker mZplxPicker;
|
|
private DictionaryPicker mZplxPicker;
|
|
@@ -197,6 +202,7 @@ public class FzQzFkActivity extends ZkjcBaseActivity<FzQzFkPresenter> implements
|
|
private String mPictureString;
|
|
private String mPictureString;
|
|
private AreaPicker mXzqhPick;
|
|
private AreaPicker mXzqhPick;
|
|
private Area mXzqhResult;
|
|
private Area mXzqhResult;
|
|
|
|
+ private String mFileName;
|
|
|
|
|
|
@Override
|
|
@Override
|
|
public void setupActivityComponent(@NonNull AppComponent appComponent) {
|
|
public void setupActivityComponent(@NonNull AppComponent appComponent) {
|
|
@@ -233,6 +239,9 @@ public class FzQzFkActivity extends ZkjcBaseActivity<FzQzFkPresenter> implements
|
|
layoutMore.setVisibility(View.VISIBLE);
|
|
layoutMore.setVisibility(View.VISIBLE);
|
|
// tvJgBt.setVisibility(View.VISIBLE);
|
|
// tvJgBt.setVisibility(View.VISIBLE);
|
|
layoutJmjg.setVisibility(View.VISIBLE);
|
|
layoutJmjg.setVisibility(View.VISIBLE);
|
|
|
|
+ if (getIntent().getBooleanExtra("is_zjyj", false)) {
|
|
|
|
+ tvJgBt.setVisibility(View.VISIBLE);
|
|
|
|
+ }
|
|
}
|
|
}
|
|
mZd = (DictionaryEntity.Dictionary) getIntent().getSerializableExtra("data");
|
|
mZd = (DictionaryEntity.Dictionary) getIntent().getSerializableExtra("data");
|
|
setData(mZd);
|
|
setData(mZd);
|
|
@@ -291,7 +300,7 @@ public class FzQzFkActivity extends ZkjcBaseActivity<FzQzFkPresenter> implements
|
|
public void afterTextChanged(Editable s) {
|
|
public void afterTextChanged(Editable s) {
|
|
if (s != null) {
|
|
if (s != null) {
|
|
if (s.length() > 200) {
|
|
if (s.length() > 200) {
|
|
- s.delete(2000, s.length());
|
|
|
|
|
|
+ s.delete(200, s.length());
|
|
ToastUtils.show("超过最大输入字符");
|
|
ToastUtils.show("超过最大输入字符");
|
|
}
|
|
}
|
|
tvFksmCount.setText(s.length() + "");
|
|
tvFksmCount.setText(s.length() + "");
|
|
@@ -434,6 +443,13 @@ public class FzQzFkActivity extends ZkjcBaseActivity<FzQzFkPresenter> implements
|
|
} else {
|
|
} else {
|
|
layoutWfjmfj.setVisibility(View.GONE);
|
|
layoutWfjmfj.setVisibility(View.GONE);
|
|
}
|
|
}
|
|
|
|
+ if ("1".equals(mJmjgResult.getLv1Id())) {
|
|
|
|
+ tvDzBt.setVisibility(View.VISIBLE);
|
|
|
|
+ tvXzBt.setVisibility(View.VISIBLE);
|
|
|
|
+ } else {
|
|
|
|
+ tvDzBt.setVisibility(View.GONE);
|
|
|
|
+ tvXzBt.setVisibility(View.GONE);
|
|
|
|
+ }
|
|
tvJmjg.setText(mJmjgResult.getLv1Value());
|
|
tvJmjg.setText(mJmjgResult.getLv1Value());
|
|
});
|
|
});
|
|
}
|
|
}
|
|
@@ -482,15 +498,12 @@ public class FzQzFkActivity extends ZkjcBaseActivity<FzQzFkPresenter> implements
|
|
try {
|
|
try {
|
|
Map<String, Object> map = new HashMap<>();
|
|
Map<String, Object> map = new HashMap<>();
|
|
map.put("warnNumber", getIntent().getStringExtra("warnNumber"));
|
|
map.put("warnNumber", getIntent().getStringExtra("warnNumber"));
|
|
|
|
+ map.put("syncId", getIntent().getStringExtra("syncId"));
|
|
if (isMj) {
|
|
if (isMj) {
|
|
if (mJmjgResult == null) {
|
|
if (mJmjgResult == null) {
|
|
ToastUtils.show("请选择见面结果");
|
|
ToastUtils.show("请选择见面结果");
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
- if (TextUtils.isEmpty(tvJmdz.getText())) {
|
|
|
|
- ToastUtils.show("请填写见面地址");
|
|
|
|
- return;
|
|
|
|
- }
|
|
|
|
if ("3".equals(mJmjgResult.getLv1Id())) {
|
|
if ("3".equals(mJmjgResult.getLv1Id())) {
|
|
if (TextUtils.isEmpty(mPictureString)) {
|
|
if (TextUtils.isEmpty(mPictureString)) {
|
|
ToastUtils.show("请上传无法见面附件");
|
|
ToastUtils.show("请上传无法见面附件");
|
|
@@ -498,7 +511,13 @@ public class FzQzFkActivity extends ZkjcBaseActivity<FzQzFkPresenter> implements
|
|
} else {
|
|
} else {
|
|
Wfjmfj wfjmfj = new Wfjmfj();
|
|
Wfjmfj wfjmfj = new Wfjmfj();
|
|
wfjmfj.setWarnNumber(getIntent().getStringExtra("warnNumber"));
|
|
wfjmfj.setWarnNumber(getIntent().getStringExtra("warnNumber"));
|
|
|
|
+ wfjmfj.setSyncId(getIntent().getStringExtra("syncId"));
|
|
wfjmfj.setFile(mPictureString);
|
|
wfjmfj.setFile(mPictureString);
|
|
|
|
+ if (!TextUtils.isEmpty(mFileName)) {
|
|
|
|
+ String[] split = mFileName.split("\\.");
|
|
|
|
+ wfjmfj.setFileName(split[0]);
|
|
|
|
+ wfjmfj.setFileSuffix(split[1]);
|
|
|
|
+ }
|
|
map.put("fj", wfjmfj);
|
|
map.put("fj", wfjmfj);
|
|
}
|
|
}
|
|
|
|
|
|
@@ -613,6 +632,7 @@ public class FzQzFkActivity extends ZkjcBaseActivity<FzQzFkPresenter> implements
|
|
|
|
|
|
mPresenter.submit(map);
|
|
mPresenter.submit(map);
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
|
|
+ e.printStackTrace();
|
|
ToastUtils.show("数据不完整,请填写完稍后再点击");
|
|
ToastUtils.show("数据不完整,请填写完稍后再点击");
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -644,6 +664,15 @@ public class FzQzFkActivity extends ZkjcBaseActivity<FzQzFkPresenter> implements
|
|
switchSmyj.setVisibility(View.VISIBLE);
|
|
switchSmyj.setVisibility(View.VISIBLE);
|
|
switchSmyj.setChecked(false);
|
|
switchSmyj.setChecked(false);
|
|
layoutXsmyj.setVisibility(View.GONE);
|
|
layoutXsmyj.setVisibility(View.GONE);
|
|
|
|
+ if (getIntent().getBooleanExtra("is_zjyj", false)) {
|
|
|
|
+ switchSmyj.setVisibility(View.GONE);
|
|
|
|
+ switchSmyj.setChecked(true);
|
|
|
|
+ layoutXsmyj.setVisibility(View.VISIBLE);
|
|
|
|
+ } else {
|
|
|
|
+ switchSmyj.setVisibility(View.VISIBLE);
|
|
|
|
+ switchSmyj.setChecked(false);
|
|
|
|
+ layoutXsmyj.setVisibility(View.GONE);
|
|
|
|
+ }
|
|
break;
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -684,8 +713,10 @@ public class FzQzFkActivity extends ZkjcBaseActivity<FzQzFkPresenter> implements
|
|
ArrayList<ImageItem> images = (ArrayList<ImageItem>) data.getSerializableExtra(ImagePicker.EXTRA_RESULT_ITEMS);
|
|
ArrayList<ImageItem> images = (ArrayList<ImageItem>) data.getSerializableExtra(ImagePicker.EXTRA_RESULT_ITEMS);
|
|
if (images != null && !images.isEmpty()) {
|
|
if (images != null && !images.isEmpty()) {
|
|
ImageItem mItem = images.get(0);
|
|
ImageItem mItem = images.get(0);
|
|
-
|
|
|
|
- mPictureString = BitmapUtils.fileToBase64(new File(mItem.path));
|
|
|
|
|
|
+ File file = new File(mItem.path);
|
|
|
|
+ Log.e("eee", "name ====== " + file.getName());
|
|
|
|
+ mPictureString = BitmapUtils.fileToBase64(file);
|
|
|
|
+ mFileName = file.getName();
|
|
ivCamera.setVisibility(View.VISIBLE);
|
|
ivCamera.setVisibility(View.VISIBLE);
|
|
ivDelete.setVisibility(View.VISIBLE);
|
|
ivDelete.setVisibility(View.VISIBLE);
|
|
|
|
|