parent
ffd8fae545
commit
d876933b50
|
|
@ -52,6 +52,7 @@ public class PayBillSubmitOperation extends AbstractOperationServicePlugIn imple
|
|||
if (jsonObject.getIntValue("code") != 0) {
|
||||
String message = jsonObject.getString("msg");
|
||||
this.addErrorMessage(entity,"SAP校验未通过不能提交:"+message);
|
||||
return;
|
||||
}else{
|
||||
bill.set("shjh_sapvalidate", true);
|
||||
SaveServiceHelper.save(new DynamicObject[]{bill});
|
||||
|
|
@ -63,10 +64,10 @@ public class PayBillSubmitOperation extends AbstractOperationServicePlugIn imple
|
|||
if (jsonObject.getIntValue("code") != 0) {
|
||||
String message = jsonObject.getString("message");
|
||||
this.addErrorMessage(entity,"费控校验未通过不能提交:"+message);
|
||||
return;
|
||||
}else{
|
||||
//根据返回信息比对
|
||||
JSONObject data = jsonObject.getJSONObject("data");
|
||||
Boolean isMatch = true;
|
||||
if (null != data) {
|
||||
JSONArray tempData1 = data.getJSONArray("tempData");
|
||||
if (!tempData1.isEmpty()) {
|
||||
|
|
@ -79,13 +80,13 @@ public class PayBillSubmitOperation extends AbstractOperationServicePlugIn imple
|
|||
int comparisonResult = applyAmountBigDecimal.compareTo(actpayamt);
|
||||
if (comparisonResult != 0) {
|
||||
this.addErrorMessage(entity,"费控校验未通过不能提交:付款金额与付款单付款金额不一致");
|
||||
isMatch = false;
|
||||
return;
|
||||
}
|
||||
String assacct = tempData.getString("assacct");//收款银行账号_payeebanknum
|
||||
String payeebanknum = bill.getString("payeebanknum");
|
||||
if (!assacct.equals(payeebanknum)) {
|
||||
this.addErrorMessage(entity,"费控校验未通过不能提交:收款银行账号与付款单银行账号不一致");
|
||||
isMatch = false;
|
||||
return;
|
||||
}
|
||||
String bebank = tempData.getString("bebank");//收款银行名称_payeebankname
|
||||
String payeebankname = bill.getString("payeebankname");
|
||||
|
|
@ -97,15 +98,17 @@ public class PayBillSubmitOperation extends AbstractOperationServicePlugIn imple
|
|||
String recbanknumber = bill.getString("recbanknumber");
|
||||
if (!bebankNum.equals(recbanknumber)) {
|
||||
this.addErrorMessage(entity,"费控校验未通过不能提交:收款联行号与付款单联行号不一致");
|
||||
isMatch = false;
|
||||
return;
|
||||
}
|
||||
}
|
||||
}else {
|
||||
this.addErrorMessage(entity,"费控校验未通过不能提交:tempData为空");
|
||||
isMatch = false;
|
||||
return;
|
||||
}
|
||||
}else {
|
||||
this.addErrorMessage(entity,"费控校验未通过不能提交:data为空");
|
||||
return;
|
||||
}
|
||||
if (isMatch) {
|
||||
bill.set("shjh_fkvalidate", true);
|
||||
SaveServiceHelper.save(new DynamicObject[]{bill});
|
||||
}
|
||||
|
|
@ -113,7 +116,6 @@ public class PayBillSubmitOperation extends AbstractOperationServicePlugIn imple
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue