CodeLife Leno 3 долоо хоног өмнө
parent
commit
f532409e15

+ 131 - 1
DBScript/李庚谱/001-DDL.sql

@@ -1113,4 +1113,134 @@ create table if not exists sys_input_suptaskrun_taskallstatus (
 	isover varchar(60) not null comment '补录任务是否完成 YESORNO',
 	primary key (term, taskCode)
 )
-comment='补录任务按照频率的补录任务状态,在同一起次完成时,才会继续下一步';
+comment='补录任务按照频率的补录任务状态,在同一起次完成时,才会继续下一步';
+
+
+-- 视图
+drop view if exists v_wfs_todotask;
+CREATE VIEW v_wfs_todotask AS
+select
+  tmp.account AS account,
+  bus.BUSINESSTYPEID AS businesstypeid,
+  task.PROCINST_ AS businessinsid,
+  task.ID_ AS soleorderid,
+  tmp.taskState AS status
+from
+  (
+    (
+      (
+        (
+          select
+            t1.PROCINST_ AS PROCINST_,
+            t1.ID_ AS ID_,
+            t1.ACTORID_ AS ACTORID_
+          from
+            jbpm_taskinstance t1
+          where
+            (t1.ACTORID_ is not null)
+            and (t1.ISOPEN_ = 1)
+            and (t1.ISSUSPENDED_ <> 1)
+        )
+        union all
+          (
+            select
+              t2.PROCINST_ AS PROCINST_,
+              t2.ID_ AS ID_,
+              concat('!', pooledacto0_.ACTORID_) AS ACTORID_
+            from
+              (
+                (
+                  jbpm_pooledactor pooledacto0_
+                  join jbpm_taskactorpool taskinstan1_ on (pooledacto0_.ID_ = taskinstan1_.POOLEDACTOR_)
+                )
+                join jbpm_taskinstance t2 on (taskinstan1_.TASKINSTANCE_ = t2.ID_)
+                and (t2.ACTORID_ is null)
+                and (t2.ISOPEN_ = 1)
+                and (t2.ISSUSPENDED_ <> 1)
+              )
+          )
+      ) task
+      join (
+        (
+          select
+            sysuser.ACCOUNT AS account,
+            'waiting' AS taskState,
+            concat('#', dept.ORGCODE, UR.ROLEID) AS taskPerson
+          from
+            (
+              (
+                sys_user sysuser
+                join sys_user_role UR on (sysuser.ACCOUNT = UR.ACCOUNT)
+              )
+              join sys_organization dept on (sysuser.ORGCODE = dept.ORGCODE)
+            )
+        )
+        union all
+          (
+            select
+              sysuser.ACCOUNT AS account,
+              'waiting' AS taskState,
+              concat('#', dept.ORGCODE, UR.ROLEID, '*', dept.ORGTYPE) AS taskPerson
+            from
+              (
+                (
+                  sys_user sysuser
+                  join sys_user_role UR on (sysuser.ACCOUNT = UR.ACCOUNT)
+                )
+                join sys_organization dept on (sysuser.ORGCODE = dept.ORGCODE)
+              )
+          )
+        union all
+          (
+            select
+              sysuser.ACCOUNT AS account,
+              'waiting' AS taskState,
+              concat('#', dept.SUPERORGCODE, UR.ROLEID) AS taskPerson
+            from
+              (
+                (
+                  sys_user sysuser
+                  join sys_user_role UR on (sysuser.ACCOUNT = UR.ACCOUNT)
+                )
+                join sys_organization dept on (sysuser.ORGCODE = dept.ORGCODE)
+                and (dept.ORGTYPE is not null)
+              )
+          )
+        union all
+          (
+            select
+              sysuser.ACCOUNT AS account,
+              'waiting' AS taskState,
+              concat('#', dept.SUPERORGCODE, UR.ROLEID, '*', dept.ORGTYPE) AS taskPerson
+            from
+              (
+                (
+                  sys_user sysuser
+                  join sys_user_role UR on (sysuser.ACCOUNT = UR.ACCOUNT)
+                )
+                join sys_organization dept on (sysuser.ORGCODE = dept.ORGCODE)
+                and (dept.ORGTYPE is not null)
+              )
+          )
+        union all
+          (
+            select
+              sysuser.ACCOUNT AS account,
+              'working' AS taskState,
+              concat('@', sysuser.ACCOUNT) AS taskPerson
+            from
+              sys_user sysuser
+          )
+        union all
+          (
+            select
+              sysuser.ACCOUNT AS account,
+              'waiting' AS taskState,
+              concat('!', sysuser.ACCOUNT) AS taskPerson
+            from
+              sys_user sysuser
+          )
+      ) tmp on (task.ACTORID_ = tmp.taskPerson)
+    )
+    join wfs_businessins bus on (bus.BUSINESSINSID = task.PROCINST_)
+  );

+ 3 - 4
Procedure/backend/project/src/main/java/com/sundata/product/rwa/calc/controllers/CalcRunningController.java

@@ -8,7 +8,6 @@ import com.sundata.product.rwa.calc.service.CalcRunningService;
 import com.sundata.product.rwa.calc.service.implement.units.GeneralLedgerGetterUnit;
 import com.sundata.product.rwa.calc.service.implement.units.GeneralLedgerUnit;
 import com.sundata.product.rwa.calc.service.implement.units.ReportInitUnit;
-import org.springframework.stereotype.Controller;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestMapping;
@@ -30,7 +29,7 @@ public class CalcRunningController extends BaseAction {
     /**
      * 启动总账取数
      *
-     * @param calcInterfaceParam 报文参数结构 { "calculateInstanceNumber": "xxx" , "calcCode":"xxx" ,"dataDate":"2025-03-07"  }
+     * @param calcInterfaceParam 报文参数结构 { "calculateInstanceNumber": "xxx" , "calcCode":"xxx" ,"dataDate":"20250307"  }
      *                           dataDate; 内容为必须
      * @return 运行结果
      */
@@ -48,7 +47,7 @@ public class CalcRunningController extends BaseAction {
     /**
      * 启动总账勾稽
      *
-     * @param calcInterfaceParam 报文参数结构 { "calculateInstanceNumber": "xxx" , "calcCode":"xxx" ,"dataDate":"2025-03-07"  }
+     * @param calcInterfaceParam 报文参数结构 { "calculateInstanceNumber": "xxx" , "calcCode":"xxx" ,"dataDate":"20250307"  }
      *                           dataDate; 内容为必须
      * @return 运行结果
      */
@@ -66,7 +65,7 @@ public class CalcRunningController extends BaseAction {
     /**
      * 启动报表计算
      *
-     * @param calcInterfaceParam 报文参数结构 { "calculateInstanceNumber": "xxx" , "calcCode":"xxx" ,"dataDate":"2025-03-07"  }
+     * @param calcInterfaceParam 报文参数结构 { "calculateInstanceNumber": "xxx" , "calcCode":"xxx" ,"dataDate":"20250307"  }
      *                           dataDate; 内容为必须
      * @return 运行结果
      */