Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
8
8timerapiv200
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
8timerv2
8timerapiv200
Commits
28991fe3
Commit
28991fe3
authored
Jul 13, 2022
by
龙于生
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增审批详情可以添加抄送人接口
parent
a2d48c6f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
40 additions
and
4 deletions
+40
-4
src/main/java/cn/timer/api/controller/spmk/SpmkController.java
+25
-1
src/main/java/cn/timer/api/utils/router/RouterUtils.java
+15
-3
No files found.
src/main/java/cn/timer/api/controller/spmk/SpmkController.java
View file @
28991fe3
...
@@ -10,9 +10,9 @@ import cn.timer.api.dao.spmk.*;
...
@@ -10,9 +10,9 @@ import cn.timer.api.dao.spmk.*;
import
cn.timer.api.dto.spmk.*
;
import
cn.timer.api.dto.spmk.*
;
import
cn.timer.api.utils.redis.RedisUtil
;
import
cn.timer.api.utils.redis.RedisUtil
;
import
cn.timer.api.utils.router.RequestDataUtils
;
import
cn.timer.api.utils.router.RequestDataUtils
;
import
com.alibaba.fastjson.JSON
;
import
com.baomidou.mybatisplus.core.toolkit.SerializationUtils
;
import
com.baomidou.mybatisplus.core.toolkit.SerializationUtils
;
import
com.mysql.cj.util.StringUtils
;
import
com.mysql.cj.util.StringUtils
;
import
net.sf.json.JSON
;
import
net.sf.json.JSONArray
;
import
net.sf.json.JSONArray
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.beans.factory.annotation.Value
;
...
@@ -1156,4 +1156,28 @@ public class SpmkController {
...
@@ -1156,4 +1156,28 @@ public class SpmkController {
}
}
return
false
;
return
false
;
}
}
/**
* 更新审批流程通过节点
* @param userBean
* @param spmkApproveDetailDto
* @return
*/
@PostMapping
(
value
=
"/updateFlowChildren"
)
@ApiOperation
(
value
=
"更新审批流程通过节点"
,
httpMethod
=
"POST"
,
notes
=
""
)
public
Result
<
Object
>
updateFlowChildren
(
@CurrentUser
UserBean
userBean
,
@Validated
@RequestBody
SpmkApproveDetailDto
spmkApproveDetailDto
)
{
try
{
// 更新 flowChildren
SpmkApproveDetailSummary
.
builder
().
id
(
spmkApproveDetailDto
.
getId
())
.
flowChildren
(
JSONArray
.
fromObject
(
spmkApproveDetailDto
.
getFlowChildren
()).
toString
()).
build
().
updateById
();
}
catch
(
Exception
e
)
{
return
ResultUtil
.
error
(
e
);
}
SpmkApproveDetailSummary
detailSummary
=
SpmkApproveDetailSummary
.
builder
().
build
().
selectOne
(
new
QueryWrapper
<
SpmkApproveDetailSummary
>()
.
lambda
().
eq
(
SpmkApproveDetailSummary:
:
getId
,
spmkApproveDetailDto
.
getId
()));
return
ResultUtil
.
data
(
JSON
.
toJSONString
(
detailSummary
));
}
}
}
src/main/java/cn/timer/api/utils/router/RouterUtils.java
View file @
28991fe3
...
@@ -659,10 +659,12 @@ public class RouterUtils {
...
@@ -659,10 +659,12 @@ public class RouterUtils {
//转派 处理
//转派 处理
//在 原审批人 列表中 插入 一个或多个被转派人(审批人)
//在 原审批人 列表中 插入 一个或多个被转派人(审批人)
}
else
if
(
sts
==
ExecutorSts
.
REDEPLOY
.
ordinal
())
{
}
else
if
(
sts
==
ExecutorSts
.
REDEPLOY
.
ordinal
())
{
List
<
User
>
users1
=
CollectionUtil
.
sub
(
listUser
,
0
,
i_user
+
1
);
//新增转派多个人功能
//新增转派多个人功能
//判断是走派多个人的 否则走旧逻辑
//判断是走派多个人的 否则走旧逻辑
if
(!
CollectionUtils
.
isEmpty
(
redeployUserList
)){
if
(!
CollectionUtils
.
isEmpty
(
redeployUserList
)){
List
<
User
>
users1
=
CollectionUtil
.
sub
(
listUser
,
0
,
i_user
+
1
);
//List<User> users1 = CollectionUtil.sub(listUser, 0, i_user+1);
redeployUserList
.
add
(
users1
.
get
(
users1
.
size
()
-
1
));
for
(
User
ruser:
redeployUserList
for
(
User
ruser:
redeployUserList
)
{
)
{
ruser
.
setExecute
(
UNEXECUTED
);
ruser
.
setExecute
(
UNEXECUTED
);
...
@@ -674,11 +676,21 @@ public class RouterUtils {
...
@@ -674,11 +676,21 @@ public class RouterUtils {
//listR.get(0).setApprovalOrder("1");
//listR.get(0).setApprovalOrder("1");
listFlowChildren
.
get
(
i
).
getRelation
().
get
(
0
).
setApprovalOrder
(
"1"
);
listFlowChildren
.
get
(
i
).
getRelation
().
get
(
0
).
setApprovalOrder
(
"1"
);
}
else
{
}
else
{
List
<
User
>
users1
=
CollectionUtil
.
sub
(
listUser
,
0
,
i_user
+
1
);
//
List<User> users1 = CollectionUtil.sub(listUser, 0, i_user+1);
redeployUser
.
setExecute
(
UNEXECUTED
);
redeployUser
.
setExecute
(
UNEXECUTED
);
users1
.
add
(
redeployUser
);
users1
.
add
(
redeployUser
);
//新加的 把转派人跟在后面说
User
user
=
users1
.
get
(
users1
.
size
()
-
2
);
User
us
=
new
User
();
us
.
setExecute
(
UNEXECUTED
);
us
.
setName
(
user
.
getName
());
us
.
setId
(
user
.
getId
());
users1
.
add
(
us
);
List
<
User
>
users2
=
CollectionUtil
.
sub
(
listUser
,
i_user
+
1
,
listUser
.
size
());
List
<
User
>
users2
=
CollectionUtil
.
sub
(
listUser
,
i_user
+
1
,
listUser
.
size
());
listUser
=
ListUtils
.
union
(
users1
,
users2
);
redeployUserList
=
users2
;
//listUser = ListUtils.union(users1, users2);
n_user
=
listUser
.
size
();
n_user
=
listUser
.
size
();
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment