diff --git a/src/views/bigScreen1/index.vue b/src/views/bigScreen1/index.vue
index 464f8f7..dba7f1a 100644
--- a/src/views/bigScreen1/index.vue
+++ b/src/views/bigScreen1/index.vue
@@ -268,8 +268,8 @@ export default {
},
{
key: "status",
- op: "range",
- value: "2,7"
+ op: "neq",
+ value: "1"
}
]
})).data
@@ -279,14 +279,21 @@ export default {
if (i.status === 2) {
i._isNew = true;
}
+ if (i.status === 0) {
+ this.$Notice.warning({
+ title: '调令被取消',
+ desc: `取消调令:[${i.equipment_id_equipments_id_relation?.name}]${i.content},计划开始时间${i.start_time}`,
+ duration: 0
+ });
+ }
if (this.transfers1.findIndex(j => j.id === i.id) !== -1) {
- this.transfers1.splice(this.transfers1.findIndex(j => j.id === i.id),1,i)
+ i.status !== 0 ? this.transfers1.splice(this.transfers1.findIndex(j => j.id === i.id),1,i) : this.transfers1.splice(this.transfers1.findIndex(j => j.id === i.id),1)
}
else if (this.transfers2.findIndex(j => j.id === i.id) !== -1) {
- this.transfers2.splice(this.transfers2.findIndex(j => j.id === i.id),1,i)
+ i.status !== 0 ? this.transfers2.splice(this.transfers2.findIndex(j => j.id === i.id),1,i) : this.transfers2.splice(this.transfers2.findIndex(j => j.id === i.id),1)
}
else if (this.transfers3.findIndex(j => j.id === i.id) !== -1) {
- this.transfers3.splice(this.transfers3.findIndex(j => j.id === i.id),1,i)
+ i.status !== 0 ? this.transfers3.splice(this.transfers3.findIndex(j => j.id === i.id),1,i) : this.transfers3.splice(this.transfers3.findIndex(j => j.id === i.id),1)
} else {
if (i.status === 2) {
this.transfers1.unshift(i)
diff --git a/src/views/order/component/createDispatch.vue b/src/views/order/component/createDispatch.vue
index f7535b7..9cc8336 100644
--- a/src/views/order/component/createDispatch.vue
+++ b/src/views/order/component/createDispatch.vue
@@ -104,7 +104,13 @@
:span-method="objectSpanMethod"
>
-
+
+
+
+
+
+
+
@@ -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;
+}
diff --git a/src/views/order/component/dispatchList.vue b/src/views/order/component/dispatchList.vue
index 11ecd1a..fe2f1ed 100644
--- a/src/views/order/component/dispatchList.vue
+++ b/src/views/order/component/dispatchList.vue
@@ -135,6 +135,11 @@ export default {
width: 54,
type: "selection"
},
+ {
+ width: 100,
+ title: "序号",
+ key: "xuhao"
+ },
{
title: "范围",
width: 140,
diff --git a/src/views/order/feedbackList.vue b/src/views/order/feedbackList.vue
index 387b14c..bfebe34 100644
--- a/src/views/order/feedbackList.vue
+++ b/src/views/order/feedbackList.vue
@@ -681,33 +681,37 @@ export default {
prop: "transfer_id_transfers_id_relation.content"
})
this.table.unshift({
- type: "index",
- width: 60,
- label: "序号",
+ type: "transfer_id_transfers_id_relation.xuhao",
+ width: 100,
+ label: "调令序号",
});
},
adjustAlignment () {
if (this.firstAdjustTable) {
const data = this.$refs['xyTable'].getListData();
- if (data.length === 0) return;
- this.form.filter(i => i.list_show).forEach((i) => {
- let lengthTemp;
- let temp = 0;
- while (!lengthTemp || temp < data.length) {
- lengthTemp = data[temp][i.field]?.length??0;
- temp++;
- }
- for (let j = 0;j < data.length;j++) {
- if (/^-?\d+\.\d+/.test(data[j][i.field])) {
+ if (data.length < 2) return;
+ try {
+ this.form.filter(i => i.list_show).forEach((i) => {
+ let maxLength = -Infinity;
+ let minLength = Infinity;
+ let numberLength = 0;
+ let temp = 0;
+ while (temp < data.length) {
+ maxLength = Math.max(maxLength, data[temp][i.field]?.length??0);
+ minLength = Math.min(minLength, data[temp][i.field]?.length??0);
+ numberLength += /^-?[0-9]+(\.[0-9]+)?$/.test(data[temp][i.field]) ? 1 : 0;
+ temp++;
+ }
+ if (numberLength === temp && numberLength !== 0 && i.edit_input !== 'radio') {
this.table.find(a => a.prop === i.field).align = 'right';
- return
}
- if (Math.abs(lengthTemp - (data[j][i.field]?.length)??0) > 4) {
+ else if (Math.abs(maxLength - minLength) > 4) {
this.table.find(a => a.prop === i.field).align = 'left';
- return
}
- }
- })
+ })
+ } catch (e) {
+ console.error(e)
+ }
this.$nextTick(() => {
this.$refs['xyTable'].doLayout();
this.firstAdjustTable = false;
diff --git a/src/views/order/handle.vue b/src/views/order/handle.vue
index b147bf0..2a365d0 100644
--- a/src/views/order/handle.vue
+++ b/src/views/order/handle.vue
@@ -146,7 +146,7 @@