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 fabe6e7d
authored
Jun 02, 2021
by
冒粤蓉
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fix
1 parent
de20b472
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
122 additions
and
104 deletions
src/App.vue
src/components/map/fenceMap.vue
src/main.js
src/routes/index.js
src/views/specialShop/addShop/index.vue
src/App.vue
View file @
fabe6e7
...
@@ -41,10 +41,36 @@ export default {
...
@@ -41,10 +41,36 @@ export default {
if
(
to
.
meta
.
keepAlives
)
{
if
(
to
.
meta
.
keepAlives
)
{
this
.
keepAlives
.
push
(
to
.
name
);
this
.
keepAlives
.
push
(
to
.
name
);
}
}
if
(
this
.
isQiankun
)
{
this
.
getBreadcrumb
();
}
}
}
},
},
methods
:
{
methods
:
{
...
mapMutations
([
'updateBaseURL'
]),
...
mapMutations
([
'updateBaseURL'
]),
getBreadcrumb
()
{
let
matched
=
this
.
$route
.
matched
.
filter
(
item
=>
item
.
name
);
// this.$route.matched 可以获取到一个数组,包含当前路由的所有嵌套路径片段的路由记录
const
first
=
matched
[
0
];
const
{
meta
,
path
}
=
first
;
const
basePath
=
'/trialRun#'
;
let
breadcrumb
=
[];
if
(
meta
)
{
const
{
title
,
parentTitle
,
parentPath
}
=
meta
;
if
(
parentTitle
)
{
breadcrumb
.
push
({
name
:
parentTitle
,
path
:
basePath
+
parentPath
})
}
if
(
title
)
{
breadcrumb
.
push
({
name
:
title
,
path
:
basePath
+
path
})
}
this
.
$root
.
parentVuex
.
dispatch
(
'menu/setBreadCrumb'
,
breadcrumb
);
}
},
goToPage
(
path
)
{
goToPage
(
path
)
{
this
.
$root
.
parentRouter
.
push
(
path
);
this
.
$root
.
parentRouter
.
push
(
path
);
}
}
...
...
src/components/map/fenceMap.vue
View file @
fabe6e7
...
@@ -221,7 +221,7 @@ export default{
...
@@ -221,7 +221,7 @@ export default{
this
.
getCurrentPosition
().
then
((
pos
)
=>
{
this
.
getCurrentPosition
().
then
((
pos
)
=>
{
this
.
lng
=
pos
.
lng
;
this
.
lng
=
pos
.
lng
;
this
.
lat
=
pos
.
lat
;
this
.
lat
=
pos
.
lat
;
this
.
radius
=
1
00
0
;
this
.
radius
=
1
5
0
;
this
.
drawFenceCircle
(
pos
)
this
.
drawFenceCircle
(
pos
)
this
.
$emit
(
'onUpdateMapData'
,{
this
.
$emit
(
'onUpdateMapData'
,{
...
...
src/main.js
View file @
fabe6e7
...
@@ -39,27 +39,6 @@ function render({ data = {} , container } = {}) {
...
@@ -39,27 +39,6 @@ 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
;
const
thisBreadCrumb
=
data
.
store
.
getters
.
curBreadCrumb
;
if
(
metaTitle
)
{
if
(
thisBreadCrumb
)
{
let
nextChildren
=
{};
nextChildren
=
{
active
:
true
,
menuName
:
metaTitle
,
path
:
'/trialRun#'
+
to
.
path
,
params
:
to
.
params
};
thisBreadCrumb
.
children
.
children
=
nextChildren
;
}
}
else
{
thisBreadCrumb
.
children
.
children
=
''
;
}
data
.
store
.
dispatch
(
'menu/setBreadCrumb'
,
thisBreadCrumb
);
next
();
})
}
}
if
(
!
window
.
__POWERED_BY_QIANKUN__
)
{
if
(
!
window
.
__POWERED_BY_QIANKUN__
)
{
...
...
src/routes/index.js
View file @
fabe6e7
...
@@ -10,6 +10,7 @@ const routes = [
...
@@ -10,6 +10,7 @@ const routes = [
name
:
'specialShop'
,
name
:
'specialShop'
,
component
:
()
=>
import
(
'../views/specialShop/index.vue'
),
component
:
()
=>
import
(
'../views/specialShop/index.vue'
),
meta
:
{
meta
:
{
title
:
'特约店列表'
,
keepAlive
:
true
keepAlive
:
true
}
}
},
},
...
@@ -18,6 +19,7 @@ const routes = [
...
@@ -18,6 +19,7 @@ const routes = [
name
:
'toDo'
,
name
:
'toDo'
,
component
:
()
=>
import
(
'../views/toDo/index.vue'
),
component
:
()
=>
import
(
'../views/toDo/index.vue'
),
meta
:
{
meta
:
{
title
:
'待办列表'
,
keepAlive
:
true
keepAlive
:
true
}
}
},
},
...
@@ -26,6 +28,7 @@ const routes = [
...
@@ -26,6 +28,7 @@ const routes = [
name
:
'vehicleManage'
,
name
:
'vehicleManage'
,
component
:
()
=>
import
(
'../views/vehicleManage/index.vue'
),
component
:
()
=>
import
(
'../views/vehicleManage/index.vue'
),
meta
:
{
meta
:
{
title
:
'试驾车辆列表'
,
keepAlive
:
true
keepAlive
:
true
}
}
},
},
...
@@ -34,15 +37,18 @@ const routes = [
...
@@ -34,15 +37,18 @@ const routes = [
name
:
'vehicleSubmit'
,
name
:
'vehicleSubmit'
,
component
:
()
=>
import
(
'../views/vehicleSubmit/index.vue'
),
component
:
()
=>
import
(
'../views/vehicleSubmit/index.vue'
),
meta
:
{
meta
:
{
title
:
'上牌资料提交'
,
keepAlive
:
true
keepAlive
:
true
}
}
},
},
{
{
path
:
'/vehicleSubmit/addVehicle'
,
path
:
'/vehicleSubmit/addVehicle'
,
name
:
'addVehicle'
,
name
:
'addVehicle'
,
meta
:
{
title
:
'资料详情'
},
component
:
()
=>
import
(
'../views/vehicleSubmit/addVehicle/index.vue'
),
component
:
()
=>
import
(
'../views/vehicleSubmit/addVehicle/index.vue'
),
meta
:
{
meta
:
{
title
:
'上牌资料详情'
,
parentTitle
:
'上牌资料提交'
,
parentPath
:
'/vehicleSubmit'
,
keepAlive
:
true
keepAlive
:
true
}
}
},
},
...
@@ -51,6 +57,7 @@ const routes = [
...
@@ -51,6 +57,7 @@ const routes = [
name
:
'vehicleCheck'
,
name
:
'vehicleCheck'
,
component
:
()
=>
import
(
'../views/vehicleSubmit/vehicleCheck/index.vue'
),
component
:
()
=>
import
(
'../views/vehicleSubmit/vehicleCheck/index.vue'
),
meta
:
{
meta
:
{
title
:
'上牌资料审核'
,
keepAlive
:
true
keepAlive
:
true
}
}
},
},
...
@@ -59,15 +66,16 @@ const routes = [
...
@@ -59,15 +66,16 @@ const routes = [
name
:
'reportManage'
,
name
:
'reportManage'
,
component
:
()
=>
import
(
'../views/reportManage/index.vue'
),
component
:
()
=>
import
(
'../views/reportManage/index.vue'
),
meta
:
{
meta
:
{
title
:
'有效试驾'
,
keepAlive
:
true
keepAlive
:
true
}
}
},
},
{
{
path
:
'/specialShop'
,
path
:
'/specialShop'
,
name
:
'specialShop'
,
name
:
'specialShop'
,
meta
:
{
title
:
'新增特约店'
},
component
:
()
=>
import
(
'../views/specialShop/index.vue'
),
component
:
()
=>
import
(
'../views/specialShop/index.vue'
),
meta
:
{
meta
:
{
title
:
'特约店列表'
,
keepAlive
:
true
keepAlive
:
true
}
}
},
},
...
@@ -76,6 +84,9 @@ const routes = [
...
@@ -76,6 +84,9 @@ const routes = [
name
:
'addShop'
,
name
:
'addShop'
,
component
:
()
=>
import
(
'../views/specialShop/addShop/index.vue'
),
component
:
()
=>
import
(
'../views/specialShop/addShop/index.vue'
),
meta
:
{
meta
:
{
title
:
'新增特约店'
,
parentTitle
:
'特约店列表'
,
parentPath
:
'/specialShop'
,
keepAlive
:
false
keepAlive
:
false
}
}
},
},
...
@@ -84,6 +95,7 @@ const routes = [
...
@@ -84,6 +95,7 @@ const routes = [
name
:
'testDriveCheckList'
,
name
:
'testDriveCheckList'
,
component
:
()
=>
import
(
'../views/testDrive/checkList.vue'
),
component
:
()
=>
import
(
'../views/testDrive/checkList.vue'
),
meta
:
{
meta
:
{
title
:
'试驶线路审核'
,
keepAlive
:
true
keepAlive
:
true
}
}
},
},
...
@@ -92,6 +104,7 @@ const routes = [
...
@@ -92,6 +104,7 @@ const routes = [
name
:
'removeAlarm'
,
name
:
'removeAlarm'
,
component
:
()
=>
import
(
'../views/alarmCenter/removeAlarm.vue'
),
component
:
()
=>
import
(
'../views/alarmCenter/removeAlarm.vue'
),
meta
:
{
meta
:
{
title
:
'拆除预警'
,
keepAlive
:
true
keepAlive
:
true
}
}
}
}
...
...
src/views/specialShop/addShop/index.vue
View file @
fabe6e7
...
@@ -166,87 +166,87 @@ export default {
...
@@ -166,87 +166,87 @@ export default {
}
}
return
{
return
{
btn_size
:
'small'
,
btn_size
:
'small'
,
configForm
:
{},
configForm
:
{},
mapData
:
[],
mapData
:
[],
submitting
:
false
,
submitting
:
false
,
btnText
:
'保存'
,
btnText
:
'保存'
,
restainFenceName
:
''
,
restainFenceName
:
''
,
specialShopOptions
:
[],
specialShopOptions
:
[],
specialShopDefaultProps
:
{
specialShopDefaultProps
:
{
children
:
'children'
,
children
:
'children'
,
label
:
'label'
,
label
:
'label'
,
value
:
'id
'
value
:
'code
'
},
},
readonlyStatus
:
false
,
readonlyStatus
:
false
,
form
:
{
form
:
{
shopName
:
''
,
shopName
:
''
,
shopCode
:
''
,
shopCode
:
''
,
shopLevel
:
'一级店'
,
shopLevel
:
'一级店'
,
fenceName
:
''
,
fenceName
:
''
,
lng
:
''
,
lng
:
''
,
lat
:
''
,
lat
:
''
,
radius
:
100
0
,
radius
:
15
0
,
bizFenceType
:
'12'
,
bizFenceType
:
'12'
,
shapeType
:
1
,
shapeType
:
1
,
specialShopId
:
''
,
specialShopId
:
''
,
specialShopName
:
''
,
specialShopName
:
''
,
// fenceNo: '',
// fenceNo: '',
electricFenceType
:
1
,
electricFenceType
:
1
,
startTime
:
''
,
startTime
:
''
,
endTime
:
''
,
endTime
:
''
,
des
:
''
,
des
:
''
,
areaCode
:
''
,
areaCode
:
''
,
analysisAddress
:
''
,
analysisAddress
:
''
,
status
:
1
,
status
:
1
,
transferError
:
false
,
transferError
:
false
,
timeType
:
2
,
timeType
:
2
,
electricTimeFenceType
:
''
,
electricTimeFenceType
:
''
,
electricTimeFenceTypes
:
[
electricTimeFenceTypes
:
[
{
{
value
:
1
,
value
:
1
,
label
:
'1个月'
label
:
'1个月'
},
{
},
{
value
:
2
,
value
:
2
,
label
:
'2个月'
label
:
'2个月'
},
{
},
{
value
:
3
,
value
:
3
,
label
:
'3个月'
label
:
'3个月'
},
{
},
{
value
:
4
,
value
:
4
,
label
:
'4个月'
label
:
'4个月'
},
{
},
{
value
:
5
,
value
:
5
,
label
:
'5个月'
label
:
'5个月'
},
{
},
{
value
:
6
,
value
:
6
,
label
:
'6个月'
label
:
'6个月'
}
}
],
],
dateRange
:
[],
dateRange
:
[],
msgtel
:
''
msgtel
:
''
},
},
rules
:
{
rules
:
{
specialShop
:
[
specialShop
:
[
{
required
:
true
,
validator
:
checkSpecialShop
,
trigger
:
'change'
}
{
required
:
true
,
validator
:
checkSpecialShop
,
trigger
:
'change'
}
],
],
fenceName
:
[
fenceName
:
[
{
required
:
true
,
message
:
'请输入特约店围栏名称'
,
trigger
:
'blur'
},
{
required
:
true
,
message
:
'请输入特约店围栏名称'
,
trigger
:
'blur'
},
{
pattern
:
/^
\S{2,200}
$/
,
message
:
'至少2字'
,
trigger
:
'blur'
},
{
pattern
:
/^
\S{2,200}
$/
,
message
:
'至少2字'
,
trigger
:
'blur'
},
],
],
radius
:
[
radius
:
[
{
validator
:
checkRadius
,
trigger
:
'blur'
}
{
validator
:
checkRadius
,
trigger
:
'blur'
}
],
],
lng
:
[
lng
:
[
{
required
:
true
,
validator
:
checkLng
,
trigger
:
'blur'
}
{
required
:
true
,
validator
:
checkLng
,
trigger
:
'blur'
}
],
],
lat
:
[
lat
:
[
{
required
:
true
,
validator
:
checkLat
,
trigger
:
'blur'
}
{
required
:
true
,
validator
:
checkLat
,
trigger
:
'blur'
}
],
],
analysisAddress
:
[
analysisAddress
:
[
{
validator
:
checkTransferAddr
,
trigger
:
'change'
}
{
validator
:
checkTransferAddr
,
trigger
:
'change'
}
],
],
}
}
}
}
},
},
created
()
{
created
()
{
...
@@ -293,7 +293,7 @@ export default {
...
@@ -293,7 +293,7 @@ export default {
this
.
restainFenceName
=
form
.
fenceName
;
this
.
restainFenceName
=
form
.
fenceName
;
this
.
form
.
fenceName
=
form
.
fenceName
;
this
.
form
.
fenceName
=
form
.
fenceName
;
this
.
form
.
msgtel
=
data
.
telNumbers
;
this
.
form
.
msgtel
=
data
.
telNumbers
;
this
.
form
.
specialShopId
=
data
.
s
hopCode
;
this
.
form
.
specialShopId
=
data
.
s
pecialShopId
;
this
.
form
.
specialShopName
=
data
.
shopName
;
this
.
form
.
specialShopName
=
data
.
shopName
;
this
.
form
.
shopLevel
=
data
.
shopLevel
;
this
.
form
.
shopLevel
=
data
.
shopLevel
;
...
@@ -346,7 +346,7 @@ export default {
...
@@ -346,7 +346,7 @@ export default {
if
(
val
&&
val
.
length
>
1
)
{
if
(
val
&&
val
.
length
>
1
)
{
const
thisNodes
=
this
.
$refs
[
'specialShopCascader'
].
getCheckedNodes
()[
0
];
const
thisNodes
=
this
.
$refs
[
'specialShopCascader'
].
getCheckedNodes
()[
0
];
this
.
form
.
specialShopId
=
val
[
1
];
this
.
form
.
specialShopId
=
val
[
1
];
this
.
form
.
specialShopName
=
thisNodes
.
label
;
this
.
form
.
specialShopName
=
thisNodes
.
label
;
}
}
},
},
updateFence
(){
updateFence
(){
...
@@ -479,7 +479,7 @@ export default {
...
@@ -479,7 +479,7 @@ export default {
const
params
=
this
.
getParams
();
const
params
=
this
.
getParams
();
params
.
id
=
this
.
shopId
;
params
.
id
=
this
.
shopId
;
updateFence
(
JSON
.
stringify
(
params
)
).
then
((
res
)
=>
{
updateFence
(
params
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
if
(
res
.
code
==
200
){
//this.closeDialog();
//this.closeDialog();
this
.
$message
({
this
.
$message
({
...
...
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