Przeglądaj źródła

Merge branch 'master' of http://110.41.163.243:9980/kd-aiot/kd-aiot-frontend-qms

liujt 9 miesięcy temu
rodzic
commit
f10c3019d5

+ 7 - 1
src/views/inspectionStandard/components/edit.vue

@@ -71,6 +71,11 @@
             />
           </el-form-item>
         </el-col>
+        <el-col :span="8" style="padding: 0">
+          <el-form-item prop="sort" label="排序">
+            <el-input v-model="form.sort" type="number"></el-input>
+          </el-form-item>
+        </el-col>
       </el-row>
       <el-row>
         <el-col :span="24">
@@ -293,7 +298,8 @@
           parameterStandards: [],
           linePoints: [],
           parameterType: '',
-          imgUrl: []
+          imgUrl: [],
+          sort:0
         };
       };
       return {

+ 16 - 0
src/views/inspectionStandard/index.vue

@@ -87,6 +87,12 @@
             columnKey: 'index',
             align: 'center'
           },
+          {
+            width: 70,
+            prop: 'sort',
+            label: '排序',
+            align: 'center'
+          },
           {
             prop: 'code',
             label: '标准编码',
@@ -119,6 +125,16 @@
             label: '版本号',
             prop: 'version',
             align: 'center'
+          },
+           {
+            label: '创建时间',
+            prop: 'createTime',
+            align: 'center'
+          },
+           {
+            label: '创建人',
+            prop: 'createUserName',
+            align: 'center'
           },
           {
             columnKey: 'action',

+ 26 - 21
src/views/inspectionTemplate/AddorUpdate.vue

@@ -86,13 +86,13 @@
         </el-col>
       </el-row>
       <el-row>
-        <el-col  style="width: 370px;">
+        <el-col style="width: 370px">
           <el-form-item label="取样数量" prop="sampleProportion">
             <el-input
               type="number"
               v-model="dataForm.sampleProportion"
               placeholder="请输入"
-              style="width:200px"
+              style="width: 200px"
             ></el-input>
             <DictSelection
               style="width: 85px"
@@ -102,7 +102,7 @@
             ></DictSelection>
           </el-form-item>
         </el-col>
-        <el-col style="width: 450px;">
+        <el-col style="width: 450px">
           <el-form-item
             label="质检报告有效期"
             prop="validityPeriod"
@@ -131,7 +131,7 @@
           :columns="columns"
           :datasource="list"
           height="400px"
-           full-height="calc(100vh - 76px)"
+          full-height="calc(100vh - 76px)"
           tool-class="ele-toolbar-form"
           cache-key="inspectionClassify"
           row-key="qualityLevelId"
@@ -168,14 +168,11 @@
           </template>
 
           <template v-slot:inspectionName="{ row }">
-            <div>
-              <el-input
-                v-model="row.inspectionName"
-               
-              ></el-input
-            ></div>
+            <div> <el-input v-model="row.inspectionName"></el-input></div>
+          </template>
+          <template v-slot:sort="{ row }">
+            <el-input v-model="row.sort" type="number"></el-input>
           </template>
-
           <template v-slot:defaultValue="{ row }">
             <div style="width: 100%; display: flex">
               <DictSelection
@@ -184,18 +181,15 @@
                 dictName="数学字符"
                 v-model="row.symbol"
               ></DictSelection>
-              <div v-if="row.textType == 3" >
+              <div v-if="row.textType == 3">
                 <el-input v-model="row.minValue" style="width: 80px"></el-input
                 >-
                 <el-input v-model="row.maxValue" style="width: 80px">
                 </el-input>
               </div>
 
-              <div v-else  style="width: 100%">
-                <el-input
-                  v-model="row.defaultValue"
-                 
-                ></el-input>
+              <div v-else style="width: 100%">
+                <el-input v-model="row.defaultValue"></el-input>
               </div>
 
               <DictSelection
@@ -230,7 +224,7 @@
           :columns="categoryColumns"
           :datasource="templateCategoryList"
           height="300px"
-           full-height="calc(100vh - 76px)"
+          full-height="calc(100vh - 76px)"
           tool-class="ele-toolbar-form"
           cache-key="inspectionClassify"
           row-key="qualityLevelId"
@@ -304,8 +298,8 @@
           templateRemark: '',
           sampleProportion: '',
           sampleProportionUnit: '%',
-          validityPeriod:'',
-          validityPeriodUnit:''
+          validityPeriod: '',
+          validityPeriodUnit: ''
         },
         columns: [
           {
@@ -324,6 +318,14 @@
             showOverflowTooltip: true,
             fixed: 'left'
           },
+          {
+            label: '排序',
+            width: 100,
+            align: 'center',
+            slot: 'sort',
+            prop: 'sort',
+            fixed: 'left'
+          },
           {
             prop: 'categoryLevelClassName',
             label: '质检类型',
@@ -473,7 +475,10 @@
         console.log(selection, 'selection');
       },
       selectChange(list) {
-        this.list = list;
+        this.list = list.map(item=>{
+          item['sort']=item['sort']||0
+          return item
+        });
       },
       handDel(index, type) {
         if (type == 1) {