Commit 9dc4e337 authored by 郭铭瑶's avatar 郭铭瑶 🤘

打包

parent 0e04b8a3
*.zip
# Logs
logs
*.log
......
......@@ -3,10 +3,15 @@
<div class="card-title" :style="`color:${color}`">
<div class="dot"/>
{{title}}
<p v-if="showTab">
<span :class="{on: curTab === '处置中'}" @click="handleClick('处置中')">处置中</span>
|
<span :class="{on: curTab === '已完成'}" @click="handleClick('已完成')">已完成</span>
</p>
<div class="line">
<img src="@/assets/images/card-title-line.png"/>
</div>
<p v-if="showTip" class="tip">数值为报修数量/占比/密度</p>
<p v-if="showTip" class="tip"><span>数值为</span>报修数量/占比/密度</p>
</div>
<div class="card-content">
<slot />
......@@ -28,8 +33,23 @@ export default {
},
color: {
type: String,
},
showTab: {
type: Boolean,
default: false,
},
},
data() {
return {
curTab: '处置中',
}
},
methods: {
handleClick(type) {
this.curTab = type
this.$store.commit('SET_CUR_TAB', type)
},
},
}
</script>
......@@ -41,11 +61,23 @@ export default {
font-size .11rem
font-weight bold
position relative
>p
font-weight normal
margin-left .05rem
font-size .09rem
>span
color #999
cursor pointer
&:hover
&.on
color #fff
.tip
position absolute
right 0
font-weight normal
font-size .08rem
>span
color #999
.dot
width .03rem
height .1rem
......
......@@ -327,7 +327,7 @@ export default {
textStyle: {
color: '#ccc',
},
fontSize: this.fontSize,
fontSize: this.fontSize * 0.9,
},
axisLine: {
lineStyle: {
......
......@@ -4,12 +4,14 @@
<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">
<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] && 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>
</i-col>
</Row>
<m-modal v-model="showImg">
<img v-if="showImg" style="width: 100%;" :src="require(`@/assets/images/${curSrc}`)"/>
<m-modal v-model="showImg" width="40%" title="图片">
<img v-if="showImg" style="max-height:45vh;width:100%;" :src="curSrc"/>
</m-modal>
</div>
</template>
......@@ -79,8 +81,9 @@ export default {
.content
flex 1
img
width 25%
width 20%
height .5rem
margin 0.05rem 0
margin-right .03rem
cursor pointer
</style>
......@@ -2,6 +2,7 @@ let BASE_URL = ''
let DATA_URL = ''
switch (process.env.NODE_ENV) {
case 'production':
// BASE_URL = 'http://10.89.4.164:18080/api'
BASE_URL = 'http://yangpu.hm.omniview.pro/api'
DATA_URL = 'http://10.89.1.208:10005'
break
......
......@@ -15,6 +15,7 @@ export default {
dispatch('getRepairInfo')
dispatch('getComplaintInfo')
dispatch('getHealthInfo')
dispatch('getDoneList')
},
getTaskList({commit}) {
ajax.get({url: api.GET_TASK_LIST}).then(res => {
......@@ -22,10 +23,15 @@ export default {
})
},
getHandleList({commit}) { // 获取并全局设置联勤联动处置列表
ajax.get({url: api.GET_HANDLE_LIST}).then(res => {
ajax.get({url: api.GET_HANDLE_LIST, params: {state_ne: 5}}).then(res => {
commit('SET_HANDLE_LIST', com.confirm(res, 'data.content', []))
})
},
getDoneList({commit}) { // 获取并全局设置已完成列表
ajax.get({url: api.GET_HANDLE_LIST, params: {state: 5}}).then(res => {
commit('SET_DONE_LIST', com.confirm(res, 'data.content', []))
})
},
getResourceCount({commit}) { // 获取运行体征
ajax.get({url: api.GET_RESOURCE_COUNT}).then(res => {
commit('SET_RESOURCE_COUNT', com.confirm(res, 'data.content', {}))
......
......@@ -5,6 +5,9 @@ export default {
SET_CURDATE(state, date) {
state.curDate = date
},
SET_CUR_TAB(state, val) {
state.handleCurTab = val
},
SET_COMMAND_MODAL(state, val) {
state.showCommandModal = val
},
......@@ -14,6 +17,9 @@ export default {
SET_HANDLE_LIST(state, data) {
state.handleList = data
},
SET_DONE_LIST(state, data) {
state.doneList = data
},
SET_RESOURCE_COUNT(state, data) {
state.resourceCount = data
},
......
export default {
showLoading: false,
curDate: null,
handleCurTab: '处置中',
showCommandModal: false,
taskList: [],
handleList: [],
doneList: [],
resourceCount: {},
communityRate: {},
marketShare: {},
......
......@@ -31,12 +31,21 @@ export default {
return path.split('.').reduce(reducer, obj)
}
},
transStatus(type) {
if (type == 1) {
return '转物业'
} else if (type == 2) {
return '转物业'
} else if (type == 5) {
return '已完成'
}
},
transType(type) {
const data = {
'staffLeaveAlarmTcfteodr': '门岗脱岗',
'accCtl': '门禁异常',
'parkFireExit': '占用消防通道',
'nonVehicleCharg': '集中充电异常',
'elevatorLock': '楼道充电',
'heap': '楼道堆物', // 延吉
'buildingVibration': '损坏承重结构',
'trash': '非定时倒垃圾',
'manholeCover': '窨井盖异常',
......@@ -44,7 +53,9 @@ export default {
'roofWater': '屋顶积水',
'hermeticSpace': '屋顶违章建筑',
'weixiuzijin': '维修资金异常',
'accCtl': '门禁异常',
'streetMonitor': '街面占用', // 控江
'staffLeaveAlarmTcfteodr': '门岗脱岗',
'elevatorLock': '楼道充电',
}
return data[type]
},
......
<template>
<div class="combine">
<m-scroll v-if="list.length > 0" :length="list.length" :limit="2">
<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>
<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 class="content">
<div>
<p>协同事项</p>
<p>{{$com.transType(item.types) || '暂无分类'}}</p>
</div>
<div>
<p>发现方式</p>
<p>{{item.check_type || '智能发现'}}</p>
<div v-if="isDoing" class="content">
<div>{{$com.transType(item.types) || '暂无分类'}}</div>
<div :title="item.create_note">事件描述:{{item.create_note || '暂无描述'}}</div>
</div>
<div>
<p>响应部门</p>
<p>{{item.cspName || item.receive_property_name}}</p>
<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>
</m-scroll>
<div v-else class="no-data">
......@@ -31,6 +26,7 @@
</template>
<script>
import {mapState} from 'vuex'
export default {
name: 'Combine',
data() {
......@@ -44,9 +40,23 @@ export default {
}
},
computed: {
...mapState([
'handleList',
'curSmartType',
'handleCurTab',
'doneList',
]),
isDoing() {
return this.handleCurTab === '处置中'
},
list() {
const {handleList} = this.$store.state
return handleList
if (this.handleCurTab === '已完成') {
return this.doneList
}
if (this.curSmartType) {
return this.handleList.filter(item => item.types === this.curSmartType)
}
return this.handleList
}
},
methods: {
......@@ -63,10 +73,6 @@ export default {
<style lang="stylus" scoped>
.combine
// .no-data
// width 100%
// height 100%
// $flex-center()
.no-data
$flex-center()
flex-direction column
......@@ -83,11 +89,20 @@ export default {
position relative
cursor pointer
transition background .2s, box-shadow .3s ease-in-out
&.done
padding .1rem
&:hover
background $section-hover
box-shadow -0.05rem .01rem .05rem .01rem rgba(0,0,0,0.8)
h5
font-size .1rem
.name
color #ccc
font-size .08rem
>span
color $edgeColor
font-size .1rem
font-weight bold
>div
&:first-child
display flex
......@@ -95,11 +110,21 @@ export default {
&.content
display flex
margin .05rem 0
justify-content space-between
p
&:first-child
color $cardFontColor
>div
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
.combine-step
position absolute
left .1rem
......
......@@ -7,7 +7,8 @@
<p>{{item.name}}</p>
</div>
</div>
<img @click="$store.commit('SET_COMMAND_MODAL', true)" class="img" src="@/assets/images/command3.png" />
<img class="img" src="@/assets/images/command3.png" />
<!-- <img @click="$store.commit('SET_COMMAND_MODAL', true)" class="img" src="@/assets/images/command3.png" /> -->
</div>
</template>
......@@ -20,12 +21,12 @@ export default {
{
img: 'command1.png',
label: '指挥长',
name: '卞洪斌',
name: '于洋',
},
{
img: 'command2.png',
label: '值班长',
name: '丁建新',
name: '吴传婷',
},
]
}
......
......@@ -29,7 +29,7 @@
</div>
<!-- <div @click="showMore" v-if="chartData.length > 8" class="more">查看更多</div> -->
<Divider>投诉分布</Divider>
<p class="tip">数值为报修数量/占比/密度</p>
<p class="tip"><span>数值为</span>报修数量/占比/密度</p>
<div class="rate">
<RateComponent
:info="rateInfo"
......@@ -123,6 +123,8 @@ export default {
transform translateY(70%)
text-align right
font-size .08rem
>span
color #999
.no-data
$flex-center()
flex-direction column
......@@ -185,11 +187,11 @@ export default {
border-radius 50%
p
margin 0 .02rem
&:nth-of-type(1)
width: .61rem
overflow hidden
text-overflow ellipsis
white-space nowrap
// &:nth-of-type(1)
// width: .61rem
// overflow hidden
// text-overflow ellipsis
// white-space nowrap
.rate
flex 1
.more
......
<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.slice(1)" :key="item.id">
<p class="title"><span class="dot"/>{{getName(item.backStatus)}}处置</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',
},
},
],
}
},
methods: {
getName(type) {
if (type == '0') {
return '转物业'
}
if (type == '1' || type == '2') {
return '物业'
}
if (type == '3') {
return '转街道'
}
if (type == '4') {
return '街道'
}
},
},
}
</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>
......@@ -106,7 +106,17 @@ export default {
legend: {
top: '15%',
formatter: (name) => {
return `${name} ${(this.chartData.find(e => e.name === name)).value}%`
const data = this.chartData
let total = 0
let tarValue
for (let i = 0; i < data.length; i++) {
total += data[i].value
if (data[i].name === name) {
tarValue = data[i].value
}
}
const percent = (tarValue / total * 100).toFixed(0)
return `${name} ${percent}%`
}
}
},
......@@ -293,6 +303,7 @@ export default {
display flex
margin .02rem 0
justify-content space-between
font-size .09rem
p
&:first-child
color $cardFontColor
......
......@@ -244,7 +244,7 @@ export default {
display flex
flex-direction column
flex-wrap wrap
margin-top 3%
margin-top 3.5%
transform translateX(-15%)
>div
min-height 16.5%
......
......@@ -8,7 +8,7 @@
</div>
<div class="right">
<m-card title="投诉信访"><ComplaintReport /></m-card>
<m-card title="联勤联动"><Combine /></m-card>
<m-card title="联勤联动" showTab><Combine @select="$emit('handle', $event)" /></m-card>
</div>
</div>
</div>
......
......@@ -18,13 +18,16 @@
<RightComponent
v-show="!fullView"
area="right"
@handle="handleMapClick"
@handle="handleListClick"
/>
</m-animate>
<MapBtns v-model="fullView" @zoomin="zoom('in')" @zoomout="zoom('out')" />
<m-modal v-model="detailModal" title="智能报警">
<m-form :label-width=".6" :model="detailData" :layout="detailLayout" />
</m-modal>
<m-modal v-model="doneModal" title="已完成处置">
<DoneComponent v-if="doneModal" :data="doneData" />
</m-modal>
<m-modal title="指挥体系" :value="showCommandModal" @close="$store.commit('SET_COMMAND_MODAL', false)">
<m-form :label-width=".7" :model="commandData" :layout="commandLayout" />
</m-modal>
......@@ -36,6 +39,7 @@ import LeftComponent from './components/left-component'
import RightComponent from './components/right-component'
import MapBtns from './components/map-btns'
import VideoComponent from './components/video-component'
import DoneComponent from './components/done-component'
import {mapState, mapActions} from 'vuex'
export default {
name: 'Main',
......@@ -44,6 +48,7 @@ export default {
RightComponent,
MapBtns,
VideoComponent,
DoneComponent,
},
data() {
return {
......@@ -71,18 +76,30 @@ export default {
width: 12,
format: val => val && this.$com.transType(val)
},
receive_property_name: {
label: '响应部门',
// receive_property_name: {
// label: '响应部门',
// width: 12,
// },
device_name: {
label: '设备地点',
width: 12,
},
},
// {
// device_name: {
// label: '设备地点',
// width: 24,
// },
// },
{
device_name: {
label: '设备地点',
create_note: {
label: '事件描述',
width: 24,
},
},
],
doneModal: false,
doneData: {},
}
},
computed: {
......@@ -92,6 +109,7 @@ export default {
'commandData',
'showCommandModal',
'handleList',
'handleCurTab',
])
},
beforeDestroy() {
......@@ -102,6 +120,7 @@ export default {
...mapActions([
'initData', // 初始化获取首次加载所需的所有数据
'getHandleList',
'getDoneList',
]),
mapComplete() {
this.init()
......@@ -109,6 +128,7 @@ export default {
this.complete = true
this.timer = setInterval(() => {
this.getHandleList()
this.getDoneList()
}, 1000 * 60 * 1)
},
init() {
......@@ -124,6 +144,15 @@ export default {
this.detailData = data
this.detailModal = true
},
handleListClick(data) {
if (this.handleCurTab === '处置中') {
this.detailData = data
this.detailModal = true
} else {
this.doneData = data
this.doneModal = true
}
},
drawSmartPoints(data) {
const {addPoint, removePoint} = this.$refs.map
removePoint(this.smartPoints)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment