Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
micro-customization-system
/
oEshield
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 901b1182
authored
Apr 19, 2022
by
张杰
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
修复bug,优化界面
1 parent
9b2ca6b5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
30 additions
and
30 deletions
src/assets/scss/monitor.scss
src/pages/monitor/fenceMap.vue
src/pages/monitor/fence_userlist.vue
src/pages/monitor/replay.vue
src/utils/mapService.js
src/assets/scss/monitor.scss
View file @
901b118
This diff is collapsed.
Click to expand it.
src/pages/monitor/fenceMap.vue
View file @
901b118
...
@@ -52,7 +52,7 @@ import remoteLoad from "utils/remoteLoad.js";
...
@@ -52,7 +52,7 @@ import remoteLoad from "utils/remoteLoad.js";
import
mapService
from
"utils/mapService.js"
;
import
mapService
from
"utils/mapService.js"
;
import
FenceMapControll
from
"./FenceMapControll.vue"
;
import
FenceMapControll
from
"./FenceMapControll.vue"
;
const
BUSINESS_SERVICE
=
services
.
business
;
const
BUSINESS_SERVICE
=
services
.
business
;
const
mapMenu
=
""
;
var
mapMenu
=
""
;
import
{
CONSTANT
}
from
"../../constant"
;
import
{
CONSTANT
}
from
"../../constant"
;
export
default
{
export
default
{
props
:
[
"fenceMapModalVisible"
,
"init"
,
"readonlyStatus"
],
props
:
[
"fenceMapModalVisible"
,
"init"
,
"readonlyStatus"
],
...
@@ -98,7 +98,7 @@ export default {
...
@@ -98,7 +98,7 @@ export default {
],
],
};
};
},
},
mounted
()
{},
async
mounted
()
{},
watch
:
{
watch
:
{
lng
(
newVal
)
{
lng
(
newVal
)
{
//this.transfer()
//this.transfer()
...
@@ -187,27 +187,22 @@ export default {
...
@@ -187,27 +187,22 @@ export default {
},
},
bindContextMenu
()
{
bindContextMenu
()
{
const
self
=
this
;
const
self
=
this
;
window
.
mapMenu
=
new
ContextMenu
(
self
.
mapObj
);
//暴露mapMenu onclick要用
var
contextMenu
=
new
AMap
.
ContextMenu
();
function
ContextMenu
(
map
)
{
contextMenu
.
addItem
(
var
me
=
this
;
"设置围栏中心"
,
this
.
contextMenuPositon
=
null
;
function
()
{
this
.
contextMenu
=
new
AMap
.
ContextMenu
({
self
.
moveCenter
();
isCustom
:
true
,
},
content
:
`<div class="context_menu" >
0
<p onclick="mapMenu.moveCenter()"><span>设置围栏中心</span></p>
);
</div>`
,
//地图绑定鼠标右击事件——弹出右键菜单
});
self
.
mapObj
.
on
(
"rightclick"
,
function
(
e
)
{
map
.
on
(
"rightclick"
,
(
e
)
=>
{
console
.
log
(
e
)
if
(
self
.
mapObj
.
getAllOverlays
(
"circle"
).
length
)
{
contextMenu
.
open
(
self
.
mapObj
,
e
.
lnglat
);
this
.
contextMenu
.
open
(
map
,
e
.
lnglat
);
self
.
contextMenuPositon
=
e
.
lnglat
;
self
.
contextMenuPositon
=
e
.
lnglat
;
//右键菜单位置
});
}
});
//contextMenu.open(self.mapObj, lnglat);
}
ContextMenu
.
prototype
.
moveCenter
=
function
addPOI
()
{
self
.
moveCenter
();
this
.
contextMenu
.
close
();
};
},
},
drawFence
()
{
drawFence
()
{
if
(
!
this
.
lng
&&
!
this
.
lat
)
{
if
(
!
this
.
lng
&&
!
this
.
lat
)
{
...
@@ -422,13 +417,13 @@ export default {
...
@@ -422,13 +417,13 @@ export default {
self
.
geolocation
.
getCurrentPosition
();
self
.
geolocation
.
getCurrentPosition
();
AMap
.
event
.
addListener
(
self
.
geolocation
,
"complete"
,
function
(
e
)
{
AMap
.
event
.
addListener
(
self
.
geolocation
,
"complete"
,
function
(
e
)
{
console
.
log
(
'complete'
,
e
)
console
.
log
(
"complete"
,
e
);
//返回定位信息
//返回定位信息
var
lnglatXY
=
mapService
.
getLngLat
(
e
.
position
.
lng
,
e
.
position
.
lat
);
var
lnglatXY
=
mapService
.
getLngLat
(
e
.
position
.
lng
,
e
.
position
.
lat
);
resolve
(
lnglatXY
);
resolve
(
lnglatXY
);
});
});
AMap
.
event
.
addListener
(
self
.
geolocation
,
"error"
,
function
(
e
)
{
AMap
.
event
.
addListener
(
self
.
geolocation
,
"error"
,
function
(
e
)
{
console
.
log
(
'error'
,
e
)
console
.
log
(
"error"
,
e
);
//返回定位出错信息
//返回定位出错信息
resolve
(
mapObj
.
getCenter
());
resolve
(
mapObj
.
getCenter
());
});
});
...
...
src/pages/monitor/fence_userlist.vue
View file @
901b118
...
@@ -29,7 +29,7 @@
...
@@ -29,7 +29,7 @@
<el-form-item>
<el-form-item>
<div
class=
"pre_select_box"
>
<div
class=
"pre_select_box"
>
<el-select
v-model=
"form.timeType"
class=
"small_select mr5"
placeholder=
"请选择"
>
<el-select
v-model=
"form.timeType"
class=
"small_select mr5"
placeholder=
"请选择"
>
<el-option
label=
"
创建
时间"
value=
"1"
></el-option>
<el-option
label=
"
激活
时间"
value=
"1"
></el-option>
</el-select>
</el-select>
<el-date-picker
v-model=
"form.timeDate"
class=
"data_picker"
value-format=
"yyyy-MM-dd"
type=
"daterange"
range-separator=
"~"
start-placeholder=
"开始日期"
end-placeholder=
"结束日期"
>
<el-date-picker
v-model=
"form.timeDate"
class=
"data_picker"
value-format=
"yyyy-MM-dd"
type=
"daterange"
range-separator=
"~"
start-placeholder=
"开始日期"
end-placeholder=
"结束日期"
>
</el-date-picker>
</el-date-picker>
...
...
src/pages/monitor/replay.vue
View file @
901b118
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
<div
class=
"controll-wrap"
>
<div
class=
"controll-wrap"
>
<div
class=
"search-box"
:class=
"resultBoxHidden?'active':''"
>
<div
class=
"search-box"
:class=
"resultBoxHidden?'active':''"
>
<h3>
轨迹回放
</h3>
<h3>
轨迹回放
</h3>
<p
class=
"info"
>
{{
name
}}
/
{{
standno
}}
/
{{
sn
}}
</p>
<p
class=
"info"
>
{{
name
||
'--'
}}
/
{{
standno
||
'--'
}}
/
{{
sn
||
'--'
}}
</p>
<el-form
ref=
"form"
:model=
"form"
:rules=
"rules"
:inline=
"false"
size=
"mini"
class=
"form"
>
<el-form
ref=
"form"
:model=
"form"
:rules=
"rules"
:inline=
"false"
size=
"mini"
class=
"form"
>
<el-form-item
label=
"查询范围"
prop=
"daterange"
>
<el-form-item
label=
"查询范围"
prop=
"daterange"
>
<el-date-picker
class=
"pull-left"
style=
"width: 100%;"
v-model=
"form.dateRange"
type=
"datetimerange"
range-separator=
"至"
start-placeholder=
"开始日期"
format=
"yyyy-MM-dd HH:mm"
:clearable=
"false"
:editable=
"false"
:picker-options=
"
{
<el-date-picker
class=
"pull-left"
style=
"width: 100%;"
v-model=
"form.dateRange"
type=
"datetimerange"
range-separator=
"至"
start-placeholder=
"开始日期"
format=
"yyyy-MM-dd HH:mm"
:clearable=
"false"
:editable=
"false"
:picker-options=
"
{
...
...
src/utils/mapService.js
View file @
901b118
...
@@ -422,10 +422,15 @@ MapService.prototype = {
...
@@ -422,10 +422,15 @@ MapService.prototype = {
// 跳转到电子围栏页面 无线设备不能跳转电子围栏 isSource:1有线,其他无线
// 跳转到电子围栏页面 无线设备不能跳转电子围栏 isSource:1有线,其他无线
let
fenceBtn
=
infoDiv
.
querySelector
(
'[data-fence]'
);
let
fenceBtn
=
infoDiv
.
querySelector
(
'[data-fence]'
);
if
(
fenceBtn
&&
info
.
isSource
==
1
)
{
fenceBtn
.
onclick
=
function
()
{
mapService
.
openPage
(
`#/monitor/fence?
${
queryCode
}
`
)
if
(
fenceBtn
)
{
if
(
info
.
isSource
!=
1
)
{
fenceBtn
.
classList
.
add
(
'fence_btn_grey'
);
}
fenceBtn
.
onclick
=
function
()
{
if
(
info
.
isSource
==
1
)
{
mapService
.
openPage
(
`#/monitor/fence?
${
queryCode
}
`
)
}
}
}
}
}
...
...
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