点检工单校验修改

This commit is contained in:
xusd 2024-11-04 09:27:22 +08:00
parent 05e0581b64
commit d15694aa0c

View File

@ -211,7 +211,7 @@ export default {
if (this.inspectionPlanList.length === 0){ if (this.inspectionPlanList.length === 0){
this.$message.error("请至少选择一个点检方案"); this.$message.error("请至少选择一个点检方案");
}else { }else {
this.submitFormData.inspectionPlanId = this.inspectionPlanList.join(','); this.$set(this.submitFormData, "inspectionPlanId", this.inspectionPlanList.join(','));
this.submitFormData.inspectionPlanName = this.inspectionPlanTreeData.filter(item=>this.inspectionPlanList.includes(item.inspectionPlanId)).map(item=>item.inspectionName).join(',') this.submitFormData.inspectionPlanName = this.inspectionPlanTreeData.filter(item=>this.inspectionPlanList.includes(item.inspectionPlanId)).map(item=>item.inspectionName).join(',')
this.inspectionPlanVisible = false; this.inspectionPlanVisible = false;
} }
@ -237,7 +237,7 @@ export default {
console.log(this.submitFormData); console.log(this.submitFormData);
this.submitFormLoading = true; this.submitFormLoading = true;
try { try {
// await this.$refs.submitForm.validate(); await this.$refs.submitForm.validate();
this.submitFormData.equipId = this.alarmFormData.equipId; this.submitFormData.equipId = this.alarmFormData.equipId;
this.submitFormData.customerId = this.alarmFormData.customerId; this.submitFormData.customerId = this.alarmFormData.customerId;
this.submitFormData.alarmId = this.alarmFormData.equipAlarmId; this.submitFormData.alarmId = this.alarmFormData.equipAlarmId;