“linengliang”
2023-09-06 cbcff3e56c65e8b0d10498571f2705a5ae730ff9
src/views/eam/modules/inspectionProject/InspectionProjectModel.vue
@@ -114,24 +114,24 @@
            </a-form-item>
          </a-col> -->
          <a-col
            v-if="analysisMethod == '2'"
            v-if="testValueType == '2'"
            :span="12"
          >
            <a-form-item
              label="待定"
              label="检测标准"
              :labelCol="labelCol"
              :wrapperCol="wrapperCol"
            >
              <a-input
                allow-clear
                :disabled="disableSubmit"
                :placeholder="disableSubmit?'':'请输入待定值'"
                v-decorator="['surfaceValue1', validatorRules.surfaceValue1 ]"
                :placeholder="disableSubmit?'':'请输入检测标准'"
                v-decorator="['detectionStandard', validatorRules.detectionStandard ]"
              />
            </a-form-item>
          </a-col>
          <a-col
            v-if="analysisMethod == '1'"
            v-if="testValueType == '1'"
            :span="12"
          >
            <a-form-item
@@ -150,7 +150,7 @@
          </a-col>
        </a-row>
        <a-row
          v-if="analysisMethod == '1'"
          v-if="testValueType == '1'"
          :gutter="24"
        >
          <a-col :span="12">
@@ -277,7 +277,7 @@
      codeDisable: true,
      disableSubmit: false,
      inspectionProjectCategoryId: '',
      analysisMethod: null,
      testValueType: null,
      model: {},
      labelCol: {
        xs: { span: 24 },
@@ -304,9 +304,15 @@
            { validator: this.validateName },
          ]
        },
        analysisMethod: {
        // analysisMethod: {
        //   rules: [
        //     { required: true, message: '请选择分析方法!' },
        //   ]
        // },
        detectionStandard: {
          rules: [
            { required: true, message: '请选择分析方法!' },
            { required: true, message: '请输入检测标准!' },
            // { validator: this.validateSurfaceValue },
          ]
        },
        surfaceValue: {
@@ -353,12 +359,12 @@
      this.model = Object.assign({}, record);
      this.visible = true;
      this.disableSubmit = false;
      this.analysisMethod = record.analysisMethod
      this.testValueType = record.testValueType
      this.$nextTick(() => {
        this.form.setFieldsValue(pick(this.model, 'inspectionProjectCategoryNumName',
          'num', 'name', 'unitId', 'testValueType', 'analysisMethod', 'inspectionMethod', 'inspectionTool', 'remark'))
          'num', 'name', 'unitId', 'detectionStandard', 'testValueType', 'inspectionMethod', 'inspectionTool', 'remark'))
      });
      if (record.analysisMethod == '1') {
      if (record.testValueType == '1') {
        this.$nextTick(() => {
          this.form.setFieldsValue(pick(this.model, 'surfaceValue', 'upValue', 'downValue'))
        });
@@ -440,7 +446,7 @@
    },
    handleChange(val) {
      this.analysisMethod = val
      this.testValueType = val
    },
    validateDownValue(rule, value, callback) {