Explorar o código

熏蒸业务变更开发和安全漏洞修复

fanxw hai 1 ano
pai
achega
ff4a5b4771

+ 5 - 0
pom.xml

@@ -51,6 +51,11 @@
51
             <groupId>org.springframework.cloud</groupId>
51
             <groupId>org.springframework.cloud</groupId>
52
             <artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
52
             <artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
53
         </dependency>
53
         </dependency>
54
+        <!-- 安全验证 -->
55
+        <dependency>  
56
+		    <groupId>org.springframework.boot</groupId>  
57
+		    <artifactId>spring-boot-starter-security</artifactId>  
58
+		</dependency>
54
         <!-- gbase依赖包 -->
59
         <!-- gbase依赖包 -->
55
         <dependency>
60
         <dependency>
56
             <groupId>com.gbase8s</groupId>
61
             <groupId>com.gbase8s</groupId>

+ 4 - 3
src/main/java/com/chinaitop/depot/fumigation/controller/FumigationAlterController.java

@@ -115,12 +115,13 @@ public class FumigationAlterController {
115
     @RequestMapping(value="/saveFumigationAfterDate", produces = MediaType.APPLICATION_JSON_VALUE, method = RequestMethod.POST)
115
     @RequestMapping(value="/saveFumigationAfterDate", produces = MediaType.APPLICATION_JSON_VALUE, method = RequestMethod.POST)
116
     @ApiOperation(value="保存熏蒸善后信息", notes = "保存熏蒸善后信息")
116
     @ApiOperation(value="保存熏蒸善后信息", notes = "保存熏蒸善后信息")
117
     @ApiImplicitParams({
117
     @ApiImplicitParams({
118
-            @ApiImplicitParam(name = "fumigationAfter", value = "熏蒸善后数据", paramType = "form")
118
+            @ApiImplicitParam(name = "fumigationAfter", value = "熏蒸善后数据", paramType = "form"),
119
+            @ApiImplicitParam(name = "fumigationProcess", value = "熏蒸过程数据", paramType = "form")
119
     })
120
     })
120
-    public Map<String, Object> saveFumigationAfterDate(String fumigationAfter) {
121
+    public Map<String, Object> saveFumigationAfterDate(String fumigationAfter, String fumigationProcess) {
121
         Map<String, Object> modelMap = new HashMap<String, Object>();
122
         Map<String, Object> modelMap = new HashMap<String, Object>();
122
         try {
123
         try {
123
-			modelMap = fumigationAfterService.saveOrUpdate(fumigationAfter);
124
+			modelMap = fumigationAfterService.saveOrUpdate(fumigationAfter, fumigationProcess);
124
 		} catch (Exception e) {
125
 		} catch (Exception e) {
125
 			modelMap.put("status", "error");
126
 			modelMap.put("status", "error");
126
 			log.error(e.getMessage(), e);
127
 			log.error(e.getMessage(), e);

+ 1 - 1
src/main/java/com/chinaitop/depot/fumigation/controller/FumigationProcessController.java

@@ -115,7 +115,7 @@ public class FumigationProcessController {
115
         tFumigationProcess.setDeleteState("1");//默认设置删除标志
115
         tFumigationProcess.setDeleteState("1");//默认设置删除标志
116
         if (tFumigationProcess.getId() == null) {
116
         if (tFumigationProcess.getId() == null) {
117
             tFumigationProcess.setId(ParameterUtil.getCode());
117
             tFumigationProcess.setId(ParameterUtil.getCode());
118
-            tFumigationProcess.setCreateTime(new Date());//创建时间
118
+            //tFumigationProcess.setCreateTime(new Date());//创建时间
119
             tFumigationProcess.setUpdateTime(tFumigationProcess.getCreateTime());//修改时间
119
             tFumigationProcess.setUpdateTime(tFumigationProcess.getCreateTime());//修改时间
120
             fumigationProcessService.add(tFumigationProcess);
120
             fumigationProcessService.add(tFumigationProcess);
121
 
121
 

+ 23 - 6
src/main/java/com/chinaitop/depot/fumigation/mapper/TFumigationAfterMapper.xml

@@ -45,6 +45,7 @@
45
     <result column="remark" property="remark" jdbcType="VARCHAR" />
45
     <result column="remark" property="remark" jdbcType="VARCHAR" />
46
     <result column="sjczsjzykssj" property="sjczsjzykssj" jdbcType="TIMESTAMP" />
46
     <result column="sjczsjzykssj" property="sjczsjzykssj" jdbcType="TIMESTAMP" />
47
     <result column="sjczsjzyjssj" property="sjczsjzyjssj" jdbcType="TIMESTAMP" />
47
     <result column="sjczsjzyjssj" property="sjczsjzyjssj" jdbcType="TIMESTAMP" />
48
+    <result column="data_status" property="dataStatus" jdbcType="VARCHAR" />
48
   </resultMap>
49
   </resultMap>
49
   <sql id="Example_Where_Clause" >
50
   <sql id="Example_Where_Clause" >
50
     <where >
51
     <where >
@@ -112,7 +113,7 @@
112
     sampling_culture_month_half, kill_insect_rate, check_insect_cage_time, insect_cage_kill_rate, 
113
     sampling_culture_month_half, kill_insect_rate, check_insect_cage_time, insect_cage_kill_rate, 
113
     effect_analysis, creater, create_time, update_time, org_id, delete_state, updatetime, 
114
     effect_analysis, creater, create_time, update_time, org_id, delete_state, updatetime, 
114
     czsjzysj, czsjzyrs, czsjff, czsjzypzr, czclcs, czclzyrs, czclpzr, xzhhcjcqk, xzhckmd, 
115
     czsjzysj, czsjzyrs, czsjff, czsjzypzr, czclcs, czclzyrs, czclpzr, xzhhcjcqk, xzhckmd, 
115
-    pyswthhcs, pysswthhcs, xzxgpj,record_id,remark,sjczsjzykssj,sjczsjzyjssj
116
+    pyswthhcs, pysswthhcs, xzxgpj,record_id,remark,sjczsjzykssj,sjczsjzyjssj,data_status
116
   </sql>
117
   </sql>
117
   <select id="selectByExample" resultMap="BaseResultMap" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfterExample" >
118
   <select id="selectByExample" resultMap="BaseResultMap" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfterExample" >
118
     select
119
     select
@@ -160,7 +161,7 @@
160
       czsjzyrs, czsjff, czsjzypzr, 
161
       czsjzyrs, czsjff, czsjzypzr, 
161
       czclcs, czclzyrs, czclpzr, 
162
       czclcs, czclzyrs, czclpzr, 
162
       xzhhcjcqk, xzhckmd, pyswthhcs, 
163
       xzhhcjcqk, xzhckmd, pyswthhcs, 
163
-      pysswthhcs, xzxgpj,record_id,remark,sjczsjzykssj,sjczsjzyjssj)
164
+      pysswthhcs, xzxgpj,record_id,remark,sjczsjzykssj,sjczsjzyjssj, data_status)
164
     values (#{id,jdbcType=VARCHAR}, #{houseId,jdbcType=INTEGER}, #{fumigationId,jdbcType=VARCHAR}, 
165
     values (#{id,jdbcType=VARCHAR}, #{houseId,jdbcType=INTEGER}, #{fumigationId,jdbcType=VARCHAR}, 
165
       #{residueCollectionTime,jdbcType=VARCHAR}, #{numberOperationsCollected,jdbcType=VARCHAR}, 
166
       #{residueCollectionTime,jdbcType=VARCHAR}, #{numberOperationsCollected,jdbcType=VARCHAR}, 
166
       #{residueCollectionMethod,jdbcType=VARCHAR}, #{collectJobApprover,jdbcType=VARCHAR}, 
167
       #{residueCollectionMethod,jdbcType=VARCHAR}, #{collectJobApprover,jdbcType=VARCHAR}, 
@@ -177,7 +178,8 @@
177
       #{czclcs,jdbcType=VARCHAR}, #{czclzyrs,jdbcType=INTEGER}, #{czclpzr,jdbcType=VARCHAR}, 
178
       #{czclcs,jdbcType=VARCHAR}, #{czclzyrs,jdbcType=INTEGER}, #{czclpzr,jdbcType=VARCHAR}, 
178
       #{xzhhcjcqk,jdbcType=VARCHAR}, #{xzhckmd,jdbcType=INTEGER}, #{pyswthhcs,jdbcType=INTEGER}, 
179
       #{xzhhcjcqk,jdbcType=VARCHAR}, #{xzhckmd,jdbcType=INTEGER}, #{pyswthhcs,jdbcType=INTEGER}, 
179
       #{pysswthhcs,jdbcType=INTEGER}, #{xzxgpj,jdbcType=VARCHAR},#{recordId,jdbcType=VARCHAR},
180
       #{pysswthhcs,jdbcType=INTEGER}, #{xzxgpj,jdbcType=VARCHAR},#{recordId,jdbcType=VARCHAR},
180
-      #{remark,jdbcType=VARCHAR},#{sjczsjzykssj,jdbcType=TIMESTAMP},#{sjczsjzyjssj,jdbcType=TIMESTAMP})
181
+      #{remark,jdbcType=VARCHAR},#{sjczsjzykssj,jdbcType=TIMESTAMP},#{sjczsjzyjssj,jdbcType=TIMESTAMP},
182
+      #{dataStatus,jdbcType=VARCHAR})
181
   </insert>
183
   </insert>
182
   <insert id="insertSelective" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfter" >
184
   <insert id="insertSelective" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfter" >
183
     insert into t_fumigation_after
185
     insert into t_fumigation_after
@@ -308,6 +310,9 @@
308
       <if test="sjczsjzyjssj != null" >
310
       <if test="sjczsjzyjssj != null" >
309
         sjczsjzyjssj,
311
         sjczsjzyjssj,
310
       </if>
312
       </if>
313
+      <if test="dataStatus != null">
314
+        data_status,
315
+      </if>
311
     </trim>
316
     </trim>
312
     <trim prefix="values (" suffix=")" suffixOverrides="," >
317
     <trim prefix="values (" suffix=")" suffixOverrides="," >
313
       <if test="id != null" >
318
       <if test="id != null" >
@@ -436,6 +441,9 @@
436
       <if test="sjczsjzyjssj != null" >
441
       <if test="sjczsjzyjssj != null" >
437
         #{sjczsjzyjssj,jdbcType=TIMESTAMP},
442
         #{sjczsjzyjssj,jdbcType=TIMESTAMP},
438
       </if>
443
       </if>
444
+      <if test="dataStatus != null">
445
+        #{dataStatus,jdbcType=VARCHAR},
446
+      </if>
439
     </trim>
447
     </trim>
440
   </insert>
448
   </insert>
441
   <select id="countByExample" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfterExample" resultType="java.lang.Integer" >
449
   <select id="countByExample" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfterExample" resultType="java.lang.Integer" >
@@ -573,6 +581,9 @@
573
       <if test="record.sjczsjzyjssj != null" >
581
       <if test="record.sjczsjzyjssj != null" >
574
         sjczsjzyjssj = #{record.sjczsjzyjssj,jdbcType=TIMESTAMP},
582
         sjczsjzyjssj = #{record.sjczsjzyjssj,jdbcType=TIMESTAMP},
575
       </if>
583
       </if>
584
+      <if test="record.dataStatus != null">
585
+        data_status = #{record.dataStatus,jdbcType=VARCHAR},
586
+      </if>
576
     </set>
587
     </set>
577
     <if test="_parameter != null" >
588
     <if test="_parameter != null" >
578
       <include refid="Update_By_Example_Where_Clause" />
589
       <include refid="Update_By_Example_Where_Clause" />
@@ -621,7 +632,8 @@
621
       xzxgpj = #{record.xzxgpj,jdbcType=VARCHAR},
632
       xzxgpj = #{record.xzxgpj,jdbcType=VARCHAR},
622
       remark = #{record.remark,jdbcType=VARCHAR},
633
       remark = #{record.remark,jdbcType=VARCHAR},
623
       sjczsjzykssj = #{record.sjczsjzykssj,jdbcType=TIMESTAMP},
634
       sjczsjzykssj = #{record.sjczsjzykssj,jdbcType=TIMESTAMP},
624
-      sjczsjzyjssj = #{record.sjczsjzyjssj,jdbcType=TIMESTAMP}
635
+      sjczsjzyjssj = #{record.sjczsjzyjssj,jdbcType=TIMESTAMP},
636
+      data_status = #{record.dataStatus,jdbcType=VARCHAR}
625
     <if test="_parameter != null" >
637
     <if test="_parameter != null" >
626
       <include refid="Update_By_Example_Where_Clause" />
638
       <include refid="Update_By_Example_Where_Clause" />
627
     </if>
639
     </if>
@@ -752,6 +764,9 @@
752
       <if test="sjczsjzyjssj != null" >
764
       <if test="sjczsjzyjssj != null" >
753
         sjczsjzyjssj = #{sjczsjzyjssj,jdbcType=TIMESTAMP},
765
         sjczsjzyjssj = #{sjczsjzyjssj,jdbcType=TIMESTAMP},
754
       </if>
766
       </if>
767
+      <if test="dataStatus != null">
768
+        data_status = #{dataStatus,jdbcType=VARCHAR},
769
+      </if>
755
     </set>
770
     </set>
756
     where id = #{id,jdbcType=VARCHAR}
771
     where id = #{id,jdbcType=VARCHAR}
757
   </update>
772
   </update>
@@ -797,7 +812,8 @@
797
       xzxgpj = #{xzxgpj,jdbcType=VARCHAR},
812
       xzxgpj = #{xzxgpj,jdbcType=VARCHAR},
798
       remark = #{remark,jdbcType=VARCHAR},
813
       remark = #{remark,jdbcType=VARCHAR},
799
       sjczsjzykssj = #{sjczsjzykssj,jdbcType=TIMESTAMP},
814
       sjczsjzykssj = #{sjczsjzykssj,jdbcType=TIMESTAMP},
800
-      sjczsjzyjssj = #{sjczsjzyjssj,jdbcType=TIMESTAMP}
815
+      sjczsjzyjssj = #{sjczsjzyjssj,jdbcType=TIMESTAMP},
816
+      data_status = #{dataStatus,jdbcType=VARCHAR}
801
     where id = #{id,jdbcType=VARCHAR}
817
     where id = #{id,jdbcType=VARCHAR}
802
   </update>
818
   </update>
803
 
819
 
@@ -810,7 +826,8 @@
810
     record.yjmc drugName,
826
     record.yjmc drugName,
811
     af.creater,
827
     af.creater,
812
     af.create_time createTime,
828
     af.create_time createTime,
813
-    record.id recordId
829
+    record.id recordId,
830
+    af.data_status datastatus
814
     FROM
831
     FROM
815
     t_fumigation_after af
832
     t_fumigation_after af
816
     INNER JOIN t_fumigation_forrecord record ON af.record_id = record.id
833
     INNER JOIN t_fumigation_forrecord record ON af.record_id = record.id

+ 26 - 9
src/main/java/com/chinaitop/depot/fumigation/mapper/TFumigationProcessMapper.xml

@@ -93,6 +93,7 @@
93
     <result column="yjmc" property="yjmc" jdbcType="INTEGER" />
93
     <result column="yjmc" property="yjmc" jdbcType="INTEGER" />
94
     <result column="jx" property="jx" jdbcType="INTEGER" />
94
     <result column="jx" property="jx" jdbcType="INTEGER" />
95
     <result column="lyhjzl" property="lyhjzl" jdbcType="VARCHAR" />
95
     <result column="lyhjzl" property="lyhjzl" jdbcType="VARCHAR" />
96
+    <result column="cjr" property="cjr" jdbcType="VARCHAR" />
96
   </resultMap>
97
   </resultMap>
97
   <sql id="Example_Where_Clause" >
98
   <sql id="Example_Where_Clause" >
98
     <where >
99
     <where >
@@ -169,7 +170,7 @@
169
     task_state, task_end_time, creater, create_time, update_time, org_id, delete_state, 
170
     task_state, task_end_time, creater, create_time, update_time, org_id, delete_state, 
170
     data_source, updatetime, yqbjyaqjc, byqcnlhqnd, mbnd, jsbyl, byzypzr, fznd, mbndwcts, 
171
     data_source, updatetime, yqbjyaqjc, byqcnlhqnd, mbnd, jsbyl, byzypzr, fznd, mbndwcts, 
171
     lswzjc, lqbwcqdbjcs, mbsj, ctz, sqqlhqnd, sqpzr, sqcsts, sqjsslhqnd,record_id,remark,data_status,
172
     lswzjc, lqbwcqdbjcs, mbsj, ctz, sqqlhqnd, sqpzr, sqcsts, sqjsslhqnd,record_id,remark,data_status,
172
-    yjlysqbh, yjmc, jx, lyhjzl
173
+    yjlysqbh, yjmc, jx, lyhjzl, cjr
173
   </sql>
174
   </sql>
174
   <select id="selectByExample" resultMap="BaseResultMap" parameterType="com.chinaitop.depot.fumigation.model.TFumigationProcessExample" >
175
   <select id="selectByExample" resultMap="BaseResultMap" parameterType="com.chinaitop.depot.fumigation.model.TFumigationProcessExample" >
175
     select
176
     select
@@ -233,7 +234,7 @@
233
       jsbyl, byzypzr, fznd, 
234
       jsbyl, byzypzr, fznd, 
234
       mbndwcts, lswzjc, lqbwcqdbjcs, 
235
       mbndwcts, lswzjc, lqbwcqdbjcs, 
235
       mbsj, ctz, sqqlhqnd, 
236
       mbsj, ctz, sqqlhqnd, 
236
-      sqpzr, sqcsts, sqjsslhqnd,record_id,remark,data_status, yjlysqbh, yjmc, jx, lyhjzl
237
+      sqpzr, sqcsts, sqjsslhqnd,record_id,remark,data_status, yjlysqbh, yjmc, jx, lyhjzl, cjr
237
       )
238
       )
238
     values (#{id,jdbcType=VARCHAR}, #{fumigationId,jdbcType=VARCHAR}, #{concentration,jdbcType=VARCHAR}, 
239
     values (#{id,jdbcType=VARCHAR}, #{fumigationId,jdbcType=VARCHAR}, #{concentration,jdbcType=VARCHAR}, 
239
       #{heapMedication,jdbcType=VARCHAR}, #{spaceMedication,jdbcType=VARCHAR}, #{deliquescenceMethod,jdbcType=VARCHAR}, 
240
       #{heapMedication,jdbcType=VARCHAR}, #{spaceMedication,jdbcType=VARCHAR}, #{deliquescenceMethod,jdbcType=VARCHAR}, 
@@ -268,7 +269,7 @@
268
       #{mbsj,jdbcType=INTEGER}, #{ctz,jdbcType=DECIMAL}, #{sqqlhqnd,jdbcType=DECIMAL}, 
269
       #{mbsj,jdbcType=INTEGER}, #{ctz,jdbcType=DECIMAL}, #{sqqlhqnd,jdbcType=DECIMAL}, 
269
       #{sqpzr,jdbcType=VARCHAR}, #{sqcsts,jdbcType=INTEGER}, #{sqjsslhqnd,jdbcType=DECIMAL},#{recordId,jdbcType=VARCHAR},
270
       #{sqpzr,jdbcType=VARCHAR}, #{sqcsts,jdbcType=INTEGER}, #{sqjsslhqnd,jdbcType=DECIMAL},#{recordId,jdbcType=VARCHAR},
270
       #{remark,jdbcType=VARCHAR},#{dataStatus,jdbcType=VARCHAR},#{yjlysqbh,jdbcType=VARCHAR}, #{yjmc,jdbcType=INTEGER}, 
271
       #{remark,jdbcType=VARCHAR},#{dataStatus,jdbcType=VARCHAR},#{yjlysqbh,jdbcType=VARCHAR}, #{yjmc,jdbcType=INTEGER}, 
271
-      #{jx,jdbcType=INTEGER}, #{lyhjzl,jdbcType=VARCHAR})
272
+      #{jx,jdbcType=INTEGER}, #{lyhjzl,jdbcType=VARCHAR}, #{cjr,jdbcType=VARCHAR})
272
   </insert>
273
   </insert>
273
   <insert id="insertSelective" parameterType="com.chinaitop.depot.fumigation.model.TFumigationProcess" >
274
   <insert id="insertSelective" parameterType="com.chinaitop.depot.fumigation.model.TFumigationProcess" >
274
     insert into t_fumigation_process
275
     insert into t_fumigation_process
@@ -543,6 +544,9 @@
543
       <if test="lyhjzl != null">
544
       <if test="lyhjzl != null">
544
         lyhjzl,
545
         lyhjzl,
545
       </if>
546
       </if>
547
+      <if test="cjr != null">
548
+        cjr,
549
+      </if>
546
     </trim>
550
     </trim>
547
     <trim prefix="values (" suffix=")" suffixOverrides="," >
551
     <trim prefix="values (" suffix=")" suffixOverrides="," >
548
       <if test="id != null" >
552
       <if test="id != null" >
@@ -815,6 +819,9 @@
815
       <if test="lyhjzl != null">
819
       <if test="lyhjzl != null">
816
         #{lyhjzl,jdbcType=VARCHAR},
820
         #{lyhjzl,jdbcType=VARCHAR},
817
       </if>
821
       </if>
822
+      <if test="cjr != null">
823
+        #{cjr,jdbcType=VARCHAR},
824
+      </if>
818
     </trim>
825
     </trim>
819
   </insert>
826
   </insert>
820
   <select id="countByExample" parameterType="com.chinaitop.depot.fumigation.model.TFumigationProcessExample" resultType="java.lang.Integer" >
827
   <select id="countByExample" parameterType="com.chinaitop.depot.fumigation.model.TFumigationProcessExample" resultType="java.lang.Integer" >
@@ -1096,6 +1103,9 @@
1096
       <if test="record.lyhjzl != null">
1103
       <if test="record.lyhjzl != null">
1097
         lyhjzl = #{record.lyhjzl,jdbcType=VARCHAR},
1104
         lyhjzl = #{record.lyhjzl,jdbcType=VARCHAR},
1098
       </if>
1105
       </if>
1106
+      <if test="record.cjr != null">
1107
+        cjr = #{record.cjr,jdbcType=VARCHAR},
1108
+      </if>
1099
     </set>
1109
     </set>
1100
     <if test="_parameter != null" >
1110
     <if test="_parameter != null" >
1101
       <include refid="Update_By_Example_Where_Clause" />
1111
       <include refid="Update_By_Example_Where_Clause" />
@@ -1192,7 +1202,8 @@
1192
       yjlysqbh = #{record.yjlysqbh,jdbcType=VARCHAR},
1202
       yjlysqbh = #{record.yjlysqbh,jdbcType=VARCHAR},
1193
       yjmc = #{record.yjmc,jdbcType=INTEGER},
1203
       yjmc = #{record.yjmc,jdbcType=INTEGER},
1194
       jx = #{record.jx,jdbcType=INTEGER},
1204
       jx = #{record.jx,jdbcType=INTEGER},
1195
-      lyhjzl = #{record.lyhjzl,jdbcType=VARCHAR}
1205
+      lyhjzl = #{record.lyhjzl,jdbcType=VARCHAR},
1206
+      cjr = #{record.cjr,jdbcType=VARCHAR}
1196
     <if test="_parameter != null" >
1207
     <if test="_parameter != null" >
1197
       <include refid="Update_By_Example_Where_Clause" />
1208
       <include refid="Update_By_Example_Where_Clause" />
1198
     </if>
1209
     </if>
@@ -1470,6 +1481,9 @@
1470
       <if test="lyhjzl != null">
1481
       <if test="lyhjzl != null">
1471
         lyhjzl = #{lyhjzl,jdbcType=VARCHAR},
1482
         lyhjzl = #{lyhjzl,jdbcType=VARCHAR},
1472
       </if>
1483
       </if>
1484
+      <if test="cjr != null">
1485
+        cjr = #{cjr,jdbcType=VARCHAR},
1486
+      </if>
1473
     </set>
1487
     </set>
1474
     where id = #{id,jdbcType=VARCHAR}
1488
     where id = #{id,jdbcType=VARCHAR}
1475
   </update>
1489
   </update>
@@ -1564,7 +1578,8 @@
1564
       yjlysqbh = #{yjlysqbh,jdbcType=VARCHAR},
1578
       yjlysqbh = #{yjlysqbh,jdbcType=VARCHAR},
1565
       yjmc = #{yjmc,jdbcType=INTEGER},
1579
       yjmc = #{yjmc,jdbcType=INTEGER},
1566
       jx = #{jx,jdbcType=INTEGER},
1580
       jx = #{jx,jdbcType=INTEGER},
1567
-      lyhjzl = #{lyhjzl,jdbcType=VARCHAR}
1581
+      lyhjzl = #{lyhjzl,jdbcType=VARCHAR},
1582
+      cjr = #{cjr,jdbcType=VARCHAR}
1568
     where id = #{id,jdbcType=VARCHAR}
1583
     where id = #{id,jdbcType=VARCHAR}
1569
   </update>
1584
   </update>
1570
 
1585
 
@@ -1575,10 +1590,11 @@
1575
     record.house_id houseId,
1590
     record.house_id houseId,
1576
     record.lspz grainKind,
1591
     record.lspz grainKind,
1577
     record.yjmc drugName,
1592
     record.yjmc drugName,
1578
-    case when record.cgxzfs!='' then '常规熏蒸' when record.hlxzfs!='' then '环流熏蒸方式' when record.hlxzynhljsjh!='' then '环流熏蒸与内环流技术结合' else '常规熏蒸' end fumigationType,
1593
+    case record.xzfs when '5245' then '常规熏蒸' when '5246' then '环流熏蒸方式' when '5248' then '环流熏蒸与内环流技术结合' else '常规熏蒸' end fumigationType,
1579
     record.creater,
1594
     record.creater,
1580
     to_char(pro.create_time, 'yyyy-mm-dd hh24:mi:ss') createTime,
1595
     to_char(pro.create_time, 'yyyy-mm-dd hh24:mi:ss') createTime,
1581
-    record.id recordId
1596
+    record.id recordId,
1597
+    pro.data_status datastatus
1582
     FROM
1598
     FROM
1583
     t_fumigation_process pro
1599
     t_fumigation_process pro
1584
     INNER JOIN t_fumigation_forrecord record ON pro.record_id = record.id
1600
     INNER JOIN t_fumigation_forrecord record ON pro.record_id = record.id
@@ -1612,7 +1628,7 @@
1612
     drug_residue_rate, dcsqtinfo_id, task_state,
1628
     drug_residue_rate, dcsqtinfo_id, task_state,
1613
     task_end_time, creater, create_time,
1629
     task_end_time, creater, create_time,
1614
     update_time, org_id, delete_state,
1630
     update_time, org_id, delete_state,
1615
-    data_source,record_id,remark,data_status, yjlysqbh, yjmc, jx, lyhjzl)
1631
+    data_source,record_id,remark,data_status, yjlysqbh, yjmc, jx, lyhjzl, cjr)
1616
     values
1632
     values
1617
     <foreach collection="list" item="process" index="index" separator=",">
1633
     <foreach collection="list" item="process" index="index" separator=",">
1618
       (#{process.id,jdbcType=INTEGER}, #{process.fumigationId,jdbcType=VARCHAR}, #{process.firstUseDrugTime,jdbcType=TIMESTAMP},
1634
       (#{process.id,jdbcType=INTEGER}, #{process.fumigationId,jdbcType=VARCHAR}, #{process.firstUseDrugTime,jdbcType=TIMESTAMP},
@@ -1632,7 +1648,8 @@
1632
       #{process.taskEndTime,jdbcType=TIMESTAMP}, #{process.creater,jdbcType=INTEGER}, #{process.createTime,jdbcType=TIMESTAMP},
1648
       #{process.taskEndTime,jdbcType=TIMESTAMP}, #{process.creater,jdbcType=INTEGER}, #{process.createTime,jdbcType=TIMESTAMP},
1633
       #{process.updateTime,jdbcType=TIMESTAMP}, #{process.orgId,jdbcType=INTEGER}, #{process.deleteState,jdbcType=VARCHAR},
1649
       #{process.updateTime,jdbcType=TIMESTAMP}, #{process.orgId,jdbcType=INTEGER}, #{process.deleteState,jdbcType=VARCHAR},
1634
       #{process.dataSource,jdbcType=VARCHAR},#{process.recordId,jdbcType=VARCHAR}, #{process.remark,jdbcType=VARCHAR},#{process.dataStatus,jdbcType=VARCHAR},
1650
       #{process.dataSource,jdbcType=VARCHAR},#{process.recordId,jdbcType=VARCHAR}, #{process.remark,jdbcType=VARCHAR},#{process.dataStatus,jdbcType=VARCHAR},
1635
-      #{process.yjlysqbh,jdbcType=VARCHAR}, #{process.yjmc,jdbcType=INTEGER}, #{process.jx,jdbcType=INTEGER}, #{process.lyhjzl,jdbcType=VARCHAR})
1651
+      #{process.yjlysqbh,jdbcType=VARCHAR}, #{process.yjmc,jdbcType=INTEGER}, #{process.jx,jdbcType=INTEGER}, #{process.lyhjzl,jdbcType=VARCHAR},
1652
+      #{process.cjr,jdbcType=VARCHAR})
1636
     </foreach>
1653
     </foreach>
1637
   </insert>
1654
   </insert>
1638
 </mapper>
1655
 </mapper>

+ 19 - 0
src/main/java/com/chinaitop/depot/fumigation/model/TFumigationAfter.java

@@ -95,6 +95,9 @@ public class TFumigationAfter {
95
     @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
95
     @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
96
     private Date sjczsjzyjssj;
96
     private Date sjczsjzyjssj;
97
 
97
 
98
+    // 数据状态(0:保存,1:提交)
99
+    private String dataStatus;
100
+
98
     /**
101
     /**
99
      * 备案id
102
      * 备案id
100
      */
103
      */
@@ -771,4 +774,20 @@ public class TFumigationAfter {
771
 	public void setSjczsjzyjssj(Date sjczsjzyjssj) {
774
 	public void setSjczsjzyjssj(Date sjczsjzyjssj) {
772
 		this.sjczsjzyjssj = sjczsjzyjssj;
775
 		this.sjczsjzyjssj = sjczsjzyjssj;
773
 	}
776
 	}
777
+
778
+	/**
779
+	 * 数据状态(0:保存,1:提交)
780
+	 * @return
781
+	 */
782
+	public String getDataStatus() {
783
+		return dataStatus;
784
+	}
785
+
786
+	/**
787
+	 * 数据状态(0:保存,1:提交)
788
+	 * @param dataStatus
789
+	 */
790
+	public void setDataStatus(String dataStatus) {
791
+		this.dataStatus = dataStatus;
792
+	}
774
 }
793
 }

+ 19 - 0
src/main/java/com/chinaitop/depot/fumigation/model/TFumigationProcess.java

@@ -214,6 +214,9 @@ public class TFumigationProcess {
214
     //领用合计总量
214
     //领用合计总量
215
     private String lyhjzl;
215
     private String lyhjzl;
216
 
216
 
217
+    //创建人
218
+    private String cjr;
219
+
217
     /**
220
     /**
218
      * 熏蒸过程表
221
      * 熏蒸过程表
219
      * @return id 熏蒸过程表
222
      * @return id 熏蒸过程表
@@ -1677,5 +1680,21 @@ public class TFumigationProcess {
1677
 	public void setLyhjzl(String lyhjzl) {
1680
 	public void setLyhjzl(String lyhjzl) {
1678
 		this.lyhjzl = lyhjzl;
1681
 		this.lyhjzl = lyhjzl;
1679
 	}
1682
 	}
1683
+
1684
+	/**
1685
+	 * 创建人
1686
+	 * @return
1687
+	 */
1688
+	public String getCjr() {
1689
+		return cjr;
1690
+	}
1691
+
1692
+	/**
1693
+	 * 创建人
1694
+	 * @param cjr
1695
+	 */
1696
+	public void setCjr(String cjr) {
1697
+		this.cjr = cjr;
1698
+	}
1680
     
1699
     
1681
 }
1700
 }

+ 2 - 1
src/main/java/com/chinaitop/depot/fumigation/service/FumigationAfterService.java

@@ -37,8 +37,9 @@ public interface FumigationAfterService {
37
     /**
37
     /**
38
      * 保存熏蒸善后数据
38
      * 保存熏蒸善后数据
39
      * @param fumigationAfter
39
      * @param fumigationAfter
40
+     * @param fumigationProcess
40
      * @return
41
      * @return
41
      * @throws Exception
42
      * @throws Exception
42
      */
43
      */
43
-	Map<String, Object> saveOrUpdate(String fumigationAfter) throws Exception;
44
+	Map<String, Object> saveOrUpdate(String fumigationAfter, String fumigationProcess) throws Exception;
44
 }
45
 }

+ 11 - 9
src/main/java/com/chinaitop/depot/fumigation/service/impl/FumigationAfterServiceImpl.java

@@ -84,7 +84,7 @@ public class FumigationAfterServiceImpl implements FumigationAfterService {
84
     }
84
     }
85
 
85
 
86
 	@Override
86
 	@Override
87
-	public Map<String, Object> saveOrUpdate(String fumigationAfter) throws Exception {
87
+	public Map<String, Object> saveOrUpdate(String fumigationAfter, String fumigationProcess) throws Exception {
88
 		Map<String, Object> modelMap = new HashMap<String, Object>();
88
 		Map<String, Object> modelMap = new HashMap<String, Object>();
89
         // JSON字符串转对象
89
         // JSON字符串转对象
90
         ObjectMapper mapper = new ObjectMapper();
90
         ObjectMapper mapper = new ObjectMapper();
@@ -97,19 +97,21 @@ public class FumigationAfterServiceImpl implements FumigationAfterService {
97
 
97
 
98
             add(tFumigationAfter);
98
             add(tFumigationAfter);
99
 
99
 
100
-            //修改熏蒸状态
101
-            TFumigationForrecordExample example = new TFumigationForrecordExample();
102
-            TFumigationForrecordExample.Criteria criteria = example.createCriteria();
103
-            criteria.andIdEqualTo(tFumigationAfter.getRecordId());
104
-
105
-            TFumigationForrecord tFumigationForrecord = new TFumigationForrecord();
106
-            tFumigationForrecord.setState(10);
107
-            fumigationForRecordService.updateByExample(tFumigationForrecord, example);
108
 
100
 
109
         } else {
101
         } else {
110
             tFumigationAfter.setUpdateTime(new Date());//修改时间
102
             tFumigationAfter.setUpdateTime(new Date());//修改时间
111
             update(tFumigationAfter);
103
             update(tFumigationAfter);
112
         }
104
         }
105
+        //修改熏蒸状态
106
+        if ("1".equals(tFumigationAfter.getDataStatus())) {
107
+        	TFumigationForrecordExample example = new TFumigationForrecordExample();
108
+        	TFumigationForrecordExample.Criteria criteria = example.createCriteria();
109
+        	criteria.andIdEqualTo(tFumigationAfter.getRecordId());
110
+        	
111
+        	TFumigationForrecord tFumigationForrecord = new TFumigationForrecord();
112
+        	tFumigationForrecord.setState(10);
113
+        	fumigationForRecordService.updateByExample(tFumigationForrecord, example);
114
+        }
113
         
115
         
114
         //把善后结果中[残渣收集作业结束时间]返回给市平台
116
         //把善后结果中[残渣收集作业结束时间]返回给市平台
115
         pushFAfterData(ParameterUtil.datetime2string(tFumigationAfter.getSjczsjzyjssj()), tFumigationAfter.getRecordId());
117
         pushFAfterData(ParameterUtil.datetime2string(tFumigationAfter.getSjczsjzyjssj()), tFumigationAfter.getRecordId());

+ 24 - 0
src/main/java/com/chinaitop/depot/utils/WebSecurityConfig.java

@@ -0,0 +1,24 @@
1
+package com.chinaitop.depot.utils;
2
+
3
+import org.springframework.context.annotation.Configuration;
4
+import org.springframework.security.config.annotation.web.builders.HttpSecurity;
5
+import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
6
+import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;
7
+
8
+@Configuration
9
+@EnableWebSecurity
10
+public class WebSecurityConfig 
11
+extends WebSecurityConfigurerAdapter 
12
+{
13
+
14
+	@Override
15
+    protected void configure(HttpSecurity http) throws Exception {
16
+		http.authorizeRequests()
17
+		.antMatchers("/**")
18
+		.permitAll() //允许所有用户访问所有资源
19
+        .and()
20
+        .csrf().disable(); // 禁用CSRF(防止伪造的跨域攻击)
21
+
22
+        super.configure(http);
23
+    }
24
+}

+ 11 - 4
src/main/resources/bootstrap.yml

@@ -10,7 +10,7 @@ mybatis:
10
 eureka:
10
 eureka:
11
   client:
11
   client:
12
     service-url:
12
     service-url:
13
-      defaultZone: http://localhost:9001/eureka/
13
+      defaultZone: http://tj_admin:Admin_1234@${eureka.instance.hostname}:9001/eureka/
14
     #register-with-eureka: false
14
     #register-with-eureka: false
15
     #fetchRegistry: false
15
     #fetchRegistry: false
16
   instance:
16
   instance:
@@ -20,6 +20,10 @@ eureka:
20
     lease-expiration-duration-in-seconds: 30
20
     lease-expiration-duration-in-seconds: 30
21
     status-page-url: http://${eureka.instance.hostname}:${server.port}/swagger-ui.html
21
     status-page-url: http://${eureka.instance.hostname}:${server.port}/swagger-ui.html
22
 
22
 
23
+management:
24
+  server:
25
+    port: -1
26
+
23
 spring:
27
 spring:
24
   application:
28
   application:
25
     name: depot-storage
29
     name: depot-storage
@@ -30,6 +34,9 @@ spring:
30
     url: jdbc:gbasedbt-sqli://101.36.160.140:19089/depot:INFORMIXSERVER=ol_gbasedbt1210;NEWCODESET=GB18030,GB18030-2000,5488;DB_LOCALE=zh_cn.GB18030-2000;GL_USEGLU=1;IFX_USE_STRENC=true;characterEncoding=utf8;
34
     url: jdbc:gbasedbt-sqli://101.36.160.140:19089/depot:INFORMIXSERVER=ol_gbasedbt1210;NEWCODESET=GB18030,GB18030-2000,5488;DB_LOCALE=zh_cn.GB18030-2000;GL_USEGLU=1;IFX_USE_STRENC=true;characterEncoding=utf8;
31
     username: gbasedbt
35
     username: gbasedbt
32
     password: cDbK2S0go8
36
     password: cDbK2S0go8
37
+    #url: jdbc:gbasedbt-sqli://10.223.3.63:9088/depot:GBASEDBTSERVER=gbaseserver2;DB_LOCALE=zh_CN.utf8;CLIENT_LOCALE=zh_CN.utf8;NEWCODESET=UTF8,utf8,57372;GL_USEGLU=1;
38
+    #username: gbasedbt
39
+    #password: 4E7#8x8Yut
33
   session:
40
   session:
34
     store-type: redis
41
     store-type: redis
35
   redis:
42
   redis:
@@ -53,9 +60,9 @@ spring:
53
       max-request-size: 20MB
60
       max-request-size: 20MB
54
   # 缓存配置 host: redis-depot
61
   # 缓存配置 host: redis-depot
55
 web:
62
 web:
56
-  upload-path: /home/depot/depot-web/apache-tomcat-8.0.53/webapps/ROOT/WEB-INF/classes/static
63
+  upload-path: /home/depot/depot-web/depot-file
57
 
64
 
58
 api:
65
 api:
59
   safety:
66
   safety:
60
-    host: localhost
61
-    port: 8765
67
+    host: 172.16.0.73
68
+    port: 8097