Merge branch 'dev' into vite
# Conflicts: # examples/main.js # examples/router/autoRoutes.js # package.json # packages/bigscreen/designer/AppDesigner.vue # packages/bigscreen/designer/components/Add.vue # packages/bigscreen/designer/components/Layout.vue # packages/bigscreen/designer/components/List.vue # packages/bigscreen/designer/components/SourceData.vue # packages/bigscreen/designer/components/form/DataConfig.vue # packages/bigscreen/designer/config.js # packages/bigscreen/viewer/AppGigscreenViewer.vue # packages/conv/creditScore/scoreManage/scoreChange.vue # packages/index.js # project/dv/apps/AppGridDV.vue # project/dvui/components/AiMonitor/dhVideo.vue # project/dvui/components/AiSwiper.vue # project/dvui/layout/AiDvBackground.vue # project/dvui/layout/AiDvSummary/AiDvSummary.vue # project/dvui/layout/AiDvWrapper/AiDvWrapper.vue # project/dvui/package.json # public/index.html # vue.config.js
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
<script>
|
||||
import List from './components/List'
|
||||
import Add from './components/Add'
|
||||
import Detail from './components/Detail'
|
||||
|
||||
export default {
|
||||
label: '播发记录',
|
||||
@@ -28,7 +29,8 @@ export default {
|
||||
|
||||
components: {
|
||||
Add,
|
||||
List
|
||||
List,
|
||||
Detail
|
||||
},
|
||||
methods: {
|
||||
onChange(data) {
|
||||
@@ -37,6 +39,11 @@ export default {
|
||||
this.params = data.params
|
||||
}
|
||||
|
||||
if (data.type === 'detail') {
|
||||
this.component = 'Detail'
|
||||
this.params = data.params
|
||||
}
|
||||
|
||||
if (data.type == 'list') {
|
||||
this.component = 'List'
|
||||
this.params = data.params
|
||||
|
||||
121
packages/device/AppBroadcast/components/Detail.vue
Normal file
121
packages/device/AppBroadcast/components/Detail.vue
Normal file
@@ -0,0 +1,121 @@
|
||||
<template>
|
||||
<ai-detail isHasSidebar class="Detail">
|
||||
<template slot="title">
|
||||
<ai-title title="任务详情" isShowBack isShowBottomBorder @onBackClick="cancel(true)">
|
||||
</ai-title>
|
||||
</template>
|
||||
<template slot="content">
|
||||
<AiSidebar :tabTitle="tabList" v-model="currIndex"></AiSidebar>
|
||||
<div v-show="currIndex == 0">
|
||||
<ai-card title="播发任务" v-show="currIndex === 0">
|
||||
<template #content>
|
||||
<ai-wrapper
|
||||
label-width="120px">
|
||||
<ai-info-item label="播发级别" v-show="info.taskType == 0">{{ $dict.getLabel('dlbMessageUrgency', info.messageLevel) }}</ai-info-item>
|
||||
<ai-info-item label="播发级别" v-show="info.taskType == 1">{{ $dict.getLabel('dlbMessageUrgency', info.messageLevel) }} - {{ $dict.getLabel('dlbDyclingType', info.cyclingType) }}</ai-info-item>
|
||||
<ai-info-item label="播放方式" :value="info.taskType == 1? '定时播放':'立即播放'"></ai-info-item>
|
||||
<ai-info-item label="创建人" :value="info.createUserName"></ai-info-item>
|
||||
<ai-info-item label="创建时间" :value="info.createTime"></ai-info-item>
|
||||
<ai-info-item label="开始日期" :value="info.startDate" v-if="info.taskType == 1"></ai-info-item>
|
||||
<ai-info-item label="播放天数" :value="info.broadcastDay" v-if="info.cyclingType == 3 && info.taskType == 1"></ai-info-item>
|
||||
<ai-info-item label="播放天数" v-if="info.cyclingType == 2 && info.taskType == 1">
|
||||
<span v-for="(item, index) in info.cyclingDateList" :key="index"><span v-if="index > 0">,</span>{{dayList[item]}}</span>
|
||||
</ai-info-item>
|
||||
<ai-info-item label="开始时间" :value="info.startTime" v-if="info.taskType == 1"></ai-info-item>
|
||||
<ai-info-item label="结束时间" :value="info.endTime" v-if="info.taskType == 1"></ai-info-item>
|
||||
</ai-wrapper>
|
||||
</template>
|
||||
</ai-card>
|
||||
</div>
|
||||
<ai-card title="播发设备" v-show="currIndex == 1">
|
||||
<template #right>
|
||||
<div style="color: #333;font-size: 15px;">共<span style="color: #0082ff;font-size: 15px;" v-if="info.devices">{{info.devices.length}}</span>个设备</div>
|
||||
</template>
|
||||
<template #content>
|
||||
<ai-table
|
||||
class="detail-table__table"
|
||||
:tableData="tableData"
|
||||
:col-configs="colConfigs"
|
||||
:total="total"
|
||||
:isShowPagination="false"
|
||||
@getList="getDetail">
|
||||
</ai-table>
|
||||
</template>
|
||||
</ai-card>
|
||||
<ai-card title="播发素材" v-show="currIndex == 2">
|
||||
<template #content>
|
||||
<div class="audios">
|
||||
<!-- <div>{{item.}}</div> -->
|
||||
<ai-audio :src="item.url" v-for="item in info.materials" :key="item.id" skin="flat" style="margin-bottom: 8px;"/>
|
||||
</div>
|
||||
</template>
|
||||
</ai-card>
|
||||
</template>
|
||||
</ai-detail>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'Detail',
|
||||
components: {},
|
||||
props: {
|
||||
dict: Object,
|
||||
params: Object,
|
||||
instance: Function,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
tabList: ['播发任务','播发设备','播发素材'],
|
||||
currIndex: 0,
|
||||
info: {},
|
||||
tableData: [],
|
||||
search: {},
|
||||
total: 0,
|
||||
colConfigs: [
|
||||
{prop: 'name', label: '设备名称', width: 400},
|
||||
{prop: 'areaName', label: '行政区划', align: 'center'},
|
||||
{prop: 'devStatus', label: '状态', align: 'center', render: (h, { row })=>{
|
||||
return h('span',null,this.dict.getLabel('dlbDevStatus',row.devStatus))
|
||||
}},
|
||||
],
|
||||
dayList: ['', '每周一', '每周二', '每周三', '每周四', '每周五', '每周六', '每周日'],
|
||||
voiceList: [],
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.$dict.load('dlbMessageUrgency','dlbDyclingType','dlbDevStatus').then(()=>{
|
||||
if(this.params.id) {
|
||||
this.getDetail()
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
},
|
||||
methods: {
|
||||
cancel(isRefresh) {
|
||||
this.$emit('change', {
|
||||
type: 'list',
|
||||
isRefresh: !!isRefresh,
|
||||
})
|
||||
},
|
||||
getDetail() {
|
||||
this.instance.post(`/app/appzyvideobroadcast/queryDetailById?id=${this.params.id}`).then((res) => {
|
||||
if(res?.data) {
|
||||
this.info = res.data
|
||||
this.tableData = res.data.devices
|
||||
this.total = res.data.devices.length
|
||||
if(this.info.cyclingType == 2) {
|
||||
this.info.cyclingDateList = this.info.cyclingDate.split(',')
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.Detail {
|
||||
height: 100%;
|
||||
}
|
||||
</style>
|
||||
@@ -5,15 +5,15 @@
|
||||
<template #content>
|
||||
<ai-search-bar bottomBorder>
|
||||
<template slot="left">
|
||||
<ai-select v-model="search.messageType" placeholder="媒资类型" clearable
|
||||
<ai-select v-model="search.type" placeholder="媒资类型" clearable
|
||||
:selectList="$dict.getDict('dlbResourceType')"
|
||||
@change=";(page.current = 1), getList()"></ai-select>
|
||||
<ai-select v-model="search.messageUrgency" placeholder="级别" clearable
|
||||
<ai-select v-model="search.messageLevel" placeholder="级别" clearable
|
||||
:selectList="$dict.getDict('dlbMessageUrgency')"
|
||||
@change=";(page.current = 1), getList()"></ai-select>
|
||||
</template>
|
||||
<template slot="right">
|
||||
<el-input v-model="search.messageName" size="small" placeholder="媒资名称" clearable
|
||||
<el-input v-model="search.sourceName" size="small" placeholder="媒资名称" clearable
|
||||
v-throttle="() => {page.current = 1, getList()}"
|
||||
@clear=";(page.current = 1), (search.messageName = ''), getList()"
|
||||
suffix-icon="iconfont iconSearch"/>
|
||||
@@ -25,14 +25,15 @@
|
||||
<!-- <el-button icon="iconfont iconDelete" size="small" @click="removeAll" :disabled="ids.length == 0">删除 </el-button> -->
|
||||
</template>
|
||||
</ai-search-bar>
|
||||
<ai-table :tableData="tableData" :col-configs="colConfigs" :total="total" :dict="dict"
|
||||
<ai-table :tableData="tableData" :col-configs="colConfigs" :total="total" :dict="dict" v-loading="loading"
|
||||
:current.sync="page.current" :size.sync="page.size" @getList="getList"
|
||||
@selection-change="(v) => (ids = v.map((e) => e.id))">
|
||||
<el-table-column slot="options" label="操作" align="center" width="180" fixed="right">
|
||||
<template slot-scope="{ row }">
|
||||
<el-button type="text" @click="onAdd(row.broadcastId)">复制</el-button>
|
||||
<el-button type="text" @click="cancel(row.broadcastId)"
|
||||
v-if="row.broadcastStatus == 0 || row.broadcastStatus == 1 || row.broadcastStatus == 2">撤回
|
||||
<!-- <el-button type="text" @click="onAdd(row.id)">复制</el-button> -->
|
||||
<el-button type="text" @click="toDetail(row.id)">详情</el-button>
|
||||
<el-button type="text" @click="reset(row.id)"
|
||||
v-if="row.taskType == 1 && (row.broadcastStatus == 0 || row.broadcastStatus == 1 || row.broadcastStatus == 2 )">撤回
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
@@ -62,25 +63,34 @@ export default {
|
||||
},
|
||||
total: 0,
|
||||
search: {
|
||||
messageName: '',
|
||||
messageType: '',
|
||||
messageUrgency: '',
|
||||
sourceName: '',
|
||||
cyclingType: '',
|
||||
messageLevel: '',
|
||||
},
|
||||
id: '',
|
||||
ids: [],
|
||||
colConfigs: [
|
||||
{prop: 'messageName', label: '媒资名称', width: 400},
|
||||
{prop: 'messageType', label: '媒资类型', align: 'center', dict: "dlbResourceType"},
|
||||
{prop: 'messageUrgency', label: '级别', align: 'center', dict: "dlbMessageUrgency"},
|
||||
{prop: 'taskType', label: '播发方式', align: 'center', dict: "dlbBroadTaskType"},
|
||||
{prop: 'startDate', label: '开始时间', align: 'center', width: 180},
|
||||
{prop: 'broadcastStatus', label: '状态', align: 'center', dict: "dlbBroadcastStatus"},
|
||||
{prop: 'areaName', label: '地区', align: 'center'},
|
||||
{prop: 'sourceName', label: '媒资名称', width: 200},
|
||||
{prop: 'type', label: '媒资类型', align: 'center', render: (h, {row}) => {
|
||||
return h('span', null, this.dict.getLabel('dlbResourceType',row.type))},
|
||||
},
|
||||
{prop: 'messageLevel', label: '级别', align: 'center', dict: "dlbMessageUrgency"},
|
||||
{prop: 'taskType', label: '播发方式', align: 'center', render: (h, {row}) => {
|
||||
return h('span', null, (row.taskType == 1? '定时播放':'立即播放'))},
|
||||
},
|
||||
{prop: 'startTime', label: '开始时间', align: 'center', width: 180},
|
||||
{prop: 'broadcastStatus', label: '状态', align: 'center',
|
||||
render: (h, { row })=>{
|
||||
return h('span',null, (row.broadcastStatus == 0? '已下发': row.broadcastStatus == 3? '播发成功': row.broadcastStatus == 6? '已取消': ''))
|
||||
}
|
||||
},
|
||||
// {prop: 'areaName', label: '地区', align: 'center'},
|
||||
{prop: 'createUserName', label: '创建人', align: 'center'},
|
||||
{slot: 'options'},
|
||||
],
|
||||
tableData: [],
|
||||
areaId: '',
|
||||
loading: false,
|
||||
}
|
||||
},
|
||||
|
||||
@@ -98,14 +108,15 @@ export default {
|
||||
|
||||
created() {
|
||||
this.areaId = this.user.info.areaId
|
||||
this.dict.load('dlbResourceType', 'dlbMessageUrgency', 'dlbBroadTaskType', 'dlbBroadcastStatus', 'dlbMessageUrgency').then(() => {
|
||||
this.dict.load('dlbDyclingType', 'dlbMessageUrgency', 'dlbBroadTaskType', 'dlbBroadcastStatus', 'dlbMessageUrgency').then(() => {
|
||||
this.getList()
|
||||
this.loading = true
|
||||
})
|
||||
},
|
||||
|
||||
methods: {
|
||||
getList() {
|
||||
this.instance.post(`/app/appzyvideobroadcast/getBroadcastRecords`, null, {
|
||||
this.instance.post(`/app/appzyvideobroadcast/list`, null, {
|
||||
params: {
|
||||
...this.page,
|
||||
...this.search,
|
||||
@@ -115,7 +126,10 @@ export default {
|
||||
if (res.code == 0) {
|
||||
this.tableData = res.data.records
|
||||
this.total = parseInt(res.data.total)
|
||||
this.loading = false
|
||||
}
|
||||
}).catch(() => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
onAdd(id) {
|
||||
@@ -126,8 +140,16 @@ export default {
|
||||
}
|
||||
})
|
||||
},
|
||||
cancel(id) {
|
||||
this.$confirm('确定撤回该广播?').then(() => {
|
||||
toDetail(id) {
|
||||
this.$emit('change', {
|
||||
type: 'detail',
|
||||
params: {
|
||||
id: id || ''
|
||||
}
|
||||
})
|
||||
},
|
||||
reset(id) {
|
||||
this.$confirm('确定要撤回该广播?').then(() => {
|
||||
this.instance.post(`/app/appzyvideobroadcast/getBroadcastRecall?broadcastId=${id}`).then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.$message.success('撤回成功!')
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
|
||||
<script>
|
||||
import List from './components/List'
|
||||
import taskList from './components/taskList'
|
||||
|
||||
export default {
|
||||
label: '广播设备管理',
|
||||
@@ -26,12 +27,13 @@ export default {
|
||||
},
|
||||
|
||||
components: {
|
||||
List
|
||||
List,
|
||||
taskList,
|
||||
},
|
||||
methods: {
|
||||
onChange(data) {
|
||||
if (data.type === 'add') {
|
||||
this.component = 'Add'
|
||||
if (data.type === 'taskList') {
|
||||
this.component = 'taskList'
|
||||
this.params = data.params
|
||||
}
|
||||
|
||||
|
||||
@@ -4,16 +4,13 @@
|
||||
<ai-title slot="title" title="广播设备管理" isShowBottomBorder/>
|
||||
<template #content>
|
||||
<ai-search-bar bottomBorder>
|
||||
<template slot="right">
|
||||
<el-input v-model="search.keyword" size="small" placeholder="设备名称/设备编号" clearable
|
||||
v-throttle="() => {page.current = 1, getList()}"
|
||||
@clear=";(page.current = 1), (search.keyword = ''), getList()" suffix-icon="iconfont iconSearch"/>
|
||||
</template>
|
||||
</ai-search-bar>
|
||||
<ai-search-bar class="ai-search-ba mar-t10">
|
||||
<template slot="left">
|
||||
<!-- <el-button icon="iconfont" type="primary" size="small">数据同步</el-button> -->
|
||||
<!-- <el-button icon="iconfont iconDelete" size="small" @click="removeAll" :disabled="ids.length == 0">删除 </el-button> -->
|
||||
<el-button type="primary" icon="iconfont iconResetting" @click="update" :loading="btnLoading">更新数据</el-button>
|
||||
</template>
|
||||
<template slot="right">
|
||||
<el-input v-model="search.name" size="small" placeholder="设备名称/设备编号" clearable
|
||||
v-throttle="() => {page.current = 1, getList()}"
|
||||
@clear=";(page.current = 1), (search.name = ''), getList()" suffix-icon="iconfont iconSearch"/>
|
||||
</template>
|
||||
</ai-search-bar>
|
||||
<ai-table :tableData="tableData" :col-configs="colConfigs" :total="total" ref="aitableex"
|
||||
@@ -21,9 +18,10 @@
|
||||
@selection-change="(v) => (ids = v.map((e) => e.id))">
|
||||
<el-table-column slot="options" label="操作" align="center" width="280" fixed="right">
|
||||
<template slot-scope="{ row }">
|
||||
<el-button type="text" @click="close(row.id)">停播</el-button>
|
||||
<el-button type="text" @click="bind(row)">绑定行政区划</el-button>
|
||||
<!-- <el-button type="text" @click="locate=true">地图标绘</el-button>-->
|
||||
<!-- <el-button type="text" @click="close(row.id)">停播</el-button> -->
|
||||
<el-button type="text" @click="toTaskList(row.deviceId)">任务列表</el-button>
|
||||
<el-button type="text" @click="bind(row)" >绑定行政区划</el-button>
|
||||
<!-- <el-button type="text" @click="locate=true">地图标绘</el-button>-->
|
||||
</template>
|
||||
</el-table-column>
|
||||
</ai-table>
|
||||
@@ -65,20 +63,21 @@ export default {
|
||||
},
|
||||
total: 0,
|
||||
search: {
|
||||
bind: '',
|
||||
keyword: '',
|
||||
name: '',
|
||||
},
|
||||
id: '',
|
||||
ids: [],
|
||||
colConfigs: [
|
||||
{
|
||||
prop: 'deviceName',
|
||||
prop: 'name',
|
||||
label: '设备名称',
|
||||
width: '200',
|
||||
},
|
||||
{
|
||||
prop: 'areaName',
|
||||
label: '所属行政区划',
|
||||
align: 'center',
|
||||
width: '200',
|
||||
},
|
||||
{
|
||||
prop: 'serialNo',
|
||||
@@ -88,7 +87,7 @@ export default {
|
||||
{
|
||||
prop: 'devStatus',
|
||||
label: '设备状态',
|
||||
width: '100',
|
||||
width: '200',
|
||||
align: 'center',
|
||||
render: (h, {row}) => {
|
||||
return h('span', null, this.dict.getLabel('dlbDevStatus', row.devStatus))
|
||||
@@ -97,10 +96,9 @@ export default {
|
||||
{
|
||||
prop: 'bind',
|
||||
label: '是否绑定区划',
|
||||
width: '120',
|
||||
align: 'center',
|
||||
render: (h, {row}) => {
|
||||
return h('span', null, this.dict.getLabel('yesOrNo', row.bind))
|
||||
return h('span', null, (row.areaId? '是': '否'))
|
||||
},
|
||||
},
|
||||
{
|
||||
@@ -113,6 +111,7 @@ export default {
|
||||
areaId: '',
|
||||
bindVisible: false,
|
||||
changeInfo: {},
|
||||
btnLoading: false,
|
||||
locate: false
|
||||
}
|
||||
},
|
||||
@@ -174,7 +173,7 @@ export default {
|
||||
})
|
||||
},
|
||||
getList() {
|
||||
this.instance.post(`/app/appdlbquipment/getDlbDeviceList`, null, {
|
||||
this.instance.post(`/app/appdlbquipment/list`, null, {
|
||||
params: {
|
||||
...this.page,
|
||||
...this.search,
|
||||
@@ -187,6 +186,32 @@ export default {
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
toTaskList(id) {
|
||||
this.$emit('change', {
|
||||
type: 'taskList',
|
||||
params: {
|
||||
id: id || '',
|
||||
// areaId: this.areaId,
|
||||
},
|
||||
})
|
||||
},
|
||||
update () {
|
||||
this.btnLoading = true
|
||||
this.instance.post(`/app/appdlbquipment/sync`, null, {
|
||||
timeout: 1000000
|
||||
}).then(res => {
|
||||
if (res.code == 0) {
|
||||
this.$message.success('更新成功')
|
||||
this.getList()
|
||||
}
|
||||
|
||||
this.btnLoading = false
|
||||
}).catch(() => {
|
||||
|
||||
this.btnLoading = false
|
||||
})
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
151
packages/device/AppEquipmentManage/components/taskList.vue
Normal file
151
packages/device/AppEquipmentManage/components/taskList.vue
Normal file
@@ -0,0 +1,151 @@
|
||||
<template>
|
||||
<section class="taskList">
|
||||
<ai-list>
|
||||
<ai-title slot="title" title="任务列表" isShowBack isShowBottomBorder @onBackClick="cancel(true)"/>
|
||||
<template #content>
|
||||
<ai-search-bar bottomBorder>
|
||||
<template slot="right">
|
||||
<el-input v-model="search.sourceName" size="small" placeholder="媒资名称/创建人" clearable
|
||||
v-throttle="() => {page.current = 1, getList()}"
|
||||
@clear=";(page.current = 1), (search.sourceName = ''), getList()" suffix-icon="iconfont iconSearch"/>
|
||||
</template>
|
||||
</ai-search-bar>
|
||||
<ai-table :tableData="tableData" :col-configs="colConfigs" :total="page.total" ref="aitableex"
|
||||
:current.sync="page.current" :size.sync="page.size" @getList="getList"
|
||||
@selection-change="(v) => (ids = v.map((e) => e.id))">
|
||||
<el-table-column slot="options" label="操作" align="center" width="280" fixed="right">
|
||||
<template slot-scope="{ row }" v-if="row.taskType == 1 && (row.broadcastStatus == 0 || row.broadcastStatus == 1 || row.broadcastStatus == 2 )">
|
||||
<el-button type="text" @click="reset(row.id)">撤回任务</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</ai-table>
|
||||
</template>
|
||||
</ai-list>
|
||||
</section>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'taskList',
|
||||
components: {},
|
||||
props: {
|
||||
dict: Object,
|
||||
instance: Function,
|
||||
params: Object,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
page: {
|
||||
current: 1,
|
||||
size: 10,
|
||||
total: 0,
|
||||
},
|
||||
search: {
|
||||
sourceName: '',
|
||||
},
|
||||
tableData: [],
|
||||
colConfigs: [
|
||||
{
|
||||
prop: 'sourceName',
|
||||
label: '任务名称',
|
||||
},
|
||||
{
|
||||
prop: 'type',
|
||||
label: '媒资类型',
|
||||
width: '200',
|
||||
align: 'center',
|
||||
render: (h, { row })=>{
|
||||
return h('span',null,this.dict.getLabel('dlbResourceType',row.type))
|
||||
}
|
||||
},
|
||||
{
|
||||
prop: 'messageLevel',
|
||||
label: '级别',
|
||||
align: 'center',
|
||||
render: (h, { row })=>{
|
||||
return h('span',null,this.dict.getLabel('dlbMessageUrgency',row.messageLevel))
|
||||
}
|
||||
},
|
||||
{
|
||||
prop: 'taskType',
|
||||
label: '播发方式',
|
||||
width: '220',
|
||||
align: 'center',
|
||||
render: (h, {row}) => {
|
||||
return h('span', null, (row.taskType == 1? '定时播放':'立即播放'))
|
||||
},
|
||||
},
|
||||
{
|
||||
prop: 'startTime',
|
||||
label: '开始时间',
|
||||
width: '120',
|
||||
align: 'center',
|
||||
},
|
||||
{
|
||||
prop: 'broadcastStatus',
|
||||
label: '状态',
|
||||
align: 'center',
|
||||
render: (h, { row })=>{
|
||||
return h('span',null, (row.broadcastStatus == 0? '已下发': row.broadcastStatus == 3? '播发成功': row.broadcastStatus == 6? '已取消': ''))
|
||||
}
|
||||
},
|
||||
{
|
||||
prop: 'createUserName',
|
||||
label: '创建人',
|
||||
align: 'center',
|
||||
},
|
||||
{
|
||||
slot: 'options',
|
||||
label: '操作',
|
||||
align: 'center',
|
||||
},
|
||||
],
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.$dict.load('dlbDyclingType','dlbMessageUrgency','dlbBroadcastStatus','dlbResourceType').then(()=>{
|
||||
this.getList()
|
||||
})
|
||||
},
|
||||
|
||||
methods: {
|
||||
getList() {
|
||||
this.instance.post(`/app/appzyvideobroadcast/list?deviceId`,null,{
|
||||
params: {
|
||||
...this.page,
|
||||
...this.search,
|
||||
deviceId: this.params.deviceId
|
||||
}
|
||||
}).then(res=>{
|
||||
if(res?.data) {
|
||||
this.tableData = res.data.records
|
||||
this.page.total = res.data.total
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
reset(id) {
|
||||
this.$confirm('确定要撤回该任务吗?').then(() => {
|
||||
this.instance.post(`/app/appzyvideobroadcast/getBroadcastRecall?broadcastId=${id}`).then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.$message.success('撤回成功!')
|
||||
this.getList()
|
||||
}
|
||||
})
|
||||
})
|
||||
},
|
||||
cancel(isRefresh) {
|
||||
this.$emit('change', {
|
||||
type: 'list',
|
||||
isRefresh: !!isRefresh,
|
||||
})
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.taskList {
|
||||
height: 100%;
|
||||
}
|
||||
</style>
|
||||
@@ -32,13 +32,46 @@
|
||||
</el-table-column>
|
||||
<el-table-column slot="options" label="操作" align="center" width="180" fixed="right">
|
||||
<div class="table-options" slot-scope="{ row }">
|
||||
<el-button type="text" @click="play(row.id)">播发</el-button>
|
||||
<!-- play(row.id) -->
|
||||
<el-button type="text" @click="getItemInfo(row.id)">播发</el-button>
|
||||
<el-button type="text" @click="remove(row.id)">删除</el-button>
|
||||
</div>
|
||||
</el-table-column>
|
||||
</ai-table>
|
||||
</template>
|
||||
</ai-list>
|
||||
|
||||
<ai-dialog
|
||||
title="广播播发"
|
||||
:visible.sync="detailDialog"
|
||||
:customFooter="true"
|
||||
:destroyOnClose="true"
|
||||
width="780px">
|
||||
<ai-detail style="background: #FFF;">
|
||||
<template #content>
|
||||
<div class="audios">
|
||||
<ai-audio :src="info.url" skin="flat"/>
|
||||
</div>
|
||||
<ai-wrapper style="margin-top: 30px;">
|
||||
<ai-info-item label="媒资名称" :value="info.name"></ai-info-item>
|
||||
<!-- <ai-info-item label="状态">{{ $dict.getLabel('dlbDevStatus', info.devStatus) }}</ai-info-item> -->
|
||||
<ai-info-item label="媒资类型">{{$dict.getLabel('dlbResourceType', info.type)}}</ai-info-item>
|
||||
<ai-info-item label="创建时间" :value="info.createTime"></ai-info-item>
|
||||
<ai-info-item label="内容" class="contentBox" v-if="info.type == 3" isLine>
|
||||
<div class="content">
|
||||
{{ info.content }}
|
||||
</div>
|
||||
</ai-info-item>
|
||||
</ai-wrapper>
|
||||
</template>
|
||||
</ai-detail>
|
||||
|
||||
<div class="dialog-footer" slot="footer">
|
||||
<el-button @click="detailDialog=false" size="medium">关闭</el-button>
|
||||
<el-button @click="play(info.id)" type="primary" size="medium">新建广播</el-button>
|
||||
</div>
|
||||
</ai-dialog>
|
||||
|
||||
</section>
|
||||
</template>
|
||||
|
||||
@@ -82,9 +115,9 @@ export default {
|
||||
return h('span', null, this.dict.getLabel('dlbResourceType', row.type))
|
||||
},
|
||||
},
|
||||
{
|
||||
slot: 'content',
|
||||
},
|
||||
// {
|
||||
// slot: 'content',
|
||||
// },
|
||||
{prop: 'createTime', label: '创建时间', align: 'center'},
|
||||
{
|
||||
prop: 'createUserName',
|
||||
@@ -101,6 +134,8 @@ export default {
|
||||
],
|
||||
tableData: [],
|
||||
areaId: '',
|
||||
detailDialog: false,
|
||||
info: {},
|
||||
}
|
||||
},
|
||||
|
||||
@@ -115,15 +150,14 @@ export default {
|
||||
},
|
||||
},
|
||||
created() {
|
||||
this.dict.load('dlbResourceType').then(() => {
|
||||
this.dict.load('dlbResourceType','dlbDevStatus').then(() => {
|
||||
this.getList()
|
||||
})
|
||||
},
|
||||
|
||||
methods: {
|
||||
getList() {
|
||||
this.instance
|
||||
.post(`/app/appdlbresource/list`, null, {
|
||||
this.instance.post(`/app/appdlbresource/list`, null, {
|
||||
params: {
|
||||
...this.page,
|
||||
...this.search,
|
||||
@@ -137,7 +171,17 @@ export default {
|
||||
})
|
||||
},
|
||||
|
||||
getItemInfo (id) {
|
||||
this.instance.post(`/app/appdlbresource/queryDetailById?id=${id}`).then(res => {
|
||||
if (res?.data) {
|
||||
this.info = res.data
|
||||
this.detailDialog = true
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
play (id) {
|
||||
this.detailDialog = false
|
||||
this.$emit('change', {
|
||||
type: 'Play',
|
||||
params: {
|
||||
@@ -184,5 +228,18 @@ export default {
|
||||
.mar-t10 {
|
||||
margin-top: 10px;
|
||||
}
|
||||
.audios {
|
||||
padding-left: 40px;
|
||||
}
|
||||
|
||||
::v-deep .ai-info-item__right {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.content {
|
||||
width: 100%;
|
||||
height: 200px;
|
||||
overflow-y: auto;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,23 +1,23 @@
|
||||
<template>
|
||||
<ai-detail>
|
||||
<ai-detail class="Play">
|
||||
<template #title>
|
||||
<ai-title title="添加广播" isShowBack isShowBottomBorder @onBackClick="cancel(false)"></ai-title>
|
||||
</template>
|
||||
<template #content>
|
||||
<ai-card title="基础信息">
|
||||
<template #content>
|
||||
<el-alert title="温馨提示:请先选择行政区划,再选择播放设备!" type="warning" show-icon :closable="false" style="margin-bottom: 12px;padding: 4px 20px;"></el-alert>
|
||||
<el-form class="ai-form" :model="formData" :rules="formRules" ref="ruleForm" label-width="120px">
|
||||
<el-form-item label="播发内容" prop="mediaId">
|
||||
<ai-select v-model="formData.mediaId" placeholder="播发内容" clearable :selectList="mediaList"></ai-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="播放设备" prop="serialNo">
|
||||
<ai-select v-model="formData.serialNo" placeholder="播放设备" clearable
|
||||
:selectList="equipmentList"></ai-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="播发级别" prop="messageLevel">
|
||||
<ai-select v-model="formData.messageLevel" placeholder="播发级别" clearable
|
||||
:selectList="$dict.getDict('dlbMessageUrgency')"></ai-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="设备行政区划">
|
||||
<ai-area-get v-model="areaId" :root="areaRootId" :instance="instance" @select="handleAreaSelect" size="small" placeholder="请选择行政区划"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="播放方式" prop="taskType" class="buildingTypes">
|
||||
<el-radio-group v-model="formData.taskType">
|
||||
<el-radio label="0">立即播放</el-radio>
|
||||
@@ -58,6 +58,10 @@
|
||||
:picker-options="{ start: formData.startTime, minTime: formData.startTime}"
|
||||
value-format="HH:mm:ss"></el-time-picker>
|
||||
</el-form-item>
|
||||
<el-form-item label="播放设备" v-if="areaId" prop="serialNo" style="width: 100%;">
|
||||
<ai-table-select nodeName="name" :instance="instance" extra="serialNo" searchKey="name" :action="`/app/appdlbquipment/list?devStatus=5&areaId=${areaId}`"
|
||||
@select="v => formData.serialNo = v.map(e=> e.serialNo).toString()" multiple/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</template>
|
||||
</ai-card>
|
||||
@@ -123,6 +127,9 @@ export default {
|
||||
mediaId: [
|
||||
{required: true, message: '请选择播发内容', trigger: 'change'}
|
||||
],
|
||||
areaId: [
|
||||
{required: true, message: '请选择行政区划', trigger: 'change'}
|
||||
],
|
||||
serialNo: [
|
||||
{required: true, message: '请选择播放设备', trigger: 'change'}
|
||||
],
|
||||
@@ -151,8 +158,20 @@ export default {
|
||||
{required: true, message: '播放天数', trigger: 'change'}
|
||||
],
|
||||
},
|
||||
areaRootId: '',
|
||||
mediaList: [],
|
||||
equipmentList: []
|
||||
equipmentList: [],
|
||||
detailDialog: false,
|
||||
isAll: false,
|
||||
input3: '',
|
||||
defaultProps: {
|
||||
children: 'children',
|
||||
label: 'label'
|
||||
},
|
||||
serialNoList: [],
|
||||
areaId: '',
|
||||
areaName: '',
|
||||
userAreaId: '',
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
@@ -166,13 +185,26 @@ export default {
|
||||
return myDate.getHours() + ':' + myDate.getMinutes() + ':' + myDate.getSeconds()
|
||||
}
|
||||
},
|
||||
|
||||
watch: {
|
||||
userAreaId: {
|
||||
handler: function(v) {
|
||||
this.areaRootId = [v?.substr(0,6),'000000'].join("")
|
||||
},
|
||||
deep: true
|
||||
}
|
||||
},
|
||||
|
||||
created() {
|
||||
this.dict.load('dlbMessageUrgency', 'dlbBroadTaskType', 'dlbDyclingType')
|
||||
Promise.all([this.getEquipmentList(), this.getMediaList()]).then(() => {
|
||||
this.formData.mediaId = this.params.id
|
||||
this.userAreaId = this.user.info.areaId
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
// 选择设备
|
||||
getSelect() {},
|
||||
getMediaList() {
|
||||
return this.instance.post(`/app/appdlbresource/list?current=1&size=10000`).then((res) => {
|
||||
if (res?.data) {
|
||||
@@ -193,7 +225,16 @@ export default {
|
||||
}
|
||||
})
|
||||
},
|
||||
// 地区选择
|
||||
handleAreaSelect(v) {
|
||||
this.areaName = v?.[0]?.label
|
||||
},
|
||||
|
||||
// 播放
|
||||
confirm() {
|
||||
if(!this.areaId) {
|
||||
this.$message.error('请选择所要播放设备的行政区划!')
|
||||
}
|
||||
this.$refs['ruleForm'].validate((valid) => {
|
||||
if (valid) {
|
||||
if (this.formData.checkList.length) {
|
||||
@@ -250,5 +291,52 @@ export default {
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.Play {
|
||||
.equipment {
|
||||
position: relative;
|
||||
.select {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.equipments {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
height: 32px;
|
||||
align-items: center;
|
||||
border-radius: 4px;
|
||||
border: 1px solid #DDD;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.container {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
.item {
|
||||
flex: 1;
|
||||
display: inline-block;
|
||||
height: auto;
|
||||
border: 1px solid #DDD;
|
||||
.title {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
padding: 10px;
|
||||
box-sizing: border-box;
|
||||
height: 50px;
|
||||
align-items: center;
|
||||
border-bottom: 1px solid #DDD;
|
||||
.checkBox {
|
||||
align-self: center;
|
||||
}
|
||||
}
|
||||
.content {
|
||||
padding: 10px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<section class="AppISManage">
|
||||
<device-slider :permissions="permissions" :show.sync="slider" :ins="instance" :dict="dict" @treeCommand="handleSliderOption" @select="handleSelectMonitor" :render-item="renderTreeItem" ref="DeviceSlider" />
|
||||
<device-slider :permissions="permissions" :show.sync="slider" :instance="instance" :dict="dict" @treeCommand="handleSliderOption" @select="handleSelectMonitor" :render-item="renderTreeItem" ref="DeviceSlider" />
|
||||
<div class="monitorPane" v-loading="isLoading" element-loading-background="rgba(0, 0, 0, 0.6)">
|
||||
<div class="headerBar">
|
||||
<el-select default-first-option size="small" v-model="splitScreen" @change="onChange">
|
||||
@@ -54,8 +54,7 @@
|
||||
splitOps() {
|
||||
return [
|
||||
{ label: '单分屏', value: 1, per: '100%' },
|
||||
{ label: '四分屏', value: 4, per: '49.2%' },
|
||||
{ label: '九分屏', value: 9, per: '32%' },
|
||||
{ label: '四分屏', value: 4, per: '49.2%' }
|
||||
]
|
||||
},
|
||||
currentSplitStyle() {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<section class="AppISMap">
|
||||
<device-slider :show.sync="slider" :ins="instance" :dict="dict" @list="v=>list=v" @select="markerClickEvent"/>
|
||||
<device-slider :show.sync="slider" :instance="instance" :dict="dict" @list="v=>list=v" @select="markerClickEvent"/>
|
||||
<div id="amap"/>
|
||||
<div ref="selectedInfoWin" class="selected">
|
||||
<b>{{ selected.deviceName }}</b>
|
||||
|
||||
@@ -22,7 +22,10 @@
|
||||
prefix-icon="el-icon-search"
|
||||
@clear="search.name = '', handleTreeFilter()" clearable/>
|
||||
</div>
|
||||
<div title>设备列表</div>
|
||||
<div title>
|
||||
<div>设备列表</div>
|
||||
<el-button type="text" icon="iconfont iconResetting" @click="updateDev" size="mini" :loading="btnLoading">刷新</el-button>
|
||||
</div>
|
||||
<div fill class="deviceList">
|
||||
<el-tree ref="deviceTree" highlight-current :render-content="renderItem" :data="treeData" :props="propsConfig"
|
||||
@node-click="handleNodeClick" @node-contextmenu="nodeContextmenu"
|
||||
@@ -48,10 +51,10 @@ export default {
|
||||
name: "deviceSlider",
|
||||
props: {
|
||||
show: Boolean,
|
||||
ins: Function,
|
||||
instance: Function,
|
||||
dict: Object,
|
||||
permissions: Function,
|
||||
renderItem: Function
|
||||
renderItem: Function,
|
||||
},
|
||||
computed: {
|
||||
overview() {
|
||||
@@ -98,7 +101,8 @@ export default {
|
||||
x: '',
|
||||
y: '',
|
||||
node: {}
|
||||
}
|
||||
},
|
||||
btnLoading: false,
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
@@ -110,8 +114,10 @@ export default {
|
||||
this.isShowMenu = false
|
||||
},
|
||||
getDevices() {
|
||||
this.ins.post("/app/appzyvideoequipment/tree", null, {
|
||||
params: {size: 999}
|
||||
this.instance.post(`/app/appzyvideoequipment/tree`, null, {
|
||||
params: {
|
||||
size: 999
|
||||
}
|
||||
}).then(res => {
|
||||
if (res?.data) {
|
||||
this.staData = res.data.count
|
||||
@@ -122,6 +128,21 @@ export default {
|
||||
})
|
||||
},
|
||||
|
||||
updateDev() {
|
||||
this.btnLoading = true
|
||||
this.instance.post(`/app/appzyvideoequipment/sync`, null, {
|
||||
timeout: 1000000
|
||||
}).then(res => {
|
||||
if (res.code == 0) {
|
||||
this.$message.success('更新成功')
|
||||
this.getDevices()
|
||||
}
|
||||
this.btnLoading = false
|
||||
}).catch(() => {
|
||||
this.btnLoading = false
|
||||
})
|
||||
},
|
||||
|
||||
handleTreeCommand(e, node) {
|
||||
this.$emit('treeCommand', {
|
||||
type: e,
|
||||
@@ -154,14 +175,16 @@ export default {
|
||||
handleTreeFilter() {
|
||||
this.$refs.deviceTree?.filter(this.search.name)
|
||||
},
|
||||
|
||||
onChange() {
|
||||
this.$refs.deviceTree?.filter(this.search.name)
|
||||
}
|
||||
},
|
||||
|
||||
},
|
||||
|
||||
created() {
|
||||
this.dict.load("deviceStatus")
|
||||
this.getDevices()
|
||||
this.$dict.load("deviceStatus").then(()=>{
|
||||
this.getDevices()
|
||||
})
|
||||
},
|
||||
|
||||
mounted() {
|
||||
@@ -247,6 +270,18 @@ export default {
|
||||
background: #3E4A69;
|
||||
padding: 0 16px;
|
||||
line-height: 28px;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
||||
::v-deep .el-button {
|
||||
padding: 0 4px;
|
||||
height: 28px;
|
||||
background: #3E4A69;
|
||||
}
|
||||
::v-deep .el-button:hover {
|
||||
border: none;
|
||||
}
|
||||
}
|
||||
|
||||
::v-deep.deviceList {
|
||||
@@ -278,8 +313,8 @@ export default {
|
||||
.el-tree-node__content {
|
||||
background: transparent!important;
|
||||
}
|
||||
|
||||
.el-tree-node__children .is-current .el-tree-node__content {
|
||||
|
||||
.el-tree-node__children .is-current > .el-tree-node__content {
|
||||
background: linear-gradient(90deg, #299FFF 0%, #0C61FF 100%)!important;
|
||||
}
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@
|
||||
<template slot-scope="{ row }">
|
||||
<div class="table-options">
|
||||
<el-button type="text" @click="toAdd(row.id)">编辑</el-button>
|
||||
<el-button type="text" @click="$router.push({name: '监护地图', query: {id: row.id, lat: row.lat, lng: row.lng}})">地图查看</el-button>
|
||||
<el-button type="text" @click="$router.push({name: '12ed7dcf13014bf0b2bbffa7d0238e0b', query: {id: row.id, lat: row.lat, lng: row.lng}})">地图查看</el-button>
|
||||
<el-button type="text" @click="toMonitor(row.id)">监测数据</el-button>
|
||||
<el-button type="text" @click="remove(row.id)">删除</el-button>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user