parent
0daa867f65
commit
9ef0b232e6
|
@ -76,7 +76,13 @@ public class PayBillApiSavePlugin implements ApiSavePlugin {
|
|||
}
|
||||
|
||||
if ("bd_supplier".equals(payeetype) || "bd_customer".equals(payeetype)) {
|
||||
// BusinessDataServiceHelper.load(payeetype, "id,number,name,societycreditcode",)
|
||||
DynamicObject[] objects = BusinessDataServiceHelper.load(payeetype.toString(), "id,number,name,societycreditcode", new QFilter("societycreditcode", QCP.equals, map.get("payeenumber").toString()).toArray());
|
||||
map.put("payeenumber", objects[0].getString("number"));
|
||||
//收款人编码
|
||||
objectNumber = objects[0].getString("number");
|
||||
} else {
|
||||
//收款人编码
|
||||
objectNumber = map.get("payeenumber").toString();
|
||||
}
|
||||
|
||||
|
||||
|
@ -84,11 +90,8 @@ public class PayBillApiSavePlugin implements ApiSavePlugin {
|
|||
//收款人类型
|
||||
objectType = payeetype.toString();
|
||||
if (!"other".equals(objectType)) {
|
||||
//收款人编码
|
||||
objectNumber = map.get("payeenumber").toString();
|
||||
//收款人ID
|
||||
fieldName1 = "payee";
|
||||
|
||||
Map<String, Object> payeebankObj = (Map<String, Object>) map.get("payeebank");
|
||||
bankNumber = (String) payeebankObj.get("number");
|
||||
logger.info("付款处理 → \nobjectType:{}\nobjectNumber:{}\nbankNumber:{}", objectType, objectNumber, bankNumber);
|
||||
|
@ -136,12 +139,21 @@ public class PayBillApiSavePlugin implements ApiSavePlugin {
|
|||
map.put("payertype", "other");
|
||||
map.put("payerformid", "other");
|
||||
}
|
||||
|
||||
if ("bd_supplier".equals(payertype) || "bd_customer".equals(payertype)) {
|
||||
DynamicObject[] objects = BusinessDataServiceHelper.load(payertype.toString(), "id,number,name,societycreditcode", new QFilter("societycreditcode", QCP.equals, map.get("payernumber").toString()).toArray());
|
||||
map.put("payernumber", objects[0].getString("number"));
|
||||
//收款人编码
|
||||
objectNumber = objects[0].getString("number");
|
||||
} else {
|
||||
//收款人编码
|
||||
objectNumber = map.get("payernumber").toString();
|
||||
}
|
||||
|
||||
objectType = payertype.toString();
|
||||
if (!"other".equals(objectType)) {
|
||||
objectNumber = map.get("payernumber").toString();
|
||||
fieldName1 = "payer";
|
||||
|
||||
|
||||
Map<String, Object> accountbank = (Map<String, Object>) map.get("accountbank");
|
||||
bankNumber = (String) accountbank.get("number");
|
||||
logger.info("收款处理 → \nobjectType:{}\nobjectNumber:{}\nbankNumber:{}", objectType, objectNumber, bankNumber);
|
||||
|
|
Loading…
Reference in New Issue