Prechádzať zdrojové kódy

Merge remote-tracking branch 'origin/master'

蔡德晨 5 rokov pred
rodič
commit
85d8f48a0e

+ 3 - 0
src/main/java/com/jeeplus/modules/sg/financial/erpcredit/entity/ErpAccount.java

@@ -5,6 +5,9 @@ import org.dozer.Mapping;
 
 import java.io.Serializable;
 
+/**
+ * 导入实体类
+ */
 public class ErpAccount implements Serializable {
     private static final long serialVersionUID = 1L;
 //    private String companyCode;//公司代码

+ 13 - 5
src/main/java/com/jeeplus/modules/sg/financial/erpcredit/mapper/xml/ErpCreditChild1Mapper.xml

@@ -98,34 +98,42 @@
 	
 	<update id="update">
 		UPDATE js_erp_credit_child1 SET
-
+			update_by = #{updateBy.id},
+			update_date = #{updateDate},
+			remarks = #{remarks},
+			del_flag = #{delFlag},
+			eqm_material_details = #{eqmMaterialDetails1},
+			eqm_unit = #{eqmUnit},
+			eqm_numbers = #{eqmNumbers},
+			eqm_total_capacity = #{eqmTotalCapacity},
+			eqm_booked_fee = #{eqmBookedFee1}
 		WHERE id = #{id}
 	</update>
 	
 	
 	<!--物理删除-->
 	<update id="delete">
-		DELETE FROM test_data_child
+		DELETE FROM js_erp_credit_child1
 		<choose>
 			<when test="id !=null and id != ''">
 				WHERE id = #{id}
 			</when>
 			<otherwise>
-				WHERE test_data_main_id = #{testDataMain.id}
+				WHERE erp_credit_id = #{erpCredit.id}
 			</otherwise>
 		</choose>
 	</update>
 	
 	<!--逻辑删除-->
 	<update id="deleteByLogic">
-		UPDATE test_data_child SET 
+		UPDATE js_erp_credit_child1 SET
 			del_flag = #{DEL_FLAG_DELETE}
 		<choose>
 			<when test="id !=null and id != ''">
 				WHERE id = #{id}
 			</when>
 			<otherwise>
-				WHERE test_data_main_id = #{testDataMain.id}
+				WHERE erp_credit_id = #{erpCredit.id}
 			</otherwise>
 		</choose>
 	</update>

+ 9 - 12
src/main/java/com/jeeplus/modules/sg/financial/erpcredit/mapper/xml/ErpCreditChild2Mapper.xml

@@ -88,43 +88,40 @@
 	</insert>
 	
 	<update id="update">
-		UPDATE test_data_child2 SET 	
-			startarea = #{startArea.id},
-			endarea = #{endArea.id},
-			starttime = #{startTime},
-			price = #{price},
-			yes_no = #{isHave},
-			test_data_main = #{testDataMain.id},
+		UPDATE js_erp_credit_child2 SET
 			update_by = #{updateBy.id},
 			update_date = #{updateDate},
-			remarks = #{remarks}
+			remarks = #{remarks},
+			del_flag = #{delFlag},
+			eqm_material_details = #{eqmMaterialDetails2},
+			mtl_booked_fee = #{mtlBookedFee2}
 		WHERE id = #{id}
 	</update>
 	
 	
 	<!--物理删除-->
 	<update id="delete">
-		DELETE FROM test_data_child2
+		DELETE FROM js_erp_credit_child2
 		<choose>
 			<when test="id !=null and id != ''">
 				WHERE id = #{id}
 			</when>
 			<otherwise>
-				WHERE test_data_main = #{testDataMain.id}
+				WHERE erp_credit_id = #{erpCredit.id}
 			</otherwise>
 		</choose>
 	</update>
 	
 	<!--逻辑删除-->
 	<update id="deleteByLogic">
-		UPDATE test_data_child2 SET 
+		UPDATE js_erp_credit_child2 SET
 			del_flag = #{DEL_FLAG_DELETE}
 		<choose>
 			<when test="id !=null and id != ''">
 				WHERE id = #{id}
 			</when>
 			<otherwise>
-				WHERE test_data_main = #{testDataMain.id}
+				WHERE erp_credit_id = #{erpCredit.id}
 			</otherwise>
 		</choose>
 	</update>

+ 13 - 11
src/main/java/com/jeeplus/modules/sg/financial/erpcredit/mapper/xml/ErpCreditChild3Mapper.xml

@@ -100,42 +100,44 @@
 	</insert>
 	
 	<update id="update">
-		UPDATE test_data_child3 SET 	
-			startarea = #{startArea.id},
-			endarea = #{endArea.id},
-			price = #{price},
-			yes_no = #{isHave},
-			test_data_main = #{testDataMain.id},
+		UPDATE js_erp_credit_child3 SET
 			update_by = #{updateBy.id},
 			update_date = #{updateDate},
-			remarks = #{remarks}
+			remarks = #{remarks},
+			del_flag = #{delFlag},
+			tenkv_model = #{tenKvModel},
+			tenkv_unit = #{tenKvUnit},
+			tenkv_length = #{tenKvLength},
+			tenkv_line_length = #{tenKvLineLength},
+			tenkv_its_line = #{tenKvItsLine},
+			tenkv_ites_fhv_follow = #{tenKvItesFhvFollow}
 		WHERE id = #{id}
 	</update>
 	
 	
 	<!--物理删除-->
 	<update id="delete">
-		DELETE FROM test_data_child3
+		DELETE FROM js_erp_credit_child3
 		<choose>
 			<when test="id !=null and id != ''">
 				WHERE id = #{id}
 			</when>
 			<otherwise>
-				WHERE test_data_main = #{testDataMain.id}
+				WHERE erp_credit_id = #{erpCredit.id}
 			</otherwise>
 		</choose>
 	</update>
 	
 	<!--逻辑删除-->
 	<update id="deleteByLogic">
-		UPDATE test_data_child3 SET 
+		UPDATE js_erp_credit_child3 SET
 			del_flag = #{DEL_FLAG_DELETE}
 		<choose>
 			<when test="id !=null and id != ''">
 				WHERE id = #{id}
 			</when>
 			<otherwise>
-				WHERE test_data_main = #{testDataMain.id}
+				WHERE erp_credit_id = #{erpCredit.id}
 			</otherwise>
 		</choose>
 	</update>

+ 18 - 0
src/main/java/com/jeeplus/modules/sg/financial/erpcredit/mapper/xml/ErpCreditMapper.xml

@@ -40,6 +40,9 @@
 		<where>
 			a.del_flag = #{DEL_FLAG_NORMAL}
 			${dataScope}
+			<if test="itemId != null and itemId != ''">
+				AND a.item_id = #{itemId}
+			</if>
 		</where>
 		<choose>
 			<when test="page !=null and page.orderBy != null and page.orderBy != ''">
@@ -122,6 +125,21 @@
 			update_by = #{updateBy.id},
 			update_date = #{updateDate},
 			remarks = #{remarks},
+			del_flag = #{delFlag},
+			item_id = #{itemId},
+			item_name = #{itemName},
+			actual_investment = #{actualInvestment},
+			transfer_assets = #{transferAssets},
+			cons_building_fee = #{consBuildingFee},
+			cons_install_fee = #{consInstallFee},
+			cons_total_fee = #{consInstallFee},
+			other_supervisor_fee = #{otherSupervisorFee},
+			other_design_fee = #{otherDesignFee},
+			other_bework_fee = #{otherBeWorkFee},
+			other_build_loan = #{otherBuildLoan},
+			other_line_damages = #{otherLineDamages},
+			other_legal_manage =#{otherLegalManage},
+			other_total_fee = #{otherTotalFee}
 		WHERE id = #{id}
 	</update>
 

+ 30 - 18
src/main/java/com/jeeplus/modules/sg/financial/erpcredit/service/ErpCreditService.java

@@ -58,33 +58,45 @@ public class ErpCreditService extends CrudService<ErpCreditMapper,ErpCredit> {
         System.out.println(erpCredit);
         super.save(erpCredit);
         for (ErpCreditChild1 erpCreditChild1 : erpCredit.getErpCreditChild1s()){
-            if (erpCreditChild1.getErpCredit().getItemId().isEmpty()){
-                continue;
-            }
             if (ErpCreditChild1.DEL_FLAG_NORMAL.equals(erpCredit.getDelFlag())){
-                erpCreditChild1.setErpCredit(erpCredit);
-                erpCreditChild1.preInsert();
-                erpCreditChild1Mapper.insert(erpCreditChild1);
+                if (StringUtils.isBlank(erpCreditChild1.getId())) {
+                    erpCreditChild1.setErpCredit(erpCredit);
+                    erpCreditChild1.preInsert();
+                    erpCreditChild1Mapper.insert(erpCreditChild1);
+                }else {
+                    erpCreditChild1.preUpdate();
+                    erpCreditChild1Mapper.update(erpCreditChild1);
+                }
+            }else {
+                erpCreditChild1Mapper.delete(erpCreditChild1);
             }
         }
         for (ErpCreditChild2 erpCreditChild2 : erpCredit.getErpCreditChild2s()){
-            if (erpCreditChild2.getErpCredit().getItemId().isEmpty()){
-                continue;
-            }
             if (ErpCreditChild2.DEL_FLAG_NORMAL.equals(erpCreditChild2.getDelFlag())){
-                erpCreditChild2.setErpCredit(erpCredit);
-                erpCreditChild2.preInsert();
-                erpCreditChild2Mapper.insert(erpCreditChild2);
+                if (StringUtils.isBlank(erpCreditChild2.getId())){
+                    erpCreditChild2.setErpCredit(erpCredit);
+                    erpCreditChild2.preInsert();
+                    erpCreditChild2Mapper.insert(erpCreditChild2);
+                }else {
+                    erpCreditChild2.preUpdate();
+                    erpCreditChild2Mapper.update(erpCreditChild2);
+                }
+            }else {
+                erpCreditChild2Mapper.delete(erpCreditChild2);
             }
         }
         for (ErpCreditChild3 erpCreditChild3 : erpCredit.getErpCreditChild3s()){
-            if (erpCreditChild3.getErpCredit().getItemId().isEmpty()){
-                continue;
-            }
             if (ErpCreditChild3.DEL_FLAG_NORMAL.equals(erpCreditChild3.getDelFlag())){
-                erpCreditChild3.setErpCredit(erpCredit);
-                erpCreditChild3.preInsert();
-                erpCreditChild3Mapper.insert(erpCreditChild3);
+                if (StringUtils.isBlank(erpCreditChild3.getId())){
+                    erpCreditChild3.setErpCredit(erpCredit);
+                    erpCreditChild3.preInsert();
+                    erpCreditChild3Mapper.insert(erpCreditChild3);
+                }else {
+                    erpCreditChild3.preUpdate();
+                    erpCreditChild3Mapper.update(erpCreditChild3);
+                }
+            }else {
+                erpCreditChild3Mapper.delete(erpCreditChild3);
             }
         }
     }

+ 72 - 40
src/main/java/com/jeeplus/modules/sg/financial/erpcredit/util/ErpInfo.java

@@ -60,6 +60,11 @@ public  class ErpInfo {
         return true;
     }
 
+    /**
+     * 获取表格数据
+     * @param importUtil
+     * @return List<ErpAccount> 导入表格数据
+     */
     public static List<ErpAccount> getErpAccount(ImportUtil importUtil)  {
         int lastRow = importUtil.getLastDataRowNum();
         List<ErpAccount> list = new ArrayList<ErpAccount>();
@@ -92,7 +97,7 @@ public  class ErpInfo {
      * @return 返回List<ErpCredit>
      */
     public static List<ErpCredit> getAllErpCreditList(List<ErpAccount> list){
-        boolean flag; //设备费开关
+        boolean flag; //设备费开关:施工费中 建筑费 安装判断 true-建筑费 false-安装费
         //获取erpCredit对象 list集合
         List<ErpCredit> erpCredits = getListErpCredit(list);
         //获取ErpCreditChild1对象 list集合 (设备费)
@@ -103,7 +108,7 @@ public  class ErpInfo {
         List<ErpCreditChild3> erpCreditChild3s = getListErpCreditChild3(list);
         //循环erpCredit对象 list集合
         for (ErpCredit erpCredit:erpCredits){
-            flag = true;
+            flag = true;//赋初始值
             //设备费 集合 循环
             for (ErpCreditChild1 erpCreditChild1:erpCreditChild1s){
                 //判断 erpCredit对象项目定义编号  与  ErpCreditChild1对象项目定义编号
@@ -130,22 +135,27 @@ public  class ErpInfo {
                     erpCredit.getErpCreditChild3s().add(erpCreditChild3);
                 }
             }
-            if (flag){
-                System.out.println("1111111111111111");
+            if (flag){//如果为true
+                //施工费合计 赋值为 建筑费(无 设备费入账金额 以及 材料费入账金额)
                 erpCredit.setConsBuildingFee(erpCredit.getConsTotalFee());
             }else {
+                //施工费合计 赋值为安装费(有 设备费入账金额 或者 材料费入账金额)
                 erpCredit.setConsInstallFee(erpCredit.getConsTotalFee());
             }
         }
         return erpCredits;
     }
 
-
+    /**
+     * 获取单独 唯一 的 数据集合(项目定义编号——其他费用合计)
+     * @param list 读取表格获得的列表
+     * @return List<ErpCredit> 主类 集合(单独唯一的数据集合)
+     */
     public static List<ErpCredit> getListErpCredit(List<ErpAccount> list){
-        List<ErpCredit> erpCredits = new ArrayList<ErpCredit>();
-        ErpCredit erpCredit=null;
-        ErpAccount erpAccount=null;
-        boolean flag = true;
+        List<ErpCredit> erpCredits = new ArrayList<ErpCredit>();//定义集合
+        ErpCredit erpCredit=null;//要获取集合对象
+        ErpAccount erpAccount=null;//导入表格对象
+        boolean flag = true;//判断 项目定义编号是否相同 true-不相同 false-相同
         double actualInvestment = 0.0;//实际投资
         double consTotalFee=0.0;//施工费:合计
         double otherSupervisorFee=0.0;//其他费用:监理费:入账金额
@@ -155,36 +165,45 @@ public  class ErpInfo {
         double otherLegalManage=0.0;//法人管理费
         double otherTotalFee=0.0;//其他费用合计
         double lineItemAmount;//行项目金额合计
+        //循环导入表格对象
         for (int i = 0; i < list.size(); i++) {
-            flag = true;
+            flag = true;//默认值为true (默认项目定义编号不相同)
             erpAccount=list.get(i);//获取erpAccount对象
+            //判断 导入表格 对象 的行项目金额是否为空
             if(erpAccount.getLineItemAmount().isEmpty()){
-                lineItemAmount=0.0;
+                lineItemAmount=0.0;//如果为空  默认值为0.0;
             }else {
+                //否则 获取行羡慕金额
                 lineItemAmount = Double.parseDouble(erpAccount.getLineItemAmount());
             }
-            //判断当前集合存在
+            //判断当前 集合有数据
             if (null!=erpCredits&&erpCredits.size()>0){
+                //循环 当前得到的ErpCredits对象
                 for (int j = 0; j < erpCredits.size(); j++) {
                     erpCredit = erpCredits.get(j);//获取 erpCredit对象
                     //判断项目定义号相同
                     if (erpAccount.getProjectDefinitionCode().equals(erpCredit.getItemId())){
-                        //实际投资
+                        //筛选(科目名称)中包含(工程成本-)的所有内容,统计行项目金额合计
                         if (erpAccount.getSubjectName().contains(ErpInfo.CON_PROJECT)){
+                            //当前实际投资+获取到的行项目金额
                             actualInvestment=erpCredit.getActualInvestment()+lineItemAmount;
+                            //替换 实际投资金额
                             erpCredit.setActualInvestment(actualInvestment);
                         }
                         //施工费:合计:入账金额 判断物料描述是否为空
                         if (erpAccount.getMaterialDetails().isEmpty()) {
+                            //筛选物料描述为空的(科目名称)中包含(工程成本-安装工程支出)的所有内容,统计行项目金额合计
                             if (erpAccount.getSubjectName().contains(ErpInfo.CON_PROJECT + ErpInfo.CON_lINE + ErpInfo.CON_IPE)) {
-                                //得到施工费:合计
+                                //当前施工费:合计+获取到的行项目金额
                                 consTotalFee = erpCredit.getConsTotalFee()+ lineItemAmount;
+                                //替换 施工费:合计金额
                                 erpCredit.setConsTotalFee(consTotalFee);
                             }
+                            //筛选物料描述为空的先筛选(科目名称)中包含(工程成本-待摊支出-其他/工程成本-待摊支出-项目法人管理费-其他/项目管理经费 - 会议费)
                             if (erpAccount.getSubjectName().contains(ErpInfo.CON_PlPlQ)||
                                     erpAccount.getSubjectName().contains(ErpInfo.CON_PLPLPLQ)||
                                     erpAccount.getSubjectName().contains(ErpInfo.CON_PLM)){
-                                //判断WBS描述为工程监理费
+                                //筛选(WBS描述)为工程监理费的行项目金额合计
                                 if (erpAccount.getWbsDetails().equals(ErpInfo.CON_PSF)){
                                     otherSupervisorFee = erpCredit.getOtherSupervisorFee()+lineItemAmount;//监理费
                                     erpCredit.setOtherSupervisorFee(otherSupervisorFee);
@@ -204,6 +223,7 @@ public  class ErpInfo {
                                     otherLineDamages = erpCredit.getOtherLineDamages()+lineItemAmount;//建设期贷款利息
                                     erpCredit.setOtherLineDamages(otherLineDamages);
                                 }
+                                //其他费用:法人管理费
                                 otherLegalManage=erpCredit.getOtherLegalManage()+lineItemAmount;
                                 erpCredit.setOtherLegalManage(otherLegalManage);
                                 //其他费用:合计
@@ -218,29 +238,32 @@ public  class ErpInfo {
             }
             //第一次,或者项目定义编码不同 进行如下方法计算
             if (flag){
-                erpCredit = new ErpCredit();
+                erpCredit = new ErpCredit();//获取ErpCredit对象
                 erpCredit.setItemId(erpAccount.getProjectDefinitionCode());//添加项目定义编号
-                erpCredit.setItemName(erpAccount.getProjectDefinitionDetails());//
-                //预先赋值,防止空指针
-                erpCredit.setConsTotalFee(lineItemAmount);
-                erpCredit.setOtherSupervisorFee(lineItemAmount);
-                erpCredit.setOtherDesignFee(lineItemAmount);
-                erpCredit.setOtherBuildLoan(lineItemAmount);
-                erpCredit.setOtherLineDamages(lineItemAmount);
-                erpCredit.setOtherLegalManage(lineItemAmount);
+                erpCredit.setItemName(erpAccount.getProjectDefinitionDetails());//项目名称
+                erpCredit.setConsTotalFee(lineItemAmount);//添加施工费合计
+                erpCredit.setOtherSupervisorFee(lineItemAmount);//添加其他:监理费
+                erpCredit.setOtherDesignFee(lineItemAmount);//添加 其他设计费
+//                erpCredit.setOtherBeWorkFee(lineItemAmount); // 添加 项目前期工作费 (暂不确定)
+                erpCredit.setOtherBuildLoan(lineItemAmount);//添加 建设期贷款利息
+                erpCredit.setOtherLineDamages(lineItemAmount);//添加 线路施工赔偿费
+                erpCredit.setOtherLegalManage(lineItemAmount);//添加 法人管理费
                 //其他费用:合计
                 erpCredit.setOtherTotalFee(lineItemAmount);
 
-                //实际投资
+                //筛选(科目名称)中包含(工程成本-)的所有内容,统计行项目金额合计
                 if (erpAccount.getSubjectName().contains(ErpInfo.CON_PROJECT)){
-                    erpCredit.setActualInvestment(lineItemAmount);//添加实际金额
+                    //添加行项目金额 到 ErpCredit对象中的实际投资金额
+                    erpCredit.setActualInvestment(lineItemAmount);
                 }
                 //施工费:合计:入账金额 判断物料描述是否为空
                 if (erpAccount.getMaterialDetails().isEmpty()) {
+                    //筛选物料描述为空的(科目名称)中包含(工程成本-安装工程支出)的所有内容,统计行项目金额合计
                     if (erpAccount.getSubjectName().contains(ErpInfo.CON_PROJECT + ErpInfo.CON_lINE + ErpInfo.CON_IPE)) {
                         //得到施工费
                         erpCredit.setConsTotalFee(lineItemAmount);
                     }
+                    //筛选物料描述为空的先筛选(科目名称)中包含(工程成本-待摊支出-其他/工程成本-待摊支出-项目法人管理费-其他/项目管理经费 - 会议费)
                     if (erpAccount.getSubjectName().contains(ErpInfo.CON_PlPlQ)||
                             erpAccount.getSubjectName().contains(ErpInfo.CON_PLPLPLQ)||
                             erpAccount.getSubjectName().contains(ErpInfo.CON_PLM)){
@@ -260,6 +283,7 @@ public  class ErpInfo {
                         if (erpAccount.getWbsDetails().equals(ErpInfo.CON_OLD)){
                             erpCredit.setOtherLineDamages(lineItemAmount);
                         }
+                        //其他费用:法人管理费
                         erpCredit.setOtherLegalManage(lineItemAmount);
                         //其他费用:合计
                         erpCredit.setOtherTotalFee(lineItemAmount);
@@ -280,7 +304,7 @@ public  class ErpInfo {
         Double eqmNumbers=0.0;//设备台数
         Double eqmBookedFee=0.0;//设备入账金额
         String materialDetails="";//筛选kva
-        boolean flag = true;//开关:判断集合是否重复
+        boolean flag = true;//开关:判断集合是否重复 true-物料描述不同 false-项目定义编号相同且物料描述相同
         ErpCreditChild1 erpCreditChild1;//设备对象
         ErpCredit erpCredit;//设备父类
         ErpAccount erpAccount;//数据集合
@@ -288,16 +312,19 @@ public  class ErpInfo {
         for (int i = 0; i < list.size(); i++) {
             flag=true;
             erpAccount=list.get(i);
+            //判断设备台数是否为空
             if (erpAccount.getTheNumber().isEmpty()){//设备台数
-                eqmNumbers=0.0;
+                eqmNumbers=0.0; //为空时 赋初始值0.0
             }else {
-                eqmNumbers = Double.parseDouble(erpAccount.getTheNumber());
+                eqmNumbers = Double.parseDouble(erpAccount.getTheNumber()); //否则 获取设备台数 信息
             }
-            if (erpAccount.getLineItemAmount().isEmpty()){//入账金额
-                eqmBookedFee=0.0;
+            //判断如行项目金额是否为空
+            if (erpAccount.getLineItemAmount().isEmpty()){
+                eqmBookedFee=0.0;//入账金额赋初始值
             }else {
-                eqmBookedFee = Double.parseDouble(erpAccount.getLineItemAmount());
+                eqmBookedFee = Double.parseDouble(erpAccount.getLineItemAmount());//行项目金额赋值费入账金额
             }
+            //判断当前 设备费 集合是否存在
             if (null!=creditListChild1&&creditListChild1.size()>0){
                 for (int j = 0; j < creditListChild1.size(); j++) {
                     erpCreditChild1 = creditListChild1.get(j);//获取设备对象
@@ -306,10 +333,10 @@ public  class ErpInfo {
                         //判断物料描述是否相同
                         if (erpAccount.getMaterialDetails().equals(erpCreditChild1.getEqmMaterialDetails1())) {
                             eqmBookedFee += erpCreditChild1.getEqmBookedFee1();//累加 入账金额
-                            erpCreditChild1.setEqmBookedFee1(eqmBookedFee);
+                            erpCreditChild1.setEqmBookedFee1(eqmBookedFee);//替换
                             eqmNumbers += erpCreditChild1.getEqmNumbers();//累计 数量
-                            erpCreditChild1.setEqmNumbers(eqmNumbers);
-                            flag = false;
+                            erpCreditChild1.setEqmNumbers(eqmNumbers);//替换
+                            flag = false;// 项目定义编号相同且物料描述相同(当前ErpAccount对象在ErpCreditChild1对象中存在且相同 跳过下面方法)
                             break;
                         }
                     }
@@ -324,6 +351,7 @@ public  class ErpInfo {
                     erpCreditChild1 = new ErpCreditChild1();//获取设备对象
                     erpCredit=new ErpCredit();//获取设备 父类 主类
                     materialDetails = erpAccount.getMaterialDetails();//获取物料描述
+                    //截取总容量kVA前数字
                     if (materialDetails.contains("kVA")){
                         String str[] =  materialDetails.split(",");
                         for (int k = 0; k < str.length; k++) {
@@ -353,19 +381,22 @@ public  class ErpInfo {
      */
     public static List<ErpCreditChild2> getListErpCreditChild2(List<ErpAccount> erpAccounts){
         List<ErpCreditChild2> creditListChild2 = new ArrayList<ErpCreditChild2>();
-        boolean flag = true;//判断 材料费
+        boolean flag = true;//判断 材料费 true-物料描述不同或者项目定义编号不同 false-仙姑定义编号物料描述相同
         double eqmBookedFee2=0.0;//材料入账金额
         ErpCreditChild2 erpCreditChild2=null;
         ErpCredit erpCredit = null;
         ErpAccount erpAccount=null;
         for (int i = 0; i < erpAccounts.size(); i++) {
-            flag=true;
+            flag=true;//默认初始值 项目定义编号不同
             erpAccount = erpAccounts.get(i);
+            //判断行项目金额是否为空
             if (erpAccount.getLineItemAmount().isEmpty()){
-                eqmBookedFee2 = 0.0;
+                eqmBookedFee2 = 0.0;//材料入账金额初始值为0.0
             }else {
+                //赋值材料入账金额为行项目金额
                 eqmBookedFee2 = Double.parseDouble(erpAccount.getLineItemAmount());
             }
+            //判断creditListChild2对象集合 是否存在
             if (null!=creditListChild2&&creditListChild2.size()>0){
                 for (int j = 0; j < creditListChild2.size(); j++) {
                     erpCreditChild2 = creditListChild2.get(j);
@@ -406,7 +437,7 @@ public  class ErpInfo {
     /**
      * 获取 10kv数据集合
      * @param erpAccounts
-     * @return
+     * @return List<ErpCreditChild3> 10KV线路信息
      */
     public static List<ErpCreditChild3> getListErpCreditChild3(List<ErpAccount> erpAccounts){
         List<ErpCreditChild3> creditChild3s = new ArrayList<ErpCreditChild3>();
@@ -423,6 +454,7 @@ public  class ErpInfo {
             }else {
                 tenKvLength = Double.parseDouble(erpAccount.getTheNumber());
             }
+            //相同判断
             if (null!=creditChild3s&&creditChild3s.size()>0){
                 for (int j = 0; j < creditChild3s.size(); j++) {
                     erpCreditChild3 = creditChild3s.get(j);
@@ -439,7 +471,7 @@ public  class ErpInfo {
                     }
                 }
             }
-            if (flag){
+            if (flag){//赋值初始值
                 if (erpAccount.getMaterialDetails().contains(ErpInfo.CON_OICAC10)||
                         erpAccount.getMaterialDetails().contains(ErpInfo.CON_OICAC20)||
                         erpAccount.getMaterialDetails().contains(ErpInfo.CON_PRCAC10)||

+ 2 - 2
src/main/java/com/jeeplus/modules/sg/financial/erpcredit/web/ErpCreditController.java

@@ -219,9 +219,9 @@ public class ErpCreditController extends BaseController {
 	public AjaxJson importFileTemplate(HttpServletResponse response) {
 		AjaxJson j = new AjaxJson();
 		try {
-			String fileName = "请假表单数据导入模板.xlsx";
+			String fileName = "表单数据导入模板.xlsx";
 			List<ErpCredit> list = Lists.newArrayList();
-			new ExportExcel("请假表单数据", ErpCredit.class, 1).setDataList(list).write(response, fileName).dispose();
+			new ExportExcel("表单数据", ErpCredit.class, 1).setDataList(list).write(response, fileName).dispose();
 			return null;
 		} catch (Exception e) {
 			j.setSuccess(false);

+ 104 - 154
src/main/webapp/webpage/modules/sg/financial/erp/erpCreditForm.jsp

@@ -2,7 +2,7 @@
 <%@ include file="/webpage/include/taglib.jsp"%>
 <html>
 <head>
-	<title>Erp项目管理</title>
+	<title>新增ERP账户</title>
 	<meta name="decorator" content="ani"/>
 	<script type="text/javascript">
 
@@ -18,7 +18,7 @@
                 return false;
 			}else{
                 jp.loading();
-                jp.post("${ctx}/test/onetomany/dialog/testDataMain1/save",$('#inputForm').serialize(),function(data){
+                jp.post("${ctx}/sg/financial/erpCredit/save",$('#inputForm').serialize(),function(data){
                     if(data.success){
                         jp.getParent().refresh();
                         var dialogIndex = parent.layer.getFrameIndex(window.name); // 获取窗口索引
@@ -71,65 +71,91 @@
 	</script>
 </head>
 <body class="bg-white">
-		<form:form id="inputForm" modelAttribute="testDataMain1" action="${ctx}/test/onetomany/dialog/testDataMain1/save" method="post" class="form-horizontal">
+		<form:form id="inputForm" modelAttribute="erpCredit" action="${ctx}/sg/financial/erpCredit/save" method="post" class="form-horizontal">
 		<form:hidden path="id"/>
 		<table class="table table-bordered">
 		   <tbody>
 				<tr>
-					<td class="width-15 active"><label class="pull-right"><font color="red">*</font>归属用户:</label></td>
+					<td class="width-15 active"><label class="pull-right"><font color="red">*</font>项目定义编号:</label></td>
 					<td class="width-35">
-						<sys:userselect id="tuser" name="tuser.id" value="${testDataMain1.tuser.id}" labelName="tuser.name" labelValue="${testDataMain1.tuser.name}"
-							    cssClass="form-control required"/>
+						<form:input path="itemId" htmlEscape="false" class="form-control required"/>
 					</td>
-					<td class="width-15 active"><label class="pull-right"><font color="red">*</font>归属部门:</label></td>
+					<td class="width-15 active"><label class="pull-right"><font color="red">*</font>项目名称:</label></td>
 					<td class="width-35">
-						<sys:treeselect id="office" name="office.id" value="${testDataMain1.office.id}" labelName="office.name" labelValue="${testDataMain1.office.name}"
-							title="部门" url="/sys/office/treeData?type=2" cssClass="form-control required" allowClear="true" notAllowSelectParent="true"/>
+						<form:input path="itemName" htmlEscape="false"    class="form-control required"/>
 					</td>
 				</tr>
 				<tr>
-					<td class="width-15 active"><label class="pull-right"><font color="red">*</font>归属区域:</label></td>
+					<td class="width-15 active"><label class="">实际投资:</label></td>
 					<td class="width-35">
-						<sys:treeselect id="area" name="area.id" value="${testDataMain1.area.id}" labelName="area.name" labelValue="${testDataMain1.area.name}"
-							title="区域" url="/sys/area/treeData" cssClass="form-control required" allowClear="true" notAllowSelectParent="true"/>
+						<form:input path="actualInvestment" htmlEscape="false"    class="form-control"/>
 					</td>
-					<td class="width-15 active"><label class="pull-right"><font color="red">*</font>名称:</label></td>
+					<td class="width-15 active"><label class="">移交生产的资产总值:</label></td>
 					<td class="width-35">
-						<form:input path="name" htmlEscape="false"    class="form-control required"/>
+						<form:input path="transferAssets" htmlEscape="false"    class="form-control"/>
 					</td>
 				</tr>
 				<tr>
-					<td class="width-15 active"><label class="pull-right"><font color="red">*</font>性别:</label></td>
+					<td class="width-15 active"><label class="">建筑费:</label></td>
 					<td class="width-35">
-						<form:radiobuttons path="sex" items="${fns:getDictList('sex')}" itemLabel="label" itemValue="value" htmlEscape="false" class="i-checks required"/>
+						<form:input path="consBuildingFee" htmlEscape="false"    class="form-control"/>
 					</td>
-					<td class="width-15 active"><label class="pull-right"><font color="red">*</font>加入日期:</label></td>
+					<td class="width-15 active"><label class="">安装费:</label></td>
 					<td class="width-35">
-							<div class='input-group form_datetime' id='inDate'>
-			                    <input type='text'  name="inDate" class="form-control required"  value="<fmt:formatDate value="${testDataMain1.inDate}" pattern="yyyy-MM-dd HH:mm:ss"/>"/>
-			                    <span class="input-group-addon">
-			                        <span class="glyphicon glyphicon-calendar"></span>
-			                    </span>
-			                </div>						            
+						<form:input path="consInstallFee" htmlEscape="false"    class="form-control"/>
 					</td>
 				</tr>
 				<tr>
-					<td class="width-15 active"><label class="pull-right">备注信息:</label></td>
+					<td class="width-15 active"><label class="">施工费:合计:</label></td>
 					<td class="width-35">
-						<form:textarea path="remarks" htmlEscape="false" rows="4"    class="form-control "/>
+						<form:input path="consTotalFee" htmlEscape="false"    class="form-control"/>
 					</td>
-					<td class="width-15 active"></td>
-		   			<td class="width-35" ></td>
-		  		</tr>
+				</tr>
+				<tr>
+					<td class="width-15 active"><label class="">监理费:</label></td>
+					<td class="width-35">
+						<form:input path="otherSupervisorFee" htmlEscape="false"    class="form-control"/>
+					</td>
+					<td class="width-15 active"><label class="">设计费:</label></td>
+					<td class="width-35">
+						<form:input path="otherDesignFee" htmlEscape="false"    class="form-control"/>
+					</td>
+				</tr>
+				<tr>
+					<td class="width-15 active"><label class="">项目前期工作费:</label></td>
+					<td class="width-35">
+						<form:input path="otherBeWorkFee" htmlEscape="false"    class="form-control"/>
+					</td>
+					<td class="width-15 active"><label class="">建设期贷款利息:</label></td>
+					<td class="width-35">
+						<form:input path="otherBuildLoan" htmlEscape="false"    class="form-control"/>
+					</td>
+				</tr>
+				<tr>
+					<td class="width-15 active"><label class="">线路施工赔偿费:</label></td>
+					<td class="width-35">
+						<form:input path="otherLineDamages" htmlEscape="false"    class="form-control"/>
+					</td>
+					<td class="width-15 active"><label class="">法人管理费:</label></td>
+					<td class="width-35">
+						<form:input path="otherLegalManage" htmlEscape="false"    class="form-control"/>
+					</td>
+				</tr>
+				<tr>
+					<td class="width-15 active"><label class="">其他费用:合计:</label></td>
+					<td class="width-35">
+						<form:input path="otherTotalFee" htmlEscape="false"    class="form-control"/>
+					</td>
+				</tr>
 		 	</tbody>
 		</table>
 		<div class="tabs-container">
             <ul class="nav nav-tabs">
-				<li class="active"><a data-toggle="tab" href="#tab-1" aria-expanded="true">火车票:</a>
+				<li class="active"><a data-toggle="tab" href="#tab-1" aria-expanded="true">设备费</a>
                 </li>
-				<li class=""><a data-toggle="tab" href="#tab-2" aria-expanded="false">飞机票:</a>
+				<li class=""><a data-toggle="tab" href="#tab-2" aria-expanded="false">材料费</a>
                 </li>
-				<li class=""><a data-toggle="tab" href="#tab-3" aria-expanded="false">汽车票:</a>
+				<li class=""><a data-toggle="tab" href="#tab-3" aria-expanded="false">10KV线路信息</a>
                 </li>
             </ul>
             <div class="tab-content">
@@ -139,75 +165,48 @@
 				<thead>
 					<tr>
 						<th class="hide"></th>
-						<th><font color="red">*</font>出发地</th>
-						<th><font color="red">*</font>目的地</th>
-						<th><font color="red">*</font>出发时间</th>
-						<th><font color="red">*</font>代理价格</th>
-						<th>是否有票</th>
-						<th>备注信息</th>
+						<th><font color="red">*</font>物料描述</th>
+						<th>单位</th>
+						<th>台数</th>
+						<th>总容量(千伏安)</th>
+						<th>入账金额(不含税价)</th>
 						<th width="10">&nbsp;</th>
 					</tr>
 				</thead>
 				<tbody id="testDataChild11List">
 				</tbody>
 			</table>
-			<script type="text/template" id="testDataChild11Tpl">//<!--
+			<script type="text/template" id="testDataChild11Tpl">
 				<tr id="testDataChild11List{{idx}}">
 					<td class="hide">
-						<input id="testDataChild11List{{idx}}_id" name="testDataChild11List[{{idx}}].id" type="hidden" value="{{row.id}}"/>
-						<input id="testDataChild11List{{idx}}_delFlag" name="testDataChild11List[{{idx}}].delFlag" type="hidden" value="0"/>
+						<input id="testDataChild11List{{idx}}_id" name="erpCreditChild1s[{{idx}}].id" type="hidden" value="{{row.id}}"/>
+						<input id="testDataChild11List{{idx}}_delFlag" name="erpCreditChild1s[{{idx}}].delFlag" type="hidden" value="0"/>
 					</td>
-					
 					<td  class="max-width-250">
-						<sys:treeselect id="testDataChild11List{{idx}}_startArea" name="testDataChild11List[{{idx}}].startArea.id" value="{{row.startArea.id}}" labelName="testDataChild11List{{idx}}.startArea.name" labelValue="{{row.startArea.name}}"
-							title="区域" url="/sys/area/treeData" cssClass="form-control  required" allowClear="true" notAllowSelectParent="true"/>
+						<input  name="erpCreditChild1s[{{idx}}].eqmMaterialDetails1" class="form-control required" type="text" value="{{row.eqmMaterialDetails1}}"/>
 					</td>
-					
-					
 					<td  class="max-width-250">
-						<sys:treeselect id="testDataChild11List{{idx}}_endArea" name="testDataChild11List[{{idx}}].endArea.id" value="{{row.endArea.id}}" labelName="testDataChild11List{{idx}}.endArea.name" labelValue="{{row.endArea.name}}"
-							title="区域" url="/sys/area/treeData" cssClass="form-control  required" allowClear="true" notAllowSelectParent="true"/>
+						<input  name="erpCreditChild1s[{{idx}}].eqmUnit" class="form-control" type="text" value="{{row.eqmUnit}}"/>
 					</td>
-					
-					
 					<td>
-						<div class='input-group form_datetime' id="testDataChild11List{{idx}}_starttime">
-		                    <input type='text'  name="testDataChild11List[{{idx}}].starttime" class="form-control required"  value="{{row.starttime}}"/>
-		                    <span class="input-group-addon">
-		                        <span class="glyphicon glyphicon-calendar"></span>
-		                    </span>
-		                </div>						            
+						<input  name="erpCreditChild1s[{{idx}}].eqmNumbers" class="form-control" type="text" value="{{row.eqmNumbers}}"/>
 					</td>
-					
-					
 					<td>
-						<input id="testDataChild11List{{idx}}_price" name="testDataChild11List[{{idx}}].price" type="text" value="{{row.price}}"    class="form-control required isFloatGteZero"/>
+						<input  name="erpCreditChild1s[{{idx}}].eqmTotalCapacity" class="form-control" type="text" value="{{row.eqmTotalCapacity}}"/>
 					</td>
-					
-					
 					<td>
-						<select id="testDataChild11List{{idx}}_isHave" name="testDataChild11List[{{idx}}].isHave" data-value="{{row.isHave}}" class="form-control m-b  ">
-							<option value=""></option>
-							<c:forEach items="${fns:getDictList('yes_no')}" var="dict">
-								<option value="${dict.value}">${dict.label}</option>
-							</c:forEach>
-						</select>
+						<input  name="erpCreditChild1s[{{idx}}].eqmBookedFee1" class="form-control" type="text" value="{{row.eqmBookedFee1}}"/>
 					</td>
-					
-					
-					<td>
-						<textarea id="testDataChild11List{{idx}}_remarks" name="testDataChild11List[{{idx}}].remarks" rows="4"    class="form-control ">{{row.remarks}}</textarea>
-					</td>
-					
+
 					<td class="text-center" width="10">
 						{{#delBtn}}<span class="close" onclick="delRow(this, '#testDataChild11List{{idx}}')" title="删除">&times;</span>{{/delBtn}}
 					</td>
-				</tr>//-->
+				</tr>
 			</script>
 			<script type="text/javascript">
 				var testDataChild11RowIdx = 0, testDataChild11Tpl = $("#testDataChild11Tpl").html().replace(/(\/\/\<!\-\-)|(\/\/\-\->)/g,"");
 				$(document).ready(function() {
-					var data = ${fns:toJson(testDataMain1.testDataChild11List)};
+					var data = ${fns:toJson(erpCredit.erpCreditChild1s)};
 					for (var i=0; i<data.length; i++){
 						addRow('#testDataChild11List', testDataChild11RowIdx, testDataChild11Tpl, data[i]);
 						testDataChild11RowIdx = testDataChild11RowIdx + 1;
@@ -221,75 +220,39 @@
 				<thead>
 					<tr>
 						<th class="hide"></th>
-						<th><font color="red">*</font>出发地</th>
-						<th><font color="red">*</font>目的地</th>
-						<th><font color="red">*</font>出发时间</th>
-						<th><font color="red">*</font>代理价格</th>
-						<th><font color="red">*</font>是否有票</th>
-						<th><font color="red">*</font>备注信息</th>
+						<th><font color="red">*</font>物料描述</th>
+						<th>入账金额(不含税价)</th>
 						<th width="10">&nbsp;</th>
 					</tr>
 				</thead>
 				<tbody id="testDataChild12List">
 				</tbody>
 			</table>
-			<script type="text/template" id="testDataChild12Tpl">//<!--
+			<script type="text/template" id="testDataChild12Tpl">
 				<tr id="testDataChild12List{{idx}}">
 					<td class="hide">
-						<input id="testDataChild12List{{idx}}_id" name="testDataChild12List[{{idx}}].id" type="hidden" value="{{row.id}}"/>
-						<input id="testDataChild12List{{idx}}_delFlag" name="testDataChild12List[{{idx}}].delFlag" type="hidden" value="0"/>
+						<input id="testDataChild12List{{idx}}_id" name="erpCreditChild2s[{{idx}}].id" type="hidden" value="{{row.id}}"/>
+						<input id="testDataChild12List{{idx}}_delFlag" name="erpCreditChild2s[{{idx}}].delFlag" type="hidden" value="0"/>
 					</td>
 					
 					<td  class="max-width-250">
-						<sys:treeselect id="testDataChild12List{{idx}}_startArea" name="testDataChild12List[{{idx}}].startArea.id" value="{{row.startArea.id}}" labelName="testDataChild12List{{idx}}.startArea.name" labelValue="{{row.startArea.name}}"
-							title="区域" url="/sys/area/treeData" cssClass="form-control  required" allowClear="true" notAllowSelectParent="true"/>
+						<input  name="erpCreditChild2s[{{idx}}].eqmMaterialDetails2" class="form-control required" type="text" value="{{row.eqmMaterialDetails2}}"/>
 					</td>
 					
 					
 					<td  class="max-width-250">
-						<sys:treeselect id="testDataChild12List{{idx}}_endArea" name="testDataChild12List[{{idx}}].endArea.id" value="{{row.endArea.id}}" labelName="testDataChild12List{{idx}}.endArea.name" labelValue="{{row.endArea.name}}"
-							title="区域" url="/sys/area/treeData" cssClass="form-control  required" allowClear="true" notAllowSelectParent="true"/>
-					</td>
-					
-					
-					<td>
-						<div class='input-group form_datetime' id="testDataChild12List{{idx}}_startTime">
-		                    <input type='text'  name="testDataChild12List[{{idx}}].startTime" class="form-control required"  value="{{row.startTime}}"/>
-		                    <span class="input-group-addon">
-		                        <span class="glyphicon glyphicon-calendar"></span>
-		                    </span>
-		                </div>						            
-					</td>
-					
-					
-					<td>
-						<input id="testDataChild12List{{idx}}_price" name="testDataChild12List[{{idx}}].price" type="text" value="{{row.price}}"    class="form-control required isFloatGteZero"/>
-					</td>
-					
-					
-					<td>
-						<select id="testDataChild12List{{idx}}_isHave" name="testDataChild12List[{{idx}}].isHave" data-value="{{row.isHave}}" class="form-control m-b  required">
-							<option value=""></option>
-							<c:forEach items="${fns:getDictList('yes_no')}" var="dict">
-								<option value="${dict.value}">${dict.label}</option>
-							</c:forEach>
-						</select>
-					</td>
-					
-					
-					<td>
-						<textarea id="testDataChild12List{{idx}}_remarks" name="testDataChild12List[{{idx}}].remarks" rows="4"    class="form-control required">{{row.remarks}}</textarea>
+						<input  name="erpCreditChild2s[{{idx}}].mtlBookedFee2" class="form-control" type="text" value="{{row.mtlBookedFee2}}"/>
 					</td>
 					
 					<td class="text-center" width="10">
 						{{#delBtn}}<span class="close" onclick="delRow(this, '#testDataChild12List{{idx}}')" title="删除">&times;</span>{{/delBtn}}
 					</td>
-				</tr>//-->
+				</tr>
 			</script>
 			<script type="text/javascript">
 				var testDataChild12RowIdx = 0, testDataChild12Tpl = $("#testDataChild12Tpl").html().replace(/(\/\/\<!\-\-)|(\/\/\-\->)/g,"");
 				$(document).ready(function() {
-					var data = ${fns:toJson(testDataMain1.testDataChild12List)};
+					var data = ${fns:toJson(erpCredit.erpCreditChild2s)};
 					for (var i=0; i<data.length; i++){
 						addRow('#testDataChild12List', testDataChild12RowIdx, testDataChild12Tpl, data[i]);
 						testDataChild12RowIdx = testDataChild12RowIdx + 1;
@@ -303,64 +266,51 @@
 				<thead>
 					<tr>
 						<th class="hide"></th>
-						<th><font color="red">*</font>出发地</th>
-						<th><font color="red">*</font>目的地</th>
-						<th>代理价格</th>
-						<th>是否有票</th>
-						<th>备注信息</th>
+						<th><font color="red">*</font>10KV电缆、架空导线型号</th>
+						<th>单位</th>
+						<th>长度</th>
+						<th>10KV线路长度(KM)</th>
+						<th>其中:10KV线路</th>
+						<th>其中:400V及以下</th>
 						<th width="10">&nbsp;</th>
 					</tr>
 				</thead>
 				<tbody id="testDataChild13List">
 				</tbody>
 			</table>
-			<script type="text/template" id="testDataChild13Tpl">//<!--
+			<script type="text/template" id="testDataChild13Tpl">
 				<tr id="testDataChild13List{{idx}}">
 					<td class="hide">
-						<input id="testDataChild13List{{idx}}_id" name="testDataChild13List[{{idx}}].id" type="hidden" value="{{row.id}}"/>
-						<input id="testDataChild13List{{idx}}_delFlag" name="testDataChild13List[{{idx}}].delFlag" type="hidden" value="0"/>
+						<input id="testDataChild13List{{idx}}_id" name="erpCreditChild3s[{{idx}}].id" type="hidden" value="{{row.id}}"/>
+						<input id="testDataChild13List{{idx}}_delFlag" name="erpCreditChild3s[{{idx}}].delFlag" type="hidden" value="0"/>
 					</td>
-					
 					<td  class="max-width-250">
-						<sys:treeselect id="testDataChild13List{{idx}}_startArea" name="testDataChild13List[{{idx}}].startArea.id" value="{{row.startArea.id}}" labelName="testDataChild13List{{idx}}.startArea.name" labelValue="{{row.startArea.name}}"
-							title="区域" url="/sys/area/treeData" cssClass="form-control  required" allowClear="true" notAllowSelectParent="true"/>
+						<input  name="erpCreditChild3s[{{idx}}].tenKvModel" class="form-control required" type="text" value="{{row.tenKvModel}}"/>
 					</td>
-					
-					
 					<td  class="max-width-250">
-						<sys:treeselect id="testDataChild13List{{idx}}_endArea" name="testDataChild13List[{{idx}}].endArea.id" value="{{row.endArea.id}}" labelName="testDataChild13List{{idx}}.endArea.name" labelValue="{{row.endArea.name}}"
-							title="区域" url="/sys/area/treeData" cssClass="form-control  required" allowClear="true" notAllowSelectParent="true"/>
+						<input  name="erpCreditChild3s[{{idx}}].tenKvUnit" class="form-control" type="text" value="{{row.tenKvUnit}}"/>
 					</td>
-					
-					
-					<td>
-						<input id="testDataChild13List{{idx}}_price" name="testDataChild13List[{{idx}}].price" type="text" value="{{row.price}}"    class="form-control "/>
+					<td  class="max-width-250">
+						<input  name="erpCreditChild3s[{{idx}}].tenKvLength" class="form-control" type="text" value="{{row.tenKvLength}}"/>
 					</td>
-					
-					
-					<td>
-						<select id="testDataChild13List{{idx}}_isHave" name="testDataChild13List[{{idx}}].isHave" data-value="{{row.isHave}}" class="form-control m-b  ">
-							<option value=""></option>
-							<c:forEach items="${fns:getDictList('yes_no')}" var="dict">
-								<option value="${dict.value}">${dict.label}</option>
-							</c:forEach>
-						</select>
+					<td  class="max-width-250">
+						<input  name="erpCreditChild3s[{{idx}}].tenKvLineLength" class="form-control" type="text" value="{{row.tenKvLineLength}}"/>
 					</td>
-					
-					
-					<td>
-						<textarea id="testDataChild13List{{idx}}_remarks" name="testDataChild13List[{{idx}}].remarks" rows="4"    class="form-control ">{{row.remarks}}</textarea>
+					<td  class="max-width-250">
+						<input  name="erpCreditChild3s[{{idx}}].tenKvItsLine" class="form-control" type="text" value="{{row.tenKvItsLine}}"/>
+					</td>
+					<td  class="max-width-250">
+						<input  name="erpCreditChild3s[{{idx}}].tenKvItesFhvFollow" class="form-control" type="text" value="{{row.tenKvItesFhvFollow}}"/>
 					</td>
-					
 					<td class="text-center" width="10">
 						{{#delBtn}}<span class="close" onclick="delRow(this, '#testDataChild13List{{idx}}')" title="删除">&times;</span>{{/delBtn}}
 					</td>
-				</tr>//-->
+				</tr>
 			</script>
 			<script type="text/javascript">
 				var testDataChild13RowIdx = 0, testDataChild13Tpl = $("#testDataChild13Tpl").html().replace(/(\/\/\<!\-\-)|(\/\/\-\->)/g,"");
 				$(document).ready(function() {
-					var data = ${fns:toJson(testDataMain1.testDataChild13List)};
+					var data = ${fns:toJson(erpCredit.erpCreditChild3s)};
 					for (var i=0; i<data.length; i++){
 						addRow('#testDataChild13List', testDataChild13RowIdx, testDataChild13Tpl, data[i]);
 						testDataChild13RowIdx = testDataChild13RowIdx + 1;

+ 2 - 2
src/main/webapp/webpage/modules/sg/financial/erp/erpCreditList.js

@@ -150,7 +150,7 @@ $(document).ready(function() {
                    }
                    ,{
                        field: 'consTotalFee',
-                       title: '计',
+                       title: '施工费:合计',
                        sortable: true,
                        sortName: 'consTotalFee'
 
@@ -199,7 +199,7 @@ $(document).ready(function() {
                    }
                    ,{
                        field: 'otherTotalFee',
-                       title: '合计',
+                       title: '其他费用:合计',
                        sortable: true,
                        sortName: 'otherTotalFee'
 

+ 1 - 1
src/main/webapp/webpage/modules/sg/financial/erp/erpCreditList.jsp

@@ -23,7 +23,7 @@
 				<form:form id="searchForm" modelAttribute="erpCredit" class="form form-horizontal well clearfix">
 					<div class="col-xs-12 col-sm-6 col-md-4">
 						<label class="label-item single-overflow pull-left" title="项目定义编码:">项目定义编码:</label>
-						<form:input path="itemId" htmlEscape="false" maxlength="64"  class="form-control"/>
+						<form:input path="itemId" htmlEscape="false" maxlength="100"  class=" form-control"/>
 					</div>
 					<div class="col-xs-12 col-sm-6 col-md-4">
 						<div style="margin-top:26px">