apzl_leasing/src_tenwa/com/tenwa/creditlimit/handler/LALimitConfigInfoHandler.java
2018-06-03 22:26:41 +08:00

44 lines
1.8 KiB
Java

package com.tenwa.creditlimit.handler;
import com.amarsoft.are.jbo.BizObject;
import com.amarsoft.are.jbo.JBOTransaction;
import com.amarsoft.awe.dw.handler.impl.CommonHandler;
import com.amarsoft.dict.als.manage.NameManager;
public class LALimitConfigInfoHandler extends CommonHandler {
@Override
protected void initDisplayForAdd(BizObject bo) throws Exception {
String productId = this.asPage.getAttribute("ProductId").toString();
String specificId = this.asPage.getAttribute("SpecificId").toString();
String elementId = this.asPage.getAttribute("ElementId").toString();
String elementName = this.asPage.getAttribute("ElementName").toString();
bo.setAttributeValue("PRODUCT_ID", productId);
bo.setAttributeValue("SPECIFIC_ID", specificId);
bo.setAttributeValue("LIMIT_ELEMENT", elementId);
bo.setAttributeValue("ELEMENT_NAME", elementName);
super.initDisplayForAdd(bo);
}
@Override
protected void beforeInsert(JBOTransaction tx, BizObject bo)
throws Exception {
String elementName = bo.getAttribute("ELEMENT_NAME").toString();
String limitOperator= bo.getAttribute("LIMIT_OPERATOR").toString();
String limitCode= bo.getAttribute("LIMIT_CODE").toString();
bo.setAttributeValue("LIMIT_DESCRIPT", elementName+NameManager.getItemName("OperatorType", limitOperator)+limitCode);
super.beforeInsert(tx, bo);
}
@Override
protected void beforeUpdate(JBOTransaction tx, BizObject bo)
throws Exception {
String elementName = bo.getAttribute("ELEMENT_NAME").toString();
String limitOperator= bo.getAttribute("LIMIT_OPERATOR").toString();
String limitCode= bo.getAttribute("LIMIT_CODE").toString();
bo.setAttributeValue("LIMIT_DESCRIPT", elementName+NameManager.getItemName("OperatorType", limitOperator)+limitCode);
super.beforeUpdate(tx, bo);
}
}