Quellcode durchsuchen

通过表单id查询流程记录

lamphua vor 10 Monaten
Ursprung
Commit
73e497b79e

+ 2
- 2
oa-back/ruoyi-admin/src/main/java/com/ruoyi/web/controller/oa/CmcDeviceApprovalController.java Datei anzeigen

@@ -168,7 +168,7 @@ public class CmcDeviceApprovalController extends BaseController
168 168
         }
169 169
         if (formDataJson.getDate("returnDate") != null) {
170 170
             cmcDeviceApproval.setRemark(formDataJson.getString("remark"));
171
-            if (formDataJson.getJSONArray("repairDevices").size() > 0) {
171
+            if (formDataJson.getDate("repairDevices") != null && formDataJson.getJSONArray("repairDevices").size() > 0) {
172 172
                 String deviceString = formDataJson.getString("repairDevices").substring(1, formDataJson.getString("repairDevices").length() - 1);
173 173
                 cmcDeviceApproval.setRepairDevices(deviceString);
174 174
                 String[] devices = deviceString.split(",");
@@ -178,7 +178,7 @@ public class CmcDeviceApprovalController extends BaseController
178 178
                     cmcDeviceService.updateCmcDevice(cmcDevice);
179 179
                 }
180 180
             }
181
-            if (formDataJson.getJSONArray("returnDevices").size() > 0) {
181
+            if (formDataJson.getDate("returnDevices") != null && formDataJson.getJSONArray("returnDevices").size() > 0) {
182 182
                 String deviceString = formDataJson.getString("returnDevices").substring(1, formDataJson.getString("returnDevices").length() - 1);
183 183
                 cmcDeviceApproval.setReturnDevices(deviceString);
184 184
                 String[] devices = deviceString.split(",");

+ 2
- 2
oa-back/ruoyi-flowable/src/main/java/com/ruoyi/flowable/service/impl/FlowTaskServiceImpl.java Datei anzeigen

@@ -1392,10 +1392,10 @@ public class FlowTaskServiceImpl extends FlowServiceFactory implements IFlowTask
1392 1392
      * @return
1393 1393
      */
1394 1394
     @Override
1395
-    public AjaxResult flowXmlAndNodeByFormIdAndName(String formId, String name) {
1395
+    public AjaxResult flowXmlAndNodeByFormIdAndName(String formId, String id) {
1396 1396
         try {
1397 1397
             List<FlowVarInst> flowVarInst = flowVarInstMapper.selectProcInstByVar(formId);
1398
-            List<FlowProcDefDto> flowProcDefList = flowDeployMapper.selectDeployList(name);
1398
+            List<FlowProcDefDto> flowProcDefList = flowDeployMapper.selectDeployListById(id);
1399 1399
             AjaxResult result = flowXmlAndNode(flowVarInst.get(0).getProcInstId(), flowProcDefList.get(0).getDeploymentId());
1400 1400
             if (result.isSuccess()) {
1401 1401
                 result.put("procInsId", flowVarInst.get(0).getProcInstId());

+ 1
- 1
oa-back/ruoyi-framework/src/main/java/com/ruoyi/framework/web/service/TokenService.java Datei anzeigen

@@ -49,7 +49,7 @@ public class TokenService
49 49
 
50 50
     protected static final long MILLIS_MINUTE = 60 * MILLIS_SECOND;
51 51
 
52
-    private static final Long MILLIS_MINUTE_TEN = 20 * 60 * 1000L;
52
+    private static final Long MILLIS_MINUTE_TEN = 120 * 60 * 1000L;
53 53
 
54 54
     @Autowired
55 55
     private RedisCache redisCache;

+ 7
- 0
oa-back/ruoyi-system/src/main/java/com/ruoyi/system/mapper/FlowDeployMapper.java Datei anzeigen

@@ -19,4 +19,11 @@ public interface FlowDeployMapper {
19 19
      * @return
20 20
      */
21 21
     List<FlowProcDefDto> selectDeployList(String name);
22
+
23
+    /**
24
+     * 流程定义列表
25
+     * @param id
26
+     * @return
27
+     */
28
+    List<FlowProcDefDto> selectDeployListById(String id);
22 29
 }

+ 22
- 0
oa-back/ruoyi-system/src/main/resources/mapper/flowable/FlowDeployMapper.xml Datei anzeigen

@@ -27,5 +27,27 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
27 27
         order by rd.id_ asc
28 28
     </select>
29 29
 
30
+    <select id="selectDeployListById" resultType="com.ruoyi.system.domain.FlowProcDefDto">
31
+
32
+        SELECT
33
+            rp.id_ as id,
34
+            rp.deployment_id_ as deploymentId,
35
+            rd.name_ as name,
36
+            rd.category_ as category,
37
+            rp.key_ as flowKey,
38
+            rp.version_ as version,
39
+            rp.suspension_state_ as suspensionState,
40
+            rd.deploy_time_  as deploymentTime
41
+        FROM
42
+            ACT_RE_PROCDEF rp
43
+                LEFT JOIN ACT_RE_DEPLOYMENT rd ON rp.deployment_id_ = rd.id_
44
+        <where>
45
+            <if test="id != null and id != ''">
46
+               and rd.id_ like concat('%', #{id}, '%')
47
+            </if>
48
+        </where>
49
+        order by rd.id_ asc
50
+    </select>
51
+
30 52
 
31 53
 </mapper>

Laden…
Abbrechen
Speichern