Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
micro-system
/
system
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 9693285e
authored
Nov 12, 2020
by
冒粤蓉
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
improve menu
1 parent
77c17659
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
2 deletions
src/main.js
src/routes/index.js
src/views/dictionaryManage/index.vue
src/main.js
View file @
9693285
...
@@ -23,7 +23,6 @@ let router = null;
...
@@ -23,7 +23,6 @@ let router = null;
let
instance
=
null
;
let
instance
=
null
;
function
render
({
data
=
{}
,
container
}
=
{})
{
function
render
({
data
=
{}
,
container
}
=
{})
{
console
.
log
(
'render innnnnn'
)
router
=
new
VueRouter
({
router
=
new
VueRouter
({
base
:
window
.
__POWERED_BY_QIANKUN__
?
'/system'
:
'/'
,
base
:
window
.
__POWERED_BY_QIANKUN__
?
'/system'
:
'/'
,
routes
,
routes
,
...
@@ -40,6 +39,25 @@ function render({ data = {} , container } = {}) {
...
@@ -40,6 +39,25 @@ function render({ data = {} , container } = {}) {
},
},
render
:
h
=>
h
(
App
),
render
:
h
=>
h
(
App
),
}).
$mount
(
container
?
container
.
querySelector
(
'#glsx-sub-system'
)
:
'#glsx-sub-system'
);
}).
$mount
(
container
?
container
.
querySelector
(
'#glsx-sub-system'
)
:
'#glsx-sub-system'
);
router
.
beforeEach
((
to
,
from
,
next
)
=>
{
const
metaTitle
=
to
.
meta
.
title
;
if
(
metaTitle
)
{
const
thisBreadCrumb
=
data
.
store
.
getters
.
curBreadCrumb
;
if
(
thisBreadCrumb
)
{
let
nextChildren
=
{};
nextChildren
=
{
active
:
true
,
menuName
:
metaTitle
,
path
:
'/system#'
+
to
.
path
,
params
:
to
.
params
};
thisBreadCrumb
.
children
.
children
=
nextChildren
;
data
.
store
.
dispatch
(
'menu/setBreadCrumb'
,
thisBreadCrumb
);
}
}
next
();
})
}
}
if
(
!
window
.
__POWERED_BY_QIANKUN__
)
{
if
(
!
window
.
__POWERED_BY_QIANKUN__
)
{
...
...
src/routes/index.js
View file @
9693285
...
@@ -38,6 +38,7 @@ const routes = [
...
@@ -38,6 +38,7 @@ const routes = [
{
{
path
:
'/dictionaryManage/dictionaryData'
,
path
:
'/dictionaryManage/dictionaryData'
,
name
:
'dictionaryData'
,
name
:
'dictionaryData'
,
meta
:
{
title
:
'字典数据'
},
component
:
()
=>
import
(
'../views/dictionaryManage/dictionaryData/index.vue'
)
component
:
()
=>
import
(
'../views/dictionaryManage/dictionaryData/index.vue'
)
},
},
{
{
...
...
src/views/dictionaryManage/index.vue
View file @
9693285
...
@@ -263,7 +263,9 @@ export default {
...
@@ -263,7 +263,9 @@ export default {
break
break
case
'list'
:
case
'list'
:
console
.
log
(
'list'
,
scope
)
console
.
log
(
'list'
,
scope
)
this
.
$router
.
push
({
name
:
'dictionaryData'
,
params
:
{
row
:
scope
}
})
const
listData
=
{
row
:
scope
};
localStorage
.
setItem
(
'dictionaryParams'
,
listData
);
this
.
$router
.
push
({
name
:
'dictionaryData'
,
params
:
listData
});
break
break
}
}
},
},
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment