Merge remote-tracking branch 'origin/2024年1月24日测试' into 2024年1月24日测试

2024年2月1日V1.0.53
liujun 2024-01-29 14:05:42 +08:00
commit abf0d8ff91
12 changed files with 2083 additions and 13 deletions

View File

@ -0,0 +1,416 @@
<template>
<div class="menjin">
<div class="block1">
<layout-title title="设备在线情况"/>
<div class="options">
<div v-for="(item,index) in block1OptionsList" :key="index" class="option">
<div class="title active">{{ item.title }}</div>
<div class="circular">
<img :src="item.img" alt="">
</div>
<div class="label">
{{ item.label1 }}<count-to :start-val="0" :end-val="item.count1" :duration="3600"/>
</div>
<div v-if="item.label2" class="label">
{{ item.label2 }}<count-to :start-val="0" :end-val="item.count2" :duration="3600"/>
</div>
</div>
</div>
</div>
<div class="block2">
<layout-title title="堆料场进出数据"/>
<div class="options">
<div v-for="(item,index) in block2OptionsList" v-if="index != 1" :key="index" class="option">
<div class="title active">{{ item.title }}</div>
<div class="items">
<div v-for="(item1,index1) in item.list" :key="index1" class="item">
<div class="label">
{{ item1.label }}<count-to :start-val="0" :end-val="item1.count" :duration="3600"/>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="block3">
<layout-title title="口门进出记录"/>
<div class="content">
<div class="options">
<div
v-for="(item,index) in block3OptionsList"
:key="index"
:class="['title', {active:index === block3OptionsIndex}]"
@click="block3OptionsClick(index)"
>
{{ item }}
</div>
</div>
<div class="table">
<div class="tr">
<div class="td">卡口名称</div>
<div class="td">{{ block3OptionsIndex===0 ? '人员':'车牌' }}</div>
<div class="td">时间</div>
<div class="td">状态</div>
</div>
<div v-for="(item,index) in block3List" :key="index" class="tr">
<div class="td line1">{{ block3OptionsIndex===0 ? item.devName : item.ROADWAYNAME }}</div>
<div class="td">{{ block3OptionsIndex===0 ? item.personName : item.PLATENO }}</div>
<div class="td line1">{{ block3OptionsIndex===0 ? item.eventTime.substring(11) : item.CROSSTIME.substring(11,19) }}</div>
<div class="td">{{ item.inAndOutType === null ? (item.VEHICLEOUT === '0' ? '出' : '进') : (item.inAndOutType === '0' ? '出' : '进') }}</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import layoutTitle from './title.vue'
import CountTo from 'vue-count-to'
import { requestFN } from '@/utils/request'
export default {
components: {
layoutTitle,
CountTo
},
data() {
return {
block1OptionsList: [
{
title: '人员闸机数',
img: require('../../../assets/map/menjin/ico1.png'),
label1: '在线数',
count1: 0
// label2: '线',
// count2: 0
},
{
title: '车辆闸机数',
img: require('../../../assets/map/menjin/ico2.png'),
label1: '在线数',
count1: 0
// label2: '线',
// count2: 0
},
{
title: '摄像头数',
img: require('../../../assets/map/menjin/ico3.png'),
label1: '摄像头数',
count1: 0
}
],
block2OptionsList: [
{
title: '今日人员情况',
list: [
{
label: '进堆料场人员数',
count: 0
},
{
label: '出堆料场人员数',
count: 0
},
{
label: '堆料场内人员数',
count: 0
}
]
},
{
title: '今日临时情况',
list: [
{
label: '临时进堆料场人员数',
count: 0
},
{
label: '临时出堆料场人员数',
count: 0
},
{
label: '临时堆料场内人员数',
count: 0
}
]
},
{
title: '今日车辆情况',
list: [
{
label: '进堆料场车辆数',
count: 0
},
{
label: '出堆料场车辆数',
count: 0
},
{
label: '堆料场内车辆数',
count: 0
}
]
}
],
block3OptionsList: ['人员闸机', '车辆闸机'],
block3OptionsIndex: 1,
block3List: [
]
}
},
mounted() {
this.getPerpleCarGateMachineCount()
this.getMachineCount()
this.listPerpleCarGateMachine('1')
},
destroyed() {
clearInterval(this.timer) //
},
methods: {
//
startPersonnelDataTimer() {
this.timer = setInterval(() => {
this.getPerpleCarGateMachineCount()
this.obtainPersonnelData()
this.getCameraCount()
}, 300000)
},
getMachineCount() {
requestFN(
'/map/getGatePositionCount',
{
id: this.id,
TYPE: this.type
}
).then((data) => {
this.block1OptionsList[0].count1 = data.data.personMachineCount
// this.block1OptionsList[0].count2 =
this.block1OptionsList[1].count1 = data.data.carMachineCount
// this.block1OptionsList[1].count2 =
this.block1OptionsList[2].count1 = data.data.cameraCount
}).catch((e) => {
})
},
getPerpleCarGateMachineCount() {
requestFN(
'/map/getPersonAndCarGateInAndOutCount',
{
TYPE: this.type
}
).then((data) => {
this.block2OptionsList[2].list[0].count = data.data.carInCount
console.log(data.data.data)
this.block2OptionsList[2].list[1].count = data.data.carOutCount
this.block2OptionsList[2].list[2].count = data.data.carOnSiteCount
this.block2OptionsList[0].list[0].count = data.data.personInCount
this.block2OptionsList[0].list[1].count = data.data.personOutCount
this.block2OptionsList[0].list[2].count = 0
}).catch((e) => {
})
},
//
obtainPersonnelData() {
requestFN(
'/UserPosition/getCurrentPersonnelData',
).then((data) => {
this.block2OptionsList[0].list[2].count = 333
this.block2OptionsList[0].list[0].count = 444
this.block2OptionsList[0].list[1].count = 555
}).catch((e) => {
})
},
listPerpleCarGateMachine(type) {
requestFN(
'/map/listGateMachine',
{
TYPE: type
}
).then((data) => {
this.block3List = data.varList.slice(0, 10)
console.log(this.block3List)
}).catch((e) => {
})
},
block3OptionsClick(index) {
this.block3OptionsIndex = index
this.listPerpleCarGateMachine(index)
},
//
obtainCarData() {
requestFN(
'/UserPosition/getCurrentCarData',
{ route: '/region/access/areaCarType' }
).then((data) => {
this.block2OptionsList[2].list[2].count = data.pd.onlineCarCount
}).catch((e) => {
})
}
}
}
</script>
<style lang="scss" scoped>
.menjin {
.title {
background-image: url("../../../assets/map/menjin/title_on.png");
background-size: 100% 100%;
background-repeat: no-repeat;
width: 113px;
height: 26px;
font-size: 14px;
line-height: 26px;
text-align: center;
color: #fff;
&.active {
background-image: url("../../../assets/map/menjin/title.png");
}
}
.block1 {
width: 410px;
background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.8));
.options {
display: flex;
justify-content: space-between;
padding: 10px 15px;
border: 1px solid;
border-image: linear-gradient(to bottom, rgba(58, 122, 149, 0), rgba(58, 122, 149, 1)) 1;
border-top: none;
.option {
display: flex;
flex-direction: column;
align-items: center;
.circular {
margin-top: 5px;
background-image: url("../../../assets/map/menjin/img1.png");
background-size: 100% 100%;
background-repeat: no-repeat;
width: 50px;
height: 50px;
text-align: center;
padding-top: 13px;
img {
width: 30px;
height: 26px;
animation: scale 2s infinite;
}
}
.label {
margin-top: 5px;
font-size: 12px;
color: #fff;
}
}
}
}
.block2 {
margin-top: 10px;
width: 410px;
background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.8));
.options {
padding: 10px 15px;
border: 1px solid;
border-image: linear-gradient(to bottom, rgba(58, 122, 149, 0), rgba(58, 122, 149, 1)) 1;
border-top: none;
.option {
.items {
display: flex;
flex-wrap: wrap;
margin-bottom: 10px;
.item {
margin-top: 10px;
font-size: 12px;
color: #fff;
flex-basis: 50%;
}
}
}
}
}
.block3 {
margin-top: 10px;
width: 410px;
background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.8));
.content {
border: 1px solid;
border-image: linear-gradient(to bottom, rgba(58, 122, 149, 0), rgba(58, 122, 149, 1)) 1;
border-top: none;
padding: 10px;
.options {
display: flex;
justify-content: flex-end;
.title {
cursor: pointer;
}
}
.table {
margin-top: 5px;
.tr {
display: flex;
&:nth-child(odd) {
background-color: rgba(42, 86, 158, 0.53);
}
.td {
flex: 1;
text-align: center;
font-size: 12px;
color: #fff;
padding: 5px;
&:nth-child(2) {
flex-basis: 20%;
}
&.green {
color: #7ccf41;
}
&.yellow {
color: #ffcb05;
}
}
}
}
}
}
}
@keyframes scale {
0% {
transform: scale(1);
}
50% {
transform: scale(0.8);
}
100% {
transform: scale(1);
}
}
.line1 {
width: 150px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
</style>

View File

@ -203,7 +203,8 @@ export default {
requestFN(
'/map/listbymeteorological',
{
CORPINFO_ID: this.corpInfoId || '035958e685cf4850bc40151c5e0617a6'
CORPINFO_ID: this.corpInfoId || '035958e685cf4850bc40151c5e0617a6',
GANGKOU: this.gangkou
}
).then((data) => {
this.listLoading = false

View File

@ -0,0 +1,413 @@
<template>
<div class="renyuan">
<div class="block1">
<layout-title title="定位基础信息"/>
<div class="options">
<div v-for="(item,index) in block1OptionsList" :key="index" class="option">
<div class="imger">
<img :src="item.img" alt="">
</div>
<div class="info">
<div class="label">{{ item.title }}</div>
<div class="text"><count-to :start-val="0" :end-val="item.count" :duration="3600"/></div>
</div>
</div>
</div>
</div>
<div class="block2">
<layout-title title="告警数据"/>
<div class="options">
<div class="bg"/>
<div v-for="(item,index) in block2OptionsList" :key="index" class="option">
<div class="label">{{ item.alarmTypeName }}</div>
<div class="info">
<span class="count"><count-to :start-val="0" :end-val="item.alarmCount" :duration="3600"/></span>
<span class="company"></span>
</div>
</div>
</div>
</div>
<div class="block3">
<layout-title title="定位标签状态"/>
<div class="content">
<div class="options">
<div
v-for="(item,index) in block3OptionsList"
:key="index"
:class="['title', {active:index === block3OptionsIndex}]"
@click="block3OptionsClick(index)"
>
{{ item }}
</div>
</div>
<div class="table">
<div class="tr">
<div class="td">卡号</div>
<div class="td">姓名</div>
<div class="td">状态</div>
</div>
<div v-infinite-scroll="load" :infinite-scroll-disabled="disabled" class="scroll">
<div v-for="(item,index) in block3List" :key="index" class="tr">
<div class="td">{{ item.devidno }}</div>
<div class="td">{{ item.fullName }}</div>
<div class="td">{{ item.onlineornot ? '在线':'离线' }}</div>
<!-- <div :class="['td',{error:item.STATE == '1'}]">{{ item.STATE == '1' ? '异常' : '正常' }}</div>-->
</div>
<div v-if="loading" class="tr">
<div class="td">加载中...</div>
</div>
</div>
<!-- <div v-for="(item,index) in block3List" :key="index" class="tr">-->
<!-- <div class="td">{{ item.cardNo }}</div>-->
<!-- <div class="td">{{ item.name }}</div>-->
<!-- <div class="td">{{ item.cardType }}</div>-->
<!-- </div>-->
</div>
<!-- <div v-show="block3OptionsIndex=== 1" class="table">-->
<!-- <div class="tr">-->
<!-- <div class="td">车牌号</div>-->
<!-- <div class="td">状态</div>-->
<!-- </div>-->
<!-- <div v-for="(item,index) in block4List" :key="index" class="tr">-->
<!-- <div class="td">{{ item.name }}</div>-->
<!-- <div class="td">在线</div>-->
<!-- </div>-->
<!-- </div>-->
</div>
</div>
</div>
</template>
<script>
import layoutTitle from './title.vue'
import { requestFN } from '../../../utils/request'
import CountTo from 'vue-count-to'
export default {
components: {
layoutTitle,
CountTo
},
data() {
return {
block1OptionsList: [
{
title: '在线员工',
img: require('../../../assets/map/renyuan/img1ico1.png'),
count: 0
},
{
title: '外协人员',
img: require('../../../assets/map/renyuan/img1ico4.png'),
count: 0
},
{
title: '内部人员',
img: require('../../../assets/map/renyuan/img1ico3.png'),
count: 0
}
// ,
// {
// title: '线',
// img: require('../../../assets/map/renyuan/img1ico2.png'),
// count: 0
// },
// {
// title: '',
// img: require('../../../assets/map/renyuan/img1ico5.png'),
// count: 0
// }
],
block2OptionsList: [
{
title: '电子围栏告警',
count: 0
},
{
title: '静超时告警',
count: 0
},
{
title: '超员/缺员告警',
count: 0
},
{
title: '离岗告警',
count: 0
},
{
title: '车辆超速告警',
count: 0
},
{
title: 'SOS求救',
count: 0
}
],
block3OptionsList: ['相关方员工', '普通员工'],
block3OptionsIndex: 0,
currentPage: 1,
loading: false,
count: 0,
totalPage: 0,
block3List: [],
block4List: [],
timer: ''
}
},
computed: {
noMore() {
return this.currentPage >= this.totalPage
},
disabled() {
return this.loading || this.noMore
}
},
mounted() {
},
destroyed() {
clearInterval(this.timer) //
},
created() {
this.getCmtWorkCardLocationCount()
},
methods: {
getCmtWorkCardLocationCount() {
requestFN(
'/map/findWorkCardLocation',
{}
).then((data) => {
this.block1OptionsList[0].count = data.onlineCount
}).catch((e) => {
})
},
getCmtWorkCardLocation() {
requestFN(
'/map/findWorkCardLocation',
{}
).then((data) => {
this.block3List = this.block3List.concat(data.list)
}).catch((e) => {
})
},
block3OptionsClick(index) {
this.currentPage = 1
this.block3List = []
this.block3OptionsIndex = index
if (index === 1) {
this.getCmtWorkCardLocation()
}
// this.getCzksPersonStaffListPage()
}
}
}
</script>
<style lang="scss" scoped>
.renyuan {
.title {
background-image: url("../../../assets/map/menjin/title_on.png");
background-size: 100% 100%;
background-repeat: no-repeat;
width: 113px;
height: 26px;
font-size: 14px;
line-height: 26px;
text-align: center;
color: #fff;
&.active {
background-image: url("../../../assets/map/menjin/title.png");
}
}
.block1 {
width: 410px;
background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.8));
.options {
padding: 10px 15px;
border: 1px solid;
border-image: linear-gradient(to bottom, rgba(58, 122, 149, 0), rgba(58, 122, 149, 1)) 1;
border-top: none;
display: flex;
flex-wrap: wrap;
.option {
display: flex;
width: 50%;
align-items: center;
margin-top: 10px;
&:nth-child(-n+2) {
margin-top: 0;
}
.imger {
width: 50px;
height: 50px;
background-image: url("../../../assets/map/menjin/img1.png");
background-size: 100% 100%;
background-repeat: no-repeat;
text-align: center;
margin-left: 20px;
img {
width: 30px;
height: 30px;
animation: scale 2s infinite;
margin-top: 10px;
}
}
.info {
color: #FFFFFF;
margin-left: 10px;
.label {
font-size: 12px;
height: 25px;
line-height: 25px;
}
.text {
font-size: 24px;
background: linear-gradient(to top, #48bbf0, #ffffff);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
font-weight: bold;
font-family: "PingFang SC", "Helvetica Neue", "Hiragino Sans GB", "Segoe UI", "Microsoft YaHei", "微软雅黑", sans-serif;
margin-top: -5px;
}
}
}
}
}
.block2 {
width: 410px;
background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.8));
margin-top: 10px;
.options {
padding: 10px 15px;
border: 1px solid;
border-image: linear-gradient(to bottom, rgba(58, 122, 149, 0), rgba(58, 122, 149, 1)) 1;
border-top: none;
display: flex;
flex-wrap: wrap;
justify-content: space-between;
align-items: center;
position: relative;
height: 244px;
.bg {
background-image: url("../../../assets/map/renyuan/img2.png");
background-size: 100% 100%;
background-repeat: no-repeat;
width: 287px;
height: 244px;
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
}
.option {
flex-basis: 35%;
text-align: center;
.label {
font-size: 14px;
color: #fff;
}
.info {
.count {
font-size: 24px;
background: linear-gradient(to top, #48bbf0, #ffffff);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
font-weight: bold;
font-family: "PingFang SC", "Helvetica Neue", "Hiragino Sans GB", "Segoe UI", "Microsoft YaHei", "微软雅黑", sans-serif;
}
.company {
font-size: 14px;
color: #fff;
}
}
}
}
}
.block3 {
margin-top: 10px;
width: 400px;
background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.8));
.content {
border: 1px solid;
border-image: linear-gradient(to bottom, rgba(58, 122, 149, 0), rgba(58, 122, 149, 1)) 1;
border-top: none;
padding: 10px;
.options {
display: flex;
justify-content: flex-end;
.title {
cursor: pointer;
}
}
.table {
margin-top: 5px;
.scroll {
max-height: 250px;
overflow-y: auto;
&::-webkit-scrollbar {
width: 5px;
}
&::-webkit-scrollbar-thumb {
border-radius: 5px;
background: rgba(2, 30, 81, 0.851);
}
&::-webkit-scrollbar-track {
border-radius: 5px;
background: rgba(255, 255, 255, 0.1);
}
}
.tr {
display: flex;
&:nth-child(odd) {
background-color: rgba(42, 86, 158, 0.53);
}
.td {
flex: 1;
text-align: center;
font-size: 12px;
color: #fff;
padding: 5px;
}
}
}
}
}
}
@keyframes scale {
0% {
transform: scale(0.9);
}
50% {
transform: scale(0.8);
}
100% {
transform: scale(0.9);
}
}
</style>

View File

@ -7,13 +7,16 @@
<temperaturestation v-if="type === '561347f0cff641dba8b2b22c0f443348'" :id="id" :type="type" :gangkou="gangkou"/>
<humiditystation v-if="type === '732fe73933b845c6b1e2aee06a38ed31'" :id="id" :type="type" :gangkou="gangkou"/>
<windspeedstation v-if="type === '2da29f00852a4653ba3e760b9de57412'" :id="id" :type="type" :gangkou="gangkou"/>
<windspeedstation-cmt v-if="type === '2da29f00852a4653ba3e760b9de5741200005'" :name="name" :id="id" :type="type" :gangkou="gangkou"/>
<xf-point v-if="type === 'point'" :id="id" :type="type" :gangkou="gangkou"/>
<xf-control v-if="type === 'xfbf01' || type ==='xfkzs01' || type ==='xfjyd01' || type ==='xfsy01'" :id="id" :type="type" :gangkou="gangkou"/>
<mk-gate-machine v-if="type === 'CAR'||type ==='PERSON' || type ==='CAMERA'" :id="id" :type="type" :gangkou="gangkou"/>
<mk-gate-machine-cfd v-if="type === 'CAR00004'||type ==='PERSON00004' " :id="id" :type="type" :gangkou="gangkou" :infoname="infoname"/>
<mk-gate-machine-cmt v-if="type === 'CAR00005'||type ==='PERSON00005' " :id="id" :type="type" :gangkou="gangkou" :infoname="infoname"/>
<zhong_da_info v-if="type === 'majordangersource'" :id="id" :type="type" :gangkou="gangkou"/>
<video-play v-if="type === 'video'" :id="id" :type="type" :gangkou="gangkou" request-url="/api/homemajor/getVideoInfo"/>
<video-play-cfd v-if="type === 'CAMERA00004' || type === 'platcamera00004'" :id="id" :type="type" :gangkou="gangkou"/>
<video-play-cmt v-if="type === 'CAMERA00005' || type === 'platcamera00005'" :id="id" :type="type" :gangkou="gangkou"/>
<video-play-plat v-if="type === 'platcamera'" :id="id" :type="type" :gangkou="gangkou" :corp-info-id="corpInfoId"/>
<!--秦港一公司 边界入侵 详细页面 start-->
<video-play-bianjieruqin v-if="type === 'bianjieruqin'" :id="id" :type="type" :gangkou="gangkou"/>
@ -43,6 +46,7 @@
<breakgroundCfdD v-if="type === 'BREAKGROUND' && corpInfoId === '635917e77af8461691d5da5507b56347'" :id="id" :type="type"/>
<hoistingCfdD v-if="type === 'HOISTING' && corpInfoId === '635917e77af8461691d5da5507b56347'" :id="id" :type="type"/>
<peoplePositionCfdD v-if="type === 'peoplePosition'" :id="id" :type="type" :infoname="infoname"/>
<peoplePositionCmt v-if="type === 'peoplePosition00005'" :id="id" :type="type" :infoname="infoname"/>
<carPositionCfdD v-if="type === 'carPosition'" :id="id" :type="type" :infoname="infoname"/>
<!--曹妃甸东 八项作业 曹实业详细页面 end-->
<peoplePositionNine v-if="type === 'peoplePositionNine'" :id="id" :type="type" :infoname="infoname"/>
@ -63,10 +67,12 @@ import weatherstation from './weatherstation.vue'
import temperaturestation from './weatherstation.vue'
import humiditystation from './weatherstation.vue'
import windspeedstation from './weatherstation.vue'
import windspeedstationCmt from './weatherstationCmt.vue'
import XfControl from './xfControl.vue'
import XfPoint from './xfPoint.vue'
import MkGateMachine from './mkGateMachine.vue'
import MkGateMachineCfd from './mkGateMachineCfd.vue'
import MkGateMachineCmt from './mkGateMachineCmt.vue'
import Zhong_da_info from './zhong_da_info.vue'
import electricityOrder from './electricityOrder.vue'
import highworkOrder from './highworkOrder.vue'
@ -76,6 +82,7 @@ import breakgroundOrder from './breakgroundOrder.vue'
import hoistingOrder from './hoistingOrder.vue'
import videoPlay from './video_play.vue'
import videoPlayCfd from './video_play_cfd.vue'
import videoPlayCmt from './video_play_cmt.vue'
import videoPlayPlat from './video_play_plat.vue'
import videoPlayBianjieruqin from './video_play_bianjieruqin.vue'
import hotworkCfdD from './hotworkCfdD.vue'
@ -87,6 +94,7 @@ import cutroadCfdD from './cutroadCfdD.vue'
import breakgroundCfdD from './breakgroundCfdD.vue'
import hoistingCfdD from './hoistingCfdD.vue'
import peoplePositionCfdD from './peoplePositionCfdD.vue'
import peoplePositionCmt from './peoplePositionCmt.vue'
import carPositionCfdD from './carPositionCfdD.vue'
import peoplePositionOne from './peoplePositionOne.vue'
import hotworkFirst from './hotworkFirst'
@ -106,6 +114,7 @@ export default {
temperaturestation,
humiditystation,
windspeedstation,
windspeedstationCmt,
electricityOrder,
highworkOrder,
cutroadOrder,
@ -114,6 +123,7 @@ export default {
hoistingOrder,
videoPlay,
videoPlayCfd,
videoPlayCmt,
videoPlayPlat,
hotworkCfdD,
confinedspaceCfdD,
@ -125,13 +135,15 @@ export default {
hoistingCfdD,
MkGateMachineCfd,
peoplePositionCfdD,
peoplePositionCmt,
carPositionCfdD,
videoPlayBianjieruqin,
peoplePositionOne,
hotworkFirst,
peoplePositionYGS,
outSourceInfo,
outSourceVideoInfo
outSourceVideoInfo,
MkGateMachineCmt
},
props: {
title: {
@ -165,7 +177,11 @@ export default {
infoname: {
type: String,
default: ''
}
},
name: {
type: String,
default: ''
},
},
methods: {
closeDialog() {

View File

@ -0,0 +1,208 @@
<template>
<div class="app-container print-work">
<div class="level-title">
<h1>卡口信息</h1>
<div class="level-btns">卡口编号:{{ id }}</div>
</div>
<table class="table-ui">
<tr>
<td class="bbg-transparent">卡口类型</td>
<td >
<template v-if="type === 'PERSON00005'">
<span>
人卡
</span>
</template>
<template v-else>
<span>
车卡
</span>
</template>
</td>
<td class="bbg-transparent">卡口位置</td>
<td >
<span>
{{ infoname }}
</span>
</td>
</tr>
<!-- <tr>-->
<!-- <td class="bbg-transparent">卡口位置名称</td>-->
<!-- <td colspan="3" >{{ '秦皇岛市北京区石家庄镇唐山村' }}</td>-->
<!-- </tr>-->
<tr>
<td class="bbg-transparent">卡口状态</td>
<td colspan="3" >{{ '在线' }}</td>
</tr>
</table>
<div class="level-title martop">
<h1>进出记录</h1>
</div>
<table class="table-ui">
<tr v-if="type === 'PERSON00005'">
<td colspan="4" style="padding: 0;">
<table class="table-vi">
<tr class="bbg-transparent">
<td>序号</td>
<td>进出位置</td>
<td>人员姓名</td>
<td>卡号</td>
<td>进出状态</td>
<td>进出时间</td>
</tr>
<tr v-for="(item, index) in measuresList" :key="item.cardNo">
<td style="text-align: center">{{ index + 1 }}</td>
<td style="text-align: center">{{ item.doorName }}</td>
<td style="text-align: center">{{ item.personName }}</td>
<td style="text-align: center">{{ item.cardNo }}</td>
<td style="text-align: center">{{ item.inAndOutType === '0' ? '出' : '进' }}</td>
<td style="text-align: center">{{ formatDate(Date.parse(new Date(item.eventTime)),"YYYY-MM-DD HH:mm:ss") }}</td>
</tr>
</table>
</td>
</tr>
<tr v-if="type === 'CAR00005'">
<td colspan="4" style="padding: 0;">
<table class="table-vi">
<tr class="bbg-transparent">
<td>序号</td>
<td>进出位置</td>
<td>车牌号</td>
<td>车辆类型</td>
<td>进出状态</td>
<td>进出时间</td>
</tr>
<tr v-for="(item, index) in measuresList" :key="item.empNo">
<td style="text-align: center">{{ index + 1 }}</td>
<td style="text-align: center">{{ item.ROADWAYNAME }}</td>
<td style="text-align: center">{{ item.PLATENO }}</td>
<td style="text-align: center">{{ item.VEHICLETYPE === '0' ? '其他车' : item.VEHICLETYPE === '1' ? '小型车' :item.VEHICLETYPE === '2' ? '大型车' : '摩托车' }}</td>
<td style="text-align: center">{{ item.VEHICLEOUT === '0' ? '进场' : '出场' }}</td>
<td style="text-align: center">{{ formatDate(Date.parse(new Date(item.CROSSTIME)),"YYYY-MM-DD HH:mm:ss") }}</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
</template>
<script>
import { requestFN } from '@/utils/request'
import moment from 'moment'
export default {
props: {
id: {
type: String,
default() {
return ''
}
},
type: {
type: String,
default() {
return ''
}
},
name: {
type: String,
default() {
return ''
}
},
infoname: {
type: String,
default() {
return ''
}
}
},
data() {
return {
config: config,
ISOTHER: false,
info: {
OTHER_PROTECTIVE_MEASURES: []
},
measuresList: [],
measuresScheduleList: []
}
},
created() {
this.getData()
this.startPersonnelDataTimer()
},
destroyed() {
clearInterval(this.timer) //
},
methods: {
formatDate(date, format) {
if (date) {
return moment(date).format(format)
} else {
return ''
}
},
getData() {
requestFN(
'/map/getGatesInAndOutNumById',
{
GANGKOU: '00005',
GATE_AREA_ID: this.id,
TYPE: this.type,
status: '0',
pageNo: 1,
pageSize: 100
}
).then((data) => {
this.info = data.pd
console.log(data.doorInfo.data.list)
this.measuresList = data.doorInfo.data.list
/* while (this.measuresList.length > 15) {
console.log('删除元素')
this.measuresList.splice(0,1)
}*/
}).catch((e) => {
})
},
//
startPersonnelDataTimer() {
this.timer = setInterval(() => {
console.log('执行定时器查询闸机信息')
this.getDataschedule()
for (let i = 0; i < this.measuresScheduleList.length; i++) {
this.measuresList.push(this.measuresScheduleList[i])
}
/* while (this.measuresList.length > 15) {
console.log('删除元素')
this.measuresList.splice(0,1)
}*/
}, 60000)
},
getDataschedule() {
requestFN(
'/map/getGatesInAndOutNumById',
{
id: this.id,
TYPE: this.type,
status: '1',
pageNo: 1,
pageSize: 10,
GANGKOU: '00005'
}
).then((data) => {
this.measuresScheduleList = data.doorInfo.data.list
}).catch((e) => {
})
}
}
}
</script>
<style lang="scss" scoped>
.martop {
margin-top: 20px;
}
</style>

View File

@ -0,0 +1,120 @@
<template>
<div class="app-container print-work">
<div class="level-title">
<h1>人员信息</h1>
</div>
<table class="table-ui">
<tr>
<td class="bbg-transparent">姓名</td>
<td >{{ info.NAME }}</td>
</tr>
<tr>
<td class="bbg-transparent">工号</td>
<td >{{ id }}</td>
</tr>
<tr>
<td class="bbg-transparent">部门</td>
<td >{{ info?info.DEPARTMENT_NAME:'' }}</td>
</tr>
<tr>
<td class="bbg-transparent">岗位</td>
<td >{{ info?info.POST_NAME:'' }}</td>
</tr>
</table>
<table class="table-ui">
<div class="level-title titles">
<h1>八项作业</h1>
</div>
<tr>
<td colspan="4" style="padding: 0;">
<table class="table-vi">
<tr class="bbg-transparent">
<td>序号</td>
<td>作业类型</td>
<td>作业内容</td>
<td>编号</td>
</tr>
<tr v-for="(item, index) in measuresList" :key="item.ID">
<td>{{ index + 1 }}</td>
<td>{{ item.WORK_TYPE }}</td>
<td>{{ item.WORK_CONTENT }}</td>
<td>{{ item.WORK_NUMBER }}</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
</template>
<script>
import { requestFN } from '@/utils/request'
import moment from 'moment/moment'
export default {
props: {
id: {
type: String,
default() {
return ''
}
},
type: {
type: String,
default() {
return ''
}
},
infoname: {
type: String,
default() {
return ''
}
}
},
data() {
return {
config: config,
info: {},
ImgList: [],
measuresList: [],
gongdanList: []
}
},
created() {
this.getData()
},
methods: {
formatDate(date, format) {
if (date) {
return moment(date).format(format)
} else {
return ''
}
},
getData() {
requestFN(
'/map/findEightsByUserId',
{
cardNo: this.id,
TYPE: this.type
}
).then((data) => {
this.info = data.info
console.log(data.info)
this.ImgList = data.ImgList
this.measuresList = data.varList
}).catch((e) => {
})
}
}
}
</script>
<style lang="scss" scoped>
.titles {
margin-top: 20px;
}
</style>

View File

@ -0,0 +1,66 @@
<template>
<div>
<div id="aLiVideoPlayer" class="prism-player"/>
</div>
</template>
<script>
export default {
props: {
id: {
type: String,
default() {
return ''
}
},
type: {
type: String,
default() {
return ''
}
}
},
data() {
return {
hls: false,
player: null,
url: ''
}
},
beforeDestroy() {
this.player && this.player.dispose()
},
created() {
console.info(this.id)
this.showVideo()
},
methods: {
showVideo() {
this.$nextTick(() => {
// eslint-disable-next-line no-undef
this.player = new Aliplayer({
'id': 'aLiVideoPlayer',
'source': config.ysVideoUrl + '/live/loadmin/38f8c7d91db97445a1f6e0ef5bbd5ae0/' + config.ysVideoDefinition + '/' + this.id + '.m3u8',
// 'source': 'http://172.16.11.146:8991/videoApi/live/loadmin/38f8c7d91db97445a1f6e0ef5bbd5ae0/4/MT-CFD-MK-IPC-16216_1.m3u8',
'width': '100%',
'height': '500px',
'autoplay': true,
'isLive': true,
'rePlay': false,
'playsinline': true,
'preload': true,
'controlBarVisibility': 'hover',
'useH5Prism': true
}, function(player) {
console.log('The player is created')
})
})
}
}
}
</script>
<style lang="scss" scoped>
</style>

View File

@ -0,0 +1,669 @@
<template>
<div class="app-container print-work">
<div class="level-title">
<h1>{{ info.EQUIPMENTNAME }}实时监测数据 {{ info.OPERATTIME }}</h1>
</div>
<div style="display: flex">
<div v-if="info.WINDDIRECTION != '-'" id="main4"/>
<div v-if="info.TEMPERATURE != '-'" id="main5"/>
<div v-if="info.WINDSPEED != '-'" id="main6"/>
</div>
<table class="table-ui">
<tr>
<td class="bbg-transparent">风速监测</td>
<td>{{ info.WINDSPEED }}</td>
<td class="bbg-transparent">风向监测</td>
<td>{{ info.WINDDIRECTION }}</td>
</tr>
<tr>
<td class="bbg-transparent">温度监测</td>
<td>{{ info.TEMPERATURE }}</td>
<td class="bbg-transparent">湿度监测</td>
<td>{{ info.COUNTARCHIVE }}</td>
</tr>
</table>
</div>
</template>
<script>
import { requestFN } from '@/utils/request'
import * as echarts from 'echarts'
let myChart4 = null
let myChart5 = null
let myChart6 = null
export default {
props: {
id: {
type: String,
default() {
return ''
}
},
type: {
type: String,
default() {
return ''
}
},
name: {
type: String,
default() {
return ''
}
}
},
data() {
return {
timer: '',
config: config,
info: {}
}
},
mounted() {
window.onresize = function() {
myChart4 && myChart4.resize()
myChart5 && myChart5.resize()
myChart6 && myChart6.resize()
}
this.getMeteorologicalinfo()
this.start()
},
beforeDestroy() {
myChart4 = null
myChart5 = null
myChart6 = null
console.log('定时器关闭')
clearInterval(this.timer)
},
methods: {
//
start() {
console.log('定时器开启')
this.timer = setInterval(this.getMeteorologicalinfo, 10000) // : ;
},
over() {
clearInterval(this.timer)
},
getMeteorologicalinfo() {
requestFN(
'/map/getDetailByName',
{
FNAME: this.name,
type: this.type
}
).then((data) => {
this.listLoading = false
this.info = data.pd || {}
this.info.COUNTARCHIVE = data.pd.COUNTARCHIVE || '-'
this.info.TEMPERATURE = data.pd.TEMPERATURE || '-'
this.info.WINDSPEED = data.pd.WINDSPEED || '-'
this.info.WINDDIRECTION = data.pd.WINDDIRECTION || '-'
this.$nextTick(() => {
if (data.pd.WINDDIRECTION != '-') {
console.log(this.info.WINDDIRECTION)
this.initEcharts1(data)
this.info.WINDDIRECTION = this.calculateWindDirection(this.info.WINDDIRECTION)
console.log(this.info.WINDDIRECTION)
}
if (data.pd.TEMPERATURE != '-') {
this.initEcharts2(data)
}
if (data.pd.WINDSPEED != '-') {
this.initEcharts3(data)
}
})
}).catch((e) => {
})
},
initEcharts1(data) {
myChart4 = echarts.init(document.querySelector('#main4'))
var option = {
title: {
// x: "center",
top: 0,
text: '风向监测',
textStyle: {
fontWeight: 'normal',
fontSize: 16,
color: '#fff'
}
},
series: {
name: '',
type: 'gauge',
min: 0,
max: 360,
startAngle: 90,
endAngle: -269.9999,
radius: '55%',
splitNumber: 8,
axisLine: {
lineStyle: {
width: 15,
shadowBlur: 0,
color: [
[0.25, '#DDBD4D'],
[0.5, '#E43F3D'],
[0.75, '#7CBB55'],
[1, '#9CD6CE']
]
}
},
axisTick: {
show: true,
splitNumber: 5,
lineStyle: {
color: '#fff'
}
},
splitLine: {
length: 10,
lineStyle: {
width: 5,
color: '#fff'
}
},
axisLabel: {
formatter: function(e) {
switch (e + '') {
case '0':
return '北'
case '45':
return '东北'
case '135':
return '东南'
case '225':
return '西南'
case '315':
return '西北'
case '360':
return '北'
case '180':
return '南'
case '90':
return '东'
case '270':
return '西'
default:
return e
}
},
distance: -60,
textStyle: {
fontSize: 14,
fontWeight: '',
color: '#fff'
}
},
pointer: {
show: true,
length: '80%',
width: 5
},
detail: {
formatter: function(param) {
var level = ''
if (param > 0 && param < 90) {
level = '东北'
} else if (param > 90 && param < 180) {
level = '东南'
} else if (param > 180 && param < 270) {
level = '西南'
} else if (param > 270 && param < 360) {
level = '西北'
} else if (param == 360) {
level = '正北'
} else if (param == 270) {
level = '正西'
} else if (param == 90) {
level = '正东'
} else if (param == 180) {
level = '正南'
}
return '当前风向:' + level + '(' + param + '°)'
},
offsetCenter: [0, 150],
textStyle: {
fontSize: 14,
color: '#fff'
}
},
data: [data.pd.WINDDIRECTION]
}
}
myChart4.setOption(option)
},
initEcharts2(data) {
myChart5 = echarts.init(document.querySelector('#main5'))
var value = data.pd.TEMPERATURE
var kd = []
// 使35
for (var i = 0, len = 130; i <= len; i++) {
if (i > 100 || i < 30) {
kd.push('0')
} else {
if (i % 5 === 0) {
kd.push('5')
} else {
kd.push('3')
}
}
}
// console.log(kd)
// 00-1000-1300-30
function getData(value) {
return [Number(value) + 30]
}
var mercuryColor = '#fd4d49'
var borderColor = '#fd4d49'
const option = {
title: {
text: '温度监测',
show: true,
textStyle: {
fontWeight: 'normal',
fontSize: 16,
color: '#fff'
}
},
yAxis: [{
show: false,
min: 0,
max: 130
}, {
show: false,
data: [],
min: 0,
max: 130
}],
xAxis: [{
show: false,
data: []
}, {
show: false,
data: []
}, {
show: false,
data: []
}, {
show: false,
min: -110,
max: 100
}],
series: [{
name: '条',
type: 'bar',
// XAxis
xAxisIndex: 0,
data: getData(value),
barWidth: 18,
itemStyle: {
normal: {
color: mercuryColor,
barBorderRadius: 0
}
},
label: {
normal: {
show: true,
position: 'top',
formatter: function(param) {
// 00-1000-1300-30
return (((param.value * 100) - (30 * 100)) / 100) + '°C'
},
textStyle: {
color: '#ccc',
fontSize: '10'
}
}
},
z: 2
}, {
name: '白框',
type: 'bar',
xAxisIndex: 1,
barGap: '-100%',
data: [129],
barWidth: 28,
itemStyle: {
normal: {
color: '#ffffff',
barBorderRadius: 50
}
},
z: 1
}, {
name: '外框',
type: 'bar',
xAxisIndex: 2,
barGap: '-100%',
data: [130],
barWidth: 38,
itemStyle: {
normal: {
color: borderColor,
barBorderRadius: 50
}
},
z: 0
}, {
name: '圆',
type: 'scatter',
hoverAnimation: false,
data: [0],
xAxisIndex: 0,
symbolSize: 48,
itemStyle: {
normal: {
color: mercuryColor,
opacity: 1
}
},
z: 2
}, {
name: '白圆',
type: 'scatter',
hoverAnimation: false,
data: [0],
xAxisIndex: 1,
symbolSize: 60,
itemStyle: {
normal: {
color: '#ffffff',
opacity: 1
}
},
z: 1
}, {
name: '外圆',
type: 'scatter',
hoverAnimation: false,
data: [0],
xAxisIndex: 2,
symbolSize: 70,
itemStyle: {
normal: {
color: borderColor,
opacity: 1
}
},
z: 0
}, {
name: '刻度',
type: 'bar',
yAxisIndex: 1,
xAxisIndex: 3,
label: {
normal: {
show: true,
position: 'right',
distance: 10,
color: '#fff',
fontSize: 10,
formatter: function(params) {
// 00-1000-1300-30
if (params.dataIndex > 100 || params.dataIndex < 30) {
return ''
} else {
if (params.dataIndex % 5 === 0) {
return params.dataIndex - 30
} else {
return ''
}
}
}
}
},
barGap: '-100%',
data: kd,
barWidth: 1,
itemStyle: {
normal: {
color: borderColor,
barBorderRadius: 10
}
},
z: 0
}]
}
myChart5.setOption(option)
},
initEcharts3(data) {
myChart6 = echarts.init(document.querySelector('#main6'))
const option = {
// backgroundColor:'#0F2D5B',
title: {
text: '风速监测',
show: true,
textStyle: {
fontWeight: 'normal',
fontSize: 16,
color: '#fff'
}
},
series: [
{
name: '外圈',
type: 'gauge',
min: 0,
max: 30,
splitNumber: 10,
center: ['50%', '55%'],
radius: '73%',
axisLine: {
lineStyle: {
color: [[1, '#2E5BA1']],
width: 20
}
},
splitLine: {
distance: -20,
length: 20,
lineStyle: {
width: 2,
color: '#0F2D5B'
}
},
axisTick: {
distance: -20,
length: 5,
lineStyle: {
color: '#0F2D5B'
}
},
axisLabel: {
distance: -25,
color: '#7392C1',
fontSize: 14
},
anchor: {
show: false
},
pointer: {
show: false
}
},
{
name: '内圈',
type: 'gauge',
min: 0,
max: 30,
splitNumber: 10,
center: ['50%', '55%'],
radius: '65%',
axisLine: {
lineStyle: {
width: 20,
color: [
[0.25, '#18EC90'],
[0.5, '#E2DC2E'],
[0.75, '#E2A02E'],
[1, '#FE4747']
]
}
},
silent: true,
pointer: {
length: '85%',
width: 4,
itemStyle: {
color: 'inherit',
borderWidth: 1,
borderColor: 'inherit', // '#0D3778',
shadowColor: 'inherit',
shadowBlur: 1
}
},
axisTick: {
show: false,
distance: -20,
length: 5,
lineStyle: {
color: '#0F2D5B'
}
},
splitLine: {
distance: -20,
length: 20,
lineStyle: {
width: 2,
color: '#0F2D5B'
}
},
axisLabel: {
show: false
},
title: { //
show: true, // , true
offsetCenter: [0, '95%'], //
color: '#ccc', // , #333
fontSize: 15 // , 15
},
detail: {
valueAnimation: true,
offsetCenter: [0, '70%'],
formatter: '{value}',
color: 'inherit', // , #333
fontSize: 20
},
data: [{
name: '风速(m/s)',
value: data.pd.WINDSPEED
}]
}
]
}
myChart6.setOption(option)
},
calculateWindDirection(angle) {
const arr = [
{
directions: '北',
minAngle: '348.76',
maxAngle: '11.25'
},
{
directions: '北东北',
minAngle: '11.26',
maxAngle: '33.75'
},
{
directions: '东北',
minAngle: '33.76',
maxAngle: '56.25'
},
{
directions: '东东北',
minAngle: '56.26',
maxAngle: '78.75'
},
{
directions: '东',
minAngle: '78.76',
maxAngle: '101.25'
},
{
directions: '东东南',
minAngle: '101.26',
maxAngle: '123.75'
},
{
directions: '东南',
minAngle: '123.76',
maxAngle: '146.25'
},
{
directions: '南东南',
minAngle: '146.26',
maxAngle: '168.75'
},
{
directions: '南',
minAngle: '168.76',
maxAngle: '191.25'
},
{
directions: '南西南',
minAngle: '191.26',
maxAngle: '213.75'
},
{
directions: '西南',
minAngle: '213.76',
maxAngle: '236.25'
},
{
directions: '西西南',
minAngle: '236.26',
maxAngle: '258.75'
},
{
directions: '西',
minAngle: '258.76',
maxAngle: '281.25'
},
{
directions: '西西北',
minAngle: '281.26',
maxAngle: '303.75'
},
{
directions: '西北',
minAngle: '303.76',
maxAngle: '326.25'
},
{
directions: '北西北',
minAngle: '326.26',
maxAngle: '348.75'
}
]
for (let i = 0; i < arr.length; i++) {
if (+angle >= +arr[i].minAngle && +angle <= +arr[i].maxAngle) {
return arr[i].directions + '风'
}
}
return '静风'
}
}
}
</script>
<style lang="scss" scoped>
#main4{
width: 340px;
height: 380px;
}
#main5{
width: 340px;
height: 380px;
}
#main6{
width: 340px;
height: 380px;
}
</style>

View File

@ -39,7 +39,7 @@
:corp-info-id="CORP_INFO_ID"
:gangkou="gangkouActive"/>
<menjin
v-if="gangkouActive && gangkouActive !== '00004' && gangkouActive !== '00002' && bottomOptionsIndex === 0"
v-if="gangkouActive && gangkouActive !== '00004' && gangkouActive !== '00002' && gangkouActive !== '00005' && bottomOptionsIndex === 0"
:corp-info-id="CORP_INFO_ID"
:area="area"
:gangkou="gangkouActive"/>
@ -48,6 +48,11 @@
:corp-info-id="CORP_INFO_ID"
:area="area"
:gangkou="gangkouActive"/>
<menjin-cmt
v-if="gangkouActive && gangkouActive === '00005' && bottomOptionsIndex === 0"
:corp-info-id="CORP_INFO_ID"
:area="area"
:gangkou="gangkouActive"/>
<menjin-czks
v-if="gangkouActive && gangkouActive === '00002' && bottomOptionsIndex === 0"
:corp-info-id="CORP_INFO_ID"
@ -79,7 +84,7 @@
:area="area"
:gangkou="gangkouActive"/>
<renyuan
v-if="gangkouActive && gangkouActive !== '00004' && gangkouActive !== '00002' && bottomOptionsIndex === 4"
v-if="gangkouActive && gangkouActive !== '00004' && gangkouActive !== '00002' && gangkouActive !== '00005' && bottomOptionsIndex === 4"
:corp-info-id="CORP_INFO_ID"
:area="area"
:gangkou="gangkouActive"/>
@ -93,6 +98,11 @@
:corp-info-id="CORP_INFO_ID"
:area="area"
:gangkou="gangkouActive"/>
<renyuanCmt
v-if="gangkouActive && gangkouActive === '00005' && bottomOptionsIndex === 4"
:corp-info-id="CORP_INFO_ID"
:area="area"
:gangkou="gangkouActive"/>
<bianjieruqin
v-if="gangkouActive && gangkouActive !== '00004' && gangkouActive !== '00002' && bottomOptionsIndex === 6"
:corp-info-id="CORP_INFO_ID"
@ -223,6 +233,7 @@
:corp-info-id="dialog.corpInfoId"
:gangkou="gangkouActive"
:infoname="dialog.infoname"
:name="dialog.name"
/>
</div>
</template>
@ -241,11 +252,13 @@ import menjinCzks from './components/menjinCzks.vue'
import renyuanCzks from './components/renyuanCzks.vue'
import menjin from './components/menjin.vue'
import menjinCfd from './components/menjinCfd.vue'
import menjinCmt from './components/menjinCmt.vue'
import xiaofang from './components/xiaofang.vue'
import anquan from './components/anquan.vue'
import anquanCfd from './components/anquanCfd.vue'
import qixiang from './components/qixiang.vue'
import renyuan from './components/renyuan.vue'
import renyuanCmt from './components/renyuanCmt.vue'
import bianjieruqin from './components/bianjieruqin.vue'
import renyuanCfd from './components/renyuanCfd.vue'
import zhongda from './components/zhongda.vue'
@ -267,6 +280,9 @@ let drag = null
let ry_drag = null
var tiandituTk = 'e8a16137fd226a62a23cc7ba5c9c78ce'
var subdomains = ['0', '1', '2', '3', '4', '5', '6', '7']
var PI = 3.1415926535897932384626
var a = 6378245.0 //
var ee = 0.00669342162296594323 // 椭球的偏心率。//判断是否在国内在中国国内的经纬度才需要做偏移
//
let czksPerLocArr = []
const Cesium = window.Cesium
@ -292,10 +308,12 @@ export default {
layoutMenu,
menjin,
menjinCfd,
menjinCmt,
xiaofang,
anquan,
qixiang,
renyuan,
renyuanCmt,
renyuanCfd,
zhongda,
layoutDialog,
@ -365,7 +383,7 @@ export default {
'x': 118.43701,
'y': 38.9866
},
CORP_INFO_ID: 'c077f4ed66844ed4a191a36fa1fc641c'
CORP_INFO_ID: '6aa255d41602497fa0f934a822820df4'
}
],
branchPoint: [],
@ -1389,6 +1407,31 @@ export default {
this.dialog.infoname = infoname
return
}
if (this.gangkouActive === '00005' && point_id.substring(0, 1) !== '1' && point_type !== 'peoplePosition') {
const { label, point_type, data_id, infoname,name, code } = pick.id._monitoItems.data
this.dialog.visible = true
this.dialog.title = label
this.dialog.type = point_type.substring(3) + this.gangkouActive
this.dialog.id = data_id
this.dialog.name = name
this.dialog.id = point_type.substring(3) === 'CAMERA' ? code : point_type.substring(3) === 'platcamera' ? code : data_id
this.dialog.infoname = infoname
console.log(this.dialog)
return
}
if (this.gangkouActive === '00005' && point_type === 'peoplePosition') {
const { label, point_type, id, corpInfoId, name, infoname } = pick.id._monitoItems.data
console.log(pick.id._monitoItems.data)
this.dialog.visible = true
this.dialog.title = label
this.dialog.type = point_type+'00005'
console.log(this.dialog.type)
this.dialog.id = id
this.dialog.name = name
this.dialog.infoname = infoname
this.dialog.corpInfoId = corpInfoId
return
}
if (point_type.indexOf('标记点') !== -1) {
const { label, point_type, data_id, corpInfoId, dialog_width, infoname } = pick.id._monitoItems.data
this.dialog.visible = true
@ -1898,6 +1941,7 @@ export default {
},
bottomOptionsItemsClick(pindex, index, label, urlType, pointUrl, dialog_width) {
var _this = this
if (this.bottomOptionsList[pindex].list[index].check || this.gangkouActive === '00004' && this.cfdBottomOptionsList[pindex].list[index].check) {
//
//
@ -2001,6 +2045,12 @@ export default {
} else {
point.infoname = varList[i].NAME
}
//
if (this.gangkouActive === '00005') {
point.name = varList[i].MAP_POINT_NAME
point.infoname = varList[i].MAP_POINT_NAME
}
console.log(point)
points.push(point)
}
if (this.gangkouActive === '00004' && urlType === 'carPosition') {
@ -2022,6 +2072,13 @@ export default {
} else {
this.dragEntity(points, pindex, index)
}
// websocket
if (this.gangkouActive === '00005' && urlType === 'peoplePosition') {
if (!this.fwebsocket.url) {
this.cmtinitNinePerLocWebsocket()
}
}
_this.dragEntity(points, pindex, index)
}).catch((e) => {
console.log(e)
})
@ -2430,6 +2487,71 @@ export default {
}
}
},
// websocket
cmtinitNinePerLocWebsocket() {
const _this = this
console.info(config.perRealTimeLocUrl)
if (window.WebSocket) {
this.fwebsocket = new WebSocket(encodeURI('ws://' + config.cmtperRealTimeLocUrl)) // oladressmain.jsp
this.fwebsocket.onopen = () => {
console.info('人员定位监听成功')
}
this.fwebsocket.onerror = function() {
console.info('连接失败')
}
this.fwebsocket.onclose = function() {
console.info('onclose')
}
this.fwebsocket.onmessage = function(message) {
const mockData = JSON.parse(message.data)
console.log(mockData)
//
const ninePerLoc = _this.ninePerLocArr.filter(item => {
const index = mockData.findIndex(item1 => {
return item.id.toString() === item1.cardno.toString()
})
return index !== -1
})
//
for (const item of mockData) {
console.log(item)
const wgs84 = _this.gcj02towgs84(parseFloat(item.longitude), parseFloat(item.latitude))
item.longitude = wgs84[0]
item.latitude = wgs84[1]
const index = ninePerLoc.findIndex(item1 => {
return item1.id.toString() === item.cardno.toString()
})
const pointColor = _this.isPointxyWithinTheArea(_this.pointBox, item.longitude, item.latitude)
if (index !== -1) {
ninePerLoc[index].x = item.longitude
ninePerLoc[index].y = item.latitude
ninePerLoc[index].icon_type = 'img4_0' + pointColor
ry_drag.getPosition(ninePerLoc[index])
} else {
const perLoc = {
id: item.cardno,
name: item.name,
x: item.longitude,
y: item.latitude,
point_type: 'peoplePosition',
icon_type: 'img4_0' + pointColor
}
ninePerLoc.push(perLoc)
ry_drag.delEntity(perLoc)
ry_drag.addEntity(perLoc)
var qianzhui = 'person'
_this.allOrientationPoint[qianzhui + item.cardno] = item.cardno
// qianzhui
}
}
// ninePerLocArr
_this.ninePerLocArr = ninePerLoc
}
}
},
/* 一公司人员定位 mqtt务必使用4.2.1版本*/
// websocket
initNinePerLocWebsocket() {
@ -2738,6 +2860,7 @@ export default {
point.empNo = data.empNo || '' //
point.cardNo = data.cardNo || '' //
point.gangkou = this.gangkouActive
console.log(point)
return point
},
//
@ -2797,7 +2920,42 @@ export default {
}
})
},
gcj02towgs84(lng, lat) {
if (this.out_of_china(lng, lat)) {
return [lng, lat]
} else {
var dlat = this.transformlat(lng - 105.0, lat - 35.0)
var dlng = this.transformlng(lng - 105.0, lat - 35.0)
var radlat = lat / 180.0 * PI
var magic = Math.sin(radlat)
magic = 1 - ee * magic * magic
var sqrtmagic = Math.sqrt(magic)
dlat = (dlat * 180.0) / ((a * (1 - ee)) / (magic * sqrtmagic) * PI)
dlng = (dlng * 180.0) / (a / sqrtmagic * Math.cos(radlat) * PI)
const mglat = lat + dlat
const mglng = lng + dlng
return [lng * 2 - mglng, lat * 2 - mglat]
}
},
out_of_china(lng, lat) {
return (lng < 72.004 || lng > 137.8347 || (lat < 0.8293 || lat > 55.8271 || false))
},
//
transformlng(lng, lat) {
var ret = 300.0 + lng + 2.0 * lat + 0.1 * lng * lng + 0.1 * lng * lat + 0.1 * Math.sqrt(Math.abs(lng))
ret += ((20.0 * Math.sin(6.0 * lng * PI) + 20.0 * Math.sin(2.0 * lng * PI)) * 2.0) / 3.0
ret += ((20.0 * Math.sin(lng * PI) + 40.0 * Math.sin((lng / 3.0) * PI)) * 2.0) / 3.0
ret += ((150.0 * Math.sin((lng / 12.0) * PI) + 300.0 * Math.sin((lng / 30.0) * PI)) * 2.0) / 3.0
return ret
},
//
transformlat(lng, lat) {
var ret = -100.0 + 2.0 * lng + 3.0 * lat + 0.2 * lat * lat + 0.1 * lng * lat + 0.2 * Math.sqrt(Math.abs(lng))
ret += ((20.0 * Math.sin(6.0 * lng * PI) + 20.0 * Math.sin(2.0 * lng * PI)) * 2.0) / 3.0
ret += ((20.0 * Math.sin(lat * PI) + 40.0 * Math.sin((lat / 3.0) * PI)) * 2.0) / 3.0
ret += ((160.0 * Math.sin((lat / 12.0) * PI) + 320 * Math.sin((lat * PI) / 30.0)) * 2.0) / 3.0
return ret
},
//
localtionReload(pindex, index) {
var _this = this
@ -2958,8 +3116,8 @@ export default {
}
this.bottomClickDisable = false
done()
}
}
},
},
}
</script>

View File

@ -9,8 +9,8 @@ const img0_2 = require('../../../assets/map/gangkou_index/point/ico3.png')
const img1_0 = require('../../../assets/map/gangkou_index/point/ico4.png')
const img1_1 = require('../../../assets/map/gangkou_index/point/ico5.png')
const img1_2 = require('../../../assets/map/gangkou_index/point/ico6.png')
// const img1_3 = require('../../../assets/map/gangkou_index/point/ico7.png')
const img1_3 = require('../../../assets/map/gangkou_index/point/ico8.png')
const img1_3 = require('../../../assets/map/gangkou_index/point/ico7.png')
const img1_4 = require('../../../assets/map/gangkou_index/point/ico8.png')
const img2_0 = require('../../../assets/map/gangkou_index/point/ico9.png')
const img2_1 = require('../../../assets/map/gangkou_index/point/ico10.png')
@ -53,7 +53,7 @@ const img8_3 = require('../../../assets/map/gangkou_index/point/ico26.png')
const imgMap = {
img0_0, img0_1, img0_2,
img1_0, img1_1, img1_2, img1_3,
img1_0, img1_1, img1_2, img1_3, img1_4,
img2_0, img2_1, img2_2, img2_3, img2_4, img2_5, img2_6, img2_7, cfd_img2_8,
cfd_img3_0, img3_0, img3_1,
img4_0, img4_0_1, img4_0_2, img4_0_3, img4_1,

View File

@ -43,7 +43,9 @@ export default class DragEntity {
this.viewer.clock.clockRange = Cesium.ClockRange.CLAMPED
this.viewer.clock.shouldAnimate = false
}
delEntity(point) {
this.viewer.entities.remove(point)
}
getPosition(point) {
if (this.viewer.clock.shouldAnimate === false) {
this.viewer.clock.shouldAnimate = true

View File

@ -11,6 +11,7 @@ const config = {
weburlNaiwang: 'http://192.168.192.201:8992/', // 附件服务器地址,
httpurlNaiwang: 'http://192.168.192.201:8992//qa-prevention-gwj/', // 附件服务器地址,
perRealTimeLocUrl: '192.168.210.32:8084/netty/test.io',
cmtperRealTimeLocUrl: '192.168.0.247:8899',
cfdfileUrl: 'http://60.2.209.238:8991/file',
xfgUrl: 'https://skqhdg.porthebei.com:9006/static/qrcode/views/xgf_hgz/index.html',
messageUrl: 'http://192.168.151.56:8082/static/qrcode/views/xgf_hgz/index.html'