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
5d2dea70
Commit
5d2dea70
authored
Oct 13, 2023
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
11269c08
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
12 deletions
+22
-12
tripmap.vue
...omponents/newTravelmanager/TravelGroupControl/tripmap.vue
+22
-12
No files found.
src/components/newTravelmanager/TravelGroupControl/tripmap.vue
View file @
5d2dea70
<
template
>
<div
class=
"tripmap-form marginT20"
v-if=
"PostConfig"
>
<div
class=
"tripmap-Search"
v-loading=
"pageLoading"
>
<div
class=
"tripmap-form marginT20"
v-if=
"PostConfig"
v-loading=
"pageLoading"
>
<div
class=
"tripmap-Search"
>
<div
style=
"display: flex;align-items: start; justify-content: space-between;"
>
<div
style=
"display: flex;flex-wrap: wrap; flex-grow: 1;"
>
<div
v-for=
"(x, index) in TripMapList"
:key=
"index"
class=
"row-aic"
>
...
...
@@ -26,7 +26,7 @@
</div>
<div
class=
"row-aic"
style=
"flex-shrink: 0;"
>
<el-button
type=
"danger"
key=
"BtnClose"
@
click=
"CloseMapBox"
>
关闭
</el-button>
<el-button
type=
"primary"
key=
"BtnCreateImg"
:
disabled=
"setLoading"
@
click=
"getResultImg()
"
>
{{
btnStr
}}
<el-button
type=
"primary"
key=
"BtnCreateImg"
:
loading=
"saveLoading"
@
click=
"saveLoading=true
"
>
{{
btnStr
}}
</el-button>
</div>
</div>
...
...
@@ -49,7 +49,7 @@
props
:
[
"PostConfig"
],
data
()
{
return
{
s
et
Loading
:
false
,
s
ave
Loading
:
false
,
pageLoading
:
false
,
SourceCountryList
:
[],
//所有国家列表
SourceCityList
:
[],
//国家下面的城市列表
...
...
@@ -125,6 +125,15 @@
},
deep
:
true
,
immediate
:
true
},
saveLoading
:
{
handler
(
val
,
oldVal
)
{
if
(
val
)
{
setTimeout
(()
=>
{
this
.
getResultImg
();
},
1000
)
}
},
}
},
created
()
{
...
...
@@ -245,7 +254,7 @@
this
.
clearCountriesMaker
();
//遍历有经纬度的城市
var
tempData
=
[];
var
that
=
this
;
var
that
=
this
;
this
.
citiesData
.
forEach
(
cItem
=>
{
if
(
cItem
.
longitude
&&
cItem
.
latitude
)
{
tempData
.
push
(
cItem
);
...
...
@@ -740,15 +749,16 @@
// 导出地图片
getResultImg
()
{
this
.
btnStr
=
"生成中.."
;
this
.
s
et
Loading
=
true
;
this
.
s
ave
Loading
=
true
;
this
.
pageLoading
=
true
;
let
that
=
this
;
var
postJson
=
{
ConfigId
:
this
.
PostConfig
.
ID
};
let
that
=
this
;
var
trip_map_obj
=
document
.
getElementById
(
"trip_map"
);
html2Canvas
(
trip_map_obj
).
then
(
function
(
canvas
)
{
html2Canvas
(
trip_map_obj
,
{
backgroundColor
:
null
,
}).
then
(
function
(
canvas
)
{
var
image
=
document
.
createElement
(
"a"
);
image
.
href
=
canvas
.
toDataURL
(
"image/png"
);
let
blob
=
that
.
base64ToBlob
(
image
.
href
);
...
...
@@ -759,17 +769,17 @@
that
.
pageLoading
=
false
;
that
.
btnStr
=
"生成图片"
;
if
(
x
.
data
.
StatusCode
==
1
)
{
that
.
s
et
Loading
=
false
;
that
.
s
ave
Loading
=
false
;
let
allPath
=
that
.
domainManager
().
ViittoFileUrl
+
x
.
data
.
FilePath
;
that
.
PostConfig
.
Mapurl
=
allPath
;
//调用父页面保存方法
that
.
PostConfig
.
TripMapList
=
JSON
.
parse
(
JSON
.
stringify
(
that
.
TripMapList
));
that
.
$emit
(
'saveMsg'
);
}
else
{
that
.
s
et
Loading
=
false
;
that
.
s
ave
Loading
=
false
;
}
});
})
;
})
},
}
};
...
...
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