新增点逻辑修改
This commit is contained in:
parent
8d28121e78
commit
236dc9fde4
|
@ -26,13 +26,21 @@
|
||||||
<!-- <el-form-item > -->
|
<!-- <el-form-item > -->
|
||||||
<el-button v-if="false" type="primary" @click="handleagain()" size="small" style="width: 150px">重置</el-button>
|
<el-button v-if="false" type="primary" @click="handleagain()" size="small" style="width: 150px">重置</el-button>
|
||||||
<div class="warning" style="margin-top:15px" @click="handleContent('postion')">
|
<div class="warning" style="margin-top:15px" @click="handleContent('postion')">
|
||||||
<i :class="contentShow.postion==false?'el-icon-arrow-right':'el-icon-arrow-down'" style="font-weight: 600;font-size: 18px;margin-right: 5px;" ></i>
|
<i
|
||||||
|
:class="contentShow.postion == false ? 'el-icon-arrow-right' : 'el-icon-arrow-down'"
|
||||||
|
style="font-weight: 600;font-size: 18px;margin-right: 5px;"
|
||||||
|
></i>
|
||||||
<p class="board-title">相机位置</p>
|
<p class="board-title">相机位置</p>
|
||||||
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i> 在 WGS84 坐标系中输入相机位置
|
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i> 在 WGS84 坐标系中输入相机位置
|
||||||
</div>
|
</div>
|
||||||
<el-form-item label="相机位置:" v-if="contentShow.postion">
|
<el-form-item label="相机位置:" v-if="contentShow.postion">
|
||||||
<el-input v-model="sizeForm.longitude" size="small" style="width: 150px" placeholder="经度"></el-input>
|
<el-input v-model="sizeForm.longitude" size="small" style="width: 150px" placeholder="经度"></el-input>
|
||||||
<el-input v-model="sizeForm.latitude" size="small" style="width: 150px; margin-left: 20px" placeholder="纬度"></el-input>
|
<el-input
|
||||||
|
v-model="sizeForm.latitude"
|
||||||
|
size="small"
|
||||||
|
style="width: 150px; margin-left: 20px"
|
||||||
|
placeholder="纬度"
|
||||||
|
></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<div style="margin-top: 15px" v-if="contentShow.postion">
|
<div style="margin-top: 15px" v-if="contentShow.postion">
|
||||||
|
@ -43,7 +51,10 @@
|
||||||
<div class="dataBoard">
|
<div class="dataBoard">
|
||||||
<div class="section">
|
<div class="section">
|
||||||
<div class="warning" @click="handleContent('coordinate')">
|
<div class="warning" @click="handleContent('coordinate')">
|
||||||
<i :class="contentShow.coordinate==false?'el-icon-arrow-right':'el-icon-arrow-down'" style="font-weight: 600;font-size: 18px;margin-right: 5px;" ></i>
|
<i
|
||||||
|
:class="contentShow.coordinate == false ? 'el-icon-arrow-right' : 'el-icon-arrow-down'"
|
||||||
|
style="font-weight: 600;font-size: 18px;margin-right: 5px;"
|
||||||
|
></i>
|
||||||
<p class="board-title">坐标转换</p>
|
<p class="board-title">坐标转换</p>
|
||||||
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i
|
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i
|
||||||
>通过将图像坐标系转换为物理坐标系,地理参考使您能够将像素测量转换为真实速度和距离。
|
>通过将图像坐标系转换为物理坐标系,地理参考使您能够将像素测量转换为真实速度和距离。
|
||||||
|
@ -53,64 +64,70 @@
|
||||||
<el-switch v-model="coordinateForm.coordinateClose"></el-switch>
|
<el-switch v-model="coordinateForm.coordinateClose"></el-switch>
|
||||||
</el-form-item> -->
|
</el-form-item> -->
|
||||||
<el-form-item label="UTM区:" class="otherThings">
|
<el-form-item label="UTM区:" class="otherThings">
|
||||||
<el-input-number v-model="coordinateForm.num" controls-position="right" :precision="0" size="small" :min="1" :max="60"></el-input-number>
|
<el-input-number
|
||||||
|
v-model="coordinateForm.num"
|
||||||
|
controls-position="right"
|
||||||
|
:precision="0"
|
||||||
|
size="small"
|
||||||
|
:min="1"
|
||||||
|
:max="60"
|
||||||
|
></el-input-number>
|
||||||
<div class="warning" style="margin:0px">
|
<div class="warning" style="margin:0px">
|
||||||
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i
|
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i
|
||||||
>地理参照允许测量物理速度和静态图像源的距离,值范围1-60。
|
>地理参照允许测量物理速度和静态图像源的距离,值范围1-60。
|
||||||
</div>
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="半球:" >
|
<el-form-item label="半球:">
|
||||||
<el-select size="small" v-model="coordinateForm.value" placeholder="请选择">
|
<el-select size="small" v-model="coordinateForm.value" placeholder="请选择">
|
||||||
<el-option
|
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"> </el-option>
|
||||||
v-for="(item) in options"
|
|
||||||
:key="item.value"
|
|
||||||
:label="item.label"
|
|
||||||
:value="item.value">
|
|
||||||
</el-option>
|
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="坐标转换:" >
|
<el-form-item label="坐标转换:">
|
||||||
<el-radio-group v-model="coordinateForm.coordinateTransformation">
|
<el-radio-group v-model="coordinateForm.coordinateTransformation">
|
||||||
<el-radio label="WGS-84坐标系"></el-radio>
|
<el-radio label="WGS-84坐标系"></el-radio>
|
||||||
<el-radio label="其他"></el-radio>
|
<el-radio label="其他"></el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<div style="width: 100%; height: 702px; margin-bottom: 10px" >
|
<div style="width: 100%; height: 702px; margin-bottom: 10px">
|
||||||
<iframe
|
<iframe ref="analysisWeb" src="./analysisWeb/index.html" frameborder="0" style="width: 100%; height: 100%"></iframe>
|
||||||
ref="analysisWeb"
|
|
||||||
src="./analysisWeb/index.html"
|
|
||||||
frameborder="0"
|
|
||||||
style="width: 100%; height: 100%"
|
|
||||||
></iframe>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="warning">
|
<div class="warning">
|
||||||
<el-button
|
<el-button size="mini" type="primary" style="color: #fffff" @click="handleDian">新增点 </el-button>
|
||||||
size="mini"
|
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i>请至少配置4个点,不满足4个点会没有数据。
|
||||||
type="primary"
|
|
||||||
style="color: #fffff"
|
|
||||||
@click="dialogVisible = true"
|
|
||||||
>新增点
|
|
||||||
</el-button>
|
|
||||||
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i
|
|
||||||
>请至少配置4个点,不满足4个点会没有数据。
|
|
||||||
</div>
|
</div>
|
||||||
<el-table border :data="coordinateTableData" >
|
<el-table border :data="coordinateTableData">
|
||||||
<template slot="empty">
|
<template slot="empty">
|
||||||
<el-empty :image-size="100" description='暂无数据'></el-empty>
|
<el-empty :image-size="100" description="暂无数据"></el-empty>
|
||||||
</template>
|
</template>
|
||||||
<el-table-column prop="pointName" label="点名称" align="center">
|
<el-table-column prop="pointName" label="点名称" align="center">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-input :disabled="scope.row.btnShow == '1'?true:false" v-model="scope.row.pointName" maxlength="30" placeholder="请输入" @blur="updateName($event)"/>
|
<el-input
|
||||||
|
:disabled="scope.row.btnShow == '1' ? true : false"
|
||||||
|
v-model="scope.row.pointName"
|
||||||
|
maxlength="30"
|
||||||
|
placeholder="请输入"
|
||||||
|
@blur="updateName($event)"
|
||||||
|
/>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="longitude" label="经度" align="center">
|
<el-table-column prop="longitude" label="经度" align="center">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-input :disabled="scope.row.btnShow == '1'?true:false" v-model="scope.row.longitude" maxlength="20" placeholder="请输入" />
|
<el-input
|
||||||
|
:disabled="scope.row.btnShow == '1' ? true : false"
|
||||||
|
v-model="scope.row.longitude"
|
||||||
|
maxlength="20"
|
||||||
|
placeholder="请输入"
|
||||||
|
/>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="latitude" label="纬度" align="center">
|
<el-table-column prop="latitude" label="纬度" align="center">
|
||||||
<template slot-scope="scope">
|
<template v-slot="{ row, $index }">
|
||||||
<el-input :disabled="scope.row.btnShow == '1'?true:false" v-model="scope.row.latitude" maxlength="20" placeholder="请输入" />
|
<el-input
|
||||||
|
:disabled="row.btnShow == '1' ? true : false"
|
||||||
|
v-model="row.latitude"
|
||||||
|
maxlength="20"
|
||||||
|
placeholder="请输入"
|
||||||
|
/>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="oldName" label="旧名字" align="center" v-if="laneform.laneClose == true">
|
<el-table-column prop="oldName" label="旧名字" align="center" v-if="laneform.laneClose == true">
|
||||||
|
@ -119,28 +136,19 @@
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||||
<template slot-scope="scope">
|
<template v-slot="{ row, $index }">
|
||||||
<el-button
|
<el-button
|
||||||
size="mini"
|
size="mini"
|
||||||
type="text"
|
type="text"
|
||||||
style="color: #2090c1"
|
style="color: #2090c1"
|
||||||
v-if="scope.row.btnShow == '1'?true:false"
|
v-if="row.btnShow == '1' ? true : false"
|
||||||
@click="handleExit(scope.row,scope.$index)"
|
@click="handleExit(row, $index)"
|
||||||
>编辑
|
>编辑
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button size="mini" type="text" style="color: #2090c1" v-else @click="handleconfirm(row, $index)"
|
||||||
size="mini"
|
|
||||||
type="text"
|
|
||||||
style="color: #2090c1"
|
|
||||||
v-else
|
|
||||||
@click="handleconfirm(scope.row,scope.$index)"
|
|
||||||
>确认编辑
|
>确认编辑
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button size="mini" type="text" style="color: #f56c6c" @click="handleDeleteDian(row, $index)"
|
||||||
size="mini"
|
|
||||||
type="text"
|
|
||||||
style="color: #f56c6c"
|
|
||||||
@click="handleDeleteDian(scope.row)"
|
|
||||||
>删除
|
>删除
|
||||||
</el-button>
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
|
@ -149,7 +157,7 @@
|
||||||
<div style="margin-top: 15px">
|
<div style="margin-top: 15px">
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
:disabled="coordinateTableData.length<4"
|
:disabled="coordinateTableData.length < 4"
|
||||||
@click="handlePos()"
|
@click="handlePos()"
|
||||||
size="small"
|
size="small"
|
||||||
style="width: 150px"
|
style="width: 150px"
|
||||||
|
@ -176,11 +184,7 @@
|
||||||
<el-form-item label="各车道中心线(区域检测器):" style="width: 300px" v-if="laneform.laneClose == true">
|
<el-form-item label="各车道中心线(区域检测器):" style="width: 300px" v-if="laneform.laneClose == true">
|
||||||
<el-switch v-model="laneform.areaDetector"></el-switch>
|
<el-switch v-model="laneform.areaDetector"></el-switch>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item label="自动识别各车道中心点坐标(断面检测器):" style="width: 300px" v-if="laneform.laneClose == true">
|
||||||
label="自动识别各车道中心点坐标(断面检测器):"
|
|
||||||
style="width: 300px"
|
|
||||||
v-if="laneform.laneClose == true"
|
|
||||||
>
|
|
||||||
<el-switch v-model="laneform.sectionDetector"></el-switch>
|
<el-switch v-model="laneform.sectionDetector"></el-switch>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-button type="primary" @click="handleagain()" size="small" style="width: 150px" v-if="laneform.laneClose == true"
|
<el-button type="primary" @click="handleagain()" size="small" style="width: 150px" v-if="laneform.laneClose == true"
|
||||||
|
@ -197,7 +201,6 @@
|
||||||
>您可以自定义进行视频分析的区域,区域之外的部分将被忽略。此功能可以帮助您检测和跟踪高分辨率视频特定部分的较小对象,实现检测器的数字变焦功能。
|
>您可以自定义进行视频分析的区域,区域之外的部分将被忽略。此功能可以帮助您检测和跟踪高分辨率视频特定部分的较小对象,实现检测器的数字变焦功能。
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<el-form ref="form" :model="identificationAreaform" label-width="fit-content">
|
<el-form ref="form" :model="identificationAreaform" label-width="fit-content">
|
||||||
<!-- <p>车道识别配置</p> -->
|
<!-- <p>车道识别配置</p> -->
|
||||||
|
|
||||||
|
@ -256,14 +259,22 @@
|
||||||
<div class="dataBoard">
|
<div class="dataBoard">
|
||||||
<div class="section">
|
<div class="section">
|
||||||
<div class="warning" @click="handleContent('plate')">
|
<div class="warning" @click="handleContent('plate')">
|
||||||
<i :class="contentShow.plate==false?'el-icon-arrow-right':'el-icon-arrow-down'" style="font-weight: 600;font-size: 18px;margin-right: 5px;" ></i>
|
<i
|
||||||
|
:class="contentShow.plate == false ? 'el-icon-arrow-right' : 'el-icon-arrow-down'"
|
||||||
|
style="font-weight: 600;font-size: 18px;margin-right: 5px;"
|
||||||
|
></i>
|
||||||
<p class="board-title">车牌识别</p>
|
<p class="board-title">车牌识别</p>
|
||||||
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i
|
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i
|
||||||
>车牌识别开关。牌照信息表示与目标属性。(断面号牌,与断面设置关联)
|
>车牌识别开关。牌照信息表示与目标属性。(断面号牌,与断面设置关联)
|
||||||
</div>
|
</div>
|
||||||
<el-form ref="form" :model="licensePlateform" label-width="fit-content" v-if="contentShow.plate">
|
<el-form ref="form" :model="licensePlateform" label-width="fit-content" v-if="contentShow.plate">
|
||||||
<el-form-item label="车牌识别开关:">
|
<el-form-item label="车牌识别开关:">
|
||||||
<el-switch v-model="licensePlateform.licensePlateClose" active-value="1" inactive-value="0" @change="changeChepai($event)"></el-switch>
|
<el-switch
|
||||||
|
v-model="licensePlateform.licensePlateClose"
|
||||||
|
active-value="1"
|
||||||
|
inactive-value="0"
|
||||||
|
@change="changeChepai($event)"
|
||||||
|
></el-switch>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- <div style="width: 100%; height: 400px; margin-bottom: 10px" v-if="licensePlateform.licensePlateClose == true"> -->
|
<!-- <div style="width: 100%; height: 400px; margin-bottom: 10px" v-if="licensePlateform.licensePlateClose == true"> -->
|
||||||
<div style="width: 100%; height: 400px; margin-bottom: 10px" v-if="false">
|
<div style="width: 100%; height: 400px; margin-bottom: 10px" v-if="false">
|
||||||
|
@ -349,12 +360,21 @@
|
||||||
<div class="dataBoard">
|
<div class="dataBoard">
|
||||||
<div class="section">
|
<div class="section">
|
||||||
<div class="warning" @click="handleContent('parking')">
|
<div class="warning" @click="handleContent('parking')">
|
||||||
<i :class="contentShow.parking==false?'el-icon-arrow-right':'el-icon-arrow-down'" style="font-weight: 600;font-size: 18px;margin-right: 5px;" ></i>
|
<i
|
||||||
|
:class="contentShow.parking == false ? 'el-icon-arrow-right' : 'el-icon-arrow-down'"
|
||||||
|
style="font-weight: 600;font-size: 18px;margin-right: 5px;"
|
||||||
|
></i>
|
||||||
<p class="board-title">停车状态</p>
|
<p class="board-title">停车状态</p>
|
||||||
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i
|
<i class="el-icon-warning" style="color: #409eff; margin: 0 3px 0 10px"></i
|
||||||
>位移、速度,例如位移<δ,速度<v,则判断车辆停车
|
>位移、速度,例如位移<δ,速度<v,则判断车辆停车
|
||||||
</div>
|
</div>
|
||||||
<el-form :inline="true" :model="stopStateform" class="demo-form-inline" label-width="fit-content" v-if="contentShow.parking">
|
<el-form
|
||||||
|
:inline="true"
|
||||||
|
:model="stopStateform"
|
||||||
|
class="demo-form-inline"
|
||||||
|
label-width="fit-content"
|
||||||
|
v-if="contentShow.parking"
|
||||||
|
>
|
||||||
<el-form-item label="位移:" style="margin-right:10px">
|
<el-form-item label="位移:" style="margin-right:10px">
|
||||||
<el-input-number
|
<el-input-number
|
||||||
v-model="stopStateform.displacement"
|
v-model="stopStateform.displacement"
|
||||||
|
@ -435,7 +455,7 @@
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<el-dialog
|
<!-- <el-dialog
|
||||||
title="新增点"
|
title="新增点"
|
||||||
:visible.sync="dialogVisible"
|
:visible.sync="dialogVisible"
|
||||||
width="30%"
|
width="30%"
|
||||||
|
@ -466,50 +486,44 @@
|
||||||
<el-button @click="dialogVisible = false">取 消</el-button>
|
<el-button @click="dialogVisible = false">取 消</el-button>
|
||||||
<el-button type="primary" @click="handleDian('addform')">确 定</el-button>
|
<el-button type="primary" @click="handleDian('addform')">确 定</el-button>
|
||||||
</span>
|
</span>
|
||||||
</el-dialog>
|
</el-dialog> -->
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import mqtt from 'mqtt'; // mqtt协议
|
import mqtt from 'mqtt'; // mqtt协议
|
||||||
import {getFeixpz,setCameraPosition,setLicensePlate,setParkingStatus,setFeixzbzh} from "@/api/index";
|
import { getFeixpz, setCameraPosition, setLicensePlate, setParkingStatus, setFeixzbzh } from '@/api/index';
|
||||||
export default {
|
export default {
|
||||||
props:{
|
props: {
|
||||||
analysisConfigurationdata: {
|
analysisConfigurationdata: {
|
||||||
default: () => false,
|
default: () => false,
|
||||||
type: Object,
|
type: Object,
|
||||||
required: true
|
required: true
|
||||||
},
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
unityDone:false,
|
unityDone: false,
|
||||||
oldName:'',
|
oldName: '',
|
||||||
formRules:{
|
formRules: {
|
||||||
pointName: [
|
pointName: [{ required: true, message: '请输入点名称', trigger: 'blur' }],
|
||||||
{ required: true, message: '请输入点名称', trigger: 'blur' },
|
longitude: [{ required: true, message: '请输入经度', trigger: 'blur' }],
|
||||||
],
|
latitude: [{ required: true, message: '请输入纬度', trigger: 'blur' }]
|
||||||
longitude: [
|
|
||||||
{ required: true, message: '请输入经度', trigger: 'blur' },
|
|
||||||
],
|
|
||||||
latitude: [
|
|
||||||
{ required: true, message: '请输入纬度', trigger: 'blur' },
|
|
||||||
],
|
|
||||||
},
|
},
|
||||||
addDianForm:{
|
addDianForm: {
|
||||||
pointName:'',
|
pointName: '',
|
||||||
longitude:"",
|
longitude: '',
|
||||||
latitude:'',
|
latitude: '',
|
||||||
oldName:''
|
oldName: ''
|
||||||
},
|
},
|
||||||
dialogVisible: false,
|
dialogVisible: false,
|
||||||
coordinateTransformationId:'',
|
coordinateTransformationId: '',
|
||||||
AnalysisSettingId:'',
|
AnalysisSettingId: '',
|
||||||
contentShow:{
|
contentShow: {
|
||||||
postion:true,
|
postion: true,
|
||||||
coordinate:false,
|
coordinate: false,
|
||||||
plate:true,
|
plate: true,
|
||||||
parking:true
|
parking: true
|
||||||
},
|
},
|
||||||
sizeForm: {
|
sizeForm: {
|
||||||
name: '',
|
name: '',
|
||||||
|
@ -520,8 +534,8 @@ export default {
|
||||||
type: [],
|
type: [],
|
||||||
resource: '',
|
resource: '',
|
||||||
desc: '',
|
desc: '',
|
||||||
longitude:'',
|
longitude: '',
|
||||||
latitude:''
|
latitude: ''
|
||||||
},
|
},
|
||||||
formInline: {
|
formInline: {
|
||||||
user: '',
|
user: '',
|
||||||
|
@ -537,36 +551,17 @@ export default {
|
||||||
value: '0',
|
value: '0',
|
||||||
num: 1
|
num: 1
|
||||||
},
|
},
|
||||||
options: [{
|
options: [
|
||||||
|
{
|
||||||
value: '南',
|
value: '南',
|
||||||
label: '南'
|
label: '南'
|
||||||
}, {
|
},
|
||||||
|
{
|
||||||
value: '北',
|
value: '北',
|
||||||
label: '北'
|
label: '北'
|
||||||
}],
|
|
||||||
coordinateTableData: [
|
|
||||||
{
|
|
||||||
name: '11',
|
|
||||||
longitude: '111',
|
|
||||||
inIp: '01',
|
|
||||||
latitude: '',
|
|
||||||
oldName:''
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: '22',
|
|
||||||
longitude: '222',
|
|
||||||
inIp: '02',
|
|
||||||
latitude: '',
|
|
||||||
oldName:''
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: '33',
|
|
||||||
longitude: '333',
|
|
||||||
inIp: '03',
|
|
||||||
latitude: '',
|
|
||||||
oldName:''
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
coordinateTableData: [],
|
||||||
//车道识别配置
|
//车道识别配置
|
||||||
laneform: {
|
laneform: {
|
||||||
laneClose: false,
|
laneClose: false,
|
||||||
|
@ -648,18 +643,17 @@ export default {
|
||||||
fileList: []
|
fileList: []
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
watch:{
|
watch: {
|
||||||
analysisConfigurationdata:{
|
analysisConfigurationdata: {
|
||||||
handler:function(old,newV){
|
handler: function(old, newV) {
|
||||||
// console.log("old",old)
|
// console.log("old",old)
|
||||||
// console.log("newV",newV)
|
// console.log("newV",newV)
|
||||||
if(newV!=null&&this.unityDone==true){
|
if (newV != null && this.unityDone == true) {
|
||||||
console.log(newV,'yyy');
|
console.log(newV, 'yyy');
|
||||||
this.$refs.analysisWeb.contentWindow.getDestination(newV)
|
this.$refs.analysisWeb.contentWindow.getDestination(newV);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
// this.getDataByMqtt()
|
// this.getDataByMqtt()
|
||||||
|
@ -675,124 +669,107 @@ export default {
|
||||||
// this.load()
|
// this.load()
|
||||||
// }, 5000);// 这样每次都会触发
|
// }, 5000);// 这样每次都会触发
|
||||||
// }
|
// }
|
||||||
getFeixpz({VideoId:this.$route.query.id}).then(res=>{
|
getFeixpz({ VideoId: this.$route.query.id }).then(res => {
|
||||||
this.sizeForm.longitude = res.data.data.cameraPositionLongitude
|
this.sizeForm.longitude = res.data.data.cameraPositionLongitude;
|
||||||
this.sizeForm.latitude = res.data.data.cameraPositionLatitude
|
this.sizeForm.latitude = res.data.data.cameraPositionLatitude;
|
||||||
this.coordinateForm.num = res.data.data.utmArea=='-1'?'':res.data.data.utmArea
|
this.coordinateForm.num = res.data.data.utmArea == '-1' ? '' : res.data.data.utmArea;
|
||||||
this.coordinateForm.value = res.data.data.hemisphere
|
this.coordinateForm.value = res.data.data.hemisphere;
|
||||||
this.coordinateForm.coordinateTransformation = res.data.data.coordinateTransformation
|
this.coordinateForm.coordinateTransformation = res.data.data.coordinateTransformation;
|
||||||
this.coordinateTableData = res.data.data.pointData!=null?res.data.data.pointData:[]
|
this.coordinateTableData =
|
||||||
this.licensePlateform.licensePlateClose = res.data.data.licensePlateRecognitionSwitch
|
res.data.data.pointData != null
|
||||||
this.stopStateform.displacement = res.data.data.parkingDisplacement
|
? res.data.data.pointData.map(item => {
|
||||||
this.stopStateform.speed = res.data.data.parkingSpeed
|
return { ...item, btnShow: '1' };
|
||||||
this.AnalysisSettingId = res.data.data.analysisSettingId
|
|
||||||
this.coordinateTransformationId = res.data.data.coordinateTransformationId
|
|
||||||
this.coordinateTableData.forEach(item=>{
|
|
||||||
item.btnShow='1'
|
|
||||||
})
|
})
|
||||||
})
|
: [];
|
||||||
|
this.licensePlateform.licensePlateClose = res.data.data.licensePlateRecognitionSwitch;
|
||||||
|
this.stopStateform.displacement = res.data.data.parkingDisplacement;
|
||||||
|
this.stopStateform.speed = res.data.data.parkingSpeed;
|
||||||
|
this.AnalysisSettingId = res.data.data.analysisSettingId;
|
||||||
|
this.coordinateTransformationId = res.data.data.coordinateTransformationId;
|
||||||
|
this.coordinateTableData.forEach(item => {
|
||||||
|
item.btnShow = '1';
|
||||||
|
});
|
||||||
|
});
|
||||||
},
|
},
|
||||||
mounted(){
|
mounted() {
|
||||||
window.OnSceneload = this.OnSceneload;
|
window.OnSceneload = this.OnSceneload;
|
||||||
window.saveCoordinate = this.saveCoordinate;
|
window.saveCoordinate = this.saveCoordinate;
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
saveCoordinate(obj){
|
saveCoordinate(obj) {
|
||||||
console.log(obj);
|
console.log(obj);
|
||||||
this.coordinateTableData.forEach(item=>{
|
this.coordinateTableData.forEach(item => {
|
||||||
if(item.pointName == obj.pointName){
|
if (item.pointName == obj.pointName) {
|
||||||
item.imageXCoordinate=obj.imageXCoordinate
|
item.imageXCoordinate = obj.imageXCoordinate;
|
||||||
item.imageYCoordinate=obj.imageYCoordinate
|
item.imageYCoordinate = obj.imageYCoordinate;
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
},
|
},
|
||||||
updateName(val){
|
|
||||||
console.log("val",val.target.value);
|
updateName(val) {
|
||||||
|
console.log('val', val.target.value);
|
||||||
},
|
},
|
||||||
handleExit(row,index){
|
handleExit(row, index) {
|
||||||
// this.oldName = row.pointName
|
// this.oldName = row.pointName
|
||||||
row.oldName = row.pointName
|
row.oldName = row.pointName;
|
||||||
console.log(this.coordinateTableData,'12312');
|
this.$refs.analysisWeb.contentWindow.exitPoint(row.pointName);
|
||||||
this.$refs.analysisWeb.contentWindow.exitPoint(row.pointName)
|
row.btnShow = '2';
|
||||||
this.coordinateTableData.forEach((item,index)=>{
|
// this.$set(this.coordinateTableData, index, row);
|
||||||
if(row.pointName == item.pointName){
|
|
||||||
item.btnShow = '2'
|
|
||||||
this.$set(this.coordinateTableData,index,item)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
handleconfirm(row,index){
|
handleconfirm(row, index) {
|
||||||
var bol = this.coordinateTableData.some((item,indexa)=>item.pointName==row.pointName&&indexa!=index)
|
var bol = this.coordinateTableData.some((item, indexa) => item.pointName == row.pointName && indexa != index);
|
||||||
if(bol==true){
|
if (bol == true) {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'info',
|
type: 'info',
|
||||||
message: '该点位已存在'
|
message: '该点位已存在'
|
||||||
});
|
});
|
||||||
return false
|
return false;
|
||||||
}
|
}
|
||||||
var string = row.oldName+','+row.pointName
|
var string = row.oldName + ',' + row.pointName;
|
||||||
this.$refs.analysisWeb.contentWindow.saveDian(string)
|
this.$refs.analysisWeb.contentWindow.saveDian(string);
|
||||||
this.coordinateTableData.forEach((item,indexnew)=>{
|
row.btnShow = '1';
|
||||||
if(row.pointName == item.pointName){
|
row.oldName = row.pointName;
|
||||||
item.btnShow = '1'
|
// this.$set(this.coordinateTableData, index, row);
|
||||||
this.$set(this.coordinateTableData,indexnew,item)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
},
|
},
|
||||||
OnSceneload(newV){
|
OnSceneload(newV) {
|
||||||
this.$refs.analysisWeb.contentWindow.getDianwei(this.$route.query.id)
|
this.$refs.analysisWeb.contentWindow.getDianwei(this.$route.query.id);
|
||||||
this.unityDone=true
|
this.unityDone = true;
|
||||||
},
|
},
|
||||||
handleDeleteDian(row){
|
handleDeleteDian(row, idx) {
|
||||||
this.$confirm('此操作将删除该点位, 是否继续?', '提示', {
|
this.$confirm('此操作将删除该点位, 是否继续?', '提示', {
|
||||||
confirmButtonText: '确定',
|
confirmButtonText: '确定',
|
||||||
cancelButtonText: '取消',
|
cancelButtonText: '取消',
|
||||||
type: 'warning'
|
type: 'warning'
|
||||||
}).then(() => {
|
})
|
||||||
this.coordinateTableData = this.coordinateTableData.filter(item => item.pointName!=row.pointName )
|
.then(() => {
|
||||||
this.$refs.analysisWeb.contentWindow.deletePoint(row.pointName)
|
this.coordinateTableData.splice(idx, 1);
|
||||||
|
// this.coordinateTableData = this.coordinateTableData.filter(item => item.pointName != row.pointName);
|
||||||
|
this.$refs.analysisWeb.contentWindow.deletePoint(row.oldName);
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'success',
|
type: 'success',
|
||||||
message: '删除成功!'
|
message: '删除成功!'
|
||||||
});
|
});
|
||||||
}).catch(() => {
|
})
|
||||||
|
.catch(() => {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'info',
|
type: 'info',
|
||||||
message: '已取消删除'
|
message: '已取消删除'
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handleDian(formName){
|
handleDian() {
|
||||||
this.$refs[formName].validate((valid) => {
|
const newPointData = {
|
||||||
if (valid) {
|
btnShow: '2',
|
||||||
console.log(this.addDianForm,'addDianForm,,,');
|
longitude: '0',
|
||||||
var bol = this.coordinateTableData.some(item=>item.pointName==this.addDianForm.pointName)
|
latitude: '0'
|
||||||
console.log(bol,'bol');
|
};
|
||||||
if(bol==true){
|
newPointData.oldName = newPointData.pointName = String(new Date().getTime());
|
||||||
this.$message({
|
this.coordinateTableData.unshift(newPointData);
|
||||||
type: 'info',
|
this.$refs.analysisWeb.contentWindow.setPOS(newPointData.pointName);
|
||||||
message: '该点位已存在'
|
|
||||||
});
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
this.addDianForm.btnShow = '2'
|
|
||||||
this.oldName = this.addDianForm.pointName
|
|
||||||
this.coordinateTableData.unshift(this.addDianForm)
|
|
||||||
this.dialogVisible = false
|
|
||||||
this.$refs.analysisWeb.contentWindow.setPOS(this.addDianForm.pointName)
|
|
||||||
this.addDianForm={}
|
|
||||||
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
},
|
||||||
phoneChange(e) {
|
phoneChange(e) {
|
||||||
console.log("e", e.currentTarget.value);
|
console.log('e', e.currentTarget.value);
|
||||||
this.addDianForm.oldName = e.currentTarget.value
|
this.addDianForm.oldName = e.currentTarget.value;
|
||||||
},
|
},
|
||||||
handleClose(done) {
|
handleClose(done) {
|
||||||
this.$confirm('确认关闭?')
|
this.$confirm('确认关闭?')
|
||||||
|
@ -802,74 +779,85 @@ export default {
|
||||||
.catch(_ => {});
|
.catch(_ => {});
|
||||||
},
|
},
|
||||||
// 坐标转换接口
|
// 坐标转换接口
|
||||||
handlePos(){
|
handlePos() {
|
||||||
let params = {
|
if (this.coordinateTableData.some(item => item.btnShow === '2')) {
|
||||||
CoordinateTransformationId:this.coordinateTransformationId,
|
this.$message.warning('请先确认编辑');
|
||||||
UTMArea:this.coordinateForm.num==''?'-1':this.coordinateForm.num,
|
return;
|
||||||
Hemisphere:this.coordinateForm.value,
|
|
||||||
CoordinateTransformation:this.coordinateForm.coordinateTransformation,
|
|
||||||
PointData:this.coordinateTableData
|
|
||||||
}
|
}
|
||||||
console.log("params",JSON.stringify(params))
|
let params = {
|
||||||
setFeixzbzh(params).then(res=>{
|
CoordinateTransformationId: this.coordinateTransformationId,
|
||||||
|
UTMArea: this.coordinateForm.num == '' ? '-1' : this.coordinateForm.num,
|
||||||
|
Hemisphere: this.coordinateForm.value,
|
||||||
|
CoordinateTransformation: this.coordinateForm.coordinateTransformation,
|
||||||
|
PointData: this.coordinateTableData.map(item => {
|
||||||
|
return {
|
||||||
|
longitude: item.longitude,
|
||||||
|
latitude: item.latitude,
|
||||||
|
pointName: item.pointName,
|
||||||
|
imageXCoordinate: item.imageXCoordinate,
|
||||||
|
imageYCoordinate: item.imageYCoordinate
|
||||||
|
};
|
||||||
|
})
|
||||||
|
};
|
||||||
|
setFeixzbzh(params).then(res => {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'success',
|
type: 'success',
|
||||||
message: res.data.msg,
|
message: res.data.msg
|
||||||
|
});
|
||||||
});
|
});
|
||||||
})
|
|
||||||
},
|
},
|
||||||
// 停车状态
|
// 停车状态
|
||||||
handleParking(){
|
handleParking() {
|
||||||
const params = new URLSearchParams();
|
const params = new URLSearchParams();
|
||||||
params.append('AnalysisSettingId', this.AnalysisSettingId)
|
params.append('AnalysisSettingId', this.AnalysisSettingId);
|
||||||
params.append('ParkingDisplacement',this.stopStateform.displacement)
|
params.append('ParkingDisplacement', this.stopStateform.displacement);
|
||||||
params.append('ParkingSpeed',this.stopStateform.speed)
|
params.append('ParkingSpeed', this.stopStateform.speed);
|
||||||
setParkingStatus(params).then(res=>{
|
setParkingStatus(params).then(res => {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'success',
|
type: 'success',
|
||||||
message: res.data.msg,
|
message: res.data.msg
|
||||||
|
});
|
||||||
});
|
});
|
||||||
})
|
|
||||||
},
|
},
|
||||||
// 车牌识别
|
// 车牌识别
|
||||||
changeChepai(val){
|
changeChepai(val) {
|
||||||
console.log(val,'val111');
|
console.log(val, 'val111');
|
||||||
const params = new URLSearchParams();
|
const params = new URLSearchParams();
|
||||||
params.append('AnalysisSettingId', this.AnalysisSettingId)
|
params.append('AnalysisSettingId', this.AnalysisSettingId);
|
||||||
params.append('LicensePlateRecognitionSwitch',val)
|
params.append('LicensePlateRecognitionSwitch', val);
|
||||||
setLicensePlate(params).then(res=>{
|
setLicensePlate(params).then(res => {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'success',
|
type: 'success',
|
||||||
message: res.data.msg,
|
message: res.data.msg
|
||||||
|
});
|
||||||
});
|
});
|
||||||
})
|
|
||||||
},
|
},
|
||||||
// 经纬度保存
|
// 经纬度保存
|
||||||
handSaveitude(){
|
handSaveitude() {
|
||||||
const params = new URLSearchParams();
|
const params = new URLSearchParams();
|
||||||
params.append('AnalysisSettingId', this.AnalysisSettingId)
|
params.append('AnalysisSettingId', this.AnalysisSettingId);
|
||||||
params.append('CameraPositionLongitude', this.sizeForm.longitude)
|
params.append('CameraPositionLongitude', this.sizeForm.longitude);
|
||||||
params.append('CameraPositionLatitude', this.sizeForm.latitude)
|
params.append('CameraPositionLatitude', this.sizeForm.latitude);
|
||||||
setCameraPosition(params).then(res=>{
|
setCameraPosition(params).then(res => {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'success',
|
type: 'success',
|
||||||
message: res.data.msg,
|
message: res.data.msg
|
||||||
|
});
|
||||||
});
|
});
|
||||||
})
|
|
||||||
},
|
},
|
||||||
// 收放
|
// 收放
|
||||||
handleContent(val){
|
handleContent(val) {
|
||||||
if(val == 'postion'){
|
if (val == 'postion') {
|
||||||
this.contentShow.postion = !this.contentShow.postion
|
this.contentShow.postion = !this.contentShow.postion;
|
||||||
}
|
}
|
||||||
if(val == 'coordinate'){
|
if (val == 'coordinate') {
|
||||||
this.contentShow.coordinate = !this.contentShow.coordinate
|
this.contentShow.coordinate = !this.contentShow.coordinate;
|
||||||
}
|
}
|
||||||
if(val == 'plate'){
|
if (val == 'plate') {
|
||||||
this.contentShow.plate = !this.contentShow.plate
|
this.contentShow.plate = !this.contentShow.plate;
|
||||||
}
|
}
|
||||||
if(val == 'parking'){
|
if (val == 'parking') {
|
||||||
this.contentShow.parking = !this.contentShow.parking
|
this.contentShow.parking = !this.contentShow.parking;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleChange(value) {
|
handleChange(value) {
|
||||||
|
@ -1079,16 +1067,16 @@ export default {
|
||||||
// const client = mqtt.connect(host) // 连接
|
// const client = mqtt.connect(host) // 连接
|
||||||
// 错误回调
|
// 错误回调
|
||||||
// console.log("this.mqttClient", this.mqttClient)
|
// console.log("this.mqttClient", this.mqttClient)
|
||||||
this.mqttClient.on('error', (err) => {
|
this.mqttClient.on('error', err => {
|
||||||
console.log('[MQTT-TEST] 连接错误:', err);
|
console.log('[MQTT-TEST] 连接错误:', err);
|
||||||
this.mqttClient.end();
|
this.mqttClient.end();
|
||||||
});
|
});
|
||||||
// 重连回调
|
// 重连回调
|
||||||
this.mqttClient.on('reconnect', (reconnect) => {
|
this.mqttClient.on('reconnect', reconnect => {
|
||||||
// console.log("[MQTT-TEST] 重连中……", reconnect);
|
// console.log("[MQTT-TEST] 重连中……", reconnect);
|
||||||
});
|
});
|
||||||
// 连接回调
|
// 连接回调
|
||||||
this.mqttClient.on('connect', (connect) => {
|
this.mqttClient.on('connect', connect => {
|
||||||
// console.log("[MQTT-TEST] 已连接的客户端ID: ", connect);
|
// console.log("[MQTT-TEST] 已连接的客户端ID: ", connect);
|
||||||
// 订阅
|
// 订阅
|
||||||
this.mqttClient.subscribe('img0', { qos: 0 });
|
this.mqttClient.subscribe('img0', { qos: 0 });
|
||||||
|
@ -1267,7 +1255,7 @@ export default {
|
||||||
// text-align: left;
|
// text-align: left;
|
||||||
// font-size: 16px;
|
// font-size: 16px;
|
||||||
// }
|
// }
|
||||||
.otherThings{
|
.otherThings {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-flow: row nowrap;
|
flex-flow: row nowrap;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
@ -1277,13 +1265,14 @@ export default {
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.analysis{
|
.analysis {
|
||||||
.board-title {
|
.board-title {
|
||||||
font-size: 17px;
|
font-size: 17px;
|
||||||
font-weight: bolder;
|
font-weight: bolder;
|
||||||
|
width: max-content;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.analysis .warning{
|
.analysis .warning {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-flow: row nowrap;
|
flex-flow: row nowrap;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
@ -1323,4 +1312,3 @@ export default {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
Loading…
Reference in New Issue