Commit 3404970c by liuyang

1.合同管理添加销售计划单号

parent 582ecd3b
...@@ -65,6 +65,7 @@ public class HGCW002 extends DaoEPBase { ...@@ -65,6 +65,7 @@ public class HGCW002 extends DaoEPBase {
public static final String FIELD_COMPANY_CODES = "companyCodes"; public static final String FIELD_COMPANY_CODES = "companyCodes";
public static final String FIELD_REMAINING_AMOUNT = "remainingAmount"; /* 剩余开票/收票金额*/ public static final String FIELD_REMAINING_AMOUNT = "remainingAmount"; /* 剩余开票/收票金额*/
public static final String FIELD_BRANCH_UNIT = "branchUnit"; public static final String FIELD_BRANCH_UNIT = "branchUnit";
public static final String FIELD_PLAN_SALES_CODE = "planSalesCode"; /* 销售计划单号*/
public static final String COL_ID = "ID"; public static final String COL_ID = "ID";
public static final String COL_ACCOUNT_CODE = "ACCOUNT_CODE"; /* 企业编码*/ public static final String COL_ACCOUNT_CODE = "ACCOUNT_CODE"; /* 企业编码*/
...@@ -158,6 +159,7 @@ public class HGCW002 extends DaoEPBase { ...@@ -158,6 +159,7 @@ public class HGCW002 extends DaoEPBase {
private BigDecimal remainingAmount = new BigDecimal("0"); /* 剩余开票/收票金额*/ private BigDecimal remainingAmount = new BigDecimal("0"); /* 剩余开票/收票金额*/
private String contractTypeStr = ""; /* 合同类型;1销售合同2劳务合同3补充协议4合同外用工*/ private String contractTypeStr = ""; /* 合同类型;1销售合同2劳务合同3补充协议4合同外用工*/
private String branchUnit = " "; private String branchUnit = " ";
private String planSalesCode = " "; /* 销售计划单号*/
/** /**
* initialize the metadata. * initialize the metadata.
...@@ -349,6 +351,10 @@ public class HGCW002 extends DaoEPBase { ...@@ -349,6 +351,10 @@ public class HGCW002 extends DaoEPBase {
eiColumn = new EiColumn(FIELD_BRANCH_UNIT); eiColumn = new EiColumn(FIELD_BRANCH_UNIT);
eiColumn.setDescName("分支单位"); eiColumn.setDescName("分支单位");
eiMetadata.addMeta(eiColumn); eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_PLAN_SALES_CODE);
eiColumn.setDescName("销售计划单号");
eiMetadata.addMeta(eiColumn);
} }
/** /**
...@@ -1023,6 +1029,14 @@ public class HGCW002 extends DaoEPBase { ...@@ -1023,6 +1029,14 @@ public class HGCW002 extends DaoEPBase {
this.branchUnit = branchUnit; this.branchUnit = branchUnit;
} }
public String getPlanSalesCode() {
return planSalesCode;
}
public void setPlanSalesCode(String planSalesCode) {
this.planSalesCode = planSalesCode;
}
/** /**
* get the value from Map. * get the value from Map.
* *
...@@ -1074,6 +1088,7 @@ public class HGCW002 extends DaoEPBase { ...@@ -1074,6 +1088,7 @@ public class HGCW002 extends DaoEPBase {
setRemainingAmount(NumberUtils.toBigDecimal(StringUtils.toString(map.get(FIELD_REMAINING_AMOUNT)), remainingAmount)); setRemainingAmount(NumberUtils.toBigDecimal(StringUtils.toString(map.get(FIELD_REMAINING_AMOUNT)), remainingAmount));
setContractTypeStr(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("contractTypeStr")), contractTypeStr)); setContractTypeStr(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("contractTypeStr")), contractTypeStr));
setBranchUnit(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("branchUnit")), branchUnit)); setBranchUnit(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("branchUnit")), branchUnit));
setPlanSalesCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("planSalesCode")), planSalesCode));
} }
/** /**
...@@ -1126,6 +1141,7 @@ public class HGCW002 extends DaoEPBase { ...@@ -1126,6 +1141,7 @@ public class HGCW002 extends DaoEPBase {
map.put(FIELD_REMAINING_AMOUNT, StringUtils.toString(remainingAmount, eiMetadata.getMeta(FIELD_REMAINING_AMOUNT))); map.put(FIELD_REMAINING_AMOUNT, StringUtils.toString(remainingAmount, eiMetadata.getMeta(FIELD_REMAINING_AMOUNT)));
map.put("contractTypeStr", StringUtils.toString(contractTypeStr, eiMetadata.getMeta("contractTypeStr"))); map.put("contractTypeStr", StringUtils.toString(contractTypeStr, eiMetadata.getMeta("contractTypeStr")));
map.put("branchUnit", StringUtils.toString(branchUnit, eiMetadata.getMeta("branchUnit"))); map.put("branchUnit", StringUtils.toString(branchUnit, eiMetadata.getMeta("branchUnit")));
map.put("planSalesCode", StringUtils.toString(planSalesCode, eiMetadata.getMeta("planSalesCode")));
return map; return map;
} }
......
...@@ -75,7 +75,7 @@ public class ServiceHGCW002 extends ServiceBase { ...@@ -75,7 +75,7 @@ public class ServiceHGCW002 extends ServiceBase {
if (list1.size() > 0){ if (list1.size() > 0){
list1 = list1.stream().filter(hgpz001 -> "分支单位".equals(hgpz001.getCustTypeName())).collect(Collectors.toList()); list1 = list1.stream().filter(hgpz001 -> "分支单位".equals(hgpz001.getCustTypeName())).collect(Collectors.toList());
List<String> custTypeList = list1.stream().map(HGPZ001::getCustType).collect(Collectors.toList()); List<String> custTypeList = list1.stream().map(HGPZ001::getCustType).collect(Collectors.toList());
CommonMethod.initBlock(outInfo, Arrays.asList(DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID), CommonMethod.initBlock(outInfo, Arrays.asList(DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID,DdynamicEnum.PLAN_SALES_CODE_BLOCK_ID),
new HashMap<String, Object>(){{put("custTypes", custTypeList);}},false); new HashMap<String, Object>(){{put("custTypes", custTypeList);}},false);
CommonMethod.comboBoxDefaultValue(outInfo,DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID.getBlockId()); CommonMethod.comboBoxDefaultValue(outInfo,DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID.getBlockId());
} }
......
...@@ -58,7 +58,7 @@ public class ServiceHGCW002A extends ServiceBase { ...@@ -58,7 +58,7 @@ public class ServiceHGCW002A extends ServiceBase {
if (list1.size() > 0){ if (list1.size() > 0){
list1 = list1.stream().filter(hgpz001 -> "分支单位".equals(hgpz001.getCustTypeName())).collect(Collectors.toList()); list1 = list1.stream().filter(hgpz001 -> "分支单位".equals(hgpz001.getCustTypeName())).collect(Collectors.toList());
List<String> custTypeList = list1.stream().map(HGPZ001::getCustType).collect(Collectors.toList()); List<String> custTypeList = list1.stream().map(HGPZ001::getCustType).collect(Collectors.toList());
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID), CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID,DdynamicEnum.PLAN_SALES_CODE_BLOCK_ID),
new HashMap<String, Object>(){{put("custTypes", custTypeList);}},false); new HashMap<String, Object>(){{put("custTypes", custTypeList);}},false);
CommonMethod.comboBoxDefaultValue(inInfo,DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID.getBlockId()); CommonMethod.comboBoxDefaultValue(inInfo,DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID.getBlockId());
} }
......
...@@ -53,7 +53,7 @@ public class ServiceHGCW002B extends ServiceBase { ...@@ -53,7 +53,7 @@ public class ServiceHGCW002B extends ServiceBase {
if (list1.size() > 0){ if (list1.size() > 0){
list1 = list1.stream().filter(hgpz001 -> "分支单位".equals(hgpz001.getCustTypeName())).collect(Collectors.toList()); list1 = list1.stream().filter(hgpz001 -> "分支单位".equals(hgpz001.getCustTypeName())).collect(Collectors.toList());
List<String> custTypeList = list1.stream().map(HGPZ001::getCustType).collect(Collectors.toList()); List<String> custTypeList = list1.stream().map(HGPZ001::getCustType).collect(Collectors.toList());
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID), CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID,DdynamicEnum.PLAN_SALES_CODE_BLOCK_ID),
new HashMap<String, Object>(){{put("custTypes", custTypeList);}},false); new HashMap<String, Object>(){{put("custTypes", custTypeList);}},false);
} }
//获取清单 //获取清单
......
...@@ -47,7 +47,7 @@ public class ServiceHGCW002C extends ServiceBase { ...@@ -47,7 +47,7 @@ public class ServiceHGCW002C extends ServiceBase {
if (list1.size() > 0){ if (list1.size() > 0){
list1 = list1.stream().filter(hgpz001 -> "分支单位".equals(hgpz001.getCustTypeName())).collect(Collectors.toList()); list1 = list1.stream().filter(hgpz001 -> "分支单位".equals(hgpz001.getCustTypeName())).collect(Collectors.toList());
List<String> custTypeList = list1.stream().map(HGPZ001::getCustType).collect(Collectors.toList()); List<String> custTypeList = list1.stream().map(HGPZ001::getCustType).collect(Collectors.toList());
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID), CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.CUSTOMER_RECORD_BLOCK_ID,DdynamicEnum.PLAN_SALES_CODE_BLOCK_ID),
new HashMap<String, Object>(){{put("custTypes", custTypeList);}},false); new HashMap<String, Object>(){{put("custTypes", custTypeList);}},false);
} }
//获取清单 //获取清单
......
...@@ -46,7 +46,8 @@ ...@@ -46,7 +46,8 @@
UPDATED_TIME as "updatedTime", <!-- 记录修改时间 --> UPDATED_TIME as "updatedTime", <!-- 记录修改时间 -->
DEP_CODE as "depCode", <!-- 部门编码 --> DEP_CODE as "depCode", <!-- 部门编码 -->
REMAINING_AMOUNT as "remainingAmount", REMAINING_AMOUNT as "remainingAmount",
BRANCH_UNIT as "branchUnit" BRANCH_UNIT as "branchUnit",
PLAN_SALES_CODE as "planSalesCode"
</sql> </sql>
<sql id="condition"> <sql id="condition">
...@@ -180,6 +181,9 @@ ...@@ -180,6 +181,9 @@
<isNotEmpty prepend=" AND " property="branchUnit"> <isNotEmpty prepend=" AND " property="branchUnit">
BRANCH_UNIT = #branchUnit# BRANCH_UNIT = #branchUnit#
</isNotEmpty> </isNotEmpty>
<isNotEmpty prepend=" AND " property="planSalesCode">
PLAN_SALES_CODE like concat('%',#planSalesCode#,'%')
</isNotEmpty>
</sql> </sql>
<sql id="conditionExport"> <sql id="conditionExport">
...@@ -310,6 +314,9 @@ ...@@ -310,6 +314,9 @@
<isNotEmpty prepend=" AND " property="branchUnit"> <isNotEmpty prepend=" AND " property="branchUnit">
A.BRANCH_UNIT = #branchUnit# A.BRANCH_UNIT = #branchUnit#
</isNotEmpty> </isNotEmpty>
<isNotEmpty prepend=" AND " property="planSalesCode">
A.PLAN_SALES_CODE like concat('%',#planSalesCode#,'%')
</isNotEmpty>
</sql> </sql>
<sql id="customCondition"> <sql id="customCondition">
...@@ -388,7 +395,8 @@ ...@@ -388,7 +395,8 @@
UPDATED_TIME, <!-- 记录修改时间 --> UPDATED_TIME, <!-- 记录修改时间 -->
DEP_CODE, <!-- 部门编码 --> DEP_CODE, <!-- 部门编码 -->
REMAINING_AMOUNT, REMAINING_AMOUNT,
BRANCH_UNIT BRANCH_UNIT,
PLAN_SALES_CODE
) )
VALUES (#id#, #accountCode#, #companyCode#, #companyName#, #projCode#, #projName#, #contractNumber#, VALUES (#id#, #accountCode#, #companyCode#, #companyName#, #projCode#, #projName#, #contractNumber#,
#contractName#, #contractType#, #contractCategory#, #partyA#, #partyB#, #partyC#, #planStartDate#, #contractName#, #contractType#, #contractCategory#, #partyA#, #partyB#, #partyC#, #planStartDate#,
...@@ -396,7 +404,7 @@ ...@@ -396,7 +404,7 @@
#engineeringAddress#, #signingDate#, #mainContractNumber#, #contractContent#, #contractingMethod#, #engineeringAddress#, #signingDate#, #mainContractNumber#, #contractContent#, #contractingMethod#,
#paymentMethod#, #pricingMethod#, #taxPoints#, #totalContractPriceExcluding#, #valueAddedTax#, #paymentMethod#, #pricingMethod#, #taxPoints#, #totalContractPriceExcluding#, #valueAddedTax#,
#totalContractPriceIncluding#, #reviewStatus#, #balanceStatus#, #createdBy#, #createdName#, #createdTime#, #totalContractPriceIncluding#, #reviewStatus#, #balanceStatus#, #createdBy#, #createdName#, #createdTime#,
#updatedBy#, #updatedName#, #updatedTime#, #depCode#, #remainingAmount#, #branchUnit#) #updatedBy#, #updatedName#, #updatedTime#, #depCode#, #remainingAmount#, #branchUnit#, #planSalesCode#)
<selectKey resultClass="long" keyProperty="id"> <selectKey resultClass="long" keyProperty="id">
SELECT MAX(ID) AS "id" FROM ${hggpSchema}.HGCW002 SELECT MAX(ID) AS "id" FROM ${hggpSchema}.HGCW002
</selectKey> </selectKey>
...@@ -449,7 +457,8 @@ ...@@ -449,7 +457,8 @@
UPDATED_NAME = #updatedName#, <!-- 记录修改名称 --> UPDATED_NAME = #updatedName#, <!-- 记录修改名称 -->
UPDATED_TIME = #updatedTime#, <!-- 记录修改时间 --> UPDATED_TIME = #updatedTime#, <!-- 记录修改时间 -->
REMAINING_AMOUNT = #remainingAmount#, REMAINING_AMOUNT = #remainingAmount#,
BRANCH_UNIT = #branchUnit# BRANCH_UNIT = #branchUnit#,
PLAN_SALES_CODE = #planSalesCode#
<!-- DEP_CODE = #depCode# 部门编码 --> <!-- DEP_CODE = #depCode# 部门编码 -->
WHERE WHERE
ID = #id# ID = #id#
...@@ -737,7 +746,8 @@ ...@@ -737,7 +746,8 @@
A.TOTAL_CONTRACT_PRICE_INCLUDING as "totalContractPriceIncluding", <!-- 合同总价(含税) --> A.TOTAL_CONTRACT_PRICE_INCLUDING as "totalContractPriceIncluding", <!-- 合同总价(含税) -->
G.ITEM_CNAME as "reviewStatus", <!-- 审核状态 --> G.ITEM_CNAME as "reviewStatus", <!-- 审核状态 -->
H.ITEM_CNAME as "balanceStatus", <!-- 结算状态;1未结算2部分结算3最终结算 --> H.ITEM_CNAME as "balanceStatus", <!-- 结算状态;1未结算2部分结算3最终结算 -->
E.CUST_TYPE_NAME as "branchUnit" E.CUST_TYPE_NAME as "branchUnit",
A.PLAN_SALES_CODE as "planSalesCode"
FROM ${hggpSchema}.HGCW002 A FROM ${hggpSchema}.HGCW002 A
LEFT JOIN ${hggpSchema}.HGCW002 B ON A.CONTRACT_NUMBER = B.MAIN_CONTRACT_NUMBER LEFT JOIN ${hggpSchema}.HGCW002 B ON A.CONTRACT_NUMBER = B.MAIN_CONTRACT_NUMBER
LEFT JOIN ${platSchema}.TEDCM01 C ON A.CONTRACT_STATUS = C.ITEM_CODE AND C.CODESET_CODE = 'hggp.cw.contractStatus' LEFT JOIN ${platSchema}.TEDCM01 C ON A.CONTRACT_STATUS = C.ITEM_CODE AND C.CODESET_CODE = 'hggp.cw.contractStatus'
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment