|
|
|
|
@ -104,7 +104,13 @@
|
|
|
|
|
:span-method="objectSpanMethod"
|
|
|
|
|
></Table>
|
|
|
|
|
|
|
|
|
|
<div class="btns">
|
|
|
|
|
<div class="btns" ref="btns">
|
|
|
|
|
<Button type="primary" @click="submit">创建调令</Button>
|
|
|
|
|
<Button type="primary" ghost @click="reset">重置列表</Button>
|
|
|
|
|
<Button type="primary" ghost @click="clone">创建模板</Button>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="btns fixed-btns" :style="{ 'display': isFixedBtns ? 'block' : 'none' }">
|
|
|
|
|
<Button type="primary" @click="submit">创建调令</Button>
|
|
|
|
|
<Button type="primary" ghost @click="reset">重置列表</Button>
|
|
|
|
|
<Button type="primary" ghost @click="clone">创建模板</Button>
|
|
|
|
|
@ -124,6 +130,7 @@ export default {
|
|
|
|
|
props: {},
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
isFixedBtns: true,
|
|
|
|
|
isSelectAllType: false,
|
|
|
|
|
isSelectAllArea: false,
|
|
|
|
|
equipmentInfos: { shuniu: [], waiwei: [], zhazhan: [] },
|
|
|
|
|
@ -546,61 +553,6 @@ export default {
|
|
|
|
|
}, Array.from({ length: Number(row.equipment.shuibengtaishu || 0)},
|
|
|
|
|
(_,i) => this.$createElement("Checkbox",{ props: { label: i } })))
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: "机组运行状态",
|
|
|
|
|
width: 200,
|
|
|
|
|
render: (h, { row }) => {
|
|
|
|
|
let name = row.equipment.name;
|
|
|
|
|
let type = row.equipment.type;
|
|
|
|
|
const create = () => {
|
|
|
|
|
let dom = [];
|
|
|
|
|
let cirs = []
|
|
|
|
|
if (/枢纽/g.test(name)) {
|
|
|
|
|
const datas = this.equipmentInfos.shuniu.find(i => (name === i.stnm) )?.data[0]
|
|
|
|
|
if (datas) {
|
|
|
|
|
let values = datas.Value?.split('.')
|
|
|
|
|
values.forEach(i => {
|
|
|
|
|
cirs.push(Number(i))
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
const datas = this.equipmentInfos.zhazhan.find(i => (name === i.STNMNEW || name === i.STNM) )?.data[0]
|
|
|
|
|
if (datas) {
|
|
|
|
|
Object.keys(datas).forEach(key => {
|
|
|
|
|
if (/PUMP+/.test(key)) {
|
|
|
|
|
if (datas[key]) {
|
|
|
|
|
cirs.push(Number(datas[key]))
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
for (let i = 0; i < cirs.length; i++) {
|
|
|
|
|
dom.push(
|
|
|
|
|
h("div", {
|
|
|
|
|
style: {
|
|
|
|
|
width: "14px",
|
|
|
|
|
height: "14px",
|
|
|
|
|
background: cirs[i] ? "green" : "red",
|
|
|
|
|
"border-radius": "100%",
|
|
|
|
|
"margin-left": "6px",
|
|
|
|
|
},
|
|
|
|
|
})
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
return dom;
|
|
|
|
|
};
|
|
|
|
|
return h(
|
|
|
|
|
"div",
|
|
|
|
|
{
|
|
|
|
|
style: {
|
|
|
|
|
display: "flex",
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
create()
|
|
|
|
|
);
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: "类别",
|
|
|
|
|
key: "yinpaishui",
|
|
|
|
|
@ -1378,7 +1330,14 @@ export default {
|
|
|
|
|
deep: true,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
mounted() {},
|
|
|
|
|
mounted() {
|
|
|
|
|
let _this = this;
|
|
|
|
|
document.querySelector(".app-wrapper").onscroll = function () {
|
|
|
|
|
let btnsTop = _this.$refs['btns']?.getBoundingClientRect()?.y;
|
|
|
|
|
let btnsHeight = _this.$refs['btns']?.getBoundingClientRect()?.height;
|
|
|
|
|
_this.isFixedBtns = btnsTop > (window.innerHeight-btnsHeight);
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
created() {
|
|
|
|
|
this.$bus.$on(
|
|
|
|
|
"getDispatches",
|
|
|
|
|
@ -1391,6 +1350,7 @@ export default {
|
|
|
|
|
this.getDiaolingleixing();
|
|
|
|
|
},
|
|
|
|
|
destroyed() {
|
|
|
|
|
document.querySelector(".app-wrapper").onscroll = null;
|
|
|
|
|
this.$bus.$off("getDispatches");
|
|
|
|
|
},
|
|
|
|
|
};
|
|
|
|
|
@ -1435,7 +1395,17 @@ export default {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
.btns {
|
|
|
|
|
background: #fff;
|
|
|
|
|
margin-top: 10px;
|
|
|
|
|
padding-left: 10px;
|
|
|
|
|
}
|
|
|
|
|
.fixed-btns {
|
|
|
|
|
width: 100%;
|
|
|
|
|
margin-top: 0;
|
|
|
|
|
padding: 10px 40px;
|
|
|
|
|
|
|
|
|
|
position: fixed;
|
|
|
|
|
bottom: 0;
|
|
|
|
|
left: 0;
|
|
|
|
|
}
|
|
|
|
|
</style>
|
|
|
|
|
|