From 4c166172c288fd57666adf2e5652a9e7b26bd46a Mon Sep 17 00:00:00 2001 From: liuz Date: Wed, 12 Sep 2018 19:48:39 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B3=95=E4=BA=BA=E5=AE=A2=E6=88=B6=E5=B8=A6?= =?UTF-8?q?=E5=80=BC=E5=92=8C=E7=BB=8F=E9=94=80=E5=95=86=E5=B8=A6=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../account/CustomerAccountController.java | 22 +++++++++++++++++++ .../group/CustomerGroupCompanyHandler.java | 3 ++- 2 files changed, 24 insertions(+), 1 deletion(-) diff --git a/src_tenwa/com/tenwa/customer/controller/account/CustomerAccountController.java b/src_tenwa/com/tenwa/customer/controller/account/CustomerAccountController.java index fea1c95ac..ee4bc78da 100644 --- a/src_tenwa/com/tenwa/customer/controller/account/CustomerAccountController.java +++ b/src_tenwa/com/tenwa/customer/controller/account/CustomerAccountController.java @@ -3,16 +3,29 @@ package com.tenwa.customer.controller.account; import java.util.List; import jbo.app.tenwa.customer.CUSTOMER_ACCOUNT; +import jbo.app.tenwa.customer.CUSTOMER_INFO; +import jbo.app.tenwa.customer.DISTRIBUTOR_INFO_TEMP; import com.amarsoft.are.jbo.BizObject; import com.amarsoft.are.jbo.BizObjectManager; +import com.amarsoft.are.jbo.JBOException; import com.amarsoft.are.jbo.JBOFactory; import com.amarsoft.are.jbo.JBOTransaction; public class CustomerAccountController { private String customer_id=""; private String id=""; + private String account; + + public String getAccount() { + return account; + } + + public void setAccount(String account) { + this.account = account; + } + public String getId() { return id; } @@ -61,4 +74,13 @@ public class CustomerAccountController { } return "false"; } + + //带值 + public String selectAccountName(JBOTransaction tx) throws JBOException{ + BizObjectManager bs = JBOFactory.getBizObjectManager(CUSTOMER_INFO.CLASS_NAME,tx); + BizObject dgc = bs.createQuery("customerid=:customerid").setParameter("customerid",customer_id).getSingleResult(false); + String distributorName =dgc!=null?dgc.getAttribute("customername").toString():""; + return distributorName; + + } } diff --git a/src_tenwa/com/tenwa/customer/handler/group/CustomerGroupCompanyHandler.java b/src_tenwa/com/tenwa/customer/handler/group/CustomerGroupCompanyHandler.java index 24368b6b2..d7ac960f1 100644 --- a/src_tenwa/com/tenwa/customer/handler/group/CustomerGroupCompanyHandler.java +++ b/src_tenwa/com/tenwa/customer/handler/group/CustomerGroupCompanyHandler.java @@ -12,7 +12,8 @@ public class CustomerGroupCompanyHandler extends CommonHandler{ JBOTransaction tx = JBOFactory.createJBOTransaction(); String groupCompanyNumber = SerialNumberUtil.getGroupCompanyNumber(tx); tx.commit(); -// bo.setAttributeValue("group_no", groupCompanyNumber); + //集团编号是否自动生成 + bo.setAttributeValue("group_no", groupCompanyNumber); super.initDisplayForAdd(bo); } }