Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
SuperMan
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
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
罗超
SuperMan
Commits
8b122053
Commit
8b122053
authored
Jan 16, 2023
by
youjie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
no message
parent
f7edfd87
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
186 additions
and
91 deletions
+186
-91
CharteringInfoManage.vue
...sManagement/CharteringManagement/CharteringInfoManage.vue
+98
-52
CharteringProductList.vue
...Management/CharteringManagement/CharteringProductList.vue
+22
-10
Map.vue
...nts/busManagement/CharteringManagement/components/Map.vue
+66
-29
No files found.
src/components/busManagement/CharteringManagement/CharteringInfoManage.vue
View file @
8b122053
This diff is collapsed.
Click to expand it.
src/components/busManagement/CharteringManagement/CharteringProductList.vue
View file @
8b122053
...
@@ -251,7 +251,7 @@
...
@@ -251,7 +251,7 @@
<button
class=
"hollowFixedBtn"
type=
"button"
<button
class=
"hollowFixedBtn"
type=
"button"
@
click=
"resetPageIndex(),selectResource()"
>
{{
$t
(
'pub.searchBtn'
)
}}
</button>
@
click=
"resetPageIndex(),selectResource()"
>
{{
$t
(
'pub.searchBtn'
)
}}
</button>
<button
class=
"normalBtn"
type=
"button"
<button
class=
"normalBtn"
type=
"button"
@
click=
"
$router.push
('CharteringInfoManage')"
>
{{
$t
(
'pub.addBtn'
)
}}
</button>
@
click=
"
goUrl
('CharteringInfoManage')"
>
{{
$t
(
'pub.addBtn'
)
}}
</button>
<!--
<button
class=
"hollowFixedBtn"
type=
"button"
@
click=
"DownLoadFile()"
>
{{
$t
(
'adm.adm_download'
)
}}
</button>
-->
<!--
<button
class=
"hollowFixedBtn"
type=
"button"
@
click=
"DownLoadFile()"
>
{{
$t
(
'adm.adm_download'
)
}}
</button>
-->
</li>
</li>
</ul>
</ul>
...
@@ -527,6 +527,7 @@
...
@@ -527,6 +527,7 @@
);
);
},
},
goUrl
(
path
,
id
)
{
goUrl
(
path
,
id
)
{
if
(
id
){
this
.
$store
.
commit
(
"pageConditionUpdate"
,
this
.
msg
);
this
.
$store
.
commit
(
"pageConditionUpdate"
,
this
.
msg
);
this
.
$router
.
push
({
this
.
$router
.
push
({
path
:
path
,
path
:
path
,
...
@@ -536,6 +537,17 @@
...
@@ -536,6 +537,17 @@
tab
:
'修改产品信息'
tab
:
'修改产品信息'
}
}
});
});
}
else
{
this
.
$router
.
push
({
path
:
path
,
query
:
{
id
:
0
,
blank
:
'y'
,
tab
:
'新增产品信息'
}
});
}
},
},
goUrlT
(
path
,
id
,
Name
)
{
goUrlT
(
path
,
id
,
Name
)
{
let
data
=
{
let
data
=
{
...
...
src/components/busManagement/CharteringManagement/components/Map.vue
View file @
8b122053
<
template
>
<
template
>
<div>
<div>
<div
style=
"text-align: center;display: flex;justify-content: center;"
>
<div
style=
"text-align: center;display: flex;justify-content: center;"
>
<el-input
class=
"w300"
style=
"margin-right: 10px;"
id=
"suggestId"
v-model=
"city"
placeholder=
"请输入搜索名称"
name=
"address_detail"
/>
<el-input
class=
"w300"
style=
"margin-right: 10px;"
id=
"suggestId"
v-model=
"city"
<input
type=
"button"
class=
"normalBtn sureBtn"
value=
"搜索"
@
click=
"search"
/>
placeholder=
"请输入需要检索的地名"
name=
"address_detail"
@
input=
"search"
/>
<!--
<input
type=
"button"
class=
"normalBtn sureBtn"
value=
"搜索"
@
click=
"search"
/>
-->
</div>
</div>
<div
style=
"height: 330px;width: 100%;margin-top: 15px;"
:id=
"`allmap_$
{id}${type}_${index}`">
</div>
<div
style=
"height: 320px;width: 100%;margin-top: 15px;"
:id=
"`allmap_$
{id}${type}_${index}`">
</div>
<div
style=
"margin-top: 10px;"
v-if=
"address_detail"
>
当前地址:
{{
address_detail
}}
</div>
<div
class=
"btnList"
>
<div
class=
"btnList"
>
<input
type=
"button"
class=
"normalBtn sureBtn"
value=
"确定"
@
click=
"sendMsg"
/>
<input
type=
"button"
class=
"normalBtn sureBtn"
value=
"确定"
@
click=
"sendMsg"
/>
<input
type=
"button"
class=
"hollowFixedBtn"
value=
"取消"
@
click=
"closeDialog"
/>
<input
type=
"button"
class=
"hollowFixedBtn"
value=
"取消"
@
click=
"closeDialog"
/>
...
@@ -19,20 +21,23 @@ export default {
...
@@ -19,20 +21,23 @@ export default {
return
{
return
{
city
:
''
,
city
:
''
,
address_detail
:
null
,
//详细地址
address_detail
:
null
,
//详细地址
add_housing_list
:
[
""
],
userlocation
:
null
,
userlocation
:
null
,
dataList
:
null
,
dataList
:
null
,
point
:
{
point
:
{
lng
:
''
,
lng
:
''
,
lat
:
''
lat
:
''
}
}
,
}
}
},
},
watch
:
{
watch
:
{
Address
:
{
Address
:
{
handler
(
newValue
)
{
handler
(
newValue
)
{
this
.
city
=
this
.
Address
this
.
city
=
this
.
Address
if
(
!
newValue
){
this
.
getcity
()
}
else
{
this
.
search
()
this
.
search
()
}
},
},
immediate
:
true
immediate
:
true
},
},
...
@@ -47,9 +52,9 @@ export default {
...
@@ -47,9 +52,9 @@ export default {
},
},
sendMsg
()
{
sendMsg
()
{
if
(
!
this
.
point
.
lng
)
{
if
(
!
this
.
point
.
lng
)
{
this
.
Error
(
"请
搜索选择
"
);
this
.
Error
(
"请
点击地图上你需要选择的地址
"
);
}
else
{
}
else
{
this
.
$emit
(
"headCallBack"
,
this
.
point
,
this
.
type
);
this
.
$emit
(
"headCallBack"
,
this
.
point
,
this
.
type
,
this
.
address_detail
);
this
.
$emit
(
"refList"
);
this
.
$emit
(
"refList"
);
}
}
},
},
...
@@ -69,16 +74,17 @@ export default {
...
@@ -69,16 +74,17 @@ export default {
})
})
local
.
search
(
that
.
city
)
local
.
search
(
that
.
city
)
map
.
addEventListener
(
'click'
,
function
(
e
,
target
)
{
map
.
addEventListener
(
'click'
,
function
(
e
,
target
)
{
var
point
=
new
BMap
.
Point
(
e
.
point
.
lng
,
e
.
point
.
lat
)
// 创建点坐标,汉得公司的经纬度坐标
// var point = new BMap.Point(e.point.lng, e.point.lat) // 创建点坐标,汉得公司的经纬度坐标
map
.
centerAndZoom
(
point
,
15
)
// map.centerAndZoom(point, 11)
// console.log(e,target)
// that.point = e.point
// // 经度
})
// console.log(that.userlocation.lng)
var
gc
=
new
BMap
.
Geocoder
();
// // 纬度
map
.
addEventListener
(
'mousedown'
,
function
(
type
)
{
// console.log(that.userlocation.lat)
var
pt
=
type
.
point
;
gc
.
getLocation
(
pt
,
function
(
rs
){
var
addComp
=
rs
.
addressComponents
;
that
.
address_detail
=
addComp
.
province
+
", "
+
addComp
.
city
+
", "
+
addComp
.
district
+
", "
+
addComp
.
street
+
", "
+
addComp
.
streetNumber
})
})
map
.
addEventListener
(
'mousedown'
,
function
(
type
,
target
,
point
,
pixel
)
{
console
.
log
(
type
.
point
,
target
+
'---'
,
point
+
'---'
,
pixel
+
'---'
)
})
})
},
},
getcity
(){
getcity
(){
...
@@ -86,22 +92,53 @@ export default {
...
@@ -86,22 +92,53 @@ export default {
var
that
=
this
var
that
=
this
// 创建Map实例
// 创建Map实例
var
map
=
new
BMap
.
Map
(
`allmap_
${
that
.
id
}${
that
.
type
}
_
${
that
.
index
}
`
)
var
map
=
new
BMap
.
Map
(
`allmap_
${
that
.
id
}${
that
.
type
}
_
${
that
.
index
}
`
)
// 获取当前位置
var
geolocation
=
new
BMap
.
Geolocation
();
geolocation
.
getCurrentPosition
(
function
(
r
){
if
(
r
){
var
mk
=
new
BMap
.
Marker
(
r
.
point
);
map
.
addOverlay
(
mk
);
map
.
panTo
(
r
.
point
);
that
.
address_detail
=
addComp
.
province
+
""
+
addComp
.
city
+
""
+
addComp
.
district
+
""
+
addComp
.
street
+
""
+
addComp
.
streetNumber
that
.
point
.
lng
=
r
.
point
.
lng
that
.
point
.
lat
=
r
.
point
.
lat
console
.
log
(
that
.
address_detail
,
'城市==='
)
console
.
log
(
'您的位置:'
+
r
.
point
.
lng
+
','
+
r
.
point
.
lat
);
}
else
{
console
.
log
(
'failed'
);
}
});
// 点击地图
map
.
addEventListener
(
'click'
,
function
(
e
,
target
)
{
// var point = new BMap.Point(e.point.lng, e.point.lat) // 创建点坐标,汉得公司的经纬度坐标
// map.centerAndZoom(point, 11)
// that.point = e.point
})
var
gc
=
new
BMap
.
Geocoder
();
map
.
addEventListener
(
'mousedown'
,
function
(
type
)
{
map
.
centerAndZoom
(
type
.
point
,
11
)
that
.
point
=
type
.
point
var
pt
=
type
.
point
;
gc
.
getLocation
(
pt
,
function
(
rs
){
var
addComp
=
rs
.
addressComponents
;
that
.
address_detail
=
addComp
.
province
+
""
+
addComp
.
city
+
""
+
addComp
.
district
+
""
+
addComp
.
street
+
""
+
addComp
.
streetNumber
})
})
// 初始化地图,设置中心点坐标,
// 初始化地图,设置中心点坐标,
var
point
=
new
BMap
.
Point
(
120.211877
,
30.255194
)
// 创建点坐标
if
(
that
.
point
.
lat
){
map
.
centerAndZoom
(
point
,
15
)
var
point
=
new
BMap
.
Point
(
that
.
point
.
lat
,
that
.
point
.
lng
)
// 创建点坐标
map
.
centerAndZoom
(
point
,
11
)
}
else
{
map
.
centerAndZoom
(
new
BMap
.
Point
(
104.073652
,
30.664369
),
11
);
}
map
.
enableScrollWheelZoom
()
map
.
enableScrollWheelZoom
()
if
(
that
.
Address
){
that
.
search
()
that
.
search
()
}
})
})
},
},
// 新增小区 点击的地址增加进list
add_housing
()
{
this
.
add_housing_list
.
push
(
this
.
city
)
},
// 删除小区
delete_housing
(
index
)
{
// console.log(index)
this
.
add_housing_list
.
splice
(
index
,
1
)
},
}
}
}
}
</
script
>
</
script
>
...
...
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