bugfix 设备保养
This commit is contained in:
parent
889f4472e6
commit
38668fca09
@ -44,10 +44,7 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item
|
<el-form-item label="部门" prop="departmentId">
|
||||||
label="部门"
|
|
||||||
prop="departmentId"
|
|
||||||
:rules="[{ required: true, message: '请选择部门', trigger: 'blur' }]">
|
|
||||||
<el-select
|
<el-select
|
||||||
v-model="form.departmentId"
|
v-model="form.departmentId"
|
||||||
:placeholder="`请选择部门`"
|
:placeholder="`请选择部门`"
|
||||||
@ -84,10 +81,7 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item
|
<el-form-item label="产线" prop="lineId">
|
||||||
label="产线"
|
|
||||||
prop="lineId"
|
|
||||||
:rules="[{ required: true, message: '请选择产线', trigger: 'blur' }]">
|
|
||||||
<el-select
|
<el-select
|
||||||
v-model="form.lineId"
|
v-model="form.lineId"
|
||||||
:placeholder="`请选择产线`"
|
:placeholder="`请选择产线`"
|
||||||
@ -183,6 +177,7 @@
|
|||||||
label="保养时长(h)"
|
label="保养时长(h)"
|
||||||
prop="maintainDuration"
|
prop="maintainDuration"
|
||||||
:rules="[
|
:rules="[
|
||||||
|
{ required: true, message: '保养时长不能为空', trigger: 'blur' },
|
||||||
{
|
{
|
||||||
type: 'number',
|
type: 'number',
|
||||||
message: '请输入正确的数字',
|
message: '请输入正确的数字',
|
||||||
|
@ -129,8 +129,8 @@
|
|||||||
width="35%"
|
width="35%"
|
||||||
:append-to-body="true"
|
:append-to-body="true"
|
||||||
custom-class="baseDialog"
|
custom-class="baseDialog"
|
||||||
@close="closeDetailForm"
|
@close="detailAddVisible = false"
|
||||||
@cancel="closeDetailForm"
|
@cancel="detailAddVisible = false"
|
||||||
@confirm="submitDetailForm">
|
@confirm="submitDetailForm">
|
||||||
<DialogForm
|
<DialogForm
|
||||||
v-if="detailAddVisible"
|
v-if="detailAddVisible"
|
||||||
@ -237,7 +237,7 @@ export default {
|
|||||||
detailTableProps: [
|
detailTableProps: [
|
||||||
{ prop: 'equipmentName', label: '设备名称' },
|
{ prop: 'equipmentName', label: '设备名称' },
|
||||||
{ prop: 'program', label: '保养项目' },
|
{ prop: 'program', label: '保养项目' },
|
||||||
{ prop: 'remark', label: '备注' },
|
// { prop: 'remark', label: '备注' },
|
||||||
],
|
],
|
||||||
detailTableQuery: {
|
detailTableQuery: {
|
||||||
pageNo: 1,
|
pageNo: 1,
|
||||||
@ -317,9 +317,21 @@ export default {
|
|||||||
value: item.id,
|
value: item.id,
|
||||||
}));
|
}));
|
||||||
},
|
},
|
||||||
|
|
||||||
|
resetForm() {
|
||||||
|
this.detailForm = {
|
||||||
|
planId: null,
|
||||||
|
equipmentId: null,
|
||||||
|
program: '',
|
||||||
|
maintenanceDes: '',
|
||||||
|
remark: '',
|
||||||
|
};
|
||||||
|
},
|
||||||
|
|
||||||
closeDetailForm() {
|
closeDetailForm() {
|
||||||
this.detailAddVisible = false;
|
this.detailAddVisible = false;
|
||||||
},
|
},
|
||||||
|
|
||||||
async submitDetailForm() {
|
async submitDetailForm() {
|
||||||
// validation
|
// validation
|
||||||
this.$refs.detailForm.validate(async (valid) => {
|
this.$refs.detailForm.validate(async (valid) => {
|
||||||
@ -410,7 +422,10 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleAddDetail() {
|
handleAddDetail() {
|
||||||
this.detailAddVisible = true;
|
this.resetForm();
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.detailAddVisible = true;
|
||||||
|
});
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
@ -101,8 +101,13 @@ export default {
|
|||||||
{ prop: 'name', label: '计划名称' },
|
{ prop: 'name', label: '计划名称' },
|
||||||
{ prop: 'departmentName', label: '部门' },
|
{ prop: 'departmentName', label: '部门' },
|
||||||
{ width: 144, prop: 'lineName', label: '产线名' },
|
{ width: 144, prop: 'lineName', label: '产线名' },
|
||||||
{ width: 144, prop: 'maintenancePeriod', label: '保养频率(天/次)' },
|
{ width: 132, prop: 'maintenancePeriod', label: '保养频率(天/次)' },
|
||||||
{ width: 144, prop: 'firstMaintenanceTime', label: '首次保养时间' },
|
{
|
||||||
|
width: 180,
|
||||||
|
prop: 'firstMaintenanceTime',
|
||||||
|
label: '首次保养时间',
|
||||||
|
filter: (val) => moment(val).format('yyyy-MM-DD HH:mm:ss'),
|
||||||
|
},
|
||||||
{ width: 144, prop: 'maintainDuration', label: '保养时长' },
|
{ width: 144, prop: 'maintainDuration', label: '保养时长' },
|
||||||
{ prop: 'maintainer', label: '计划保养人员' },
|
{ prop: 'maintainer', label: '计划保养人员' },
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user