库区设置

清空盘点
盘点照片
增加随行未操作黄色图标
hebei-cangzhouyancao
yiming 3 years ago committed by LAPTOP-S9HJSOEB\昊天
parent 06d7eb0bff
commit 931f83c546

Binary file not shown.

@ -10,12 +10,12 @@
<!-- <script src="/video_play_plugins/video.js"></script> --> <!-- <script src="/video_play_plugins/video.js"></script> -->
<script src="/video_play_plugins/webrtcplayer.js"></script> <script src="/video_play_plugins/webrtcplayer.js"></script>
<title>昆船垛机视觉系统</title> <title>垛机视觉系统</title>
</head> </head>
<body> <body>
<noscript> <noscript>
<strong>We're sorry but 昆船垛机视觉系统 doesn't work properly without JavaScript enabled. Please enable it to <strong>We're sorry but 垛机视觉系统 doesn't work properly without JavaScript enabled. Please enable it to
continue.</strong> continue.</strong>
</noscript> </noscript>

@ -66,6 +66,16 @@ export default {
url: "/realTime/allCameras", url: "/realTime/allCameras",
name: "获取全部球机" name: "获取全部球机"
}, },
allCamerasByArea:{
method: "GET",
url: "/realTime/allCamerasByArea",
name: "根据库区查询球机"
},
getAllAreas:{
method: "GET",
url: "/realTime/allAreas",
name: "获取全部库区"
},
getWallStyle:{ getWallStyle:{
method: "GET", method: "GET",
url: "/realTime/wallStyle", url: "/realTime/wallStyle",
@ -227,6 +237,11 @@ export default {
url: '/ScanAndCheck', url: '/ScanAndCheck',
name: '盘点操作里参数', name: '盘点操作里参数',
method: 'GET' method: 'GET'
},
clearStock: {
url: '/stock/clearStock',
name: '清空盘点',
method: 'GET'
} }
} }

@ -10,6 +10,7 @@
> >
<span slot="tab" > <span slot="tab" >
{{ getRandom(latticeRow + 1 -index, latticeRow, nums.row, total.row) }} {{ getRandom(latticeRow + 1 -index, latticeRow, nums.row, total.row) }}
<a-icon type="check-circle" v-if="status.row[index] === 3" style="color: #e7c205f1" />
<a-icon type="close-circle" v-if="status.row[index] === 1" style="color: #d81e06"/> <a-icon type="close-circle" v-if="status.row[index] === 1" style="color: #d81e06"/>
<a-icon type="check-circle" v-else-if="status.row[index] === 2" style="color: #1afa29" /> <a-icon type="check-circle" v-else-if="status.row[index] === 2" style="color: #1afa29" />
<a-icon type="exclamation-circle" v-else style="color: #909399" /> <a-icon type="exclamation-circle" v-else style="color: #909399" />
@ -48,7 +49,8 @@
<span slot="tab"> <span slot="tab">
{{ getRandom(index, latticeColumn, nums.column, total.column) }} {{ getRandom(index, latticeColumn, nums.column, total.column) }}
<!-- <a-icon :id="`${shelveId}-row-${getRandom(index,latticeRow,nums.row,total.row)}`"/> --> <!-- <a-icon :id="`${shelveId}-row-${getRandom(index,latticeRow,nums.row,total.row)}`"/> -->
<a-icon type="close-circle" v-if="status.column[index] === 1" style="color: #d81e06" /> <a-icon type="check-circle" v-if="status.column[index] === 3" style="color: #e7c205f1" />
<a-icon type="close-circle" v-else-if="status.column[index] === 1" style="color: #d81e06" />
<a-icon type="check-circle" v-else-if="status.column[index] === 2" style="color: #1afa29" /> <a-icon type="check-circle" v-else-if="status.column[index] === 2" style="color: #1afa29" />
<a-icon type="exclamation-circle" v-else style="color: #909399" /> <a-icon type="exclamation-circle" v-else style="color: #909399" />
</span> </span>
@ -217,7 +219,7 @@ export default {
getStatusBg(row,column,status) { getStatusBg(row,column,status) {
var dom = document.getElementById(this.direction+"-"+this.side+"-"+row+'-'+column); var dom = document.getElementById(this.direction+"-"+this.side+"-"+row+'-'+column);
var color = status == 1 ?'#d81e06': (status == 2|| status == 3) ? '#1afa29': '#bfbfbf'; var color = status == 1 ?'#d81e06': (status == 2 ||status == 3 ) ? '#1afa29': (status == 0)?'#f9e182':'#bfbfbf';
dom.style.background = color dom.style.background = color
}, },

@ -39,30 +39,18 @@
style="display: flex;align-items: center;justify-content: center;width:100px;height:300px;"> style="display: flex;align-items: center;justify-content: center;width:100px;height:300px;">
暂无图片 暂无图片
</div> </div>
<p>盘点</p> <p>盘点顶部</p>
</div> </div>
<div class="img-box"> <div class="img-box">
<viewer v-if="checkObj.preoperationPic" style="height:300px;"> <viewer v-if="checkObj.checkPic" style="height: 300px">
<img :src="imgUrl+checkObj.preoperationPic"/> <img :src="imgUrl+checkObj.checkPic+'.jpg'"/>
</viewer>
<div v-else style="display: flex;align-items: center;justify-content: center;width:100px;height:300px;">
暂无图片
</div>
<p>操作前照片</p>
</div>
<div class="img-box">
<viewer v-if="checkObj.overoperationPic" style="width:100%;height:300px;">
<img :src="imgUrl+checkObj.overoperationPic"/>
</viewer> </viewer>
<div <div
v-else v-else
style="display: flex;align-items: center;justify-content: center;width:100px;height:300px;"> style="display: flex;align-items: center;justify-content: center;width:100px;height:300px;">
暂无图片 暂无图片
</div> </div>
<p>操作后照片</p> <p>盘点侧面图</p>
</div> </div>
</div> </div>
</div> </div>
@ -120,12 +108,18 @@ export default {
label:'盘点任务号', label:'盘点任务号',
key: 'checkNum' key: 'checkNum'
}, },
{ {
label:'盘点时间', label:'盘点时间',
key: 'exportTime' key: 'exportTime'
}, },
{
label:'wms条码',
key: 'wmsCode'
},
{
label:'扫描条码',
key: 'trayCode'
},
], ],
statusMap: {0:"未盘点",1:"盘点异常",2:"核对正确",3:"人工核对正确"} statusMap: {0:"未盘点",1:"盘点异常",2:"核对正确",3:"人工核对正确"}

@ -1,6 +1,17 @@
<template> <template>
<div class="check-page"> <div class="check-page">
<div class="button-box"> <div class="button-box">
<a-popconfirm
title="是否确定清空盘点"
ok-text="是"
cancel-text="否"
@confirm="clearStock"
>
<a-button type="primary" class="export-all">
清空盘点
</a-button>
</a-popconfirm>
<a-button type="primary" @click="exportStock" class="export-all"> <a-button type="primary" @click="exportStock" class="export-all">
导出巷道盘点数据 导出巷道盘点数据
</a-button> </a-button>
@ -17,6 +28,10 @@
<span class="info-text"> <span class="info-text">
<a-tag color="#1afa29" style="width:30px;height:20px;margin-right:6px"></a-tag> <a-tag color="#1afa29" style="width:30px;height:20px;margin-right:6px"></a-tag>
盘点正确 盘点正确
</span>
<span class="info-text">
<a-tag color="#f9e182" style="width:30px;height:20px;margin-right:6px"></a-tag>
未确认
</span> </span>
<span class="info-text"> <span class="info-text">
<a-tag color="#bfbfbf" style="width:30px;height:20px;margin-right:6px"></a-tag> <a-tag color="#bfbfbf" style="width:30px;height:20px;margin-right:6px"></a-tag>
@ -170,6 +185,14 @@ export default {
}); });
}, },
clearStock() {
this.$api.httpApi.clearStock({
}).then(res => {
message.info('已清空盘点信息');
}).catch(err => {
});
},
exportAllStock() { exportAllStock() {
this.$utils.downloadFileUrl('盘点列表.xls', '/api/stock/exportAll'); this.$utils.downloadFileUrl('盘点列表.xls', '/api/stock/exportAll');

@ -106,10 +106,11 @@
<template> <template>
<span style="height:100%;"> <span style="height:100%;">
<happy-scroll color="rgba(100,100,100,0.5)" size="8" class="scroll-box" style="width:320px;height:90px;"> <happy-scroll color="rgba(100,100,100,0.5)" size="8" class="scroll-box" style="width:320px;height:90px;">
<viewer><img class="historyImg" :src="imgUrl+text.pic"/></viewer> <viewer><img class="historyImg" :src="imgUrl+text.pic"/>
<img class="historyImg" :src="imgUrl+text.pic+'.jpg'"/>
</viewer>
</happy-scroll> </happy-scroll>
</span> </span>
</template> </template>
</span> </span>

@ -1,9 +1,10 @@
<template> <template>
<div class="realTime bg-white"> <div class="realTime bg-white">
<a-tabs default-active-key="1" slot="headerContent" v-model="tabKey" @change="tabsChange" padding:10px> <a-tabs default-active-key="1" slot="headerContent" v-model="tabKey" @change="tabsChange" padding:10px>
<a-tab-pane :key="item.streetId.toString()" :tab="item.streetName" v-for="item in realTimeListData"></a-tab-pane> <a-tab-pane :key="item.streetId.toString()" :tab="item.streetName" v-for="item in realTimeListData">
</a-tab-pane>
</a-tabs> </a-tabs>
<!-- {{cameras.length}} {{ selectTab.videoStyleRow }} * {{ selectTab.videoStyleColumn }}-->
<a-row :gutter="20"> <a-row :gutter="20">
<a-col <a-col
v-for="(item, index) in cameras.slice(0, selectTab.videoStyleRow * selectTab.videoStyleColumn)" v-for="(item, index) in cameras.slice(0, selectTab.videoStyleRow * selectTab.videoStyleColumn)"

@ -25,6 +25,7 @@
v-decorator="['plcId', { rules: [{ required: true, message: '请输入巷道标识!' }] }]" v-decorator="['plcId', { rules: [{ required: true, message: '请输入巷道标识!' }] }]"
/> />
</a-form-item> </a-form-item>
</div> </div>
<div class="across-layout"> <div class="across-layout">
<a-form-item label="PLC IP" :label-col="formItemAcrossLayout.labelCol"> <a-form-item label="PLC IP" :label-col="formItemAcrossLayout.labelCol">
@ -277,7 +278,8 @@ export default {
camera1Id:newVal.camera1Id, camera1Id:newVal.camera1Id,
camera2Id:newVal.camera2Id, camera2Id:newVal.camera2Id,
camera1Name:newVal.camera1Name, camera1Name:newVal.camera1Name,
camera2Name:newVal.camera2Name camera2Name:newVal.camera2Name,
area:newVal.area
}) })
}) })
} }

@ -3,6 +3,12 @@
<a-button type="primary" @click="full" v-if="!isFullscreen"> <a-icon type="right" /> </a-button> <a-button type="primary" @click="full" v-if="!isFullscreen"> <a-icon type="right" /> </a-button>
<a-button type="primary" @click="full" v-if="isFullscreen"><a-icon type="left" /> 退出全屏 </a-button> <a-button type="primary" @click="full" v-if="isFullscreen"><a-icon type="left" /> 退出全屏 </a-button>
<!-- @change="tabsChange" v-model="tabKey"-->
<a-tabs v-model="activeKey" slot="headerContent" @change="tabChange" v-if="areas" padding:10px>
<a-tab-pane :key="item.toString()" :tab="item" v-for="item in areas">
</a-tab-pane>
</a-tabs>
<a-row v-for='rowIndex in row' :key='rowIndex'> <a-row v-for='rowIndex in row' :key='rowIndex'>
<a-col v-for='colIndex in column' :key='colIndex' :span="24/column" :style="{height: videoHeight}" > <a-col v-for='colIndex in column' :key='colIndex' :span="24/column" :style="{height: videoHeight}" >
<video class="camera" :id="rowIndex+'-'+colIndex" autoplay muted :style="{'height': '100%',width:'100%','object-fit':'fill'}" ></video> <video class="camera" :id="rowIndex+'-'+colIndex" autoplay muted :style="{'height': '100%',width:'100%','object-fit':'fill'}" ></video>
@ -35,7 +41,9 @@ export default {
isFullscreen: false, isFullscreen: false,
originHeight: 0, originHeight: 0,
fullHeight: 0, fullHeight: 0,
players: [] players: [],
areas:[],
activeKey: ''
} }
}, },
//watch: {}, //watch: {},
@ -51,7 +59,8 @@ export default {
this.getWallStyle(); this.getWallStyle();
this.$nextTick(() => { this.$nextTick(() => {
this.getAllCameras()
this.getAllAreas()
}); });
let isFullscreen = let isFullscreen =
document.fullscreenElement || document.fullscreenElement ||
@ -124,13 +133,55 @@ export default {
console.log(err) console.log(err)
}) })
}, },
getAllAreas(){
this.$api.httpApi.getAllAreas({
data: {}
}).then(res => {
if(res.code == 200) {
this.getAllCameras()
}
}).catch(err => {
console.log(err)
})
},
destory(){ destory(){
for(let player of this.players){ for(let player of this.players){
console.log("stop") console.log("stop")
player.destroy() player.destroy()
} }
this.players = []
}, },
tabChange(){
this.destory();
this.$api.httpApi.allCamerasByArea({
params:{
area:this.activeKey
}
}).then(res => {
if(res.code == 200) {
let cameras = res.data;
for(let i = 1;i<=cameras.length;i++){
let rowIndex = Math.floor((i-1) / this.column) + 1;
if(rowIndex > this.row){
return
}
let columnIndex = i % this.column;
if(columnIndex == 0){
columnIndex = this.column;
}
let idName = rowIndex + "-" + columnIndex;
console.log("idName:"+idName);
let server = cameras[i-1].rtcServer+":"+ cameras[i-1].rtcServerPort
let video = document.getElementById(idName);
let player = new WebRtcPlayer(server,video,"camera"+cameras[i-1].id);
this.players.push(player);
}
}
}).catch(err => {
console.log(err)
})
},
full () { full () {
if(this.isFullscreen){ if(this.isFullscreen){
this.exitfullscreen() this.exitfullscreen()

Loading…
Cancel
Save