Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yangpu
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
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
郭铭瑶
yangpu
Commits
f3cdca8b
Commit
f3cdca8b
authored
Nov 20, 2020
by
郭铭瑶
🤘
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
联勤联动分类,智能发现分类
parent
e2c8f1cf
Show whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
270 additions
and
80 deletions
+270
-80
mode1.vue
src/components/MonitorComponents/MonitorCard/mode1.vue
+30
-0
monitor-form.vue
...components/MonitorComponents/MonitorForm/monitor-form.vue
+6
-4
api.js
src/server/api.js
+3
-2
actions.js
src/store/actions.js
+7
-1
mutations.js
src/store/mutations.js
+6
-0
state.js
src/store/state.js
+2
-0
common.js
src/util/common.js
+14
-3
combine.vue
src/views/components/combine.vue
+54
-24
done-component.vue
src/views/components/done-component.vue
+93
-0
right-component.vue
src/views/components/right-component.vue
+1
-1
smart-discover.vue
src/views/components/smart-discover.vue
+34
-9
main.vue
src/views/main.vue
+20
-36
No files found.
src/components/MonitorComponents/MonitorCard/mode1.vue
View file @
f3cdca8b
...
@@ -3,6 +3,11 @@
...
@@ -3,6 +3,11 @@
<div
class=
"card-title"
:style=
"`color:$
{color}`">
<div
class=
"card-title"
:style=
"`color:$
{color}`">
<div
class=
"dot"
/>
<div
class=
"dot"
/>
{{
title
}}
{{
title
}}
<p
v-if=
"showTab"
>
<span
:class=
"
{on: curTab === '处置中'}" @click="handleClick('处置中')">处置中
</span>
|
<span
:class=
"
{on: curTab === '已完成'}" @click="handleClick('已完成')">已完成
</span>
</p>
<div
class=
"line"
>
<div
class=
"line"
>
<img
src=
"@/assets/images/card-title-line.png"
/>
<img
src=
"@/assets/images/card-title-line.png"
/>
</div>
</div>
...
@@ -23,8 +28,23 @@ export default {
...
@@ -23,8 +28,23 @@ export default {
},
},
color
:
{
color
:
{
type
:
String
,
type
:
String
,
},
showTab
:
{
type
:
Boolean
,
default
:
false
,
},
},
data
()
{
return
{
curTab
:
'处置中'
,
}
}
},
},
methods
:
{
handleClick
(
type
)
{
this
.
curTab
=
type
this
.
$store
.
commit
(
'SET_CUR_TAB'
,
type
)
},
},
}
}
</
script
>
</
script
>
...
@@ -35,6 +55,16 @@ export default {
...
@@ -35,6 +55,16 @@ export default {
align-items center
align-items center
font-size .11rem
font-size .11rem
font-weight bold
font-weight bold
>p
font-weight normal
margin-left .05rem
font-size .09rem
>span
color #999
cursor pointer
&:hover
&.on
color #fff
.dot
.dot
width .03rem
width .03rem
height .1rem
height .1rem
...
...
src/components/MonitorComponents/MonitorForm/monitor-form.vue
View file @
f3cdca8b
...
@@ -4,12 +4,14 @@
...
@@ -4,12 +4,14 @@
<Row
class=
"row"
v-for=
"(row, rowIndex) in layout"
:key=
"rowIndex"
>
<Row
class=
"row"
v-for=
"(row, rowIndex) in layout"
:key=
"rowIndex"
>
<i-col
class=
"col"
v-for=
"(col, key) in row"
:key=
"key"
:span=
"col.width"
:offset=
"col.offset || 0"
>
<i-col
class=
"col"
v-for=
"(col, key) in row"
:key=
"key"
:span=
"col.width"
:offset=
"col.offset || 0"
>
<div
:style=
"`text-align: $
{col.align || 'right'}; width:${labelWidth}rem;`">
{{
col
.
label
}}
:
</div>
<div
:style=
"`text-align: $
{col.align || 'right'}; width:${labelWidth}rem;`">
{{
col
.
label
}}
:
</div>
<img
v-if=
"col.type == 'img'"
@
click=
"handleView(model[key])"
:src=
"require(`@/assets/images/$
{model[key]}`)"/>
<template
v-if=
"col.type == 'img'"
>
<img
v-for=
"img in model[key].split(',')"
:key=
"img"
@
click=
"handleView(img)"
:src=
"img"
/>
</
template
>
<div
v-else
class=
"content"
>
{{col.format ? col.format(model[key]) : (model[key] || ' ')}}
</div>
<div
v-else
class=
"content"
>
{{col.format ? col.format(model[key]) : (model[key] || ' ')}}
</div>
</i-col>
</i-col>
</Row>
</Row>
<m-modal
v-model=
"showImg"
>
<m-modal
v-model=
"showImg"
width=
"40%"
title=
"图片"
>
<img
v-if=
"showImg"
style=
"
width: 100%;"
:src=
"require(`@/assets/images/$
{curSrc}`)
"/>
<img
v-if=
"showImg"
style=
"
max-height:45vh;width:100%;"
:src=
"curSrc
"
/>
</m-modal>
</m-modal>
</div>
</div>
</template>
</template>
...
@@ -79,7 +81,7 @@ export default {
...
@@ -79,7 +81,7 @@ export default {
.content
.content
flex 1
flex 1
img
img
width 2
5
%
width 2
0
%
height .5rem
height .5rem
margin 0.05rem 0
margin 0.05rem 0
cursor pointer
cursor pointer
...
...
src/server/api.js
View file @
f3cdca8b
...
@@ -2,12 +2,13 @@ let BASE_URL = ''
...
@@ -2,12 +2,13 @@ let BASE_URL = ''
let
DATA_URL
=
''
let
DATA_URL
=
''
switch
(
process
.
env
.
NODE_ENV
)
{
switch
(
process
.
env
.
NODE_ENV
)
{
case
'production'
:
case
'production'
:
BASE_URL
=
'http://yangpu.hm.omniview.pro/api'
BASE_URL
=
'http://10.89.4.164/api'
// BASE_URL = 'http://yangpu.hm.omniview.pro/api'
DATA_URL
=
'http://10.89.1.208:10005'
DATA_URL
=
'http://10.89.1.208:10005'
break
break
default
:
default
:
// BASE_URL = 'http://yapi.omniview.pro/mock/350/api'
BASE_URL
=
'http://yangpu.hm.omniview.pro/api'
BASE_URL
=
'http://yangpu.hm.omniview.pro/api'
// BASE_URL = 'http://yapi.omniview.pro/mock/350'
DATA_URL
=
'http://10.89.1.208:10005'
DATA_URL
=
'http://10.89.1.208:10005'
}
}
export
default
{
export
default
{
...
...
src/store/actions.js
View file @
f3cdca8b
...
@@ -22,6 +22,7 @@ export default {
...
@@ -22,6 +22,7 @@ export default {
dispatch
(
'getDiscoverInfo'
)
dispatch
(
'getDiscoverInfo'
)
dispatch
(
'getRepairInfo'
)
dispatch
(
'getRepairInfo'
)
dispatch
(
'getHandleList'
)
dispatch
(
'getHandleList'
)
dispatch
(
'getDoneList'
)
},
},
async
getGreenInfo
({
commit
})
{
async
getGreenInfo
({
commit
})
{
const
result
=
[
const
result
=
[
...
@@ -113,7 +114,7 @@ export default {
...
@@ -113,7 +114,7 @@ export default {
}).
then
(
res
=>
{
}).
then
(
res
=>
{
const
sum
=
{
total
:
0
,
today
:
0
}
const
sum
=
{
total
:
0
,
today
:
0
}
const
data
=
com
.
confirm
(
res
,
'data.content'
,
[])
const
data
=
com
.
confirm
(
res
,
'data.content'
,
[])
const
keys
=
[
'
staffLeaveAlarmTcfteodr'
,
'parkFireExit'
,
'nonVehicleCharg'
,
'elevatorLock'
,
'buildingVibration'
,
'trash'
,
'manholeCover'
,
'waterTank'
,
'roofWater'
,
'hermeticSpace'
,
'accCtl
'
]
const
keys
=
[
'
heap'
,
'parkFireExit'
,
'nonVehicleCharg'
,
'buildingVibration'
,
'trash'
,
'manholeCover'
,
'waterTank'
,
'roofWater'
,
'hermeticSpace'
,
'accCtl'
,
'streetMonitor
'
]
const
result
=
data
.
filter
(
item
=>
keys
.
indexOf
(
item
.
types
)
>=
0
)
const
result
=
data
.
filter
(
item
=>
keys
.
indexOf
(
item
.
types
)
>=
0
)
result
.
forEach
(
e
=>
{
result
.
forEach
(
e
=>
{
sum
.
total
+=
+
e
.
total
sum
.
total
+=
+
e
.
total
...
@@ -141,4 +142,9 @@ export default {
...
@@ -141,4 +142,9 @@ export default {
commit
(
'SET_HANDLE_LIST'
,
com
.
confirm
(
res
,
'data.content'
,
[]))
commit
(
'SET_HANDLE_LIST'
,
com
.
confirm
(
res
,
'data.content'
,
[]))
})
})
},
},
getDoneList
({
commit
})
{
// 获取并全局设置已完成列表
ajax
.
get
({
url
:
api
.
GET_HANDLE_LIST
,
params
:
{
state
:
5
,
streetId
}}).
then
(
res
=>
{
commit
(
'SET_DONE_LIST'
,
com
.
confirm
(
res
,
'data.content'
,
[]))
})
},
}
}
src/store/mutations.js
View file @
f3cdca8b
...
@@ -51,7 +51,13 @@ export default {
...
@@ -51,7 +51,13 @@ export default {
SET_REPAIR_INFO
(
state
,
data
)
{
SET_REPAIR_INFO
(
state
,
data
)
{
state
.
repairInfo
=
data
state
.
repairInfo
=
data
},
},
SET_CUR_TAB
(
state
,
val
)
{
state
.
handleCurTab
=
val
},
SET_HANDLE_LIST
(
state
,
data
)
{
SET_HANDLE_LIST
(
state
,
data
)
{
state
.
handleList
=
data
state
.
handleList
=
data
},
},
SET_DONE_LIST
(
state
,
data
)
{
state
.
doneList
=
data
},
}
}
src/store/state.js
View file @
f3cdca8b
...
@@ -95,7 +95,9 @@ export default {
...
@@ -95,7 +95,9 @@ export default {
patrolList
:
[],
patrolList
:
[],
discoverSum
:
{},
discoverSum
:
{},
discoverInfo
:
[],
discoverInfo
:
[],
handleCurTab
:
'处置中'
,
handleList
:
[],
handleList
:
[],
doneList
:
[],
repairInfo
:
[[
0
,
0
],
[
0
,
0
]],
repairInfo
:
[[
0
,
0
],
[
0
,
0
]],
streetInfo
:
{
streetInfo
:
{
310110020000
:
{
310110020000
:
{
...
...
src/util/common.js
View file @
f3cdca8b
...
@@ -31,12 +31,21 @@ export default {
...
@@ -31,12 +31,21 @@ export default {
return
path
.
split
(
'.'
).
reduce
(
reducer
,
obj
)
return
path
.
split
(
'.'
).
reduce
(
reducer
,
obj
)
}
}
},
},
transStatus
(
type
)
{
if
(
type
==
1
)
{
return
'转物业'
}
else
if
(
type
==
2
)
{
return
'转物业'
}
else
if
(
type
==
5
)
{
return
'已完成'
}
},
transType
(
type
)
{
transType
(
type
)
{
const
data
=
{
const
data
=
{
'
staffLeaveAlarmTcfteodr'
:
'门岗脱岗
'
,
'
accCtl'
:
'门禁异常
'
,
'parkFireExit'
:
'占用消防通道'
,
'parkFireExit'
:
'占用消防通道'
,
'nonVehicleCharg'
:
'集中充电异常'
,
'nonVehicleCharg'
:
'集中充电异常'
,
'
elevatorLock'
:
'楼道充电'
,
'
heap'
:
'楼道堆物'
,
// 延吉
'buildingVibration'
:
'损坏承重结构'
,
'buildingVibration'
:
'损坏承重结构'
,
'trash'
:
'非定时倒垃圾'
,
'trash'
:
'非定时倒垃圾'
,
'manholeCover'
:
'窨井盖异常'
,
'manholeCover'
:
'窨井盖异常'
,
...
@@ -44,7 +53,9 @@ export default {
...
@@ -44,7 +53,9 @@ export default {
'roofWater'
:
'屋顶积水'
,
'roofWater'
:
'屋顶积水'
,
'hermeticSpace'
:
'屋顶违章建筑'
,
'hermeticSpace'
:
'屋顶违章建筑'
,
'weixiuzijin'
:
'维修资金异常'
,
'weixiuzijin'
:
'维修资金异常'
,
'accCtl'
:
'门禁异常'
,
'streetMonitor'
:
'街面占用'
,
// 控江
// 'staffLeaveAlarmTcfteodr': '门岗脱岗',
// 'elevatorLock': '楼道充电',
}
}
return
data
[
type
]
return
data
[
type
]
},
},
...
...
src/views/components/combine.vue
View file @
f3cdca8b
<
template
>
<
template
>
<div
class=
"combine"
>
<div
class=
"combine"
>
<m-scroll
v-if=
"list.length > 0"
:length=
"list.length"
:limit=
"$store.state.currentStreetInfo.name === '新江湾城街道' ? 2 : 3"
>
<m-scroll
v-if=
"list.length > 0"
:length=
"list.length"
:limit=
"$store.state.currentStreetInfo.name === '新江湾城街道' ? 2 : 3"
>
<div
@
click=
"$emit('select', item)"
class=
"detail
"
v-for=
"item in list"
:key=
"item.id"
>
<div
@
click=
"$emit('select', item)"
:class=
"
{detail: true, done: !isDoing}
" v-for="item in list" :key="item.id">
<div>
<div>
<h5>
{{
item
.
communityName
}}
</h5>
<h5>
{{
item
.
communityName
}}
</h5>
<p>
{{
item
.
create_time
}}
</p>
<p
v-if=
"isDoing"
>
{{
item
.
create_time
}}
</p>
<p
v-else
class=
"name"
><span>
{{
item
.
receive_property_name
}}
</span>
完成处置
</p>
</div>
</div>
<div
class=
"content"
>
<div
v-if=
"isDoing"
class=
"content"
>
<div>
<div>
{{
$com
.
transType
(
item
.
types
)
||
'暂无分类'
}}
</div>
<p>
协同事项
</p>
<div
:title=
"item.create_note"
>
事件描述:
{{
item
.
create_note
||
'暂无描述'
}}
</div>
<p>
{{
$com
.
transType
(
item
.
types
)
||
'暂无分类'
}}
</p>
</div>
<div>
<p>
发现方式
</p>
<p>
{{
item
.
check_type
||
'智能发现'
}}
</p>
</div>
<div>
<p>
响应部门
</p>
<p>
{{
item
.
cspName
||
item
.
receive_property_name
}}
</p>
</div>
</div>
<div
v-else
class=
"content"
>
<div>
{{
$com
.
transType
(
item
.
types
)
||
'暂无分类'
}}
</div>
<div>
{{
item
.
create_time
}}
</div>
</div>
</div>
<m-step
class=
"combine-step"
:steps=
"steps"
:current=
"getCurrent(item)"
/>
<m-step
v-if=
"isDoing"
class=
"combine-step"
:steps=
"steps"
:current=
"getCurrent(item)"
/>
</div>
</div>
</m-scroll>
</m-scroll>
<div
v-else
class=
"no-data"
>
<div
v-else
class=
"no-data"
>
...
@@ -31,6 +26,7 @@
...
@@ -31,6 +26,7 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
{
mapState
}
from
'vuex'
export
default
{
export
default
{
name
:
'Combine'
,
name
:
'Combine'
,
data
()
{
data
()
{
...
@@ -44,12 +40,23 @@ export default {
...
@@ -44,12 +40,23 @@ export default {
}
}
},
},
computed
:
{
computed
:
{
...
mapState
([
'handleList'
,
'curSmartType'
,
'handleCurTab'
,
'doneList'
,
]),
isDoing
()
{
return
this
.
handleCurTab
===
'处置中'
},
list
()
{
list
()
{
const
{
handleList
,
curSmartType
}
=
this
.
$store
.
state
// if (this.handleCurTab === '已完成') {
if
(
curSmartType
)
{
// return this.doneList
return
handleList
.
filter
(
item
=>
item
.
types
===
curSmartType
)
// }
if
(
this
.
curSmartType
)
{
return
this
.
handleList
.
filter
(
item
=>
item
.
types
===
this
.
curSmartType
)
}
}
return
handleList
return
this
.
handleList
}
}
},
},
methods
:
{
methods
:
{
...
@@ -82,11 +89,20 @@ export default {
...
@@ -82,11 +89,20 @@ export default {
position relative
position relative
cursor pointer
cursor pointer
transition background .2s, box-shadow .3s ease-in-out
transition background .2s, box-shadow .3s ease-in-out
&.done
padding .1rem
&:hover
&:hover
background $section-hover
background $section-hover
box-shadow -0.05rem .01rem .05rem .01rem rgba(0,0,0,0.8)
box-shadow -0.05rem .01rem .05rem .01rem rgba(0,0,0,0.8)
h5
h5
font-size .1rem
font-size .1rem
.name
color #ccc
font-size .08rem
>span
color $edgeColor
font-size .1rem
font-weight bold
>div
>div
&:first-child
&:first-child
display flex
display flex
...
@@ -94,11 +110,25 @@ export default {
...
@@ -94,11 +110,25 @@ export default {
&.content
&.content
display flex
display flex
margin .05rem 0
margin .05rem 0
justify-content space-between
>div
p
&:first-child
color $cardFontColor
font-size .08rem
font-size .08rem
color #ccc
&:first-child
color #FF9D27
border .01rem solid @color
border-radius .02rem
padding 0 .05rem
margin-right .05rem
&:last-child
flex 1
overflow hidden
white-space nowrap
text-overflow ellipsis
text-align right
// p
// &:first-child
// color $cardFontColor
// font-size .08rem
.combine-step
.combine-step
position absolute
position absolute
left .1rem
left .1rem
...
...
src/views/components/done-component.vue
0 → 100644
View file @
f3cdca8b
<
template
>
<div
class=
"done-component"
>
<div>
<p
class=
"title"
><span
class=
"dot"
/>
风险报警信息
</p>
<m-form
:label-width=
".6"
:model=
"data"
:layout=
"layout"
/>
</div>
<div
v-for=
"item in data.details"
:key=
"item.id"
>
<p
class=
"title"
><span
class=
"dot"
/>
{{
item
.
disposalDept
}}
处置
</p>
<m-form
:label-width=
".6"
:model=
"item"
:layout=
"detailLayout"
/>
</div>
</div>
</
template
>
<
script
>
export
default
{
name
:
'DoneComponent'
,
props
:
{
data
:
{
type
:
Object
,
required
:
true
,
},
},
data
()
{
return
{
layout
:
[
{
communityName
:
{
label
:
'小区名称'
,
width
:
24
,
},
device_name
:
{
label
:
'报警地址'
,
width
:
24
,
},
types
:
{
label
:
'报警类型'
,
width
:
24
,
format
:
val
=>
this
.
$com
.
transType
(
val
)
},
create_note
:
{
label
:
'报警内容'
,
width
:
24
,
},
create_time
:
{
label
:
'报警时间'
,
width
:
24
,
},
state
:
{
label
:
'处置状态'
,
width
:
24
,
format
:
val
=>
this
.
$com
.
transStatus
(
val
)
},
},
],
detailLayout
:
[
{
checkTime
:
{
label
:
'处置时间'
,
width
:
24
,
},
backResult
:
{
label
:
'处置结果'
,
width
:
24
,
},
imgs
:
{
label
:
'处置图片'
,
width
:
24
,
type
:
'img'
,
},
},
],
}
},
}
</
script
>
<
style
lang=
"stylus"
scoped
>
.done-component
.title
background rgba(51,145,255,.2)
color $edgeColor
padding .05rem 0
display flex
align-items center
font-weight bold
font-size .11rem
>.dot
display inline-block
width .03rem
height .12rem
background $edgeColor
margin-right .1rem
</
style
>
src/views/components/right-component.vue
View file @
f3cdca8b
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
</div>
</div>
<div
class=
"right"
>
<div
class=
"right"
>
<m-card
title=
"主动巡检"
><Patrol
@
select=
"$emit('patrol', $event)"
/></m-card>
<m-card
title=
"主动巡检"
><Patrol
@
select=
"$emit('patrol', $event)"
/></m-card>
<m-card
title=
"联勤联动"
><Combine
@
select=
"$emit('handle', $event)"
/></m-card>
<m-card
title=
"联勤联动"
showTab
><Combine
@
select=
"$emit('handle', $event)"
/></m-card>
<m-card
title=
"鹰眼监控"
v-if=
"$store.state.currentStreetInfo.name === '新江湾城街道'"
>
<m-card
title=
"鹰眼监控"
v-if=
"$store.state.currentStreetInfo.name === '新江湾城街道'"
>
<div
class=
"monitor-video"
>
<div
class=
"monitor-video"
>
<div
v-for=
"(img, i) in imgs"
@
click=
"handleClick(i)"
:key=
"img"
:style=
"`background-image: url($
{require(`@/assets/images/${img}`)})`">
<div
v-for=
"(img, i) in imgs"
@
click=
"handleClick(i)"
:key=
"img"
:style=
"`background-image: url($
{require(`@/assets/images/${img}`)})`">
...
...
src/views/components/smart-discover.vue
View file @
f3cdca8b
...
@@ -11,7 +11,7 @@
...
@@ -11,7 +11,7 @@
</div>
</div>
</div>
</div>
<div
class=
"detail"
>
<div
class=
"detail"
>
<div
@
click=
"handleClick(item.types
)"
:class=
"
{on: item.types === curSmartTyp
e}" v-for="item in list" :key="item.types">
<div
@
click=
"handleClick(item.types
, item.visible)"
:class=
"
{on: item.types === curSmartType, visible: item.visibl
e}" v-for="item in list" :key="item.types">
<p><img
:src=
"require(`@/assets/images/$
{item.img}`)" />
{{
item
.
name
}}
</p>
<p><img
:src=
"require(`@/assets/images/$
{item.img}`)" />
{{
item
.
name
}}
</p>
<m-count
:class=
"
{count: true, yellow: item.value > 0}" :value="item.value" :decimal="0" />
<m-count
:class=
"
{count: true, yellow: item.value > 0}" :value="item.value" :decimal="0" />
</div>
</div>
...
@@ -72,19 +72,41 @@ export default {
...
@@ -72,19 +72,41 @@ export default {
},
},
list
()
{
list
()
{
const
{
discoverInfo
}
=
this
.
$store
.
state
const
{
discoverInfo
}
=
this
.
$store
.
state
return
discoverInfo
.
map
((
item
,
i
)
=>
({
const
result
=
discoverInfo
.
map
((
item
,
i
)
=>
({
name
:
this
.
$com
.
transType
(
item
.
types
),
name
:
this
.
$com
.
transType
(
item
.
types
),
value
:
+
item
.
numbers
||
0
,
value
:
+
item
.
numbers
||
0
,
img
:
`smart
${
i
+
1
}
.png`
,
img
:
`smart
${
i
+
1
}
.png`
,
types
:
item
.
types
,
types
:
item
.
types
,
visible
:
this
.
calcVisible
(
item
.
types
),
}))
}))
return
result
.
sort
((
a
,
b
)
=>
b
.
visible
-
a
.
visible
)
}
}
},
},
methods
:
{
methods
:
{
handleClick
(
type
)
{
handleClick
(
type
,
visible
)
{
if
(
visible
)
{
this
.
$store
.
commit
(
'SET_CUR_SMART_TYPE'
,
type
===
this
.
curSmartType
?
null
:
type
)
this
.
$store
.
commit
(
'SET_CUR_SMART_TYPE'
,
type
===
this
.
curSmartType
?
null
:
type
)
}
}
},
},
calcVisible
(
type
)
{
const
{
name
}
=
this
.
$store
.
state
.
currentStreetInfo
const
keys
=
[
'平凉路街道'
,
'控江路街道'
,
'长白新村街道'
,
'延吉新村街道'
,
'殷行街道'
,
'大桥街道'
,
'新江湾城街道'
,
]
if
(
keys
.
indexOf
(
name
)
<
0
)
{
if
(
type
===
'parkFireExit'
||
type
===
'nonVehicleCharg'
)
return
false
}
if
(
name
!==
'控江路街道'
&&
type
===
'streetMonitor'
)
return
false
if
(
name
!==
'延吉新村街道'
&&
type
===
'heap'
)
return
false
return
true
},
},
}
}
</
script
>
</
script
>
...
@@ -129,8 +151,11 @@ export default {
...
@@ -129,8 +151,11 @@ export default {
margin .01rem
margin .01rem
width calc((100% - 0.04rem) / 2)
width calc((100% - 0.04rem) / 2)
background #0A2F59
background #0A2F59
cursor pointer
border .01rem solid transparent
border .01rem solid transparent
opacity .3
&.visible
cursor pointer
opacity 1
&.on
&.on
&:hover
&:hover
$selected()
$selected()
...
...
src/views/main.vue
View file @
f3cdca8b
...
@@ -19,7 +19,7 @@
...
@@ -19,7 +19,7 @@
v-show=
"!fullView"
v-show=
"!fullView"
area=
"right"
area=
"right"
@
patrol=
"handleMapClick"
@
patrol=
"handleMapClick"
@
handle=
"handle
Map
Click"
@
handle=
"handle
List
Click"
@
video=
"handleViewVideo"
@
video=
"handleViewVideo"
/>
/>
</m-animate>
</m-animate>
...
@@ -27,6 +27,9 @@
...
@@ -27,6 +27,9 @@
<m-modal
v-model=
"detailModal"
title=
"智能报警"
>
<m-modal
v-model=
"detailModal"
title=
"智能报警"
>
<m-form
:label-width=
".6"
:model=
"detailData"
:layout=
"detailLayout"
/>
<m-form
:label-width=
".6"
:model=
"detailData"
:layout=
"detailLayout"
/>
</m-modal>
</m-modal>
<m-modal
v-model=
"doneModal"
title=
"已完成处置列表"
>
<DoneComponent
v-if=
"doneModal"
:data=
"doneData"
/>
</m-modal>
<m-modal
v-model=
"patrolModal"
title=
"主动巡检"
>
<m-modal
v-model=
"patrolModal"
title=
"主动巡检"
>
<m-form
:label-width=
".6"
:model=
"patrolData"
:layout=
"patrolLayout"
/>
<m-form
:label-width=
".6"
:model=
"patrolData"
:layout=
"patrolLayout"
/>
</m-modal>
</m-modal>
...
@@ -44,6 +47,7 @@ import LeftComponent from './components/left-component'
...
@@ -44,6 +47,7 @@ import LeftComponent from './components/left-component'
import
RightComponent
from
'./components/right-component'
import
RightComponent
from
'./components/right-component'
import
MapBtns
from
'./components/map-btns'
import
MapBtns
from
'./components/map-btns'
import
VideoComponent
from
'./components/video-component'
import
VideoComponent
from
'./components/video-component'
import
DoneComponent
from
'./components/done-component'
import
{
mapState
,
mapActions
}
from
'vuex'
import
{
mapState
,
mapActions
}
from
'vuex'
export
default
{
export
default
{
name
:
'Main'
,
name
:
'Main'
,
...
@@ -52,6 +56,7 @@ export default {
...
@@ -52,6 +56,7 @@ export default {
RightComponent
,
RightComponent
,
MapBtns
,
MapBtns
,
VideoComponent
,
VideoComponent
,
DoneComponent
,
},
},
data
()
{
data
()
{
return
{
return
{
...
@@ -96,40 +101,6 @@ export default {
...
@@ -96,40 +101,6 @@ export default {
},
},
},
},
],
],
// detailLayout: [
// {
// id: {
// label: '工单编号',
// width: 12,
// },
// type: {
// label: '事件类型',
// width: 12,
// },
// },
// {
// time: {
// label: '报警时间',
// width: 12,
// },
// level: {
// label: '报警等级',
// width: 12,
// },
// },
// {
// address: {
// label: '地址',
// width: 24,
// },
// },
// {
// result: {
// label: '处理结论',
// width: 24,
// },
// },
// ],
patrolLayout
:
[
patrolLayout
:
[
{
{
communityName
:
{
communityName
:
{
...
@@ -168,6 +139,8 @@ export default {
...
@@ -168,6 +139,8 @@ export default {
},
},
},
},
],
],
doneModal
:
false
,
doneData
:
{},
}
}
},
},
computed
:
{
computed
:
{
...
@@ -175,10 +148,10 @@ export default {
...
@@ -175,10 +148,10 @@ export default {
'currentStreetInfo'
,
'currentStreetInfo'
,
'streetInfo'
,
'streetInfo'
,
'curSmartType'
,
'curSmartType'
,
'xinjiangwanPaths'
,
'showCommandModal'
,
'showCommandModal'
,
'patrolList'
,
'patrolList'
,
'handleList'
,
'handleList'
,
'handleCurTab'
,
])
])
},
},
beforeCreate
()
{
beforeCreate
()
{
...
@@ -197,6 +170,7 @@ export default {
...
@@ -197,6 +170,7 @@ export default {
'getDiscoverInfo'
,
'getDiscoverInfo'
,
'getRepairInfo'
,
'getRepairInfo'
,
'getHandleList'
,
'getHandleList'
,
'getDoneList'
,
'getCheckSum'
,
'getCheckSum'
,
'getPatrolList'
,
'getPatrolList'
,
]),
]),
...
@@ -212,6 +186,7 @@ export default {
...
@@ -212,6 +186,7 @@ export default {
this
.
getCheckSum
()
this
.
getCheckSum
()
this
.
getPatrolList
()
this
.
getPatrolList
()
this
.
getHandleList
()
this
.
getHandleList
()
this
.
getDoneList
()
},
1000
*
60
*
1
)
},
1000
*
60
*
1
)
},
},
init
()
{
init
()
{
...
@@ -236,6 +211,15 @@ export default {
...
@@ -236,6 +211,15 @@ export default {
}
}
// this.$refs.map.focus(data.x || data.gpsx, data.y || data.gpsy, 8)
// this.$refs.map.focus(data.x || data.gpsx, data.y || data.gpsy, 8)
},
},
handleListClick
(
data
)
{
if
(
this
.
handleCurTab
===
'处置中'
)
{
this
.
detailData
=
data
this
.
detailModal
=
true
}
else
{
this
.
doneData
=
data
this
.
doneModal
=
true
}
},
drawSmartPoints
(
data
)
{
drawSmartPoints
(
data
)
{
const
{
addPoint
,
removePoint
}
=
this
.
$refs
.
map
const
{
addPoint
,
removePoint
}
=
this
.
$refs
.
map
removePoint
(
this
.
smartPoints
)
removePoint
(
this
.
smartPoints
)
...
...
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