1.发运明细过滤处理
This commit is contained in:
ljw 2024-12-12 18:36:45 +08:00
parent a2ee62d197
commit 062a58eb37
2 changed files with 30 additions and 22 deletions

View File

@ -532,6 +532,10 @@ public class ShippingDetailsFormPlugin extends AbstractBillPlugIn implements Bef
int currentRowIndex = this.getModel().getEntryCurrentRowIndex("yem_es_materialinfo");
String yemsourcebilltype = (String) this.getModel().getValue("yem_sourcebilltype");
if ("yem_es_salesorder".equals(yemsourcebilltype)) {
DynamicObjectCollection dynamicObjectCollection = this.getModel().getEntryEntity("yem_es_materialinfo");
if (!dynamicObjectCollection.isEmpty()) {
DynamicObject yemEsMaterialinfo = dynamicObjectCollection.get(currentRowIndex);
long yemCoreentryid = yemEsMaterialinfo.getLong("yem_coreentryid");
String yemsourcebillno = (String) this.getModel().getValue("yem_sourcebillno");
if (YEM.isNotEmpty(yemsourcebillno)) {
DynamicObject dynamicObject = BusinessDataServiceHelper.loadSingle("yem_es_salesorder", "", new QFilter[]{
@ -540,11 +544,11 @@ public class ShippingDetailsFormPlugin extends AbstractBillPlugIn implements Bef
});
if (dynamicObject != null) {
dynamicObject = BusinessDataServiceHelper.loadSingle(dynamicObject.getPkValue(), dynamicObject.getDynamicObjectType().getName());
DynamicObjectCollection dynamicObjectCollection = dynamicObject.getDynamicObjectCollection("yem_es_materialinfo");
if (dynamicObjectCollection != null && dynamicObjectCollection.size() > 0) {
DynamicObject dynamicObject1 = dynamicObjectCollection.get(currentRowIndex);
if (dynamicObject1 != null) {
DynamicObjectCollection yem_es_salesorder_z = dynamicObject1.getDynamicObjectCollection("yem_es_salesorder_z");
DynamicObjectCollection dynamicObject1 = dynamicObject.getDynamicObjectCollection("yem_es_materialinfo");
for (DynamicObject object : dynamicObject1) {
long aLong = object.getLong("id");
if (yemCoreentryid == aLong) {
DynamicObjectCollection yem_es_salesorder_z = object.getDynamicObjectCollection("yem_es_salesorder_z");
Map<String, Object> datas = new HashMap();
List<DynamicObject> zjNumberList = new ArrayList();
for (DynamicObject temp : yem_es_salesorder_z) {
@ -558,6 +562,7 @@ public class ShippingDetailsFormPlugin extends AbstractBillPlugIn implements Bef
}
}
}
}
}

View File

@ -129,6 +129,9 @@ public class YemDelivernoticeService extends AbstractOperationServicePlugIn {
//单据编号
json.put("number", dataEntitie.getString("billno"));
//送货客户
if (dataEntitie.getString("yem_sale_type").equals("B")) {
}
DynamicObject yemCustomer = dataEntitie.getDynamicObject("yem_customer1");
if (yemCustomer != null) {
json.put("customer", setJson("number", yemCustomer.getString("number")));