Commit b68ab0347bbe26db5e5a2eadd541123655d33480

Authored by 王富生
1 parent 9f40ae38

app养护计划明细提交

urbanops-module-garden/src/main/java/com/zteits/urbanops/module/garden/service/inspectionplan/InspectionPlanServiceImpl.java
@@ -341,7 +341,11 @@ public class InspectionPlanServiceImpl implements InspectionPlanService { @@ -341,7 +341,11 @@ public class InspectionPlanServiceImpl implements InspectionPlanService {
341 } 341 }
342 342
343 /*1.查询登录用户角色*/ 343 /*1.查询登录用户角色*/
344 - Set<String> batchNos = getBatchNosByLoginUserId(); 344 + Set<String> batchNos = this.getBatchNosByLoginUserId();
  345 + if(CollectionUtils.isEmpty(batchNos)){
  346 + return PageResult.empty();
  347 + }
  348 +
345 pageReqVO.setBatchNos(batchNos); 349 pageReqVO.setBatchNos(batchNos);
346 pageReqVO.setLocalDate(LocalDate.now()); 350 pageReqVO.setLocalDate(LocalDate.now());
347 /*2.分页*/ 351 /*2.分页*/
urbanops-module-garden/src/main/java/com/zteits/urbanops/module/garden/service/maintainplan/MaintainPlanServiceImpl.java
@@ -347,6 +347,9 @@ public class MaintainPlanServiceImpl implements MaintainPlanService { @@ -347,6 +347,9 @@ public class MaintainPlanServiceImpl implements MaintainPlanService {
347 347
348 /*1.查询登录用户计划编码列表*/ 348 /*1.查询登录用户计划编码列表*/
349 Set<String> batchNos = this.getBatchNosByLoginUserId(); 349 Set<String> batchNos = this.getBatchNosByLoginUserId();
  350 + if(CollectionUtils.isEmpty(batchNos)){
  351 + return PageResult.empty();
  352 + }
350 pageReqVO.setBatchNos(batchNos); 353 pageReqVO.setBatchNos(batchNos);
351 pageReqVO.setLocalDate(LocalDate.now()); 354 pageReqVO.setLocalDate(LocalDate.now());
352 /*2.分页*/ 355 /*2.分页*/
@@ -388,6 +391,9 @@ public class MaintainPlanServiceImpl implements MaintainPlanService { @@ -388,6 +391,9 @@ public class MaintainPlanServiceImpl implements MaintainPlanService {
388 } 391 }
389 /*1.查询登录用户计划编码列表*/ 392 /*1.查询登录用户计划编码列表*/
390 Set<String> batchNos = this.getBatchNosByLoginUserId(); 393 Set<String> batchNos = this.getBatchNosByLoginUserId();
  394 + if(CollectionUtils.isEmpty(batchNos)){
  395 + return PageResult.empty();
  396 + }
391 pageReqVO.setBatchNos(batchNos); 397 pageReqVO.setBatchNos(batchNos);
392 pageReqVO.setLocalDate(LocalDate.now()); 398 pageReqVO.setLocalDate(LocalDate.now());
393 /*2.分页*/ 399 /*2.分页*/
urbanops-module-garden/src/main/resources/mapper/inspectionplan/InspectionPlanCommitMapper.xml
@@ -38,6 +38,8 @@ @@ -38,6 +38,8 @@
38 FROM 38 FROM
39 garden_inspection_plan_commit a, garden_inspection_plan b 39 garden_inspection_plan_commit a, garden_inspection_plan b
40 where a.batch_no=b.batch_no 40 where a.batch_no=b.batch_no
  41 + AND a.deleted = b. deleted
  42 + AND a.deleted = 0
41 <if test="req.planNo != null and req.planNo !=''"> 43 <if test="req.planNo != null and req.planNo !=''">
42 and a.plan_no = #{req.planNo} 44 and a.plan_no = #{req.planNo}
43 </if> 45 </if>
urbanops-module-garden/src/main/resources/mapper/inspectionplan/InspectionPlanDetailMapper.xml
@@ -21,7 +21,6 @@ @@ -21,7 +21,6 @@
21 a.road_name, 21 a.road_name,
22 a.plan_type_id, 22 a.plan_type_id,
23 a.level_id, 23 a.level_id,
24 - a.plan_type_id,  
25 a.rate, 24 a.rate,
26 a.cycle_id, 25 a.cycle_id,
27 b.sort_num, 26 b.sort_num,
@@ -35,9 +34,6 @@ @@ -35,9 +34,6 @@
35 garden_inspection_plan_detail b 34 garden_inspection_plan_detail b
36 WHERE 35 WHERE
37 a.batch_no = b.batch_no 36 a.batch_no = b.batch_no
38 - AND b.batch_no=c.batch_no  
39 - AND a.road_id=b.road_id  
40 - AND a.dept_id =b.dept_id  
41 AND a.deleted = b.deleted 37 AND a.deleted = b.deleted
42 AND a.deleted = 0 38 AND a.deleted = 0
43 AND a.batch_no = #{req.batchNo} 39 AND a.batch_no = #{req.batchNo}
urbanops-module-garden/src/main/resources/mapper/inspectionplan/InspectionPlanMapper.xml
@@ -18,6 +18,7 @@ @@ -18,6 +18,7 @@
18 a.batch_no, 18 a.batch_no,
19 a.road_id, 19 a.road_id,
20 a.road_name, 20 a.road_name,
  21 + a.busi_line,
21 a.plan_type_id, 22 a.plan_type_id,
22 a.level_id, 23 a.level_id,
23 a.finish_state, 24 a.finish_state,
@@ -25,7 +26,7 @@ @@ -25,7 +26,7 @@
25 a.end_time 26 a.end_time
26 FROM 27 FROM
27 garden_inspection_plan a 28 garden_inspection_plan a
28 - WHERE a.deleted=0 29 + WHERE a.deleted = 0
29 <if test="req.roadName != null and req.roadName !=''"> 30 <if test="req.roadName != null and req.roadName !=''">
30 AND a.road_name LIKE CONCAT('%',#{req.roadName},'%') 31 AND a.road_name LIKE CONCAT('%',#{req.roadName},'%')
31 </if> 32 </if>
urbanops-module-garden/src/main/resources/mapper/maintainplan/MaintainPlanCommitMapper.xml
@@ -108,6 +108,7 @@ @@ -108,6 +108,7 @@
108 WHERE 108 WHERE
109 a.batch_no = b.batch_no 109 a.batch_no = b.batch_no
110 AND a.plan_no = c.plan_no 110 AND a.plan_no = c.plan_no
  111 + AND a.finish_state = 2
111 AND c.plan_no = #{req.planNo} 112 AND c.plan_no = #{req.planNo}
112 </select> 113 </select>
113 </mapper> 114 </mapper>
114 \ No newline at end of file 115 \ No newline at end of file