蔡德晨 před 5 roky
rodič
revize
83f8fcf099

+ 19 - 0
src/main/java/com/jeeplus/modules/sg/entity/TzData.java

@@ -4,6 +4,25 @@ public class TzData {
     private String id;
     private String type;
     private Double fee;
+    private String state;
+    private String wbsCode;
+
+
+    public String getState() {
+        return state;
+    }
+
+    public void setState(String state) {
+        this.state = state;
+    }
+
+    public String getWbsCode() {
+        return wbsCode;
+    }
+
+    public void setWbsCode(String wbsCode) {
+        this.wbsCode = wbsCode;
+    }
 
     public String getId() {
         return id;

+ 49 - 17
src/main/java/com/jeeplus/modules/sg/mapper/xml/JkxlMapper.xml

@@ -115,25 +115,45 @@
 		)
 	</insert>
 
-	<insert id="saveProject" parameterType="com.jeeplus.modules.sg.entity.WbsProject">
-		insert into sg_wbs_project
-		(id,
-		 project_name,
-		 create_date
-		) values (
-		 #{id},
-		 #{name},
-		 #{createDate}
-		)
-	</insert>
 
-    <!--<update id="updateData" parameterType="com.jeeplus.modules.sg.entity.WbsProject">-->
-          <!--update sg_wbs_fee set-->
 
-          <!--<where>-->
-              <!--id = #{id} and wbs_code = #{wbsCode}-->
-          <!--</where>-->
-    <!--</update>-->
+    <update id="updateData" parameterType="com.jeeplus.modules.sg.entity.WbsProject">
+          update sg_wbs_fee set
+             <if test="rgFtFee != null and rgFtFee != ''">
+				 rg_fee_ft = #{rgFtFee},
+			 </if>
+		     <if test="cbrFtFee != null and cbrFtFee != ''">
+				 cbr_fee_ft = #{cbrFtFee},
+		     </if>
+		     <if test="fbrFtFee != null and fbrFtFee != ''">
+				 fbr_fee_ft =  #{fbrFtFee},
+		     </if>
+		      <if test="jxFtFee != null and jxFtFee != ''">
+				  jx_fee_ft =  #{jxFtFee},
+			  </if>
+		      <if test="measuresFee1 != null and measuresFee1 != ''">
+				  measures_fee1 = #{measuresFee1},
+		     </if>
+		      <if test="measuresFee2 != null and measuresFee2 != ''">
+				  measures_fee2 = #{measuresFee2},
+		     </if>
+		     <if test="otherCost != null and otherCost != ''">
+				 other_cost = #{otherCost},
+		     </if>
+		     <if test="fees != null and fees != ''">
+				 fees = #{fees},
+		     </if>
+		     <if test="tex != null and tex != ''">
+				 tex = #{tex},
+		    </if>
+		    <if test="totalFee != null and totalFee != ''">
+				total_fee = #{totalFee},
+		    </if>
+		    id = #{id}
+          <where>
+              id = #{id} and wbs_code = #{wbsCode}
+          </where>
+    </update>
 
 	<select id="getTzFee" parameterType="com.jeeplus.modules.sg.entity.TzData" resultType="com.jeeplus.modules.sg.entity.TzData">
 		select id,type,fee from sg_wbs_fee_tz
@@ -169,6 +189,18 @@
 		)
 	</insert>
 
+	<insert id="saveProject" parameterType="com.jeeplus.modules.sg.entity.WbsProject">
+		insert into sg_wbs_project
+		(id,
+		 project_name,
+		 create_date
+		) values (
+		 #{id},
+		 #{name},
+		 #{createDate}
+		)
+	</insert>
+
 
 
 	

+ 1 - 0
src/main/java/com/jeeplus/modules/sg/service/JkxlService.java

@@ -50,6 +50,7 @@ public class JkxlService {
 
     @Transactional
    public void  updateFee(TzData tzData){
+       tzData.setFee(0.00);
        jkxlMapper.updateTzFee(tzData);
    }
 

+ 3 - 2
src/main/java/com/jeeplus/modules/sg/web/JkxlController.java

@@ -80,8 +80,9 @@ public class JkxlController extends BaseController {
     return list1;
   }
 
-//  @RequestMapping("/relist")
-//  public String reList(){
+//  @RequestMapping("/fttz")
+//  public String reList(HttpServletRequest request){
+//
 //
 //  }