Compare commits
2 Commits
67fec9f726
...
3e92771397
Author | SHA1 | Date | |
---|---|---|---|
3e92771397 | |||
963efc52d0 |
@ -296,8 +296,10 @@ public class ObjectToJsonUtils {
|
||||
}
|
||||
}
|
||||
}
|
||||
if(entityObject.size()>0){
|
||||
jsonArray.add(entityObject);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
JSONObject entityObject = new JSONObject();
|
||||
for (int j = 0; j < yem_subentryentity.size(); j++) {
|
||||
@ -382,10 +384,12 @@ public class ObjectToJsonUtils {
|
||||
}
|
||||
}
|
||||
}
|
||||
if(entityObject.size()>0){
|
||||
jsonArray.add(entityObject);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} else { //单据提拼接
|
||||
if (StringUtils.isEmpty(yem_erpfiledformid)) {
|
||||
continue;
|
||||
@ -430,9 +434,11 @@ public class ObjectToJsonUtils {
|
||||
}
|
||||
}
|
||||
}
|
||||
if(entityObject.size()>0){
|
||||
jsonArray.add(entityObject);
|
||||
}
|
||||
}
|
||||
}
|
||||
widgetValueEntry.put("widgetValue", jsonArray);
|
||||
json.put(yem_iaformid, widgetValueEntry);
|
||||
Object.put("details", json);//分录数据
|
||||
|
@ -194,10 +194,12 @@ public class intebilllogonDemo extends AbstractBillPlugIn {
|
||||
if (key.equals("generatejson_zz")) {
|
||||
DynamicObject yemFormid = dataEntity.getDynamicObject("yem_formid");
|
||||
if (yemFormid != null) {
|
||||
Map map = new HashMap<>();
|
||||
map.put("entityName", yemFormid.getString("number"));
|
||||
// map.put("billtype","yem_orderproreqbill_DB");
|
||||
JSONObject json = ObjectToJsonUtils.ObjectToJson(dataEntity.getLong("yem_formcode"), map);
|
||||
long yem_formcode = dataEntity.getLong("yem_formcode");
|
||||
if(yem_formcode==0){
|
||||
this.getView().showErrorNotification("请选择单据后重试!");
|
||||
return;
|
||||
}
|
||||
JSONObject json = ObjectToJsonUtils.ToJson(dataEntity, yem_formcode, yemFormid.getString("number"), " ");
|
||||
this.getView().getModel().setValue("yem_generatejson", json);
|
||||
this.getView().showSuccessNotification("获取完成!");
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user