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
b61b1c74
Commit
b61b1c74
authored
May 24, 2022
by
Joey
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(@gms/gms-plugin-billexpand): 工会取回和提交增加动作
parent
442a73ce
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
101 additions
and
35 deletions
+101
-35
gh_retrieveAction.js
...n-billexpand/src/actions/labourUnion/gh_retrieveAction.js
+51
-25
gh_submitAction.js
...gin-billexpand/src/actions/labourUnion/gh_submitAction.js
+33
-9
emcon.js
develop/@gms/gms-plugin-billexpand/src/emcon.js
+17
-1
No files found.
develop/@gms/gms-plugin-billexpand/src/actions/labourUnion/gh_retrieveAction.js
View file @
b61b1c74
...
...
@@ -2,31 +2,57 @@ export default {
execute
(
bill
,
param
)
{
bill
=
bill
.
dom
||
bill
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
false
)
GMS
.
$http
.
post
(
`/rbc/bill/action/zgh/change/work/
${
param
.
define
}
/bill.Basic.retrieve`
,
{
approvalComments
:
comments
,
data
:
bill
.
getBuillData
(),
detailData
:
[],
const
fn
=
()
=>
{
GMS
.
$http
.
post
(
`/rbc/bill/action/zgh/change/work/
${
param
.
define
}
/bill.Basic.retrieve`
,
{
data
:
bill
.
getBuillData
(),
detailData
:
[],
}
).
then
((
res
)
=>
{
if
(
res
.
data
&&
res
.
data
.
code
==
0
)
{
GMS
.
$hideContainer
.
$Message
.
success
(
'操作成功!'
)
const
curTagId
=
window
.
nros
.
context
.
getCurrTag
();
GMS
.
vbus
.
$emit
(
'change-form-state'
,
{
state
:
'readOnly'
},
curTagId
)
}
else
{
const
{
data
}
=
res
data
.
message
&&
GMS
.
$hideContainer
.
$Message
.
error
({
content
:
errorMessageUtil
.
submitAction
.
getErrorMessage
(
data
.
message
),
duration
:
3
});
}
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"loading"
,
false
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
}).
catch
((
err
)
=>
{
GMS
.
$hideContainer
.
$Message
.
error
(
'系统错误,请联系管理员'
)
console
.
error
(
err
);
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"loading"
,
false
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
})
}
if
(
param
.
param
.
actions
)
{
let
saveParam
=
{
actions
:
param
.
param
.
actions
}
).
then
((
res
)
=>
{
if
(
res
.
data
&&
res
.
data
.
code
==
0
)
{
GMS
.
$hideContainer
.
$Message
.
success
(
'操作成功!'
)
}
else
{
const
{
data
}
=
res
data
.
message
&&
GMS
.
$hideContainer
.
$Message
.
error
({
content
:
errorMessageUtil
.
submitAction
.
getErrorMessage
(
data
.
message
),
duration
:
3
});
}
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"loading"
,
false
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"loading"
,
false
)
}).
catch
(()
=>
{
GMS
.
$hideContainer
.
$Message
.
error
(
'系统错误,请联系管理员'
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"loading"
,
false
)
})
bill
.
executeServerAction
(
saveParam
,
function
(
code
,
data
)
{
if
(
code
===
200
)
{
fn
()
}
else
{
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
if
(
data
.
message
)
{
const
errMsg
=
data
.
message
.
split
(
'nested exception is'
)
GMS
.
$hideContainer
.
$message
.
error
(
errMsg
&&
errMsg
[
1
]
||
'操作异常请联系管理员'
);
}
else
{
GMS
.
$hideContainer
.
$message
.
error
(
"操作异常请联系管理员"
);
}
}
}.
bind
(
this
));
}
else
{
fn
()
}
},
}
develop/@gms/gms-plugin-billexpand/src/actions/labourUnion/gh_submitAction.js
View file @
b61b1c74
...
...
@@ -111,16 +111,40 @@ export default {
})
}
if
(
param
&&
param
.
param
&&
param
.
param
.
useSignature
)
{
showSignModal
(
bill
,
param
,
'提交人'
).
then
(()
=>
{
saveBill
(
bill
,
param
).
then
(
submitFn
)
}).
catch
(()
=>
{
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"loading"
,
false
)
})
const
fn
=
()
=>
{
if
(
param
&&
param
.
param
&&
param
.
param
.
useSignature
)
{
showSignModal
(
bill
,
param
,
'提交人'
).
then
(()
=>
{
saveBill
(
bill
,
param
).
then
(
submitFn
)
}).
catch
(()
=>
{
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"loading"
,
false
)
})
}
else
{
submitFn
()
}
}
else
{
submitFn
()
if
(
param
.
param
.
actions
)
{
let
saveParam
=
{
actions
:
param
.
param
.
actions
}
bill
.
executeServerAction
(
saveParam
,
function
(
code
,
data
)
{
if
(
code
===
200
)
{
fn
()
}
else
{
bill
.
setControlsSate
(
param
[
"_control_name_"
],
"enable"
,
true
)
if
(
data
.
message
)
{
const
errMsg
=
data
.
message
.
split
(
'nested exception is'
)
GMS
.
$hideContainer
.
$message
.
error
(
errMsg
&&
errMsg
[
1
]
||
'操作异常请联系管理员'
);
}
else
{
GMS
.
$hideContainer
.
$message
.
error
(
"操作异常请联系管理员"
);
}
}
}.
bind
(
this
));
}
else
{
fn
()
}
}
else
{
...
...
develop/@gms/gms-plugin-billexpand/src/emcon.js
View file @
b61b1c74
...
...
@@ -2275,7 +2275,15 @@ export default {
"type"
:
"Boolean"
,
"title"
:
"电子签章"
,
"key"
:
"useSignature"
}
},
{
"clearable"
:
true
,
"ref"
:
"gams2.bill"
,
"type"
:
"select"
,
"title"
:
"执行动作"
,
"key"
:
"actions"
,
"innerRef"
:
"actions"
},
]
},
"description"
:
""
,
...
...
@@ -2344,6 +2352,14 @@ export default {
"path"
:
"报销/工会"
,
"extends"
:
{
"param"
:
[
{
"clearable"
:
true
,
"ref"
:
"gams2.bill"
,
"type"
:
"select"
,
"title"
:
"执行动作"
,
"key"
:
"actions"
,
"innerRef"
:
"actions"
},
]
},
"description"
:
""
,
...
...
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