调令修改

master
xy 2 years ago
parent a25ed0b559
commit 948cd82da6

@ -136,7 +136,7 @@ export default {
}, },
submit() { submit() {
this.smsForm.content = `${ this.$refs['elEdit_feedback_department_id']?.selectedLabel ? this.$refs['elEdit_feedback_department_id'].selectedLabel + '-' : '' }${ this.$refs['elEdit_feedback_admin_id']?.selectedLabel ? this.$refs['elEdit_feedback_admin_id'].selectedLabel + '-' : '' }${ this.form.content }` this.smsForm.content = `调令平台反馈:${ this.$moment().format('YYYY-MM-DD HH:mm') }${ this.row.equipment_id_equipments_id_relation.name },关于${ this.form.content }指令有误,申请${ this.$refs['elEdit_type']?.selectedLabel || '' }`
if (this.type === "add") { if (this.type === "add") {
this.form.transfer_id = this.transfer_id; this.form.transfer_id = this.transfer_id;
if (this.form.hasOwnProperty("id")) { if (this.form.hasOwnProperty("id")) {

@ -104,7 +104,7 @@
执行状态{{ typeMap.get(data.status) }} 执行状态{{ typeMap.get(data.status) }}
</p> </p>
<p> <p>
开启数量{{ data.kaiqishuliang }} / {{ data.equipment_id_equipments_id_relation.bengzhashuliang }} 开启数量{{ data.kaiqishuliang }} / {{ data.equipment_id_equipments_id_relation ? data.equipment_id_equipments_id_relation.bengzhashuliang : 0 }}
</p> </p>
<div style="display:flex;"> <div style="display:flex;">
@ -363,8 +363,8 @@ export default {
[1, "待下发"], [1, "待下发"],
[2, "已下发"], [2, "已下发"],
[3, "确认接收"], [3, "确认接收"],
[4, "已通知开"], [4, "已通知开"],
[5, "确认开"], [5, "确认开"],
[6, "已通知关机"], [6, "已通知关机"],
[7, "确认关机"] [7, "确认关机"]
]), ]),

@ -79,12 +79,12 @@ export default {
}, },
{ {
value: 3, value: 3,
label: "通知开", label: "通知开",
auth: "noticeOpen" auth: "noticeOpen"
}, },
{ {
value: 4, value: 4,
label: "开", label: "开",
auth: "open" auth: "open"
}, },
{ {

@ -121,12 +121,12 @@ export default {
}, },
{ {
value: 3, value: 3,
label: "通知开", label: "通知开",
auth: "noticeOpen" auth: "noticeOpen"
}, },
{ {
value: 4, value: 4,
label: "开", label: "开",
auth: "open" auth: "open"
}, },
], ],

@ -68,11 +68,11 @@ export default {
}, },
{ {
value: 3, value: 3,
label: "通知开" label: "通知开"
}, },
{ {
value: 4, value: 4,
label: "开" label: "开"
} }
], ],
statusType: [ statusType: [

@ -9,6 +9,7 @@
$refs['callbackList'].show() $refs['callbackList'].show()
}" }"
@callback="e => { @callback="e => {
$refs['callback'].setRow(e)
$refs['callback'].setId(e.id) $refs['callback'].setId(e.id)
$refs['callback'].setType('add') $refs['callback'].setType('add')
$refs['callback'].show() $refs['callback'].show()
@ -20,6 +21,7 @@
$refs['callbackList'].show() $refs['callbackList'].show()
}" }"
@callback="e => { @callback="e => {
$refs['callback'].setRow(e)
$refs['callback'].setId(e.id) $refs['callback'].setId(e.id)
$refs['callback'].setType('add') $refs['callback'].setType('add')
$refs['callback'].show() $refs['callback'].show()

@ -14,7 +14,7 @@
</template> </template>
<template> <template>
<template> <template>
<div class="text" v-html="splitSpan(weather ? weather[key] : '')"></div> <div class="text" v-html="key === 'weather' ? weather[key] : splitSpan(weather ? weather[key] : '')"></div>
</template> </template>
</template> </template>
</Card> </Card>

@ -35,7 +35,7 @@
style="width: 300px" style="width: 300px"
> >
<el-option <el-option
v-for="item in tiaozhengleixings" v-for="item in types"
:key="item.id" :key="item.id"
:label="item.value" :label="item.value"
:value="item.id" :value="item.id"
@ -219,6 +219,33 @@ export default {
} else { } else {
return Number(this.detail?.equipment_id_equipments_id_relation?.bengzhashuliang) || 0 return Number(this.detail?.equipment_id_equipments_id_relation?.bengzhashuliang) || 0
} }
},
types () {
let type = this.detail?.equipment_id_equipments_id_relation?.type;
if (type === 1) {
return [
{
id: 0,
value: "关闭"
},
{
id: 1,
value: "新开"
}
]
} else {
return [
{
id: 0,
value: "关闭"
},
{
id: 1,
value: "调整开度"
}
]
}
} }
}, },
watch: { watch: {

@ -245,6 +245,7 @@ export default {
}, },
areas: [], areas: [],
types: [], types: [],
diaolingleixing: [],
abilities: [], abilities: [],
select: { select: {
area: [], area: [],
@ -613,6 +614,29 @@ export default {
} }
},i.key))), },i.key))),
}, },
{
title: "调令类型",
key: "diaolingleixing",
width: 160,
align: "center",
render: (h, { row, index }) =>
h("Select", {
props: {
value: this.data[index].diaolingleixing,
size: "small"
},
on: {
['on-change']:e => {
this.data[index].diaolingleixing = e
}
}
},
this.diaolingleixing.map(i => h("Option",{
props: {
value: i.value
}
},i.key))),
},
{ {
title: "开启时间", title: "开启时间",
width: 140, width: 140,
@ -1159,6 +1183,22 @@ export default {
} }
this.$bus.$emit("yinpaishui", this.abilities); this.$bus.$emit("yinpaishui", this.abilities);
}, },
async getDiaolingleixing() {
const obj = (await show({ id: 85 }, false))?.select_item;
if (obj && typeof obj === "object") {
let keys = Object.keys(obj);
if (keys.length > 0) {
this.diaolingleixing = keys.map((key) => {
return {
key,
value: /^\d*$/.test(obj[key]) ? Number(obj[key]) : obj[key],
};
});
}
}
console.log(this.diaolingleixing)
this.$bus.$emit("diaolingleixing", this.abilities);
},
pickDate() { pickDate() {
this.$bus.$emit("pickDate", this.date); this.$bus.$emit("pickDate", this.date);
@ -1259,6 +1299,7 @@ export default {
this.getType(); this.getType();
this.getAbility(); this.getAbility();
this.getEquipmentInfos(); this.getEquipmentInfos();
this.getDiaolingleixing();
}, },
destroyed() { destroyed() {
this.$bus.$off("getDispatches"); this.$bus.$off("getDispatches");
@ -1273,7 +1314,10 @@ export default {
::v-deep .equip-number .ivu-checkbox ~ span { ::v-deep .equip-number .ivu-checkbox ~ span {
display: none; display: none;
} }
.flex-center { ::v-deep .ivu-checkbox-inner {
border-color: $primaryColor;
}
.flex-center {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: center; justify-content: center;

@ -22,7 +22,7 @@
</template> </template>
<template> <template>
<template> <template>
<div class="text" v-html="splitSpan(weather ? weather[key] : '')"></div> <div class="text" v-html="key === 'weather' ? weather[key] : splitSpan(weather ? weather[key] : '')"></div>
</template> </template>
</template> </template>
</Card> </Card>

@ -25,9 +25,6 @@
<Select clearable v-model="select.filter[1].value" placeholder="请选择类别" style="width: 140px;margin-left: 6px;"> <Select clearable v-model="select.filter[1].value" placeholder="请选择类别" style="width: 140px;margin-left: 6px;">
<Option v-for="item in abilities" :value="item.value">{{ item.key }}</Option> <Option v-for="item in abilities" :value="item.value">{{ item.key }}</Option>
</Select> </Select>
<Select clearable v-model="selectArea" placeholder="请选择范围" style="width: 140px;margin-left: 6px;">
<Option v-for="item in areas" :value="item.value">{{ item.key }}</Option>
</Select>
<Input style="width: 140px;margin-left: 6px;" clearable v-model="select.filter[0].value" placeholder="搜索内容"/> <Input style="width: 140px;margin-left: 6px;" clearable v-model="select.filter[0].value" placeholder="搜索内容"/>
<!-- <Select--> <!-- <Select-->
<!-- v-model="select.filter[0].key"--> <!-- v-model="select.filter[0].key"-->
@ -532,6 +529,11 @@ export default {
return false return false
} }
} }
if ([7].find(i => i.status)) {
if (item === 'adjust') {
return false
}
}
return true return true
}, },

Loading…
Cancel
Save