java110 лет назад: 5
Родитель
Сommit
6e23ea90f4

+ 2 - 2
java110-db/src/main/resources/mapper/community/RepairReturnVisitServiceDaoImplMapper.xml

@@ -29,10 +29,10 @@
         where 1 = 1
         and rrp.state = '1800'
         and rs.return_visit_flag in ('002','003')
-        <if test="state ==null or visitId == ''">
+        <if test="state == 'waiting'">
             and t.repair_id is null
         </if>
-        <if test="state !=null and visitId != ''">
+        <if test="state == 'finish'">
             and t.repair_id is not null
         </if>
         <if test="visitId !=null and visitId != ''">

+ 2 - 2
service-community/src/main/java/com/java110/community/api/RepairApi.java

@@ -120,8 +120,8 @@ public class RepairApi {
      */
     @RequestMapping(value = "/queryRepairReturnVisit", method = RequestMethod.GET)
     public ResponseEntity<String> queryRepairReturnVisit(@RequestParam(value = "communityId") String communityId,
-                                                         @RequestParam(value = "repairId") String repairId,
-                                                         @RequestParam(value = "repairName") String repairName,
+                                                         @RequestParam(value = "repairId",required = false) String repairId,
+                                                         @RequestParam(value = "repairName",required = false) String repairName,
                                                          @RequestParam(value = "state") String state,
                                                          @RequestParam(value = "page") int page,
                                                          @RequestParam(value = "row") int row) {