fix:
1.传EAS金额精度强制更改为2 2.产品类型删除效验
This commit is contained in:
parent
674a1ed3c7
commit
1c7a4b4299
@ -0,0 +1,21 @@
|
||||
package com.yem.em.bd.ProductsGroup.op;
|
||||
|
||||
import com.yem.em.bd.ProductsGroup.validator.BomChangeSavevalidatorEdit;
|
||||
import kd.bos.entity.plugin.AbstractOperationServicePlugIn;
|
||||
import kd.bos.entity.plugin.AddValidatorsEventArgs;
|
||||
import kd.bos.entity.plugin.PreparePropertysEventArgs;
|
||||
|
||||
public class ProductsGroupSave extends AbstractOperationServicePlugIn {
|
||||
|
||||
@Override
|
||||
public void onPreparePropertys(PreparePropertysEventArgs e) {
|
||||
super.onPreparePropertys(e);
|
||||
e.getFieldKeys().addAll(this.billEntityType.getAllFields().keySet());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onAddValidators(AddValidatorsEventArgs e) {
|
||||
super.onAddValidators(e);
|
||||
e.addValidator(new BomChangeSavevalidatorEdit());
|
||||
}
|
||||
}
|
@ -0,0 +1,24 @@
|
||||
package com.yem.em.bd.ProductsGroup.validator;
|
||||
|
||||
import kd.bos.dataentity.entity.DynamicObject;
|
||||
import kd.bos.entity.ExtendedDataEntity;
|
||||
import kd.bos.entity.validate.AbstractValidator;
|
||||
import kd.bos.orm.query.QCP;
|
||||
import kd.bos.orm.query.QFilter;
|
||||
import kd.bos.servicehelper.BusinessDataServiceHelper;
|
||||
|
||||
public class BomChangeSavevalidatorEdit extends AbstractValidator {
|
||||
@Override
|
||||
public void validate() {
|
||||
ExtendedDataEntity[] dataEntities = this.getDataEntities();
|
||||
for (ExtendedDataEntity dataEntitie : dataEntities) {
|
||||
DynamicObject dataEntity = dataEntitie.getDataEntity();
|
||||
long aLong = dataEntity.getLong("id");
|
||||
DynamicObject dynamicObject = BusinessDataServiceHelper.loadSingle(dataEntity.getDataEntityType().getName()
|
||||
, "id,parent", new QFilter[]{new QFilter("parent.id", QCP.equals, aLong)});
|
||||
if (dynamicObject != null) {
|
||||
this.addMessage(dataEntitie, "当前单有下级,不允许删除!!!");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -318,12 +318,12 @@ public class YemDelivernoticeService extends AbstractOperationServicePlugIn {
|
||||
json.put("price", materialentry.getBigDecimal("yem_priceandtax"));
|
||||
//金额
|
||||
BigDecimal yemAmt = materialentry.getBigDecimal("yem_amt");
|
||||
json.put("nonTaxAmount", BigDecimalUtils.div(yemAmt,1,4));
|
||||
json.put("nonTaxAmount", BigDecimalUtils.div(yemAmt,1,2));
|
||||
//金额本位币
|
||||
json.put("localNonTaxAmount", materialentry.getBigDecimal("yem_locamt"));
|
||||
//税额
|
||||
BigDecimal yemTaxamount = materialentry.getBigDecimal("yem_taxamount");
|
||||
json.put("tax", BigDecimalUtils.div(yemTaxamount,1,4));
|
||||
json.put("tax", BigDecimalUtils.div(yemTaxamount,1,2));
|
||||
//税额本位币
|
||||
json.put("localTax", materialentry.getBigDecimal("yem_curtaxamount"));
|
||||
//价税合计
|
||||
|
@ -17,17 +17,17 @@ public class Application {
|
||||
cosmic.setWebPath("E:/Cosmic/Comics_YXZG/YXZG-server/webapp");
|
||||
|
||||
////152
|
||||
cosmic.setClusterNumber("yxzg-topview-dev");
|
||||
cosmic.setTenantNumber("yxzg-topview-dev");
|
||||
cosmic.setServerIP("10.64.112.152");
|
||||
cosmic.setFileServerPathIPAndPort("", "");
|
||||
cosmic.setConfigUrl("10.64.112.152:2181", "zookeeper", "Cosmic@5092");
|
||||
// cosmic.setClusterNumber("yxzg-topview-dev");
|
||||
// cosmic.setTenantNumber("yxzg-topview-dev");
|
||||
// cosmic.setServerIP("10.64.112.152");
|
||||
// cosmic.setFileServerPathIPAndPort("", "");
|
||||
// cosmic.setConfigUrl("10.64.112.152:2181", "zookeeper", "Cosmic@5092");
|
||||
System.setProperty("mq.debug.queue.tag", "wrxtest");
|
||||
////134
|
||||
// cosmic.setClusterNumber("yxzg-prod");
|
||||
// cosmic.setTenantNumber("yxzg-prod");
|
||||
// cosmic.setServerIP("10.64.111.134");
|
||||
// cosmic.setConfigUrl("10.64.111.134:2181","zookeeper","d@f*g:SGVsbG8==U4HRwjlqTOp0p9b60T+T8D2fQ8ThQgJLu/qgfLyLgknPa2RwYXNzd29yZA==");
|
||||
cosmic.setClusterNumber("yxzg-prod");
|
||||
cosmic.setTenantNumber("yxzg-prod");
|
||||
cosmic.setServerIP("10.64.111.134");
|
||||
cosmic.setConfigUrl("10.64.111.134:2181","zookeeper","d@f*g:SGVsbG8==U4HRwjlqTOp0p9b60T+T8D2fQ8ThQgJLu/qgfLyLgknPa2RwYXNzd29yZA==");
|
||||
|
||||
cosmic.setStartWithQing(false);
|
||||
cosmic.start();
|
||||
|
Loading…
Reference in New Issue
Block a user