Commit 4ad0cf15 by jason

新增供應商閃退bug

parent 679817da
......@@ -140,20 +140,24 @@ public class NewSupplierPresenter extends BasePresenter<NewSupplierContract.Mode
MultiInputBean price= new MultiInputBean(InfoMultiBean.ITEM_TYPE_INPUT, "最低採購金額", false, "請輸入最低金額", new InputFilter[]{InputFilterUtils.getLengthFilter(mContext, 9)}, EditorInfo.TYPE_CLASS_NUMBER | EditorInfo.TYPE_NUMBER_FLAG_DECIMAL);
con.setOnFocusChangeListener((v, hasFocus) -> {
if (hasFocus && TextUtil.isNotEmptyOrNullOrUndefined(supplierBean.getContactInformation())) {
supplierBean.setContactInformation("");
infoMultiBeans.get(telephoneIndex).setShowValue("");
infoMultiAdapter.notifyItemChanged(telephoneIndex);
if (supplierBean != null) {
if (hasFocus && TextUtil.isNotEmptyOrNullOrUndefined(supplierBean.getContactInformation())) {
supplierBean.setContactInformation("");
infoMultiBeans.get(telephoneIndex).setShowValue("");
infoMultiAdapter.notifyItemChanged(telephoneIndex);
}
}
});
price.setOnFocusChangeListener((v, hasFocus) -> {
String minimumAmount = infoMultiBeans.get(lowPurchaseAmount).getShowValue();
if (hasFocus && TextUtil.isNotEmptyOrNullOrUndefined(minimumAmount)) {
supplierBean.setMinimumAmount(0d);
infoMultiBeans.get(lowPurchaseAmount).setShowValue("");
infoMultiAdapter.notifyItemChanged(lowPurchaseAmount);
if (supplierBean != null) {
String minimumAmount = infoMultiBeans.get(lowPurchaseAmount).getShowValue();
if (hasFocus && TextUtil.isNotEmptyOrNullOrUndefined(minimumAmount)) {
supplierBean.setMinimumAmount(0d);
infoMultiBeans.get(lowPurchaseAmount).setShowValue("");
infoMultiAdapter.notifyItemChanged(lowPurchaseAmount);
}
}
});
infoMultiBeans.add(con);
infoMultiBeans.add(price);
......
......@@ -55,7 +55,7 @@ public class InputProvider<T extends InfoMultiBean> extends MyBaseItemProvider<T
baseViewHolder.setVisible(R.id.tv_expect,true);
baseViewHolder.setText(R.id.tv_expect,infoMultiBean.getHint());
}else {
baseViewHolder.setGone(R.id.tv_expect,false);
baseViewHolder.setGone(R.id.tv_expect,true);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment