| | |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <!--累计点--> |
| | | <el-row :gutter="20" v-if="formData.pointType === 'CUMULATE'"> |
| | | <el-col :span="24"> |
| | | <el-form-item label="瞬时测点" prop="cumulatePoint.pointNo"> |
| | | <el-select |
| | | v-model="formData.cumulatePoint.pointNo" |
| | | filterable |
| | | placeholder="请选择"> |
| | | <el-option |
| | | v-for="(item, index) in pointList" |
| | | :key="index" |
| | | :label="item.pointName" |
| | | :value="item.pointNo"/> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="累计长度" prop="cumulatePoint.length"> |
| | | <el-input-number v-model="formData.cumulatePoint.length" style="width: 100%" |
| | | :min="1" :max="3000" |
| | | :controls="false"/> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="除数" prop="cumulatePoint.divisor"> |
| | | <el-input-number v-model="formData.cumulatePoint.divisor" style="width: 100%" |
| | | :min="1" :max="3000" |
| | | :controls="false"/> |
| | | </el-form-item> |
| | | </el-col> |
| | | |
| | | </el-row> |
| | | </el-form> |
| | | <template #footer> |
| | | <el-button :disabled="formLoading" type="primary" @click="submitForm">确 定</el-button> |
| | |
| | | tagNo: '', |
| | | dimension: '', |
| | | valueType: '', |
| | | }, |
| | | cumulatePoint: { |
| | | id: '', |
| | | pointId: '', |
| | | pointNo: '', |
| | | length: '', |
| | | divisor: '' |
| | | } |
| | | }) |
| | | const formRules = reactive({ |
| | |
| | | pointType: [{required: true, message: '测点类型不能为空', trigger: 'blur'}], |
| | | dataType: [{required: true, message: '数据类型不能为空', trigger: 'blur'}], |
| | | minfreqid: [{required: true, message: '采集频率不能为空', trigger: 'blur'}], |
| | | "measurePoint.valueType": [{required: true, message: '采集频率不能为空', trigger: 'blur'}], |
| | | "measurePoint.dimension": [{required: true, message: '采集频率不能为空', trigger: 'blur'}], |
| | | "measurePoint.valueType": [{required: true, message: '值类型不能为空', trigger: 'blur'}], |
| | | "measurePoint.dimension": [{required: true, message: '平滑尺度不能为空', trigger: 'blur'}], |
| | | "cumulatePoint.pointNo": [{required: true, message: '累计测点不能为空', trigger: 'blur'}], |
| | | "cumulatePoint.length": [{required: true, message: '累计长度不能为空', trigger: 'blur'}], |
| | | "cumulatePoint.divisor": [{required: true, message: '除数不能为空', trigger: 'blur'}], |
| | | }) |
| | | const formRef = ref() // 表单 Ref |
| | | |
| | |
| | | tagNo: '', |
| | | dimension: '1', |
| | | valueType: 'SIMULATE', |
| | | }, |
| | | cumulatePoint: { |
| | | id: '', |
| | | pointId: '', |
| | | pointNo: '', |
| | | length: 60, |
| | | divisor: 60 |
| | | } |
| | | } |
| | | formRef.value?.resetFields() |