jsmapChange&bigScreen

This commit is contained in:
shijing 2022-07-04 17:17:12 +08:00
parent 57f192e39b
commit d0fa208280
12 changed files with 1267 additions and 259 deletions

BIN
public/img/alarm_bg.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.4 KiB

BIN
public/img/b_quiet.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 617 B

BIN
public/img/b_ring.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 319 B

BIN
public/img/car.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 714 B

BIN
public/img/rotate_line.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 803 B

BIN
public/img/round.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 215 B

BIN
public/img/speaker.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

BIN
public/img/user.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 742 B

File diff suppressed because one or more lines are too long

View File

@ -9,25 +9,34 @@
</div>
</el-header>
<el-main class="nopadding">
<scTable ref="table" :apiObj="apiObj" row-key="id" @selection-change="selectionChange" stripe @resetQuery="resetQuery" >
<scTable ref="table" :apiObj="apiObj" row-key="id" @selection-change="selectionChange" stripe
@resetQuery="resetQuery">
<el-table-column type="selection" width="50"></el-table-column>
<el-table-column label="序号" type="index" width="50"></el-table-column>
<el-table-column label="设备编号" prop="deviceCode" min-width="100"></el-table-column>
<el-table-column label="通道编号" prop="channelCode" min-width="100"></el-table-column>
<el-table-column label="通道名称" prop="channelName" min-width="150"></el-table-column>
<el-table-column label="通道状态" prop="stat" min-width="150"></el-table-column>
<el-table-column label="通道类型" min-width="100">
<template #default="scope">{{scope.row.channelType}}</template>
<el-table-column label="通道状态" prop="stat" min-width="150">
<template #default="scope">
<span v-if="scope.row.stat===0">不启用</span>
<span v-else>启用</span>
</template>
</el-table-column>
<el-table-column label="设备类型" min-width="100">
<template #default="scope">{{scope.row.cameraType}}</template>
<el-table-column label="摄像头类型" min-width="100">
<template #default="scope">{{deviceTypes[scope.row.cameraType]}}</template>
</el-table-column>
<el-table-column label="是否在线" prop="isOnline" min-width="180"></el-table-column>
<el-table-column label="创建时间" prop="createTime" width="160"></el-table-column>
<el-table-column label="操作" fixed="right" align="center" width="160">
<el-table-column label="是否在线" prop="isOnline" min-width="180">
<template #default="scope">
<span v-if="scope.row.isOnline===0">离线</span>
<span v-else>在线</span>
</template>
</el-table-column>
<el-table-column label="创建时间" prop="createTime" min-width="160"></el-table-column>
<el-table-column label="操作" fixed="right" align="center" width="260">
<template #default="scope">
<el-button-group>
<el-button text type="primary" size="small" @click="handlePosition(scope.row)">标记位置</el-button>
<el-button text type="primary" size="small" @click="handlePosition(scope.row)">标记位置
</el-button>
<el-button text type="primary" size="small" @click="handleView(scope.row)">实时监控</el-button>
<el-popconfirm title="确定删除吗?" @confirm="handleDel(scope.row, scope.$index)">
<template #reference>
@ -53,14 +62,16 @@
<el-button @click="limitedVisible = false">关闭</el-button>
</template>
</el-dialog>
<video-channel-view v-if="dialogSave" ref="saveDialog" :channelType="60" :channelCode="channelCode" :channelName="channelName" @closed="dialogSave=false"></video-channel-view>
<channel-view v-if="dialogSave" ref="saveDialog" :channelType="60" :channelCode="channelCode"
:channelName="channelName" @closed="dialogSave=false"></channel-view>
</template>
<script>
import videoChannelView from './vchannel_view'
import channelView from './vchannel_view'
export default {
name: 'monitor',
components: {
videoChannelView
channelView
},
data() {
return {
@ -72,23 +83,27 @@
search: {
keyword: null
},
channelId:'',
params:{
json:{
channelId: '',
params: {
json: {
data: {
channelId: "",
streamType: "2",
type: "flv"
}
},
code:'video_realtime'
code: 'video_realtime'
},
deviceTypes: {
'1': '枪机',
'2': '球机',
'3': '半球'
}
}
},
created(){
created() {
const scriptInfo = document.createElement("script");
scriptInfo.setAttribute("data-callType","callScript");
scriptInfo.setAttribute("data-callType", "callScript");
scriptInfo.src = "https://cdn.bootcdn.net/ajax/libs/flv.js/1.6.2/flv.js";
document.head.appendChild(scriptInfo)
},
@ -97,7 +112,7 @@
this.params.json.data.channelId = row.channelCode;
this.channelName = row.channelName;
this.limitedVisible = true;
this.$API.am.video.item.req(this.params).then(res=>{
this.$API.am.video.item.req(this.params).then(res => {
debugger;
console.log(res);
this.url = res.url;
@ -113,17 +128,17 @@
}
})
},
handlePosition(row){
handlePosition(row) {
this.channelCode = row.channelCode;
this.channelName = row.channelName;
this.dialogSave = true;
},
//
async handleDel(row){
await this.$API.am.area.delete.req(row.id).then(res=>{
if(res.err_msg){
async handleDel(row) {
await this.$API.am.area.delete.req(row.id).then(res => {
if (res.err_msg) {
this.$message.error(res.err_msg);
}else{
} else {
this.$refs.table.refresh();
this.$message.success("删除成功")
}
@ -131,17 +146,17 @@
},
//
async batch_del(){
async batch_del() {
this.$confirm(`确定删除选中的 ${this.selection.length} 项吗?如果删除项中含有子集将会被一并删除`, '提示', {
type: 'warning'
}).then(() => {
const loading = this.$loading();
let params = {pk:{pks:this.selection}};
this.$API.am.area.deletes.req(params).then(res=>{
let params = {pk: {pks: this.selection}};
this.$API.am.area.deletes.req(params).then(res => {
loading.close();
if(res.err_msg){
if (res.err_msg) {
this.$message.error(res.err_msg);
}else{
} else {
this.$refs.table.refresh();
this.$message.success("删除成功")
}
@ -150,17 +165,17 @@
})
},
//
selectionChange(selection){
selectionChange(selection) {
this.selection = selection;
},
//
upsearch(){
upsearch() {
},
resetQuery(){
resetQuery() {
this.query = {}
}
}

View File

@ -200,6 +200,7 @@
that.form.location = pixel;*/
this.form.code = this.channelCode;
this.form.type = this.channelType;
this.form.name = this.channelName;
that.$API.am.tdevice.labelLocation.req(that.form)
.then(res => {
that.isSaveing = false;

File diff suppressed because it is too large Load Diff