lvzhikai 4 년 전
부모
커밋
5229af165a

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

@@ -156,7 +156,7 @@ public class FumigationPlanController {
156
 
156
 
157
         tFumigationPlan.setDeleteState("1");//默认设置删除标志
157
         tFumigationPlan.setDeleteState("1");//默认设置删除标志
158
         tPesticidePlan.setDeleteState("1");//默认设置删除标志
158
         tPesticidePlan.setDeleteState("1");//默认设置删除标志
159
-        if (tFumigationPlan.getId() == null) {
159
+        if (StringUtils.isBlank(tFumigationPlan.getId())) {
160
             tFumigationPlan.setCreateTime(new Date());//创建时间
160
             tFumigationPlan.setCreateTime(new Date());//创建时间
161
             tFumigationPlan.setState(1);//待审批
161
             tFumigationPlan.setState(1);//待审批
162
 
162
 

+ 1 - 1
src/main/java/com/chinaitop/depot/intelligent/fumigation/service/impl/FumigationPlanServiceImpl.java

@@ -61,7 +61,7 @@ public class FumigationPlanServiceImpl implements FumigationPlanService {
61
 
61
 
62
     @Override
62
     @Override
63
     public void update(TFumigationPlan tFumigationPlan) {
63
     public void update(TFumigationPlan tFumigationPlan) {
64
-        tFumigationPlanMapper.updateByPrimaryKey(tFumigationPlan);
64
+        tFumigationPlanMapper.updateByPrimaryKeySelective(tFumigationPlan);
65
     }
65
     }
66
 
66
 
67
     @Override
67
     @Override

+ 3 - 1
src/main/java/com/chinaitop/depot/intelligent/fumigation/service/impl/PesiticidePlanServiceImpl.java

@@ -22,10 +22,12 @@ public class PesiticidePlanServiceImpl implements PesticidePlanService {
22
     @Resource
22
     @Resource
23
     private TFumigationPesticideMapper tFumigationPesticideMapper;
23
     private TFumigationPesticideMapper tFumigationPesticideMapper;
24
 
24
 
25
+    @Override
25
     public List<Map<String,Object>> getPesticidePlanList(Map<String, Object> map) {
26
     public List<Map<String,Object>> getPesticidePlanList(Map<String, Object> map) {
26
         return tFumigationPesticideMapper.getPesticidePlanList(map);
27
         return tFumigationPesticideMapper.getPesticidePlanList(map);
27
     }
28
     }
28
 
29
 
30
+    @Override
29
     public List<Map<String,Object>> getPesticidePlanLists(Map<String, Object> map) {
31
     public List<Map<String,Object>> getPesticidePlanLists(Map<String, Object> map) {
30
         return tFumigationPesticideMapper.getPesticidePlanLists(map);
32
         return tFumigationPesticideMapper.getPesticidePlanLists(map);
31
     }
33
     }
@@ -47,7 +49,7 @@ public class PesiticidePlanServiceImpl implements PesticidePlanService {
47
 
49
 
48
     @Override
50
     @Override
49
     public void update(TFumigationPesticide tFumigationPesticide) {
51
     public void update(TFumigationPesticide tFumigationPesticide) {
50
-        tFumigationPesticideMapper.updateByPrimaryKey(tFumigationPesticide);
52
+        tFumigationPesticideMapper.updateByPrimaryKeySelective(tFumigationPesticide);
51
     }
53
     }
52
 
54
 
53
     @Override
55
     @Override