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 3fd02a18
authored
Nov 12, 2020
by
冒粤蓉
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
improve menu
1 parent
098fd495
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
38 additions
and
7 deletions
src/main.js
src/views/dictionaryManage/dictionaryData/index.vue
src/views/dictionaryManage/index.vue
src/main.js
View file @
3fd02a1
...
@@ -40,7 +40,7 @@ function render({ data = {} , container } = {}) {
...
@@ -40,7 +40,7 @@ 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
)
=>
{
router
.
beforeEach
((
to
,
from
,
next
)
=>
{
const
metaTitle
=
to
.
meta
.
title
;
const
metaTitle
=
to
.
meta
.
title
;
if
(
metaTitle
)
{
if
(
metaTitle
)
{
const
thisBreadCrumb
=
data
.
store
.
getters
.
curBreadCrumb
;
const
thisBreadCrumb
=
data
.
store
.
getters
.
curBreadCrumb
;
...
...
src/views/dictionaryManage/dictionaryData/index.vue
View file @
3fd02a1
...
@@ -86,6 +86,7 @@ export default {
...
@@ -86,6 +86,7 @@ export default {
data
()
{
data
()
{
return
{
return
{
DICTSTATUS
:
this
.
$Constants
.
DICT_STATUS
,
DICTSTATUS
:
this
.
$Constants
.
DICT_STATUS
,
storageParams
:
{},
searchForm
:
{
searchForm
:
{
name
:
''
name
:
''
},
},
...
@@ -198,20 +199,49 @@ export default {
...
@@ -198,20 +199,49 @@ export default {
}
}
},
},
mounted
()
{
mounted
()
{
this
.
searchForm
.
name
=
this
.
$route
.
params
.
row
.
dictName
let
params
=
this
.
$route
.
params
;
this
.
dictDataForm
.
dictType
=
this
.
$route
.
params
.
row
.
dictType
if
((
JSON
.
stringify
(
params
)
===
'{}'
||
!
params
))
{
this
.
dictDataForm
.
enableStatus
=
this
.
$route
.
params
.
row
.
enableStatus
params
=
this
.
getInitStorage
();
this
.
storageParams
=
params
;
}
if
(
params
)
{
this
.
searchForm
.
name
=
params
.
row
.
dictName
this
.
dictDataForm
.
dictType
=
params
.
row
.
dictType
this
.
dictDataForm
.
enableStatus
=
params
.
row
.
enableStatus
}
},
},
methods
:
{
methods
:
{
getInitStorage
()
{
const
getStorageParams
=
localStorage
.
getItem
(
'dictionaryParams'
);
if
(
getStorageParams
)
{
return
JSON
.
parse
(
getStorageParams
);
}
else
{
return
''
;
}
},
// 重置搜索条件
// 重置搜索条件
refresh
()
{
refresh
()
{
let
name
=
''
;
if
(
this
.
$route
.
params
.
row
)
{
name
=
this
.
$route
.
params
.
row
.
dictName
;
}
else
if
(
this
.
storageParams
.
row
)
{
name
=
this
.
storageParams
.
row
.
dictName
;
}
this
.
searchForm
=
{
this
.
searchForm
=
{
name
:
this
.
$route
.
params
.
row
.
dictName
name
}
}
},
},
beforeSearchFn
()
{
beforeSearchFn
()
{
return
new
Promise
((
resolve
,
reject
)
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
this
.
searchForm
.
type
=
this
.
$route
.
params
.
row
.
dictType
let
getDictType
=
''
;
setTimeout
(()
=>
{
if
(
this
.
$route
.
params
.
row
)
{
getDictType
=
this
.
$route
.
params
.
row
.
dictType
;
}
else
if
(
this
.
storageParams
.
row
)
{
getDictType
=
this
.
storageParams
.
row
.
dictType
;
}
this
.
searchForm
.
type
=
getDictType
;
if
(
this
.
searchForm
.
daterange
)
{
if
(
this
.
searchForm
.
daterange
)
{
this
.
searchForm
.
sDate
=
this
.
searchForm
.
daterange
[
0
]
this
.
searchForm
.
sDate
=
this
.
searchForm
.
daterange
[
0
]
this
.
searchForm
.
eDate
=
this
.
searchForm
.
daterange
[
1
]
this
.
searchForm
.
eDate
=
this
.
searchForm
.
daterange
[
1
]
...
@@ -220,6 +250,7 @@ export default {
...
@@ -220,6 +250,7 @@ export default {
if
(
this
.
searchForm
.
sDate
)
delete
this
.
searchForm
.
sDate
&&
delete
this
.
searchForm
.
eDate
if
(
this
.
searchForm
.
sDate
)
delete
this
.
searchForm
.
sDate
&&
delete
this
.
searchForm
.
eDate
}
}
resolve
()
resolve
()
},
100
)
})
})
},
},
// 确定
// 确定
...
...
src/views/dictionaryManage/index.vue
View file @
3fd02a1
...
@@ -277,7 +277,7 @@ export default {
...
@@ -277,7 +277,7 @@ export default {
case
'list'
:
case
'list'
:
console
.
log
(
'list'
,
scope
)
console
.
log
(
'list'
,
scope
)
const
listData
=
{
row
:
scope
};
const
listData
=
{
row
:
scope
};
localStorage
.
setItem
(
'dictionaryParams'
,
listData
);
localStorage
.
setItem
(
'dictionaryParams'
,
JSON
.
stringify
(
listData
)
);
this
.
$router
.
push
({
name
:
'dictionaryData'
,
params
:
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