修改维修提交
This commit is contained in:
parent
95fbe0176c
commit
e2c11c0b5d
@ -80,7 +80,7 @@
|
||||
</span>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="24" style="margin: 0">
|
||||
<el-row :gutter="24" style="margin: 0" v-if="item.repair_action != 3">
|
||||
<el-col :span="6" :lg="6" :md="8" :xs="24">
|
||||
<span class="name">不良现象</span>
|
||||
<div class="text">
|
||||
@ -91,21 +91,24 @@
|
||||
<el-col :span="6" :lg="6" :md="8" :xs="24">
|
||||
<span class="name">SLA不达标原因</span>
|
||||
<div class="text">
|
||||
<el-input :size="size" v-model="item.sla_non_compliance_reason" placeholder="SLA不达标原因"></el-input>
|
||||
<el-input :size="size" v-model="item.sla_non_compliance_reason"
|
||||
placeholder="SLA不达标原因"></el-input>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="24" style="margin: 0">
|
||||
<el-row :gutter="24" style="margin: 0" v-if="item.repair_action != 3">
|
||||
<el-col :span="12" :lg="12" :md="12" :xs="24">
|
||||
<span class="name">现场步骤分析</span>
|
||||
<div class="text">
|
||||
<el-input type="textarea" :size="size" v-model="item.analysis_steps" placeholder="现场步骤分析"></el-input>
|
||||
<el-input type="textarea" :size="size" v-model="item.analysis_steps"
|
||||
placeholder="现场步骤分析"></el-input>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<div class="btnAdd" v-if="item.repair_action === 1">
|
||||
<div class="cardBody">
|
||||
<sc-table ref="table" :data="params.repair_info" style="width: 100%;" :hidePagination="true" :hideDo="true" :hideEmpty="true" :size="size">
|
||||
<sc-table ref="table" :data="params.repair_info" style="width: 100%;" :hidePagination="true"
|
||||
:hideDo="true" :hideEmpty="true" :size="size">
|
||||
<sc-table-column type="index" label="序号" width="65"></sc-table-column>
|
||||
<sc-table-column prop="new_part_mpn" label="部件MPN" :show-overflow-tooltip="true" width="240">
|
||||
<template #default="scope">
|
||||
@ -133,7 +136,8 @@
|
||||
</el-scrollbar>
|
||||
</el-main>
|
||||
</el-container>
|
||||
<info-save-dialog ref="saveDialog" v-if="dialog.save" @success="handleSaveSuccess" @closed="dialog.save=false"></info-save-dialog>
|
||||
<info-save-dialog ref="saveDialog" v-if="dialog.save" @success="handleSaveSuccess"
|
||||
@closed="dialog.save=false"></info-save-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
@ -160,7 +164,7 @@ export default {
|
||||
sla_non_compliance_reason: "",
|
||||
confirmed_defects: "",
|
||||
analysis_steps: "",
|
||||
repair_action:""
|
||||
repair_action: 3
|
||||
}
|
||||
]
|
||||
},
|
||||
@ -198,9 +202,24 @@ export default {
|
||||
|
||||
},
|
||||
async submit() {
|
||||
const res = await this.$API.orders.order.repair.submit.post(this.params);
|
||||
let data = this.$TOOL.objCopy(this.params)
|
||||
data.repair_info.forEach(item => {
|
||||
if (item.repair_action === 2) {
|
||||
delete item.new_part_mpn
|
||||
delete item.new_part_sn
|
||||
delete item.sla
|
||||
} else if (item.repair_action === 3) {
|
||||
delete item.new_part_mpn
|
||||
delete item.new_part_sn
|
||||
delete item.sla
|
||||
delete item.confirmed_defects
|
||||
delete item.sla_non_compliance_reason
|
||||
delete item.analysis_steps
|
||||
}
|
||||
});
|
||||
const res = await this.$API.orders.order.repair.submit.post(data);
|
||||
if (res.code == 200) {
|
||||
console.log(res.data)
|
||||
this.$message.success('操作成功')
|
||||
}
|
||||
},
|
||||
|
||||
@ -209,47 +228,68 @@ export default {
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.mainView{background: #fff;}
|
||||
.title{color: #222;font-weight: 600;}
|
||||
.mainView {
|
||||
background: #fff;
|
||||
}
|
||||
|
||||
.title {
|
||||
color: #222;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.boxListBorderBottom {
|
||||
border-bottom: 1px solid #e8e8e8;
|
||||
padding-bottom: 5px;
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
|
||||
.boxList {
|
||||
margin-top: 15px;
|
||||
|
||||
.el-row {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
|
||||
.el-col {
|
||||
margin: 0 0 12px 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.flexCol {
|
||||
padding: 5px 12px 6px 12px;
|
||||
}
|
||||
}
|
||||
|
||||
.name {
|
||||
color: #555;
|
||||
display: inline-block;
|
||||
margin-bottom: 6px;
|
||||
}
|
||||
}
|
||||
|
||||
.btnBox {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.cardBody {
|
||||
margin-top: 15px;
|
||||
}
|
||||
|
||||
.flexCol {
|
||||
display: flex;align-items: center;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.name {
|
||||
margin-bottom: 0;
|
||||
margin-right: 15px;
|
||||
}
|
||||
|
||||
.text {
|
||||
font-weight: 400;
|
||||
}
|
||||
}
|
||||
.btnAdd{margin-top: 15px;}
|
||||
|
||||
.btnAdd {
|
||||
margin-top: 15px;
|
||||
}
|
||||
</style>
|
||||
Loading…
Reference in New Issue
Block a user