张延森 hace 3 años
padre
commit
60a244591d

+ 3
- 1
src/main/java/com/yunzhi/nanyang/controller/TaWorkJobController.java Ver fichero

@@ -107,9 +107,11 @@ public class TaWorkJobController extends BaseController {
107 107
             return ResponseBean.error("非工作状态, 不能操作");
108 108
         }
109 109
 
110
-        int status = mode ? Constants.WORK_DOING : Constants.WORK_PAUSE;
110
+//        int status = mode ? Constants.WORK_DOING : Constants.WORK_PAUSE;
111
+        int status = Constants.WORK_DOING;
111 112
 
112 113
         taWorkJob.setStatus(status);
114
+        taWorkJob.setStartDate(LocalDateTime.now());
113 115
 
114 116
         // 联动状态
115 117
         iTaOrderService.updateStatus(taWorkJob.getOrderId(), "work_status", Constants.WORK_DOING);

+ 2
- 2
src/main/resources/mapper/TaMachineryMapper.xml Ver fichero

@@ -11,7 +11,7 @@
11 11
                      fn_distance ( t.location, #{location} ) AS distance
12 12
                 FROM ta_machinery t
13 13
                 WHERE
14
-                      t.`status` = 1
14
+                      t.`status` > -1
15 15
                 <if test="orgId != null and orgId != ''">
16 16
                     AND t.org_id = #{orgId}
17 17
                 </if>
@@ -32,7 +32,7 @@
32 32
         INNER JOIN ta_org s on t.org_id = s.org_id
33 33
         WHERE
34 34
             t.machinery_id = #{machineryId}
35
-            AND t.`status` = 1
35
+            AND t.`status` &gt; -1
36 36
     </select>
37 37
     <select id="getOneOfTypes" resultType="com.yunzhi.nanyang.vo.MachineSummary">
38 38
         SELECT