소스 검색

fix: 通知/经销商产品现存表

zh 2 년 전
부모
커밋
760e6fb113
2개의 변경된 파일30개의 추가작업 그리고 9개의 파일을 삭제
  1. 9 9
      src/layout/components/Navbar.vue
  2. 21 0
      src/views/basic_data/stock/product_list_customer.vue

+ 9 - 9
src/layout/components/Navbar.vue

@@ -93,7 +93,7 @@
           <el-radio-button :label="2">到货通知</el-radio-button>
         </el-radio-group>
       </div>
-      <div v-if="noticeType === 2" class="mymain-container">
+      <div v-show="noticeType === 2" class="mymain-container">
         <el-form ref="form" :model="form" label-width="80px" label-position="left" size="mini">
           <el-row>
             <el-col>
@@ -168,7 +168,7 @@
           </div>
         </div>
       </div>
-      <div v-if="noticeType === 1" class="mymain-container">
+      <div v-show="noticeType === 1" class="mymain-container">
         <div class="table">
           <el-table
             ref="table"
@@ -229,7 +229,7 @@
         </div>
       </div>
     </el-dialog>
-    <el-dialog title="物流通知" :visible.sync="isLogistics" width="60%" :modal="true" @close="isLogistics = false">
+    <!-- <el-dialog title="物流通知" :visible.sync="isLogistics" width="60%" :modal="true" @close="isLogistics = false">
       <div class="table">
         <el-table
           ref="table"
@@ -267,7 +267,7 @@
           </el-table-column>
         </el-table>
       </div>
-      <!-- 分页 -->
+    
       <div class="fr">
         <el-pagination
           :current-page="currentPage"
@@ -281,7 +281,7 @@
       </div>
       <br />
       <br />
-    </el-dialog>
+    </el-dialog> -->
     <el-dialog
       title="物流到货通知"
       :visible.sync="visible"
@@ -501,7 +501,7 @@ export default {
         pageSize: this.pageSize2,
         specification: this.form.specification
       }).then(res => {
-        console.log(res.data.records,'999');
+        console.log(res.data.records, '999')
         this.noticeList = res.data.records
         this.listTotal2 = res.data.total
         // this.listLoading = false
@@ -769,9 +769,9 @@ export default {
       }, 20000)
     },
 
-    handleShow() {
-      ;(this.isLogistics = true), this.getListInvoiceOrder()
-    },
+    // handleShow() {
+    //   ;(this.isLogistics = true), this.getListInvoiceOrder()
+    // },
     // 更改每页数量
     handleSizeChange2(val) {
       this.pageSize2 = val

+ 21 - 0
src/views/basic_data/stock/product_list_customer.vue

@@ -37,6 +37,20 @@ export default {
       recordSelected: []
     }
   },
+  computed: {
+    filterNumber() {
+      return num => {
+        num = Number(num)
+        if (num <= 0) {
+          return '无货'
+        } else if (num >= 1 && num <= 50) {
+          return num
+        } else {
+          return '有货'
+        }
+      }
+    }
+  },
   methods: {
     // 列表请求函数
     getList(...p) {
@@ -47,6 +61,13 @@ export default {
     exportList: exportListStockToDayCustomerV2,
     // 表格列解析渲染数据更改
     columnParsing(item, defaultData) {
+      if (item.colName === 'open_number') {
+        defaultData.render = (h, { row, index, column }) => {
+          return (
+            <div>{this.filterNumber(row.openNumber)}</div>
+          )
+        }
+      }
       return defaultData
     },
     // 监听勾选变化