客户接口优化
This commit is contained in:
parent
553883a227
commit
e4719f1c44
|
|
@ -609,7 +609,7 @@ public class ClearAccountBillOperation extends AbstractOperationServicePlugIn im
|
|||
clear.put("DMBTR1",entryinfo.getBigDecimal("shjh_e_cursettle").abs());//清账金额--sap接收的正数金额
|
||||
IT_CLEAR.add(clear);
|
||||
}else{
|
||||
//将当前清账分录对象中的清账金额与clear对象合并
|
||||
//将当前清账分录对象中的清账金额与clear对象的金额相加
|
||||
clear.put("DMBTR1",JhzjUtils.addTwoAmount(clear.getBigDecimal("DMBTR1"),
|
||||
entryinfo.getBigDecimal("shjh_e_cursettle").abs()));
|
||||
}
|
||||
|
|
@ -659,7 +659,7 @@ public class ClearAccountBillOperation extends AbstractOperationServicePlugIn im
|
|||
}
|
||||
|
||||
private JSONObject getClearJsonObj(JSONArray IT_CLEAR, DynamicObject entryinfo){
|
||||
//根据清账单分录和json集合查找对应json对象
|
||||
//根据清账单分录和json集合查找对应json对象(凭证号、年度、凭证行号、科目都一样)
|
||||
JSONObject jsonobj;
|
||||
for (int i = 0; i < IT_CLEAR.size(); i++) {
|
||||
jsonobj = IT_CLEAR.getJSONObject(i);
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ public class RecBillSaveOperation extends AbstractOperationServicePlugIn impleme
|
|||
bill.set("payername", shjhCustomer.getString("name"));//付款人名称
|
||||
}
|
||||
}else {
|
||||
QFilter qFilter1 = new QFilter("number", QCP.equals, "4000042");
|
||||
QFilter qFilter1 = new QFilter("number", QCP.equals, "1042086");//4000042
|
||||
DynamicObject bdCustomer = BusinessDataServiceHelper.loadSingle("bd_customer", qFilter1.toArray());
|
||||
if (null != bdCustomer) {
|
||||
bill.set("payer", bdCustomer.getPkValue());//付款人id
|
||||
|
|
|
|||
|
|
@ -115,8 +115,8 @@ public class CustomerControler {
|
|||
currentCus.set("enable",1);//默认可用
|
||||
currentCus.set("type","1");//伙伴类型 默认法人企业
|
||||
currentCus.set("bizfunction",",1,2,3,4,");//业务职能 默认全选
|
||||
currentCus.set("createorg", JhzjUtils.GROUPID);//创建组织 默认为集团
|
||||
currentCus.set("org", JhzjUtils.GROUPID);//管理组织 默认为集团
|
||||
// currentCus.set("createorg", JhzjUtils.GROUPID);//创建组织 默认为集团
|
||||
// currentCus.set("org", JhzjUtils.GROUPID);//管理组织 默认为集团
|
||||
currentCus.set("ctrlstrategy","1");//控制策略 默认逐级分配1 自由分配2
|
||||
currentCus.set("group",custype.getLong("id"));//客户分组
|
||||
// currentCus.set("bitindex",1);//位图
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ import com.alibaba.fastjson.JSONObject;
|
|||
import com.drew.lang.annotations.NotNull;
|
||||
import kd.bos.api.client.ApiResult;
|
||||
import kd.bos.context.RequestContext;
|
||||
import kd.bos.dataentity.OperateOption;
|
||||
import kd.bos.dataentity.entity.DynamicObject;
|
||||
import kd.bos.id.ID;
|
||||
import kd.bos.logging.Log;
|
||||
|
|
@ -17,6 +18,7 @@ import kd.bos.openapi.common.custom.annotation.ApiRequestBody;
|
|||
import kd.bos.openapi.common.result.CustomApiResult;
|
||||
import kd.bos.orm.query.QFilter;
|
||||
import kd.bos.servicehelper.BusinessDataServiceHelper;
|
||||
import kd.bos.servicehelper.operation.OperationServiceHelper;
|
||||
import kd.bos.servicehelper.operation.SaveServiceHelper;
|
||||
import shjh.jhzj7.fi.fi.utils.EsbUtils;
|
||||
import shjh.jhzj7.fi.fi.webapi.model.CustomerFiveModel;
|
||||
|
|
@ -65,6 +67,7 @@ public class CustomerFiveControler {
|
|||
Date enddate;
|
||||
DynamicObject currentOrg;
|
||||
JSONObject json_body;
|
||||
OperateOption oop = OperateOption.create();
|
||||
for (int i = 0; i < detailsJson.size(); i++) {
|
||||
json_body = detailsJson.getJSONObject(i);
|
||||
orgNumber = json_body.getString("code");
|
||||
|
|
@ -114,6 +117,7 @@ public class CustomerFiveControler {
|
|||
currentOrg.set("enable",0);
|
||||
}
|
||||
SaveServiceHelper.save(new DynamicObject[]{currentOrg});
|
||||
OperationServiceHelper.executeOperate("save", entityName, new DynamicObject[]{currentOrg}, oop);
|
||||
}
|
||||
if(itemsJson.isEmpty()){
|
||||
EsbUtils.saveLog(apimenthod,"ESB",json_obj.toString(),null,true,"API");
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ import com.alibaba.fastjson.JSONObject;
|
|||
import com.drew.lang.annotations.NotNull;
|
||||
import kd.bos.api.client.ApiResult;
|
||||
import kd.bos.context.RequestContext;
|
||||
import kd.bos.dataentity.OperateOption;
|
||||
import kd.bos.dataentity.entity.DynamicObject;
|
||||
import kd.bos.id.ID;
|
||||
import kd.bos.logging.Log;
|
||||
|
|
@ -17,7 +18,7 @@ import kd.bos.openapi.common.custom.annotation.ApiRequestBody;
|
|||
import kd.bos.openapi.common.result.CustomApiResult;
|
||||
import kd.bos.orm.query.QFilter;
|
||||
import kd.bos.servicehelper.BusinessDataServiceHelper;
|
||||
import kd.bos.servicehelper.operation.SaveServiceHelper;
|
||||
import kd.bos.servicehelper.operation.OperationServiceHelper;
|
||||
import shjh.jhzj7.fi.fi.utils.EsbUtils;
|
||||
import shjh.jhzj7.fi.fi.webapi.model.ProfitCenterModel;
|
||||
|
||||
|
|
@ -56,6 +57,7 @@ public class ProfitCenterControler {
|
|||
String orgName;
|
||||
DynamicObject currentOrg;
|
||||
JSONObject json_body;
|
||||
OperateOption oop = OperateOption.create();
|
||||
for (int i = 0; i < detailsJson.size(); i++) {
|
||||
json_body = detailsJson.getJSONObject(i);
|
||||
orgNumber = json_body.getString("code");
|
||||
|
|
@ -86,7 +88,8 @@ public class ProfitCenterControler {
|
|||
if("0".equals(json_body.getString("status"))){
|
||||
currentOrg.set("enable",0);
|
||||
}
|
||||
SaveServiceHelper.save(new DynamicObject[]{currentOrg});
|
||||
// SaveServiceHelper.save(new DynamicObject[]{currentOrg});
|
||||
OperationServiceHelper.executeOperate("save", entityName, new DynamicObject[]{currentOrg}, oop);
|
||||
}
|
||||
if(itemsJson.isEmpty()){
|
||||
EsbUtils.saveLog(apimenthod,"ESB",json_obj.toString(),null,true,"API");
|
||||
|
|
|
|||
Loading…
Reference in New Issue