Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
V
vue-gjjs
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
fukai
vue-gjjs
Commits
c5b83c7b
Commit
c5b83c7b
authored
Jan 06, 2022
by
wangguangchao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
复核功能优化
parent
e5acc24d
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
41 additions
and
105 deletions
+41
-105
commonFuncs.js
src/mixin/commonFuncs.js
+1
-73
Event.js
src/model/Trnrel/Event.js
+29
-25
Transaction.js
src/store/Transaction.js
+7
-4
Inftrnps.vue
src/views/Business/Trnrel/Inftrnps.vue
+2
-2
index.vue
src/views/Review/index.vue
+2
-1
No files found.
src/mixin/commonFuncs.js
View file @
c5b83c7b
...
@@ -88,79 +88,7 @@ export default {
...
@@ -88,79 +88,7 @@ export default {
}
}
},
},
async
handlePass
(
data
)
{
async
handlePass
(
data
)
{
debugger
;
this
.
$store
.
state
.
Transaction
.
operateFuns
[
data
.
operateId
][
"pass"
]()
this
.
$confirm
(
'您确定复核该笔交易?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(
async
()
=>
{
let
idxInt
=
parseInt
(
data
.
idx
);
const
selIds
=
[
idxInt
+
1
];
//rowno选中行
const
selDst
=
"trncorco.trnstm"
//列表对应后台模型中的stream
let
params
=
{
selDst
:
selDst
,
selIds
:
selIds
};
this
.
declareParams
.
trnName
=
"trnrel"
;
console
.
log
(
this
);
this
.
model
.
pageId
=
data
.
pageId
;
let
rtnmsg
=
await
this
.
executeRule
(
"relrow"
,
params
)
if
(
rtnmsg
.
respCode
==
SUCCESS
)
{
debugger
;
let
errorMsg
=
""
;
let
fieldErrorsFlag
=
(
JSON
.
stringify
(
rtnmsg
.
fieldErrors
)
==
"{}"
);
if
(
!
fieldErrorsFlag
){
let
errorMsgkey
=
""
;
let
errorMsgVal
=
""
;
for
(
const
key
in
rtnmsg
.
fieldErrors
)
{
errorMsgkey
=
key
;
errorMsgVal
=
rtnmsg
.
fieldErrors
[
key
];
}
errorMsg
=
errorMsgkey
+
':'
+
errorMsgVal
;
this
.
$notify
.
error
({
title
:
'错误'
,
message
:
'复核失败!错误信息['
+
errorMsg
+
']'
});
}
else
{
this
.
$notify
({
title
:
'成功'
,
message
:
'复核成功'
,
type
:
'success'
});
debugger
;
// const that = this.root;
// that.executeRule("searow").then(res => {
// //TODO 处理数据逻辑
// that.$refs.inftrnps.stmData.data = res.data.trncorco_trnstm.rows;
// this.model.trncorco.trnstm = res.data.trncorco_trnstm;
// })
this
.
$router
.
history
.
push
(
"/taskList"
,
()
=>
{
this
.
$store
.
commit
(
"setTaskListTabVal"
,
'trnrel'
)
})
}
}
else
{
let
errorMsg
=
""
;
let
fieldErrorsFlag
=
(
JSON
.
stringify
(
rtnmsg
.
fieldErrors
)
==
"{}"
);
if
(
!
fieldErrorsFlag
){
let
errorMsgkey
=
""
;
let
errorMsgVal
=
""
;
for
(
const
key
in
rtnmsg
.
fieldErrors
)
{
errorMsgkey
=
key
;
errorMsgVal
=
rtnmsg
.
fieldErrors
[
key
];
}
errorMsg
=
errorMsgkey
+
':'
+
errorMsgVal
;
}
else
if
(
rtnmsg
.
respMsg
){
errorMsg
=
rtnmsg
.
respMsg
;
}
this
.
$notify
.
error
({
title
:
'错误'
,
message
:
'复核失败!错误信息['
+
errorMsg
+
']'
});
}
}
)
},
},
},
},
};
};
src/model/Trnrel/Event.js
View file @
c5b83c7b
...
@@ -86,16 +86,17 @@ export default {
...
@@ -86,16 +86,17 @@ export default {
this
.
$notify
.
error
({
title
:
'错误'
,
message
:
'服务请求失败!'
});
this
.
$notify
.
error
({
title
:
'错误'
,
message
:
'服务请求失败!'
});
}
}
},
},
async
onHandle
(
idx
,
row
)
{
async
onHandle
(
idx
,
row
)
{
let
trnName
=
row
.
交易代码
.
toLowerCase
();
let
viewurl
=
"/review/"
+
trnName
;
let
viewurl
=
"/review/ditopn"
;
const
operateId
=
await
this
.
$store
.
dispatch
(
'Transaction/setOperateFuns'
,
{
pass
:
this
.
onRelrow
.
bind
(
this
,
idx
),
let
pageId
=
this
.
model
.
pageId
;
refuse
:
()
=>
{
alert
(
"功能开发中"
)
}
debugger
;
});
this
.
$router
.
push
({
path
:
viewurl
,
query
:{
routeParams
:
{
process
:
"1"
,
commitFlag
:
"1"
},
trn
:
row
[
'INR'
],
idx
:
idx
,
pageId
:
pageId
}});
this
.
$router
.
push
({
path
:
viewurl
,
query
:
{
routeParams
:
{
process
:
"1"
,
commitFlag
:
"1"
},
trn
:
row
[
'INR'
],
idx
:
idx
,
operateId
:
operateId
}
});
},
},
async
onRelrow
(
idx
)
{
async
onRelrow
(
idx
)
{
...
@@ -103,8 +104,8 @@ export default {
...
@@ -103,8 +104,8 @@ export default {
confirmButtonText
:
'确定'
,
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
type
:
'warning'
}).
then
(
async
()
=>
{
}).
then
(
async
()
=>
{
const
selIds
=
[
idx
+
1
];
//rowno选中行
const
selIds
=
[
idx
+
1
];
//rowno选中行
const
selDst
=
"trncorco.trnstm"
//列表对应后台模型中的stream
const
selDst
=
"trncorco.trnstm"
//列表对应后台模型中的stream
let
params
=
{
selDst
:
selDst
,
selIds
:
selIds
};
let
params
=
{
selDst
:
selDst
,
selIds
:
selIds
};
...
@@ -115,45 +116,48 @@ export default {
...
@@ -115,45 +116,48 @@ export default {
let
errorMsg
=
""
;
let
errorMsg
=
""
;
let
fieldErrorsFlag
=
(
JSON
.
stringify
(
rtnmsg
.
fieldErrors
)
==
"{}"
);
let
fieldErrorsFlag
=
(
JSON
.
stringify
(
rtnmsg
.
fieldErrors
)
==
"{}"
);
if
(
!
fieldErrorsFlag
)
{
if
(
!
fieldErrorsFlag
)
{
let
errorMsgkey
=
""
;
let
errorMsgkey
=
""
;
let
errorMsgVal
=
""
;
let
errorMsgVal
=
""
;
for
(
const
key
in
rtnmsg
.
fieldErrors
)
{
for
(
const
key
in
rtnmsg
.
fieldErrors
)
{
errorMsgkey
=
key
;
errorMsgkey
=
key
;
errorMsgVal
=
rtnmsg
.
fieldErrors
[
key
];
errorMsgVal
=
rtnmsg
.
fieldErrors
[
key
];
}
}
errorMsg
=
errorMsgkey
+
':'
+
errorMsgVal
;
errorMsg
=
errorMsgkey
+
':'
+
errorMsgVal
;
this
.
$notify
.
error
({
title
:
'错误'
,
message
:
'复核失败!错误信息['
+
errorMsg
+
']'
});
this
.
$notify
.
error
({
title
:
'错误'
,
message
:
'复核失败!错误信息['
+
errorMsg
+
']'
});
}
else
{
}
else
{
this
.
$notify
({
this
.
$notify
({
title
:
'成功'
,
title
:
'成功'
,
message
:
'复核成功'
,
message
:
'复核成功'
,
type
:
'success'
type
:
'success'
});
});
debugger
;
// const that = this.root;
const
that
=
this
.
root
;
// that.executeRule("searow").then(res => {
that
.
executeRule
(
"searow"
).
then
(
res
=>
{
// //TODO 处理数据逻辑
//TODO 处理数据逻辑
// that.$refs.inftrnps.stmData.data = res.data.trncorco_trnstm.rows;
that
.
$refs
.
inftrnps
.
stmData
.
data
=
res
.
data
.
trncorco_trnstm
.
rows
;
// this.model.trncorco.trnstm = res.data.trncorco_trnstm;
this
.
model
.
trncorco
.
trnstm
=
res
.
data
.
trncorco_trnstm
;
// })
})
this
.
$store
.
dispatch
(
"TagsView/delView"
,
this
.
$route
)
this
.
$router
.
history
.
push
(
"/taskList"
,
()
=>
{
this
.
$store
.
commit
(
"setTaskListTabVal"
,
'trnrel'
)
});
}
}
}
}
else
{
else
{
let
errorMsg
=
""
;
let
errorMsg
=
""
;
let
fieldErrorsFlag
=
(
JSON
.
stringify
(
rtnmsg
.
fieldErrors
)
==
"{}"
);
let
fieldErrorsFlag
=
(
JSON
.
stringify
(
rtnmsg
.
fieldErrors
)
==
"{}"
);
if
(
!
fieldErrorsFlag
)
{
if
(
!
fieldErrorsFlag
)
{
let
errorMsgkey
=
""
;
let
errorMsgkey
=
""
;
let
errorMsgVal
=
""
;
let
errorMsgVal
=
""
;
for
(
const
key
in
rtnmsg
.
fieldErrors
)
{
for
(
const
key
in
rtnmsg
.
fieldErrors
)
{
errorMsgkey
=
key
;
errorMsgkey
=
key
;
errorMsgVal
=
rtnmsg
.
fieldErrors
[
key
];
errorMsgVal
=
rtnmsg
.
fieldErrors
[
key
];
}
}
errorMsg
=
errorMsgkey
+
':'
+
errorMsgVal
;
errorMsg
=
errorMsgkey
+
':'
+
errorMsgVal
;
}
else
if
(
rtnmsg
.
respMsg
)
{
}
else
if
(
rtnmsg
.
respMsg
)
{
errorMsg
=
rtnmsg
.
respMsg
;
errorMsg
=
rtnmsg
.
respMsg
;
}
}
this
.
$notify
.
error
({
title
:
'错误'
,
message
:
'复核失败!错误信息['
+
errorMsg
+
']'
});
this
.
$notify
.
error
({
title
:
'错误'
,
message
:
'复核失败!错误信息['
+
errorMsg
+
']'
});
}
}
...
@@ -377,7 +381,7 @@ export default {
...
@@ -377,7 +381,7 @@ export default {
});
});
that
.
$refs
.
inftrnps
.
stmData
.
data
=
arr
;
that
.
$refs
.
inftrnps
.
stmData
.
data
=
arr
;
this
.
model
.
trncorco
.
trnstm
=
res
.
data
.
trncorco_trnstm
;
this
.
model
.
trncorco
.
trnstm
=
res
.
data
.
trncorco_trnstm
;
if
(
res
.
data
.
trncorco_trnstm
.
rows
.
length
==
0
)
{
if
(
res
.
data
.
trncorco_trnstm
.
rows
.
length
==
0
)
{
this
.
$notify
({
this
.
$notify
({
title
:
'成功'
,
title
:
'成功'
,
message
:
'搜索完毕,无满足条件记录'
,
message
:
'搜索完毕,无满足条件记录'
,
...
...
src/store/Transaction.js
View file @
c5b83c7b
...
@@ -9,16 +9,19 @@ const mutations = {
...
@@ -9,16 +9,19 @@ const mutations = {
* @param {Object} funs
* @param {Object} funs
* @returns
* @returns
*/
*/
ADD_OPERATE_FUN
(
state
,
funs
)
{
ADD_OPERATE_FUN
(
state
,
{
id
,
funs
})
{
const
id
=
Symbol
(
"transaction-id"
);
state
.
operateFuns
[
id
]
=
funs
;
state
.
operateFuns
[
id
]
=
funs
;
return
id
;
},
},
};
};
const
actions
=
{
const
actions
=
{
setOperateFuns
({
commit
},
funs
)
{
setOperateFuns
({
commit
},
funs
)
{
commit
(
"ADD_OPERATE_FUN"
,
funs
);
return
new
Promise
(
resolve
=>
{
// const id = Symbol("transaction-id");
const
id
=
new
Date
().
valueOf
();
commit
(
'ADD_OPERATE_FUN'
,
{
id
,
funs
})
resolve
(
id
)
});
},
},
};
};
...
...
src/views/Business/Trnrel/Inftrnps.vue
View file @
c5b83c7b
...
@@ -435,7 +435,7 @@
...
@@ -435,7 +435,7 @@
>
>
处理
处理
</c-button>
<
!--
<
/c-button>
<c-button
<c-button
style=
"margin-left: 0"
style=
"margin-left: 0"
size=
"small"
size=
"small"
...
@@ -444,7 +444,7 @@
...
@@ -444,7 +444,7 @@
>
>
复核
复核
</c-button>
</c-button>
-->
...
...
src/views/Review/index.vue
View file @
c5b83c7b
...
@@ -347,7 +347,8 @@ export default {
...
@@ -347,7 +347,8 @@ export default {
// 复核通过需要传递参数:复核意见和tips
// 复核通过需要传递参数:复核意见和tips
// 通过 - 清空tips
// 通过 - 清空tips
data
=
{
data
=
{
pageId
:
this
.
$route
.
query
.
pageId
,
// pageId: this.$route.query.pageId,
operateId
:
this
.
$route
.
query
.
operateId
,
idx
:
this
.
$route
.
query
.
idx
,
idx
:
this
.
$route
.
query
.
idx
,
remark
:
this
.
remark
,
remark
:
this
.
remark
,
tips
:
[]
//this.$store.state.Status.highlights
tips
:
[]
//this.$store.state.Status.highlights
...
...
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