Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mingPayPc
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
fengzhaoyu
mingPayPc
Commits
66c9464c
Commit
66c9464c
authored
Dec 07, 2019
by
liang ce
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
router 判断
parent
719a294c
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
21 additions
and
12 deletions
+21
-12
axios.js
src/api/axios.js
+9
-0
CanteenManagementHome.vue
...ponents/pages/CanteenManagement/CanteenManagementHome.vue
+4
-4
PaymentManagementHome.vue
...ponents/pages/PaymentManagement/PaymentManagementHome.vue
+7
-7
rightsManagementHome.vue
...omponents/pages/rightsManagement/rightsManagementHome.vue
+1
-1
No files found.
src/api/axios.js
View file @
66c9464c
...
@@ -92,6 +92,9 @@ const $http = {
...
@@ -92,6 +92,9 @@ const $http = {
}
}
}).
then
((
res
)
=>
{
}).
then
((
res
)
=>
{
return
resolve
(
res
)
return
resolve
(
res
)
}).
catch
(
err
=>
{
console
.
log
(
err
)
return
reject
()
})
})
})
})
},
},
...
@@ -100,6 +103,9 @@ const $http = {
...
@@ -100,6 +103,9 @@ const $http = {
let
getData
=
data
===
undefined
?
''
:
qs
.
stringify
(
data
)
let
getData
=
data
===
undefined
?
''
:
qs
.
stringify
(
data
)
axios
.
get
(
`
${
BASE_URL
}${
url
}
?
${
getData
}
`
).
then
((
res
)
=>
{
axios
.
get
(
`
${
BASE_URL
}${
url
}
?
${
getData
}
`
).
then
((
res
)
=>
{
return
resolve
(
res
)
return
resolve
(
res
)
}).
catch
(
err
=>
{
console
.
log
(
err
)
return
reject
()
})
})
})
})
},
},
...
@@ -108,6 +114,9 @@ const $http = {
...
@@ -108,6 +114,9 @@ const $http = {
let
getData
=
data
===
undefined
?
''
:
qs
.
stringify
(
data
)
let
getData
=
data
===
undefined
?
''
:
qs
.
stringify
(
data
)
axios
.
delete
(
`
${
BASE_URL
}${
url
}
?
${
getData
}
`
).
then
((
res
)
=>
{
axios
.
delete
(
`
${
BASE_URL
}${
url
}
?
${
getData
}
`
).
then
((
res
)
=>
{
return
resolve
(
res
)
return
resolve
(
res
)
}).
catch
(
err
=>
{
console
.
log
(
err
)
return
reject
()
})
})
})
})
}
}
...
...
src/components/pages/CanteenManagement/CanteenManagementHome.vue
View file @
66c9464c
...
@@ -44,16 +44,16 @@ export default {
...
@@ -44,16 +44,16 @@ export default {
this
.
defaultSelectedKeys
=
this
.
$route
.
name
this
.
defaultSelectedKeys
=
this
.
$route
.
name
this
.
chooseMenuList
=
this
.
$route
.
name
this
.
chooseMenuList
=
this
.
$route
.
name
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'4100'
)
>
-
1
)
{
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'4100'
)
>
-
1
)
{
router
.
push
({
path
:
'/classificationOfDishes'
})
router
.
push
({
path
:
'/classificationOfDishes'
})
this
.
chooseMenuList
=
'classificationOfDishes'
this
.
chooseMenuList
=
'classificationOfDishes'
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'4200'
)
>
-
1
)
{
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'4200'
)
>
-
1
)
{
router
.
push
({
path
:
'/menuManagement'
})
router
.
push
({
path
:
'/menuManagement'
})
this
.
chooseMenuList
=
'menuManagement'
this
.
chooseMenuList
=
'menuManagement'
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'4300'
)
>
-
1
)
{
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'4300'
)
>
-
1
)
{
router
.
push
({
path
:
'/consumptionOrder'
})
router
.
push
({
path
:
'/consumptionOrder'
})
this
.
chooseMenuList
=
'consumptionOrder'
this
.
chooseMenuList
=
'consumptionOrder'
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'4400'
)
>
-
1
)
{
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'4400'
)
>
-
1
)
{
router
.
push
({
path
:
'/consumptionStatistics'
})
router
.
push
({
path
:
'/consumptionStatistics'
})
this
.
chooseMenuList
=
'consumptionStatistics'
this
.
chooseMenuList
=
'consumptionStatistics'
}
}
},
},
...
...
src/components/pages/PaymentManagement/PaymentManagementHome.vue
View file @
66c9464c
...
@@ -39,25 +39,25 @@ export default {
...
@@ -39,25 +39,25 @@ export default {
this
.
defaultSelectedKeys
=
this
.
$route
.
name
this
.
defaultSelectedKeys
=
this
.
$route
.
name
this
.
chooseMenuList
=
this
.
$route
.
name
this
.
chooseMenuList
=
this
.
$route
.
name
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3100'
)
>
-
1
)
{
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3100'
)
>
-
1
)
{
router
.
push
({
path
:
'/accountManagement'
})
router
.
push
({
path
:
'/accountManagement'
})
this
.
chooseMenuList
=
'accountManagement'
this
.
chooseMenuList
=
'accountManagement'
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3200'
)
>
-
1
)
{
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3200'
)
>
-
1
)
{
router
.
push
({
path
:
'/rechargeRecord'
})
router
.
push
({
path
:
'/rechargeRecord'
})
this
.
chooseMenuList
=
'rechargeRecord'
this
.
chooseMenuList
=
'rechargeRecord'
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3300'
)
>
-
1
)
{
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3300'
)
>
-
1
)
{
router
.
push
({
path
:
'/allowancePayment'
})
router
.
push
({
path
:
'/allowancePayment'
})
this
.
chooseMenuList
=
'allowancePayment'
this
.
chooseMenuList
=
'allowancePayment'
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3400'
)
>
-
1
)
{
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3400'
)
>
-
1
)
{
router
.
push
({
path
:
'/recordsOfConsumption'
})
router
.
push
({
path
:
'/recordsOfConsumption'
})
this
.
chooseMenuList
=
'recordsOfConsumption'
this
.
chooseMenuList
=
'recordsOfConsumption'
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3500'
)
>
-
1
)
{
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3500'
)
>
-
1
)
{
router
.
push
({
path
:
'/systemReconciliation'
})
router
.
push
({
path
:
'/systemReconciliation'
})
this
.
chooseMenuList
=
'systemReconciliation'
this
.
chooseMenuList
=
'systemReconciliation'
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3600'
)
>
-
1
)
{
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3600'
)
>
-
1
)
{
router
.
push
({
path
:
'/paymentManagementSetting'
})
router
.
push
({
path
:
'/paymentManagementSetting'
})
this
.
chooseMenuList
=
'paymentManagementSetting'
this
.
chooseMenuList
=
'paymentManagementSetting'
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3700'
)
>
-
1
)
{
}
else
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'3700'
)
>
-
1
)
{
router
.
push
({
path
:
'/operationLog'
})
router
.
push
({
path
:
'/operationLog'
})
this
.
chooseMenuList
=
'operationLog'
this
.
chooseMenuList
=
'operationLog'
}
}
},
},
...
...
src/components/pages/rightsManagement/rightsManagementHome.vue
View file @
66c9464c
...
@@ -35,7 +35,7 @@ export default {
...
@@ -35,7 +35,7 @@ export default {
this
.
defaultSelectedKeys
=
this
.
$route
.
name
this
.
defaultSelectedKeys
=
this
.
$route
.
name
this
.
chooseMenuList
=
this
.
$route
.
name
this
.
chooseMenuList
=
this
.
$route
.
name
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'9100'
)
>
-
1
)
{
if
(
this
.
$store
.
state
.
menuList
.
indexOf
(
'9100'
)
>
-
1
)
{
router
.
push
({
path
:
'/rightsManagement'
})
router
.
push
({
path
:
'/rightsManagement'
})
this
.
chooseMenuList
=
'rightsManagement'
this
.
chooseMenuList
=
'rightsManagement'
}
}
},
},
...
...
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