Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
micro-customization-system
/
micro-trialrun
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 65001ed2
authored
May 30, 2021
by
冒粤蓉
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fux
1 parent
11db8732
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
55 additions
and
16 deletions
src/App.vue
src/routes/index.js
src/views/specialShop/index.vue
src/App.vue
View file @
65001ed
...
@@ -20,8 +20,8 @@
...
@@ -20,8 +20,8 @@
<span
@
click=
"goToPage('/app-vue-history/about')"
>
app-vue-history About
</span>
<span
@
click=
"goToPage('/app-vue-history/about')"
>
app-vue-history About
</span>
</p>
</p>
</div>
-->
</div>
-->
<keep-alive
>
<keep-alive
:include=
"keepAlives"
>
<router-view
/>
<router-view
v-if=
"!$route.meta.isKeepAlive"
/>
</keep-alive>
</keep-alive>
</div>
</div>
</
template
>
</
template
>
...
@@ -33,6 +33,14 @@ export default {
...
@@ -33,6 +33,14 @@ export default {
data
()
{
data
()
{
return
{
return
{
isQiankun
:
window
.
__POWERED_BY_QIANKUN__
,
isQiankun
:
window
.
__POWERED_BY_QIANKUN__
,
keepAlives
:
[]
}
},
watch
:
{
$route
(
to
,
from
)
{
if
(
to
.
meta
.
keepAlives
)
{
this
.
keepAlives
.
push
(
to
.
name
);
}
}
}
},
},
methods
:
{
methods
:
{
...
...
src/routes/index.js
View file @
65001ed
...
@@ -8,59 +8,92 @@ const routes = [
...
@@ -8,59 +8,92 @@ const routes = [
{
{
path
:
'/'
,
path
:
'/'
,
name
:
'specialShop'
,
name
:
'specialShop'
,
component
:
()
=>
import
(
'../views/specialShop/index.vue'
)
component
:
()
=>
import
(
'../views/specialShop/index.vue'
),
meta
:
{
keepAlive
:
true
}
},
},
{
{
path
:
'/todo'
,
path
:
'/todo'
,
name
:
'toDo'
,
name
:
'toDo'
,
component
:
()
=>
import
(
'../views/toDo/index.vue'
)
component
:
()
=>
import
(
'../views/toDo/index.vue'
),
meta
:
{
keepAlive
:
true
}
},
},
{
{
path
:
'/vehicleManage'
,
path
:
'/vehicleManage'
,
name
:
'vehicleManage'
,
name
:
'vehicleManage'
,
component
:
()
=>
import
(
'../views/vehicleManage/index.vue'
)
component
:
()
=>
import
(
'../views/vehicleManage/index.vue'
),
meta
:
{
keepAlive
:
true
}
},
},
{
{
path
:
'/vehicleSubmit'
,
path
:
'/vehicleSubmit'
,
name
:
'vehicleSubmit'
,
name
:
'vehicleSubmit'
,
component
:
()
=>
import
(
'../views/vehicleSubmit/index.vue'
)
component
:
()
=>
import
(
'../views/vehicleSubmit/index.vue'
),
meta
:
{
keepAlive
:
true
}
},
},
{
{
path
:
'/vehicleSubmit/addVehicle'
,
path
:
'/vehicleSubmit/addVehicle'
,
name
:
'addVehicle'
,
name
:
'addVehicle'
,
meta
:
{
title
:
'新增车辆'
},
meta
:
{
title
:
'新增车辆'
},
component
:
()
=>
import
(
'../views/vehicleSubmit/addVehicle/index.vue'
)
component
:
()
=>
import
(
'../views/vehicleSubmit/addVehicle/index.vue'
),
meta
:
{
keepAlive
:
true
}
},
},
{
{
path
:
'/vehicleCheck'
,
path
:
'/vehicleCheck'
,
name
:
'vehicleCheck'
,
name
:
'vehicleCheck'
,
component
:
()
=>
import
(
'../views/vehicleSubmit/vehicleCheck/index.vue'
)
component
:
()
=>
import
(
'../views/vehicleSubmit/vehicleCheck/index.vue'
),
meta
:
{
keepAlive
:
true
}
},
},
{
{
path
:
'/reportManage'
,
path
:
'/reportManage'
,
name
:
'reportManage'
,
name
:
'reportManage'
,
component
:
()
=>
import
(
'../views/reportManage/index.vue'
)
component
:
()
=>
import
(
'../views/reportManage/index.vue'
),
meta
:
{
keepAlive
:
true
}
},
},
{
{
path
:
'/specialShop'
,
path
:
'/specialShop'
,
name
:
'specialShop'
,
name
:
'specialShop'
,
meta
:
{
title
:
'新增特约店'
},
meta
:
{
title
:
'新增特约店'
},
component
:
()
=>
import
(
'../views/specialShop/index.vue'
)
component
:
()
=>
import
(
'../views/specialShop/index.vue'
),
meta
:
{
keepAlive
:
true
}
},
},
{
{
path
:
'/specialShop/addShop'
,
path
:
'/specialShop/addShop'
,
name
:
'addShop'
,
name
:
'addShop'
,
component
:
()
=>
import
(
'../views/specialShop/addShop/index.vue'
)
component
:
()
=>
import
(
'../views/specialShop/addShop/index.vue'
),
meta
:
{
keepAlive
:
false
}
},
},
{
{
path
:
'/testDrive/checkList'
,
path
:
'/testDrive/checkList'
,
name
:
'testDriveCheckList'
,
name
:
'testDriveCheckList'
,
component
:
()
=>
import
(
'../views/testDrive/checkList.vue'
)
component
:
()
=>
import
(
'../views/testDrive/checkList.vue'
),
meta
:
{
keepAlive
:
true
}
},
},
{
{
path
:
'/alarmCenter/removeAlarm'
,
path
:
'/alarmCenter/removeAlarm'
,
name
:
'removeAlarm'
,
name
:
'removeAlarm'
,
component
:
()
=>
import
(
'../views/alarmCenter/removeAlarm.vue'
)
component
:
()
=>
import
(
'../views/alarmCenter/removeAlarm.vue'
),
meta
:
{
keepAlive
:
true
}
}
}
]
]
...
...
src/views/specialShop/index.vue
View file @
65001ed
...
@@ -215,9 +215,7 @@ export default {
...
@@ -215,9 +215,7 @@ export default {
this
.
searchForm
=
{}
this
.
searchForm
=
{}
},
},
btnClick
(
pType
,
scope
)
{
btnClick
(
pType
,
scope
)
{
if
(
scope
)
{
const
shopId
=
scope
&&
scope
.
shopId
;
const
{
shopId
}
=
scope
;
}
switch
(
pType
)
{
switch
(
pType
)
{
case
'create'
:
case
'create'
:
this
.
$router
.
push
({
name
:
'addShop'
})
this
.
$router
.
push
({
name
:
'addShop'
})
...
...
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