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
482ceddc
Commit
482ceddc
authored
Jul 11, 2022
by
潘际乾
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
BusNavbar 公共组件提取
parent
ba674982
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
113 additions
and
8 deletions
+113
-8
Infsea.vue
src/views/Business/Infbdd/Infsea.vue
+5
-2
Infsea.vue
src/views/Business/Infbed/Infsea.vue
+5
-1
Infsea.vue
src/views/Business/Infdid/Infsea.vue
+7
-5
BusNavbar.vue
src/views/Public/BusNavbar.vue
+96
-0
No files found.
src/views/Business/Infbdd/Infsea.vue
View file @
482ceddc
...
...
@@ -307,7 +307,7 @@
<el-dialog
:visible
.
sync=
"initdialog"
:title=
"'交易列表'"
append-to-body
>
<div
class=
"m-list-btns"
>
<m-busbtn
ref=
"childs"
:ownref=
"ownref"
@
onChoose=
"onChoose"
>
11
</m-busbtn>
<m-busbtn
ref=
"childs"
:ownref=
"ownref"
trnName=
"ditsel"
:model=
"ditselModel"
@
onChoose=
"onChoose"
>
11
</m-busbtn>
</div>
</el-dialog>
</div>
...
...
@@ -317,7 +317,9 @@ import Api from "~/service/Api";
import
commonProcess
from
"~/mixin/commonProcess"
;
import
CodeTable
from
"~/config/CodeTable"
;
import
Event
from
"~/model/Infbdd/Event"
;
import
BusNavbar
from
"~/views/Business/Infbdd/BusNavbar"
import
DitselModel
from
"~/model/Ditsel"
import
BusNavbar
from
"~/views/Public/BusNavbar"
;
export
default
{
inject
:
[
"root"
],
...
...
@@ -326,6 +328,7 @@ export default {
components
:{
'm-busbtn'
:
BusNavbar
},
data
()
{
return
{
ditselModel
:
new
DitselModel
().
data
,
ownref
:
""
,
initdialog
:
false
,
trnData
:
{
...
...
src/views/Business/Infbed/Infsea.vue
View file @
482ceddc
...
...
@@ -238,7 +238,7 @@
<el-dialog
:visible
.
sync=
"initdialog"
:title=
"'交易列表'"
append-to-body
>
<div
class=
"m-list-btns"
>
<m-busbtn
ref=
"childs"
:ownref=
"ownref"
@
onChoose=
"onChoose"
>
11
</m-busbtn>
<m-busbtn
ref=
"childs"
:ownref=
"ownref"
trnName=
"ditsel"
:model=
"letselModel"
@
onChoose=
"onChoose"
>
11
</m-busbtn>
</div>
</el-dialog>
</div>
...
...
@@ -250,6 +250,9 @@ import CodeTable from "~/config/CodeTable"
import
Event
from
"~/model/Infbed/Event"
import
BusNavbar
from
"~/views/Business/Infbdd/BusNavbar"
import
LetselModel
from
"~/model/Letsel"
import
BusNavbar
from
"~/views/Public/BusNavbar"
;
export
default
{
inject
:
[
'root'
],
props
:[
"model"
,
"codes"
],
...
...
@@ -257,6 +260,7 @@ export default {
components
:{
'm-busbtn'
:
BusNavbar
},
data
(){
return
{
letselModel
:
new
LetselModel
().
data
,
ownref
:
""
,
initdialog
:
false
,
trnData
:
{
...
...
src/views/Business/Infdid/Infsea.vue
View file @
482ceddc
...
...
@@ -387,9 +387,7 @@
<el-dialog
:visible
.
sync=
"initdialog"
:title=
"'交易列表'"
append-to-body
>
<div
class=
"m-list-btns"
>
<m-busbtn
ref=
"childs"
:ownref=
"ownref"
@
onChoose=
"onChoose"
>
11
</m-busbtn
>
<m-busbtn
ref=
"childs"
:ownref=
"ownref"
trnName=
"ditsel"
:model=
"ditselModel"
@
onChoose=
"onChoose"
></m-busbtn>
</div>
</el-dialog>
...
...
@@ -587,7 +585,9 @@ import Api from "~/service/Api";
import
commonProcess
from
"~/mixin/commonProcess"
;
import
CodeTable
from
"~/config/CodeTable"
;
import
Event
from
"~/model/Infdid/Event"
;
import
BusNavbar
from
"~/views/Business/Infdid/BusNavbar"
;
import
DitselModel
from
"~/model/Ditsel"
import
BusNavbar
from
"~/views/Public/BusNavbar"
;
export
default
{
inject
:
[
"root"
],
...
...
@@ -596,6 +596,7 @@ export default {
components
:
{
"m-busbtn"
:
BusNavbar
},
data
()
{
return
{
ditselModel
:
new
DitselModel
().
data
,
ownref
:
""
,
initdialog
:
false
,
dialogTableVisible
:
false
,
...
...
@@ -636,7 +637,8 @@ export default {
},
};
},
methods
:
{
...
Event
,
methods
:
{
...
Event
,
async
getButtons
(
ownref
){
this
.
initdialog
=
true
this
.
ownref
=
ownref
...
...
src/views/Public/BusNavbar.vue
0 → 100644
View file @
482ceddc
<
template
>
<div
class=
"busnavbar"
>
<div
class=
"busnavbar-items"
>
<c-button
style=
"margin-left: 7px"
size=
"medium"
type=
"primary"
class=
"medium_bcs"
v-for=
"(item, index) in navcode"
v-bind:key=
"index"
@
click
.
native=
"onNarBtnClick(item.code, item.index)"
:title=
"item.title"
:disabled=
"item.isDis === 'N'"
>
{{
item
.
label
}}
</c-button
>
</div>
</div>
</
template
>
<
script
>
import
Api
from
"~/service/Api"
;
import
commonProcess
from
"~/mixin/commonProcess"
;
export
default
{
props
:
[
"ownref"
,
"trnName"
,
"model"
],
components
:
{},
mixins
:
[
commonProcess
],
// 里面包含了Default、Check等的公共处理
data
()
{
return
{
navcode
:
[
// {code:"",label:"",isDis:"",title:""},
],
};
},
methods
:
{
//各入口按钮请求
async
onNarBtnClick
(
code
,
i
)
{
this
.
model
.
cfgfil
[
`subtrn
${
i
}
`
]
=
code
;
let
rtnmsg
=
await
this
.
executeRule
(
`cfgfil.hotsub
${
i
}
`
);
if
(
rtnmsg
.
respCode
==
SUCCESS
)
{
this
.
navcode
=
[];
this
.
$emit
(
"onChoose"
,
code
.
toLowerCase
());
}
else
{
this
.
$notify
.
error
({
title
:
"错误"
,
message
:
"服务请求失败!"
});
}
},
getIndex
(
module
)
{
for
(
let
i
=
1
;
i
<=
12
;
i
++
)
{
var
temp
=
this
.
model
.
cfgfil
[
`subtxt
${
i
}
`
];
if
(
module
==
temp
)
{
return
i
;
}
}
return
0
;
},
},
mounted
()
{
this
.
$nextTick
(
function
()
{
this
.
$on
(
"childmethods"
,
async
function
()
{
this
.
navcode
=
[];
//请求按钮数据
this
.
model
.
didgrp
.
rec
.
ownref
=
this
.
ownref
;
console
.
log
(
"ownref:"
+
this
.
ownref
);
let
rtnmsg
=
await
this
.
executeRule
(
"didgrp.rec.ownref"
);
//didgrp_rec_ownref
if
(
rtnmsg
.
respCode
==
SUCCESS
)
{
//重置数组
this
.
navcode
=
[];
this
.
updateModel
(
rtnmsg
.
data
);
//this.model.cfgfil.btnstm = rtnmsg.data.cfgfil_btnstm.rows
//给inr赋值,后面弹窗里面的按钮请求会用到
//this.model.didgrp.rec.inr = rtnmsg.data.didgrp_rec_inr
const
length
=
this
.
model
.
cfgfil
.
btnstm
.
rows
.
length
;
let
btnStr
=
this
.
model
.
cfgfil
.
btnstm
.
rows
;
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
let
arr
=
btnStr
[
i
].
split
(
"
\
t"
);
var
index
=
this
.
getIndex
(
arr
[
1
]);
let
newList
=
{
code
:
arr
[
0
],
label
:
arr
[
1
],
isDis
:
arr
[
2
],
title
:
arr
[
3
],
index
:
index
,
};
this
.
navcode
.
push
(
newList
);
}
}
else
{
this
.
navcode
=
[];
this
.
$notify
.
error
({
title
:
"错误"
,
message
:
"服务请求失败!"
});
}
});
});
},
};
</
script
>
<
style
>
</
style
>
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