xiaodai2022 2 gadi atpakaļ
vecāks
revīzija
337e3e7f38
1 mainītis faili ar 13 papildinājumiem un 16 dzēšanām
  1. 13 16
      src/views/stock/check/components/resultUplodModel.vue

+ 13 - 16
src/views/stock/check/components/resultUplodModel.vue

@@ -16,10 +16,7 @@
     <el-card style="margin: -20px">
       <el-row :gutter="10" style="height: 550px">
         <el-col :span="24">
-          <upload-excel
-            :on-success="handleSuccess"
-            :before-upload="beforeUpload"
-          />
+          <upload-excel :on-success="handleSuccess" :before-upload="beforeUpload" />
           <el-table
             :data="tableData"
             size="mini"
@@ -39,11 +36,7 @@
           </el-table>
         </el-col>
         <el-col :span="24" style="text-align: right; margin: 15px 0 0 0">
-          <el-button
-            v-if="!isDetail"
-            :size="'mini'"
-            type="primary"
-            @click="submitForm"
+          <el-button v-if="!isDetail" :size="'mini'" type="primary" @click="submitForm"
             >保 存
           </el-button>
           <el-button :size="'mini'" @click="showModelThis = false">{{
@@ -71,6 +64,7 @@ export default {
       showModelThis: this.showModel,
       isfile: false,
       head: [
+        "商品批次号",
         "商品编码",
         // "商品属性编码",
         "商品名称",
@@ -85,7 +79,8 @@ export default {
         "新建时间",
         "仓库编码",
         "仓库名称",
-        "可用库存",
+        "可用总库存",
+        "批次库存数",
         "盘点库存",
       ],
       tableData: [],
@@ -146,6 +141,8 @@ export default {
     },
     handleSuccess({ results, header }) {
       this.length = 0;
+      console.log(this.head);
+      console.log(header);
       if (this.head.length !== header.length) {
         this.$message.error("表头与导入模板不匹配!");
         return;
@@ -192,10 +189,10 @@ export default {
         }
         this.tableData.forEach((v) => {
           list.push({
-            value0: v.value0,
-            value1: v.value1,
-            // value2: v.value2,
-            value14: v.value14+"",
+            value0: v.value0 + "",
+            value1: v.value1 + "",
+            value2: v.value2 + "",
+            value16: v.value16 + "",
           });
           if (!isnumber(v.value14)) {
             isn = false;
@@ -231,7 +228,7 @@ export default {
 };
 </script>
 
-   <style lang="scss" scoped>
+<style lang="scss" scoped>
 .checkDetail {
   .excelUploadBox {
     position: relative;
@@ -312,4 +309,4 @@ export default {
     }
   }
 }
-</style>
+</style>