瀏覽代碼

Merge remote-tracking branch 'origin/master'

liuwj 2 年之前
父節點
當前提交
d0fbe45964

+ 25 - 3
itdmWeb/src/views/module-iTDM/weituo/modules/step/Step1.vue

@@ -56,8 +56,10 @@
         </a-form-model-item>
       </a-col>
     </a-row>
-    <a-form-item :wrapperCol="{span: 19, offset: 5}">
-      <a-button type="primary" @click="nextStep">下一步</a-button>
+    <a-form-item class="buttonAll">
+      <div class="all">
+        <a-button type="primary" @click="nextStep" class="next">下一步</a-button>
+      </div>
     </a-form-item>
   </a-form-model>
 
@@ -170,4 +172,24 @@ export default {
   }
 
 }
-</script>
+</script>
+
+<style scoped>
+  .next{
+    width: 35%;
+    margin-left: 20px;
+    margin-right: 20px;
+    margin-top: 20px;
+  }
+  .buttonAll{
+    width: 100%;
+    align-items: center;
+    justify-content: center;
+  }
+  .all{
+    width: 100%;
+    display: flex;
+    align-items: center;
+    justify-content: center;
+  }
+</style>

+ 32 - 16
itdmWeb/src/views/module-iTDM/weituo/modules/step/Step2.vue

@@ -7,7 +7,7 @@
     >
       <template
         v-for="(col, i) in ['sampleName', 'sampleModelSpecification', 'sampleQuantities','sampleManufacturer']"
-        :slot="col" slot-scope="text, record, index">
+        :slot="col" slot-scope="text, record">
         <a-input
           :disabled="formDisabled"
           :key="col"
@@ -16,13 +16,10 @@
           :placeholder="columns[i].title"
           @change="e => handleChange(e.target.value, record.key, col)"
         />
-
-        <a-input type="hidden" name="id" :value="index"></a-input>
       </template>
 
-      <template slot="operation" slot-scope="text, record, index">
+      <template slot="operation" slot-scope="text, record">
           <span>
-              <a-divider type="vertical" />
               <a-popconfirm title="是否要删除此行?" :disabled="formDisabled"  @confirm="remove(record.key)">
                 <a>删除</a>
               </a-popconfirm>
@@ -34,10 +31,11 @@
     </a-button>
 
 
-    <a-form-item :wrapperCol="{span: 19, offset: 5}">
-      <a-button style="margin-left: 8px" @click="prevStep">上一步</a-button>
-
-      <a-button type="primary" @click="nextStep">下一步</a-button>
+    <a-form-item class="buttonAll">
+      <div class="all">
+        <a-button @click="prevStep" class="next">上一步</a-button>
+        <a-button type="primary" @click="nextStep" class="next">下一步</a-button>
+      </div>
 
     </a-form-item>
   </a-form-model>
@@ -85,33 +83,34 @@ export default {
           title: '样品名称',
           dataIndex: 'sampleName',
           key: 'sampleName',
-          width: '20%',
+          align:"center",
           scopedSlots: { customRender: 'sampleName' }
         },
         {
           title: '样品规格/型号',
           dataIndex: 'sampleModelSpecification',
           key: 'sampleModelSpecification',
-          width: '20%',
+          align:"center",
           scopedSlots: { customRender: 'sampleModelSpecification' }
         },
         {
           title: '样品数量',
           dataIndex: 'sampleQuantities',
           key: 'sampleQuantities',
-          width: '40%',
+          align:"center",
           scopedSlots: { customRender: 'sampleQuantities' }
         },
         {
           title: '生产厂家',
           dataIndex: 'sampleManufacturer',
           key: 'sampleManufacturer',
-          width: '40%',
+          align:"center",
           scopedSlots: { customRender: 'sampleManufacturer' }
         },
         {
           title: '操作',
           key: 'action',
+          align:"center",
           scopedSlots: { customRender: 'operation' }
         }
       ],
@@ -200,7 +199,24 @@ export default {
 </script>
 
 <style lang="less" scoped>
-.card {
-  margin-bottom: 24px;
-}
+  .card {
+    margin-bottom: 24px;
+  }
+  .next{
+    width: 35%;
+    margin-left: 20px;
+    margin-right: 20px;
+    margin-top: 20px;
+  }
+  .buttonAll{
+    width: 100%;
+    align-items: center;
+    justify-content: center;
+  }
+  .all{
+    width: 100%;
+    display: flex;
+    align-items: center;
+    justify-content: center;
+  }
 </style>

+ 36 - 12
itdmWeb/src/views/module-iTDM/weituo/modules/step/Step3.vue

@@ -8,7 +8,7 @@
 
 
         <template v-for="(col, i) in ['yangpinKeyId', 'testItems', 'standardRequirement','judgementBasis','beizhu']"
-                  :slot="col" slot-scope="text, record, index">
+                  :slot="col" slot-scope="text, record">
 
 
           <a-select
@@ -68,9 +68,8 @@
 
         </template>
 
-        <template slot="operation" slot-scope="text, record, index">
+        <template slot="operation" slot-scope="text, record">
           <span>
-              <a-divider type="vertical" />
               <a-popconfirm  :disabled="formDisabled" title="是否要删除此行?" @confirm="remove(record.key)">
                 <a>删除</a>
               </a-popconfirm>
@@ -84,9 +83,11 @@
       </a-button>
 
 
-      <a-form-item :wrapperCol="{span: 19, offset: 5}">
-        <a-button style="margin-left: 8px" @click="prevStep">上一步</a-button>
-        <a-button v-if="!disabled" style="margin-left: 8px" @click="submitForm">提交</a-button>
+      <a-form-item class="buttonAll">
+        <div class="all">
+          <a-button style="margin-left: 8px" @click="prevStep" class="next">上一步</a-button>
+          <a-button v-if="!disabled" type="primary" style="margin-left: 8px" @click="submitForm" class="next">提交</a-button>
+        </div>
 
 
       </a-form-item>
@@ -123,6 +124,7 @@ export default {
           title: '样品名称',
           dataIndex: 'yangpinKeyId',
           key: 'yangpinKeyId',
+          align:"center",
           width: '15%',
           scopedSlots: { customRender: 'yangpinKeyId' }
         },
@@ -130,13 +132,15 @@ export default {
           title: '检测项目',
           dataIndex: 'testItems',
           key: 'testItems',
-          width: '20%',
+          align:"center",
+          width: '15%',
           scopedSlots: { customRender: 'testItems' }
         },
         {
           title: '检测依据',
           dataIndex: 'standardRequirement',
           key: 'standardRequirement',
+          align:"center",
           width: '20%',
           scopedSlots: { customRender: 'standardRequirement' }
         },
@@ -144,19 +148,22 @@ export default {
           title: '判定依据',
           dataIndex: 'judgementBasis',
           key: 'judgementBasis',
-          width: '20%',
+          align:"center",
+          width: '25%',
           scopedSlots: { customRender: 'judgementBasis' }
         },
         {
           title: '备注',
           dataIndex: 'beizhu',
           key: 'beizhu',
-          width: '25%',
+          width: '15%',
+          align:"center",
           scopedSlots: { customRender: 'beizhu' }
         },
         {
           title: '操作',
           key: 'action',
+          align:"center",
           scopedSlots: { customRender: 'operation' }
         }
       ],
@@ -254,7 +261,24 @@ export default {
 </script>
 
 <style lang="less" scoped>
-.card {
-  margin-bottom: 24px;
-}
+  .card {
+    margin-bottom: 24px;
+  }
+  .next{
+    width: 35%;
+    margin-left: 20px;
+    margin-right: 20px;
+    margin-top: 20px;
+  }
+  .buttonAll{
+    width: 100%;
+    align-items: center;
+    justify-content: center;
+  }
+  .all{
+    width: 100%;
+    display: flex;
+    align-items: center;
+    justify-content: center;
+  }
 </style>