Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
rbc-demo
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
王衍超
rbc-demo
Commits
409e20bb
Commit
409e20bb
authored
Mar 10, 2022
by
乔延琦
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop-yuancheng' into 'develop'
Develop yuancheng See merge request GFP/RBC/rbc-frontend!83
parents
b9d3aa29
af1cafa9
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
96 additions
and
17 deletions
+96
-17
agreeAction.js
...lop/@gms/gms-plugin-billexpand/src/actions/agreeAction.js
+49
-8
rejectAction.js
...op/@gms/gms-plugin-billexpand/src/actions/rejectAction.js
+43
-7
bill-form-runner.vue
develop/@rbc/runner-bill-form/src/views/bill-form-runner.vue
+4
-2
No files found.
develop/@gms/gms-plugin-billexpand/src/actions/agreeAction.js
View file @
409e20bb
import
Bridge
from
'../components-control/util/bridge'
import
Bridge
from
'../components-control/util/bridge'
import
SelectApprovers
from
'../components-control/select-approvers.vue'
import
SelectApprovers
from
'../components-control/select-approvers.vue'
import
{
compareData
}
from
"../components-control/util/dataChange"
export
default
{
export
default
{
execute
:
function
(
bill
,
param
)
{
execute
:
function
(
bill
,
param
)
{
if
(
bill
)
{
if
(
bill
)
{
...
@@ -7,19 +8,62 @@ export default {
...
@@ -7,19 +8,62 @@ export default {
GMS
.
$hideContainer
.
$Message
.
error
(
'请配置审批轨迹'
)
GMS
.
$hideContainer
.
$Message
.
error
(
'请配置审批轨迹'
)
return
return
}
}
if
(
compareData
(
GMS
.
oldBillData
,
bill
.
getBuillData
()))
{
this
.
approvalLogical
(
bill
,
param
,
this
)
}
else
{
GMS
.
billDataChangeChecked
=
true
GMS
.
$hideContainer
.
$Modal
.
confirm
({
title
:
"信息提示"
,
content
:
"信息发生变化, 是否保存"
,
onOk
:
()
=>
{
this
.
saveLogical
(
bill
,
param
,
{
data
:
bill
.
getBuillData
(),
detailData
:
[]},
this
)
},
onCancel
:
()
=>
{
this
.
approvalLogical
(
bill
,
param
,
this
)
}
})
}
}
else
{
GMS
.
$hideContainer
.
$Message
.
error
(
'缺少参数'
);
}
},
saveLogical
:
(
bill
,
param
,
postData
,
_this
)
=>
{
let
url
=
`/rbc/bill/action/executed/
${
param
.
define
}
/bill.Basic.save?transmission=total`
GMS
.
$http
.
post
(
url
,
JSON
.
stringify
(
postData
),
{
headers
:
{
post
:
{
"Content-Type"
:
"application/json"
,
},
},
})
.
then
((
response
)
=>
{
if
(
response
.
data
.
code
==
0
)
{
_this
.
approvalLogical
(
bill
,
param
,
_this
)
}
else
{
response
.
data
.
message
&&
GMS
.
vbus
.
$Message
.
error
({
content
:
response
.
data
.
message
,
duration
:
3
});
}
})
},
approvalLogical
:
(
bill
,
param
,
_this
)
=>
{
let
taskId
=
bill
.
getGlobalParam
(
'reviewParam'
).
taskId
;
let
taskId
=
bill
.
getGlobalParam
(
'reviewParam'
).
taskId
;
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
false
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
false
)
let
selectedApprovers
=
[]
let
selectedApprovers
=
[]
window
.
GMS
.
$http
.
get
(
`/bpm/bill/selectApprover/ApproverList/
${
taskId
}
`
).
then
((
res
)
=>
{
window
.
GMS
.
$http
.
get
(
`/bpm/bill/selectApprover/ApproverList/
${
taskId
}
`
).
then
((
res
)
=>
{
if
(
res
.
data
.
code
==
204
)
{
if
(
res
.
data
.
code
==
204
)
{
this
.
executeApproval
(
bill
,
param
)
_this
.
executeApproval
(
bill
,
param
,
_this
)
return
return
}
}
else
if
(
res
.
data
.
code
!=
200
)
{
else
if
(
res
.
data
.
code
!=
200
)
{
delete
GMS
.
billDataChangeChecke
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
GMS
.
$hideContainer
.
$Message
.
error
(
res
.
data
.
msg
||
'提交失败,请联系系统管理员'
);
GMS
.
$hideContainer
.
$Message
.
error
(
res
.
data
.
msg
||
'提交失败,请联系系统管理员'
);
return
return
}
}
delete
GMS
.
billDataChangeChecke
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
const
nodeData
=
res
.
data
.
ApproverVo
const
nodeData
=
res
.
data
.
ApproverVo
const
optionList
=
[...
nodeData
.
approvers
]
const
optionList
=
[...
nodeData
.
approvers
]
...
@@ -52,7 +96,7 @@ export default {
...
@@ -52,7 +96,7 @@ export default {
approvers
:
selectedApprovers
,
approvers
:
selectedApprovers
,
}
}
).
then
(()
=>
{
).
then
(()
=>
{
this
.
executeApproval
(
bill
,
param
)
_
this
.
executeApproval
(
bill
,
param
)
}).
catch
(()
=>
{
}).
catch
(()
=>
{
GMS
.
$hideContainer
.
$Message
.
error
(
'选择审批人发生错误'
)
GMS
.
$hideContainer
.
$Message
.
error
(
'选择审批人发生错误'
)
})
})
...
@@ -63,11 +107,8 @@ export default {
...
@@ -63,11 +107,8 @@ export default {
}).
catch
(()
=>
{
}).
catch
(()
=>
{
GMS
.
$hideContainer
.
$Message
.
error
(
'未找到下一节点的审批人'
);
GMS
.
$hideContainer
.
$Message
.
error
(
'未找到下一节点的审批人'
);
})
})
}
else
{
GMS
.
$hideContainer
.
$Message
.
error
(
'缺少参数'
);
}
},
},
executeApproval
:
function
(
bill
,
param
)
{
executeApproval
:
function
(
bill
,
param
,
_this
)
{
if
(
param
.
param
.
actions
)
{
if
(
param
.
param
.
actions
)
{
let
saveParam
=
{
let
saveParam
=
{
actions
:
param
.
param
.
actions
,
actions
:
param
.
param
.
actions
,
...
@@ -80,7 +121,7 @@ export default {
...
@@ -80,7 +121,7 @@ export default {
}
}
bill
.
executeServerAction
(
saveParam
,
function
(
code
,
data
)
{
bill
.
executeServerAction
(
saveParam
,
function
(
code
,
data
)
{
if
(
code
===
200
)
{
if
(
code
===
200
)
{
this
.
approval
(
bill
,
param
);
_
this
.
approval
(
bill
,
param
);
// bill.setControlsSate(param["_control_name_"], "loading", false)
// bill.setControlsSate(param["_control_name_"], "loading", false)
}
else
{
}
else
{
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
...
@@ -89,7 +130,7 @@ export default {
...
@@ -89,7 +130,7 @@ export default {
}
}
}.
bind
(
this
));
}.
bind
(
this
));
}
else
{
}
else
{
this
.
approval
(
bill
,
param
);
_
this
.
approval
(
bill
,
param
);
}
}
},
},
approval
:
function
(
bill
,
param
)
{
approval
:
function
(
bill
,
param
)
{
...
...
develop/@gms/gms-plugin-billexpand/src/actions/rejectAction.js
View file @
409e20bb
import
Bridge
from
'../components-control/util/bridge'
import
Bridge
from
'../components-control/util/bridge'
import
{
compareData
}
from
"../components-control/util/dataChange"
export
default
{
export
default
{
execute
:
function
(
bill
,
param
)
{
execute
:
function
(
bill
,
param
)
{
if
(
bill
){
if
(
bill
){
if
(
compareData
(
GMS
.
oldBillData
,
bill
.
getBuillData
()))
{
this
.
approvalLogical
(
bill
,
param
,
this
)
}
else
{
GMS
.
billDataChangeChecked
=
true
GMS
.
$hideContainer
.
$Modal
.
confirm
({
title
:
"信息提示"
,
content
:
"信息发生变化, 是否保存"
,
onOk
:
()
=>
{
this
.
saveLogical
(
bill
,
param
,
{
data
:
bill
.
getBuillData
(),
detailData
:
[]},
this
)
},
onCancel
:
()
=>
{
this
.
approvalLogical
(
bill
,
param
,
this
)
}
})
}
}
else
{
GMS
.
$hideContainer
.
$Message
.
error
(
'缺少参数'
);
}
},
approvalLogical
:
(
bill
,
param
,
_this
)
=>
{
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
false
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
false
)
if
(
param
.
param
.
actions
){
if
(
param
.
param
.
actions
){
let
saveParam
=
{
let
saveParam
=
{
...
@@ -9,20 +30,36 @@ export default {
...
@@ -9,20 +30,36 @@ export default {
}
}
bill
.
executeServerAction
(
saveParam
,
function
(
code
,
data
){
bill
.
executeServerAction
(
saveParam
,
function
(
code
,
data
){
if
(
code
===
200
){
if
(
code
===
200
){
this
.
approval
(
bill
,
param
);
_this
.
approval
(
bill
,
param
);
// bill.setControlsSate(param["_control_name_"],"loading",false)
}
else
{
}
else
{
// bill.setControlsSate(param["_control_name_"],"loading",false)
delete
GMS
.
billDataChangeChecke
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
GMS
.
$hideContainer
.
$message
.
error
(
"操作异常请联系管理员"
);
GMS
.
$hideContainer
.
$message
.
error
(
"操作异常请联系管理员"
);
}
}
}.
bind
(
this
));
}.
bind
(
this
));
}
else
{
}
else
{
this
.
approval
(
bill
,
param
);
_
this
.
approval
(
bill
,
param
);
}
}
}
else
{
},
GMS
.
$hideContainer
.
$Message
.
error
(
'缺少参数'
);
saveLogical
:
(
bill
,
param
,
postData
,
_this
)
=>
{
let
url
=
`/rbc/bill/action/executed/
${
param
.
define
}
/bill.Basic.save?transmission=total`
GMS
.
$http
.
post
(
url
,
JSON
.
stringify
(
postData
),
{
headers
:
{
post
:
{
"Content-Type"
:
"application/json"
,
},
},
})
.
then
((
response
)
=>
{
if
(
response
.
data
.
code
==
0
)
{
_this
.
approvalLogical
(
bill
,
param
,
_this
)
}
else
{
response
.
data
.
message
&&
GMS
.
vbus
.
$Message
.
error
({
content
:
response
.
data
.
message
,
duration
:
3
});
}
}
})
},
},
approval
:
function
(
bill
,
param
){
approval
:
function
(
bill
,
param
){
if
(
!
bill
.
getGlobalParam
(
'reviewParam'
)
||
!
bill
.
getGlobalParam
(
'reviewParam'
).
taskId
)
{
if
(
!
bill
.
getGlobalParam
(
'reviewParam'
)
||
!
bill
.
getGlobalParam
(
'reviewParam'
).
taskId
)
{
...
@@ -34,7 +71,6 @@ export default {
...
@@ -34,7 +71,6 @@ export default {
GMS
.
$http
.
post
(
'/gms/workflow/task/completed/'
+
taskId
+
'?result=3&comments='
+
comments
).
then
(
GMS
.
$http
.
post
(
'/gms/workflow/task/completed/'
+
taskId
+
'?result=3&comments='
+
comments
).
then
(
function
(
response
)
{
function
(
response
)
{
if
(
response
.
status
==
200
||
response
.
statusText
==
'OK'
)
{
if
(
response
.
status
==
200
||
response
.
statusText
==
'OK'
)
{
// console.log('驳回成功');
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"loading"
,
false
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"loading"
,
false
)
GMS
.
$hideContainer
.
$Message
.
success
(
'驳回成功!'
)
GMS
.
$hideContainer
.
$Message
.
success
(
'驳回成功!'
)
...
...
develop/@rbc/runner-bill-form/src/views/bill-form-runner.vue
View file @
409e20bb
...
@@ -78,8 +78,10 @@ export default {
...
@@ -78,8 +78,10 @@ export default {
return
return
}
}
const
tem
=
this
.
curBill
&&
this
.
curBill
.
getBuillData
()
||
{}
const
tem
=
this
.
curBill
&&
this
.
curBill
.
getBuillData
()
||
{}
if
(
compareData
(
GMS
.
oldBillDataMap
[
this
.
curTagId
],
tem
))
cb
(
true
)
if
(
compareData
(
GMS
.
oldBillDataMap
[
this
.
curTagId
],
tem
)
||
this
.
state
==
'readOnly'
||
GMS
.
billDataChangeChecked
)
{
else
{
delete
GMS
.
billDataChangeChecke
cb
(
true
)
}
else
{
this
.
$Modal
.
confirm
({
this
.
$Modal
.
confirm
({
title
:
"信息提示"
,
title
:
"信息提示"
,
content
:
"信息发生变化,确认关闭?"
,
content
:
"信息发生变化,确认关闭?"
,
...
...
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