| | |
| | | style="width: 90px" @change="(m) => subOtherForm(m, 'temperature')"></el-input> |
| | | <span class="template-panel__unit">℃</span> |
| | | </el-form-item> |
| | | <el-form-item v-if="insOrder.ifsOrderType!=='02wg'" label="湿度:"> |
| | | <el-input v-model="currentOtherForm.humidity" :disabled="state > 1" placeholder="" size="small" |
| | | style="width: 90px" @change="(m) => subOtherForm(m, 'humidity')"></el-input> |
| | | <span class="template-panel__unit">%RH</span> |
| | | </el-form-item> |
| | | <el-form-item label="检测时间:"> |
| | | <el-date-picker v-model="currentOtherForm.detectionTime" :disabled="state > 1" type="date" |
| | | value-format="yyyy-MM-dd" placeholder="请选择日期" size="small" style="width: 160px" |
| | |
| | | inspectionItem: 1, |
| | | inspectionItemSubclass: "20(常温)", |
| | | }, |
| | | // 检测条件与检验结论按模板 id 分组:{ [templateId]: { temperature, humidity, detectionTime, detectionPlace, deviceIds, insResult } } |
| | | // 检测条件与检验结论按模板 id 分组:{ [templateId]: { temperature, detectionTime, detectionPlace, deviceIds, insResult } } |
| | | otherForm: {}, |
| | | equipForm: { |
| | | value0: null, |
| | |
| | | return ( |
| | | this.otherForm[this.currentTable] || { |
| | | temperature: null, |
| | | humidity: null, |
| | | detectionTime: null, |
| | | detectionPlace: null, |
| | | deviceIds: [], |
| | |
| | | (this.insOrder.templateConditions || []).forEach((item) => { |
| | | this.$set(this.otherForm, item.templateId, { |
| | | temperature: item.temperature != null ? item.temperature : null, |
| | | humidity: item.humidity != null ? item.humidity : null, |
| | | detectionTime: item.detectionTime != null ? item.detectionTime : null, |
| | | detectionPlace: item.detectionPlace != null ? item.detectionPlace : null, |
| | | deviceIds: Array.isArray(item.deviceIds) ? [...item.deviceIds] : [], |
| | |
| | | if (!this.otherForm[templateId]) { |
| | | this.$set(this.otherForm, templateId, { |
| | | temperature: null, |
| | | humidity: null, |
| | | detectionTime: null, |
| | | detectionPlace: null, |
| | | deviceIds: [], |
| | |
| | | const form = this.otherForm[m.templateId] || {}; |
| | | if (this.insOrder.ifsOrderType !== "02wg") { |
| | | if (!form.temperature) missing.push(`请填写「${m.templateName}」的温度`); |
| | | if (!form.humidity) missing.push(`请填写「${m.templateName}」的湿度`); |
| | | } |
| | | if (!form.detectionTime) missing.push(`请选择「${m.templateName}」的检测时间`); |
| | | if (!form.detectionPlace) missing.push(`请填写「${m.templateName}」的检测地点`); |
| | |
| | | id: this.insOrder.id, |
| | | templateId: template.templateId, |
| | | temperature: form.temperature == null ? null : form.temperature, |
| | | humidity: form.humidity == null ? null : form.humidity, |
| | | detectionTime: form.detectionTime || null, |
| | | detectionPlace: form.detectionPlace || null, |
| | | deviceIds: Array.isArray(form.deviceIds) ? [...form.deviceIds] : [], |