Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
html
/
MeteorologicalBureau
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
0d67cf58
authored
Apr 09, 2020
by
hanjixin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug
parent
2490986f
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
136 additions
and
77 deletions
+136
-77
map/index.html
+136
-77
No files found.
map/index.html
View file @
0d67cf58
<!DOCTYPE html>
<html>
<head>
<meta
name=
"viewport"
content=
"width=device-width initial-scale=1.0 maximum-scale=1.0 user-scalable=0"
/>
<head>
<meta
name=
"viewport"
content=
"width=device-width initial-scale=1.0 maximum-scale=1.0 user-scalable=0"
/>
<meta
http-equiv=
"Content-Type"
content=
"text/html; charset=utf-8"
/>
<title>
MAP
</title>
<link
rel=
"stylesheet"
href=
"css/main.css"
>
<style>
<link
rel=
"stylesheet"
href=
"css/main.css"
/>
<style></style>
</head>
</style>
</head>
<body>
<body>
<div
id=
"container"
></div>
<div
id=
nav
>
<div
class=
"item"
onclick=
"go(0)"
><span
class=
"icon icon1"
></span>
预警信息
</div>
<div
class=
"item"
onclick=
"go(1)"
><span
class=
"icon icon2"
></span>
设备
</div>
<div
id=
"nav"
>
<div
class=
"item"
onclick=
"go(0)"
>
<span
class=
"icon icon1"
></span>
预警信息
</div>
<div
class=
"item"
onclick=
"go(1)"
>
<span
class=
"icon icon2"
></span>
设备
</div>
<div
class=
"subnav subnav1"
>
<div
class=
''
onclick=
"go(1,0)"
>
大喇叭
</div>
<div
class=
""
onclick=
"go(1,0)"
>
大喇叭
</div>
<div
onclick=
"go(1,1)"
>
显示屏
</div>
<div
onclick=
"go(1,2)"
>
北斗
</div>
</div>
<div
class=
"item"
onclick=
"go(2)"
><span
class=
"icon icon3"
></span>
人员
</div>
<div
class=
"item"
onclick=
"go(2)"
>
<span
class=
"icon icon3"
></span>
人员
</div>
<div
class=
"subnav subnav2"
>
<div
onclick=
"go(2,0)"
>
信息员
</div>
<div
onclick=
"go(2,1)"
>
应急责任人
</div>
...
...
@@ -43,104 +49,157 @@
</style>
<script
src=
"./js/tools.js"
></script>
<script
src=
"./js/Map3D.js"
></script>
<script
language=
javascript
>
<script
language=
"javascript"
>
//
<
script
language
=
javascript
type
=
module
>
//http://106.120.82.243:8080/qxyj/pageHtml/login.html wis 12379
// import { Map3D } from './js/Map3D.js';
// import { GetParams } from './js/tools.js';
window
.
urlParams
=
GetParams
()
window
.
urlParams
=
GetParams
();
//成都 重庆 天津 北京 上海 大连 三沙 湖北 中国
//350200
//350500
//320300 370100
window
.
map3d
=
new
Map3D
(
urlParams
.
adcode
||
'610000'
||
'成都'
,
'container'
,
urlParams
,
(
_map3d
)
=>
{
go
(
0
)
});
window
.
review
=
function
(
params
)
{
map3d
.
review
()
}
window
.
delPoi
=
function
(
params
)
{
window
.
map3d
=
new
Map3D
(
urlParams
.
adcode
||
"610000"
||
"成都"
,
"container"
,
urlParams
,
_map3d
=>
{
go
(
0
);
}
);
window
.
review
=
function
(
params
)
{
map3d
.
review
();
};
window
.
delPoi
=
function
(
params
)
{
try
{
map3d
.
map
.
clearInfoWindow
()
map3d
.
delPoi
(
pois
)
window
.
pois
=
[]
}
catch
(
error
)
{
}
}
window
.
addPoiByApi
=
function
(
api
,
type
,
type1
)
{
map3d
.
map
.
clearInfoWindow
();
map3d
.
delPoi
(
pois
);
map3d
.
map
.
remove
(
pois
);
map3d
.
cluster
.
clearMarkers
();
if
(
params
)
window
.
pois
=
[];
}
catch
(
error
)
{
}
};
window
.
addPoiByApi
=
function
(
api
,
type
,
type1
)
{
console
.
log
(
api
);
window
.
delPoi
()
window
.
review
()
window
.
delPoi
(
1
);
window
.
review
();
$
.
get
(
api
).
then
(
res
=>
{
var
currentDetailList
=
res
.
data
var
currentDetailList
=
res
.
data
;
console
.
log
(
currentDetailList
);
if
(
type1
==
'MassMarks'
)
{
map3d
.
addPoisMassMarks
(
currentDetailList
,
type
).
then
(
res
=>
window
.
pois
=
res
)
}
else
if
(
type1
==
'Single'
)
{
map3d
.
addPoisSingle
(
currentDetailList
,
type
).
then
(
res
=>
window
.
pois
=
res
)
if
(
type1
==
"MassMarks"
)
{
window
.
delPoi
(
0
);
map3d
.
addPoisMassMarks
(
currentDetailList
,
type
)
.
then
(
res
=>
(
window
.
pois
=
res
,
console
.
log
(
1
)));
}
else
if
(
type1
==
"Single"
)
{
window
.
delPoi
(
0
);
map3d
.
addPoisSingle
(
currentDetailList
,
type
)
.
then
(
res
=>
(
window
.
pois
=
res
,
console
.
log
(
1
)));
}
else
{
map3d
.
addPoisMarkerClusterer
(
currentDetailList
,
type
).
then
(
res
=>
window
.
pois
=
res
)
window
.
delPoi
(
0
);
map3d
.
addPoisMarkerClusterer
(
currentDetailList
,
type
)
.
then
(
res
=>
(
window
.
pois
=
res
,
console
.
log
(
1
)));
}
});
}
};
</script>
<script>
var
oldi1
=
0
,
oldi2
=
0
var
oldi1
=
0
,
oldi2
=
0
;
function
popclose
()
{
console
.
log
(
'popclose'
);
map3d
.
map
.
clearInfoWindow
()
console
.
log
(
"popclose"
);
map3d
.
map
.
clearInfoWindow
();
}
function
go
(
i1
,
i2
)
{
console
.
log
(
oldi1
,
oldi2
);
console
.
log
(
i1
,
i2
);
if
(
i1
==
oldi1
&&
i2
==
oldi2
)
{
return
false
return
false
;
}
$
(
".item"
).
removeClass
(
"active"
).
removeClass
(
"text-shadow"
)
$
(
".item"
).
eq
(
i1
).
addClass
(
"active text-shadow"
)
$
(
".subnav"
).
hide
()
$
(
".subnav"
+
i1
).
show
()
$
(
".subnav"
+
i1
).
find
(
"div"
).
removeClass
(
"active"
).
removeClass
(
"text-shadow"
)
if
(
typeof
(
i2
)
!=
'undefined'
)
{
$
(
".subnav"
+
i1
).
find
(
"div"
).
eq
(
i2
).
addClass
(
"active text-shadow"
)
$
(
".item"
)
.
removeClass
(
"active"
)
.
removeClass
(
"text-shadow"
);
$
(
".item"
)
.
eq
(
i1
)
.
addClass
(
"active text-shadow"
);
$
(
".subnav"
).
hide
();
$
(
".subnav"
+
i1
).
show
();
$
(
".subnav"
+
i1
)
.
find
(
"div"
)
.
removeClass
(
"active"
)
.
removeClass
(
"text-shadow"
);
if
(
typeof
i2
!=
"undefined"
)
{
$
(
".subnav"
+
i1
)
.
find
(
"div"
)
.
eq
(
i2
)
.
addClass
(
"active text-shadow"
);
}
if
(
i1
==
0
&&
typeof
(
i2
)
==
'undefined'
)
{
//预警信息
addPoiByApi
(
'http://123.56.149.208:8091/external/get/early/warn/city/two/list/'
+
urlParams
.
adcode
,
'setWarnPoint'
,
'Single'
)
oldi1
=
i1
,
oldi2
=
i2
if
(
i1
==
0
&&
typeof
i2
==
"undefined"
)
{
//预警信息
addPoiByApi
(
"http://123.56.149.208:8091/external/get/early/warn/city/two/list/"
+
urlParams
.
adcode
,
"setWarnPoint"
,
"Single"
);
(
oldi1
=
i1
),
(
oldi2
=
i2
);
}
if
(
i1
==
1
&&
i2
==
0
)
{
//大喇叭
addPoiByApi
(
`http://123.56.149.208:8091/external/get/early/warn/equipment/two?code=
${
urlParams
.
adcode
}
&clientStyle=1`
,
'setEquipmentPoint'
,
'Cluster'
)
oldi1
=
i1
,
oldi2
=
i2
}
if
(
i1
==
1
&&
i2
==
1
)
{
//显示屏
addPoiByApi
(
`http://123.56.149.208:8091/external/get/early/warn/equipment/two?code=
${
urlParams
.
adcode
}
&clientStyle=2`
,
'setEquipmentPoint'
,
'Single'
)
oldi1
=
i1
,
oldi2
=
i2
}
if
(
i1
==
1
&&
i2
==
2
)
{
//北斗
addPoiByApi
(
`http://123.56.149.208:8091/external/get/early/warn/equipment/two?code=
${
urlParams
.
adcode
}
&clientStyle=3`
,
'setEquipmentPoint'
,
'Single'
)
oldi1
=
i1
,
oldi2
=
i2
if
(
i1
==
1
&&
i2
==
0
)
{
//大喇叭
addPoiByApi
(
`http://123.56.149.208:8091/external/get/early/warn/equipment/two?code=
${
urlParams
.
adcode
}
&clientStyle=1`
,
"setEquipmentPoint"
,
"Cluster"
);
(
oldi1
=
i1
),
(
oldi2
=
i2
);
}
if
(
i1
==
1
&&
i2
==
1
)
{
//显示屏
addPoiByApi
(
`http://123.56.149.208:8091/external/get/early/warn/equipment/two?code=
${
urlParams
.
adcode
}
&clientStyle=2`
,
"setEquipmentPoint"
,
"Single"
);
(
oldi1
=
i1
),
(
oldi2
=
i2
);
}
if
(
i1
==
1
&&
i2
==
2
)
{
//北斗
addPoiByApi
(
`http://123.56.149.208:8091/external/get/early/warn/equipment/two?code=
${
urlParams
.
adcode
}
&clientStyle=3`
,
"setEquipmentPoint"
,
"Single"
);
(
oldi1
=
i1
),
(
oldi2
=
i2
);
}
if
(
i1
==
2
&&
i2
==
0
)
{
//信息员
addPoiByApi
(
'http://123.56.149.208:8091/external/get/early/warn/people/two/info/'
+
urlParams
.
adcode
,
'setPersonalPoint'
,
'Cluster'
)
oldi1
=
i1
,
oldi2
=
i2
if
(
i1
==
2
&&
i2
==
0
)
{
//信息员
addPoiByApi
(
"http://123.56.149.208:8091/external/get/early/warn/people/two/info/"
+
urlParams
.
adcode
,
"setPersonalPoint"
,
"Cluster"
);
(
oldi1
=
i1
),
(
oldi2
=
i2
);
}
if
(
i1
==
2
&&
i2
==
1
)
{
//应急责任人
addPoiByApi
(
'http://123.56.149.208:8091/external/get/early/warn/people/two/principal/'
+
urlParams
.
adcode
,
'setPrincipalPoint'
,
'Single'
)
oldi1
=
i1
,
oldi2
=
i2
if
(
i1
==
2
&&
i2
==
1
)
{
//应急责任人
addPoiByApi
(
"http://123.56.149.208:8091/external/get/early/warn/people/two/principal/"
+
urlParams
.
adcode
,
"setPrincipalPoint"
,
"Single"
);
(
oldi1
=
i1
),
(
oldi2
=
i2
);
}
}
// go(i1,i2)
</script>
</body>
</body>
</html>
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