Ver código fonte

提交主数据验证标准

PC-202503171525\Administrator 1 ano atrás
pai
commit
53f713f470
1 arquivos alterados com 31 adições e 4 exclusões
  1. 31 4
      src/views/material/product/components/QualityInfo.vue

+ 31 - 4
src/views/material/product/components/QualityInfo.vue

@@ -16,9 +16,24 @@
           </el-form-item>
         </el-col>
         <el-col :span="4">
-          <el-form-item label="检验标准" prop="">
-            <!-- 计量 计重 -->
-          </el-form-item>
+          <el-col :span="4">
+            <el-form-item label="检验标准" prop="inspectionStandards">
+              <!-- 计量 计重 -->
+              <el-select
+                style="width: 100%"
+                v-model="form.inspectionStandards"
+                placeholder="请选择"
+              >
+                <el-option
+                  v-for="item in inspectionStandardsList"
+                  :label="item.label"
+                  :value="item.value"
+                  :key="item.value"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
         </el-col>
         <el-col :span="6" v-if="form.isComeCheck == 1">
           <el-form-item label="物料级别" prop="checkFormula">
@@ -101,13 +116,15 @@
     data() {
       return {
         qualityTemplateList: [],
-        levelOptions: []
+        levelOptions: [],
+        inspectionStandardsList: []
       };
     },
     watch: {},
     created() {
       this.getQualityTemplateList();
       this.getDictList('level_type');
+      this.getDictListIqoCode('iqo_code');
     },
     methods: {
       async getDictList(code) {
@@ -121,6 +138,16 @@
           };
         });
       },
+      async getDictListIqoCode(code) {
+        let { data: res } = await getByCode(code);
+        this.inspectionStandardsList = res.map((item) => {
+          let values = Object.keys(item);
+          return {
+            value: Number(values[0]),
+            label: item[values[0]]
+          };
+        });
+      },
       getQualityTemplateList() {
         getQualityTemplate().then((res) => {
           this.qualityTemplateList = res;