| | |
| | | style="width: 90px" @change="m => subOtherForm(m, 'temperature')" /> |
| | | <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" size="small" |
| | | style="width: 90px" @change="m => subOtherForm(m, 'humidity')" /> |
| | | <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" |
| | |
| | | currentOtherForm() { |
| | | 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 (templateId == null || this.otherForm[templateId]) return; |
| | | this.$set(this.otherForm, templateId, { |
| | | temperature: null, |
| | | humidity: null, |
| | | detectionTime: null, |
| | | detectionPlace: null, |
| | | deviceIds: [], |
| | |
| | | const form = this.otherForm[item.templateId] || {}; |
| | | if (this.insOrder.ifsOrderType !== "02wg") { |
| | | if (!form.temperature) missing.push(`请填写「${item.templateName}」的温度`); |
| | | if (!form.humidity) missing.push(`请填写「${item.templateName}」的湿度`); |
| | | } |
| | | if (!form.detectionTime) missing.push(`请选择「${item.templateName}」的检测时间`); |
| | | if (!form.detectionPlace) missing.push(`请填写「${item.templateName}」的检测地点`); |