施工管控修改

This commit is contained in:
cwchen 2024-09-19 11:27:16 +08:00
parent 66cc36b74d
commit 7024f13a11
19 changed files with 65 additions and 14 deletions

BIN
src/assets/gif/1.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 65 KiB

BIN
src/assets/gif/12.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 73 KiB

BIN
src/assets/gif/123.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

BIN
src/assets/gif/1234.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

BIN
src/assets/gif/124.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 79 KiB

BIN
src/assets/gif/13.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 72 KiB

BIN
src/assets/gif/134.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

BIN
src/assets/gif/14.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 73 KiB

BIN
src/assets/gif/2.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 64 KiB

BIN
src/assets/gif/23.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 73 KiB

BIN
src/assets/gif/234.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

BIN
src/assets/gif/24.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 72 KiB

BIN
src/assets/gif/3.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 64 KiB

BIN
src/assets/gif/34.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 73 KiB

BIN
src/assets/gif/4.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 64 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 117 KiB

View File

@ -7,10 +7,10 @@
<el-button type="primary" plain @click="searchData">查询</el-button>
</div>
<div class="dev-box" v-if="isShow">
<div :class="getStyle(item)" @click="sendParams(item.devCode, index)" v-for="(item, index) in devArr"
:key="item.id">
<div :class="getStyle(item)" @click="sendParams(item.devCode, item.warnPosition, index)"
v-for="(item, index) in devArr" :key="item.id">
<img :src="dz_dev_img">
<div class="layout dev-info">
<div class="layout dev-info" :style="{ color: (item.isWarn === 0 ? '#000' : '#ff0000') }">
<div>{{ item.proName }}</div>
<div>班组{{ item.teamName }}</div>
<div>班组长{{ item.teamLeader }}-{{ item.leaderPhone }}</div>
@ -25,7 +25,7 @@
</div>
<div class="center">
<div class="center-1">
<img :src="dz_dev_warn_img" />
<img :src="dz_dev_warn_img" style="width: 100%;height: 100%;object-fit: contain;" />
</div>
<div class="center-2 layout">
<!-- 吊装视频播放 -->
@ -59,7 +59,7 @@
</div>
<div class="infinite-list-wrapper" v-if="isShow3">
<ul class="list" v-infinite-scroll="loadWarnInfoData" infinite-scroll-disabled="busy"
infinite-scroll-distance="50">
infinite-scroll-distance="0">
<li v-for="(item, index) in tableData" :key="index" class="warn-li layout">
<span class="layout">{{ item.devName }}</span>
<span class="layout">{{ item.warnTime }}</span>
@ -184,6 +184,8 @@ export default {
pageNum: 0,
pageSize: 10
},
//
intervalId: null
};
},
created() {
@ -195,8 +197,34 @@ export default {
this.$refs.iframePage.src = this.htmlContent;
this.busy = false;
})
this.startRefresh();
},
destroyed() {
this.stopRefresh();
},
methods: {
startRefresh() {
//
this.intervalId = setInterval(this.refreshData, 1000 * 30 * 1);
},
stopRefresh() {
if (this.intervalId) {
clearInterval(this.intervalId);
this.intervalId = null;
}
},
refreshData() {
alert('刷新了');
//
this.tableData.splice(0);
this.queryParams.pageNum = 0;
this.isHasData = true;
this.loadWarnInfoData();
//
this.devArr.splice(0);
this.isShow = false;
this.laodDzWarnList();
},
/* 吊装设备点击赋值 */
getStyle(item) {
if (item.status === "check") {
@ -208,11 +236,17 @@ export default {
}
},
/* 向吊装视频传递参数 */
sendParams(devCode, index) {
sendParams(devCode, warnPosition, index) {
this.devArr.forEach(item => {
item.status = 'nocheck'
})
this.devArr[index].status = 'check'
//
if (warnPosition) {
this.dz_dev_warn_img = require('../../../../assets/gif/'+warnPosition+'.gif');
} else {
this.dz_dev_warn_img = dz_dev_warn_img;
}
// dom
this.$forceUpdate();
this.$refs.iframePage.contentWindow.postMessage({ devCode: devCode }, '*');
@ -262,8 +296,8 @@ export default {
})
} else {
this.isHasData = false;
if(this.queryParams.pageNum === 1){
this.isShow3 = false;
if (this.queryParams.pageNum === 1) {
this.isShow3 = false;
}
}
this.loading = false;

View File

@ -313,6 +313,12 @@ export default {
created() {
this.getPersonsTree();
},
mounted(){
alert('页面初始化完成');
},
destroyed(){
alert('页面销毁了');
},
methods: {
//
getTodayDate() {
@ -352,14 +358,14 @@ export default {
},
/* 人员树过滤 */
filterNode(value, data, node) {
if (!value) {
/* if (!value) {
if (node.level == 1 || node.level == 2) {
node.expanded = true
} else {
node.expanded = false
}
return true
}
} */
//
let val = value.toLowerCase()
return this.chooseNode(val, data, node)
@ -760,8 +766,12 @@ export default {
},
//icon
renderContent(h, { node, data }) {
let isTeamLeader = data.isTeamLeader, type = data.type,isWarn = data.isWarn,style = '';
if(isWarn === 1){
style = 'warnColor'
}
// 使
let icon, span = <span>{node.label}</span>, isTeamLeader = data.isTeamLeader, type = data.type;
let icon, span = <span class={style}>{node.label}</span>;
if (node.level === 1) {
icon = 'pro_icon';
} else if (node.level === 2) {
@ -770,10 +780,13 @@ export default {
icon = 'team_nocheck_icon';
} else if (node.level === 4 && isTeamLeader === 1) {
icon = '';
span = <span>{node.label} <el-tag size="mini">班组长</el-tag></span>;
span = <span class={style}>{node.label}<el-tag size="mini">班组长</el-tag></span>;
} else if (node.level === 4 && type === 1) {
icon = '';
span = <span>{node.label} <el-tag size="mini">临时人员</el-tag></span>;
span = <span class={style}>{node.label} <el-tag size="mini">临时人员</el-tag></span>;
}else if(node.level === 4 && isTeamLeader === 0 && type === 0){
icon = '';
span = <span class={style}>{node.label}</span>;
}
return (
<span class="custom-tree-node">
@ -1088,4 +1101,8 @@ export default {
::v-deep .team_nocheck_icon {
background-image: url("../../../../assets/images/team_nocheck_icon.png") !important;
}
::v-deep .warnColor {
color: red;
}
</style>

View File

@ -108,7 +108,7 @@
<h4>预警信息</h4>
<div class="infinite-list-wrapper" v-if="isShow3">
<ul class="list" v-infinite-scroll="loadWarnInfoData" infinite-scroll-disabled="busy"
infinite-scroll-distance="50">
infinite-scroll-distance="0">
<li v-for="(item, index) in warnInfoArr" :key="index" class="warn-li layout">
<span class="layout">{{ item.devTypeName }}</span>
<span class="layout">{{ item.devName }}</span>