Compare commits
No commits in common. "c6730121bb8d1fa24dc5ffe0a51da41cb21d0e77" and "c4afa4df0452e83ba67fa97901b2a5bdc6e53b5c" have entirely different histories.
c6730121bb
...
c4afa4df04
|
|
@ -1,15 +1,9 @@
|
|||
package zcgj.zcdev.zcdev.pr.plugin.form;
|
||||
|
||||
import kd.bos.bill.AbstractBillPlugIn;
|
||||
import kd.bos.bill.BillShowParameter;
|
||||
import kd.bos.dataentity.entity.DynamicObject;
|
||||
import kd.bos.dataentity.entity.DynamicObjectCollection;
|
||||
import kd.bos.entity.datamodel.events.ChangeData;
|
||||
import kd.bos.entity.datamodel.events.PropertyChangedArgs;
|
||||
import kd.bos.form.ShowType;
|
||||
import kd.bos.form.control.EntryGrid;
|
||||
import kd.bos.form.events.HyperLinkClickEvent;
|
||||
import kd.bos.form.events.HyperLinkClickListener;
|
||||
import kd.bos.form.field.BasedataEdit;
|
||||
import kd.bos.form.field.RefBillEdit;
|
||||
import kd.bos.form.field.TextEdit;
|
||||
|
|
@ -29,9 +23,8 @@ import java.util.EventObject;
|
|||
* 2:结算期间初始化赋值
|
||||
* 3:供应商赋值和必录逻辑
|
||||
* 4:关联设备维修申请字段过滤
|
||||
* 5:发票号码超链接点击跳转
|
||||
*/
|
||||
public class MaintenanceConfirmBillPlugin extends AbstractBillPlugIn implements BeforeF7SelectListener, HyperLinkClickListener {
|
||||
public class MaintenanceConfirmBillPlugin extends AbstractBillPlugIn implements BeforeF7SelectListener {
|
||||
@Override
|
||||
public void registerListener(EventObject e) {
|
||||
super.registerListener(e);
|
||||
|
|
@ -43,8 +36,6 @@ public class MaintenanceConfirmBillPlugin extends AbstractBillPlugIn implements
|
|||
if (zcgj_maintenance != null) {
|
||||
zcgj_maintenance.addBeforeF7SelectListener(this);
|
||||
}
|
||||
EntryGrid control = this.getControl("zcgj_entryentity");
|
||||
control.addHyperClickListener(this);
|
||||
}
|
||||
|
||||
public void afterCreateNewData(EventObject e) {
|
||||
|
|
@ -92,32 +83,6 @@ public class MaintenanceConfirmBillPlugin extends AbstractBillPlugIn implements
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void hyperLinkClick(HyperLinkClickEvent hyperLinkClickEvent) {
|
||||
String fieldName = hyperLinkClickEvent.getFieldName();
|
||||
if ("zcgj_invoice".equals(fieldName)) {
|
||||
//发票号码
|
||||
EntryGrid entryGrid = getView().getControl("zcgj_entryentity");
|
||||
int[] selectRows = entryGrid.getSelectRows();
|
||||
if (selectRows != null && selectRows.length == 1) {
|
||||
DynamicObjectCollection dynamicObjectCollection = this.getModel().getDataEntity(true).getDynamicObjectCollection("zcgj_entryentity");
|
||||
DynamicObject dynamicObject = dynamicObjectCollection.get(selectRows[0]);
|
||||
DynamicObject zcgjInvoice = dynamicObject.getDynamicObject("zcgj_invoice");
|
||||
long invoiceId = zcgjInvoice.getLong("id");
|
||||
if (invoiceId != 0) {
|
||||
//弹出发票详情
|
||||
BillShowParameter showParameter = new BillShowParameter();
|
||||
showParameter.setPkId(invoiceId);
|
||||
showParameter.setFormId("ec_in_invoice");
|
||||
showParameter.getOpenStyle().setShowType(ShowType.MainNewTabPage); //打开方式
|
||||
getView().showForm(showParameter);
|
||||
}
|
||||
} else {
|
||||
this.getView().showTipNotification("请选择一条发票数据。");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void beforeF7Select(BeforeF7SelectEvent beforeF7SelectEvent) {
|
||||
String name = beforeF7SelectEvent.getProperty().getName();
|
||||
|
|
|
|||
|
|
@ -326,7 +326,7 @@ public class MaterialInBillEditPluginExt extends AbstractEcmaBillPlugin implemen
|
|||
case "matoftaxamount"://材料含税总金额
|
||||
this.matoftaxamountChanged((BigDecimal) propValue);
|
||||
break;
|
||||
case "matamount"://材料总金额
|
||||
case "matamount":
|
||||
this.matamountChanged((BigDecimal) propValue);
|
||||
break;
|
||||
case "proboq":
|
||||
|
|
@ -811,8 +811,8 @@ public class MaterialInBillEditPluginExt extends AbstractEcmaBillPlugin implemen
|
|||
|
||||
private void matamountChanged(BigDecimal propValue) {
|
||||
this.getModel().beginInit();
|
||||
BigDecimal exchangerate = (BigDecimal) this.getModel().getValue("exchangerate");//汇率
|
||||
this.getModel().setValue("stdmateamount", propValue.multiply(exchangerate));//材料不含税金额(本位币)
|
||||
BigDecimal exchangerate = (BigDecimal) this.getModel().getValue("exchangerate");
|
||||
this.getModel().setValue("stdmateamount", propValue.multiply(exchangerate));
|
||||
this.getModel().endInit();
|
||||
this.getView().updateView("stdmateamount");
|
||||
this.summaryTotalAmount();
|
||||
|
|
|
|||
|
|
@ -192,16 +192,6 @@ public class MaterialInbPurchaseApplyPlugin extends AbstractBillPlugIn implement
|
|||
this.getView().updateView("transoftaxamount");
|
||||
this.getView().updateView("totaloftaxamount");
|
||||
this.getModel().endInit();
|
||||
} else if ("oftaxamount".equals(key)) {
|
||||
//入库单明细-含税金额
|
||||
boolean inputtaxprice = (boolean) this.getModel().getValue("inputtaxprice");//录入含税价
|
||||
boolean inputtotalprice = (boolean) this.getModel().getValue("inputtotalprice");//录入总价
|
||||
if (inputtaxprice && inputtotalprice) {
|
||||
BigDecimal matAmount = (BigDecimal) this.getModel().getValue("matamount");//材料总金额
|
||||
BigDecimal transAmount = (BigDecimal) this.getModel().getValue("transamount");//总运费
|
||||
BigDecimal totalAmount = matAmount.add(transAmount);
|
||||
this.getModel().setValue("totalamount", totalAmount);//入库总金额
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue