Przeglądaj źródła

所有页签不刷新。页签切换不刷新 保留查询条件,新页签打开不保留查询条件,二级页面(编辑详情等)通过按钮进入页面刷新数据不保留查询条件

chenrui 3 lat temu
rodzic
commit
b3cc8ad725
37 zmienionych plików z 506 dodań i 276 usunięć
  1. 9 2
      src/components/MultiTab/MultiTab.vue
  2. 14 6
      src/views/basicData/bulkPartsTypeManagement/list.vue
  3. 14 6
      src/views/basicData/customerTypeManagement/list.vue
  4. 14 6
      src/views/basicData/expenseType/list.vue
  5. 14 6
      src/views/basicData/storeTransferOutTypeManagement/list.vue
  6. 13 6
      src/views/bulkManagement/bulkImport/list.vue
  7. 10 6
      src/views/bulkManagement/bulkReturnGoods/edit.vue
  8. 10 6
      src/views/bulkManagement/bulkReturnGoods/grabEdit.vue
  9. 17 13
      src/views/bulkManagement/bulkReturnGoods/list.vue
  10. 15 9
      src/views/bulkManagement/bulkWarehousingOrder/detail.vue
  11. 11 7
      src/views/bulkManagement/bulkWarehousingOrder/edit.vue
  12. 17 13
      src/views/bulkManagement/bulkWarehousingOrder/list.vue
  13. 10 4
      src/views/customerManagement/customerInfo/edit.vue
  14. 17 13
      src/views/customerManagement/customerInfo/list.vue
  15. 13 8
      src/views/notice/list.vue
  16. 18 4
      src/views/power/role/roleList.vue
  17. 18 4
      src/views/power/user/userList.vue
  18. 12 14
      src/views/productManagement/newProduct/detail.vue
  19. 16 11
      src/views/productManagement/newProduct/list.vue
  20. 18 11
      src/views/productManagement/priceChangeRecord/list.vue
  21. 14 9
      src/views/productManagement/productBrand/list.vue
  22. 12 6
      src/views/productManagement/productCategory/list.vue
  23. 6 6
      src/views/productManagement/productInfo/edit.vue
  24. 17 13
      src/views/productManagement/productInfo/list.vue
  25. 18 14
      src/views/productManagement/productInfoJg/list.vue
  26. 13 5
      src/views/reportData/chainCustomerReport/list.vue
  27. 13 5
      src/views/reportData/chainReceivedSendStorageReport/list.vue
  28. 17 9
      src/views/reportData/chainSalesDetailReport/list.vue
  29. 14 6
      src/views/reportData/chainSalesReport/list.vue
  30. 13 5
      src/views/reportData/chainStockReport/list.vue
  31. 12 4
      src/views/reportData/customerReport/list.vue
  32. 12 4
      src/views/reportData/receivedSendStorageReport/list.vue
  33. 12 7
      src/views/reportData/stockExpenditureReport/list.vue
  34. 12 7
      src/views/reportData/stockIncomeReport/list.vue
  35. 14 6
      src/views/storeManagement/bind/list.vue
  36. 14 6
      src/views/storeManagement/userAuthorization/list.vue
  37. 13 9
      src/views/supplierManagement/supplierInfo/list.vue

+ 9 - 2
src/components/MultiTab/MultiTab.vue

@@ -114,9 +114,16 @@ export default {
       this[key](route)
     },
     renderTabPaneMenu (e) {
+      // return (
+      //   <a-menu {...{ on: { click: ({ key, item, domEvent }) => { this.closeMenuClick(key, e) } } }}>
+      //     {this.activeKey == e ? (<a-menu-item key="refashThat">刷新页面</a-menu-item>) : ''}
+      //     <a-menu-item key="closeRight">关闭右侧</a-menu-item>
+      //     <a-menu-item key="closeLeft">关闭左侧</a-menu-item>
+      //     <a-menu-item key="closeAll">关闭全部</a-menu-item>
+      //   </a-menu>
+      // )
       return (
         <a-menu {...{ on: { click: ({ key, item, domEvent }) => { this.closeMenuClick(key, e) } } }}>
-          {this.activeKey == e ? (<a-menu-item key="refashThat">刷新页面</a-menu-item>) : ''}
           <a-menu-item key="closeRight">关闭右侧</a-menu-item>
           <a-menu-item key="closeLeft">关闭左侧</a-menu-item>
           <a-menu-item key="closeAll">关闭全部</a-menu-item>
@@ -174,7 +181,7 @@ export default {
         >
           <span slot="tab">
             {this.renderTabPane(page.meta.customTitle || page.meta.title, page.name)}
-            {this.activeKey == page.name ? (<a-icon
+            {this.activeKey == 'page.name' ? (<a-icon
               {...{ on: { click: refashThat } }}
               style={{ marginLeft: '8px', fontSize: '12px' }}
               type="reload" />) : ''}

+ 14 - 6
src/views/basicData/bulkPartsTypeManagement/list.vue

@@ -15,6 +15,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ y: tableHeight }"
+        :defaultLoadData="false"
         bordered>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
@@ -122,22 +123,29 @@ export default {
       this.openModal = false
       this.$refs.table.refresh(true)
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 195
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
-  },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
   }
 }
 </script>

+ 14 - 6
src/views/basicData/customerTypeManagement/list.vue

@@ -31,6 +31,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ y: tableHeight }"
+        :defaultLoadData="false"
         bordered>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
@@ -138,22 +139,29 @@ export default {
       this.openModal = false
       this.$refs.table.refresh(true)
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 235
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
-  },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
   }
 }
 </script>

+ 14 - 6
src/views/basicData/expenseType/list.vue

@@ -17,6 +17,7 @@
         :scroll="{ y: tableHeight }"
         :showPagination="false"
         :defaultExpandedRowKeys="defaultExpandedRowKeys"
+        :defaultLoadData="false"
         bordered>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
@@ -158,22 +159,29 @@ export default {
         })
       }
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 195
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.$refs.table.refresh(true)
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.$refs.table.refresh(true)
     }
-  },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
   }
 }
 </script>

+ 14 - 6
src/views/basicData/storeTransferOutTypeManagement/list.vue

@@ -20,6 +20,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ y: tableHeight }"
+		:defaultLoadData="false"
         bordered>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
@@ -123,22 +124,29 @@ export default {
       this.openModal = false
       this.$refs.table.refresh(true)
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 195
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
-  }
 }
 </script>

+ 13 - 6
src/views/bulkManagement/bulkImport/list.vue

@@ -212,17 +212,17 @@ export default {
       document.body.appendChild(link)
       link.click()
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 400
     }
   },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
-  },
   watch: {
     advanced (newValue, oldValue) {
       const _this = this
@@ -231,9 +231,16 @@ export default {
       }, 400)
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },

+ 10 - 6
src/views/bulkManagement/bulkReturnGoods/edit.vue

@@ -424,14 +424,18 @@ export default {
     }
   },
   mounted () {
-    this.initPage()
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.initPage()
+    }
+  },
+  activated () {
+    // 如果是新页签打开或者进入新的子页(例:存在列表第2条数据编辑页页签时再打开第4条数据的编辑页),则重置当前页面
+    if (this.$store.state.app.isNewTab || !this.$store.state.app.isNewSubTab) {
+      this.initPage()
+    }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      if (!vm.disabled) {
-        vm.initPage()
-      }
-    })
+    next(vm => {})
   }
 }
 </script>

+ 10 - 6
src/views/bulkManagement/bulkReturnGoods/grabEdit.vue

@@ -422,14 +422,18 @@ export default {
     }
   },
   mounted () {
-    this.initPage()
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.initPage()
+    }
+  },
+  activated () {
+    // 如果是新页签打开或者进入新的子页(例:存在列表第2条数据编辑页页签时再打开第4条数据的编辑页),则重置当前页面
+    if (this.$store.state.app.isNewTab || !this.$store.state.app.isNewSubTab) {
+      this.initPage()
+    }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      if (!vm.disabled) {
-        vm.initPage()
-      }
-    })
+    next(vm => {})
   }
 }
 </script>

+ 17 - 13
src/views/bulkManagement/bulkReturnGoods/list.vue

@@ -71,6 +71,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ x: 1330, y: tableHeight }"
+        :defaultLoadData="false"
         bordered>
         <!-- 散件退货单号 -->
         <template slot="sparePartsReturnNo" slot-scope="text, record">
@@ -304,17 +305,19 @@ export default {
         }
       })
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+      this.openModal = false
+      this.getSupplierList()
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 235
     }
   },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
-  },
   watch: {
     advanced (newValue, oldValue) {
       const _this = this
@@ -323,20 +326,21 @@ export default {
       }, 400)
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.openModal = false
-      vm.getSupplierList()
-      if (!vm.disabled) {
-        vm.$refs.table.refresh()
-      }
-    })
+    next(vm => {})
   }
 }
 </script>

+ 15 - 9
src/views/bulkManagement/bulkWarehousingOrder/detail.vue

@@ -74,6 +74,7 @@
               :columns="columns"
               :data="loadData"
               :scroll="{ x: 1180 }"
+              :defaultLoadData="false"
               bordered>
             </s-table>
           </a-collapse-panel>
@@ -215,17 +216,22 @@ export default {
     }
   },
   mounted () {
-    this.getDetail()
-    this.getDetailCount()
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.$refs.table.refresh(true)
+      this.getDetail()
+      this.getDetailCount()
+    }
+  },
+  activated () {
+    // 如果是新页签打开或者进入新的子页(例:存在列表第2条数据编辑页页签时再打开第4条数据的编辑页),则重置当前页面
+    if (this.$store.state.app.isNewTab || !this.$store.state.app.isNewSubTab) {
+      this.$refs.table.refresh(true)
+      this.getDetail()
+      this.getDetailCount()
+    }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      if (!vm.disabled) {
-        vm.getDetail()
-        vm.getDetailCount()
-        vm.$refs.table.refresh()
-      }
-    })
+    next(vm => {})
   }
 }
 </script>

+ 11 - 7
src/views/bulkManagement/bulkWarehousingOrder/edit.vue

@@ -663,18 +663,22 @@ export default {
       this.getProductType()
       this.resetSearchForm()
       this.$refs.chooseTable.refresh(true)
+      this.openModal = false
     }
   },
   mounted () {
-    this.initPage()
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.initPage()
+    }
+  },
+  activated () {
+    // 如果是新页签打开或者进入新的子页(例:存在列表第2条数据编辑页页签时再打开第4条数据的编辑页),则重置当前页面
+    if (this.$store.state.app.isNewTab || !this.$store.state.app.isNewSubTab) {
+      this.initPage()
+    }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.openModal = false
-      if (!vm.disabled) {
-        vm.initPage()
-      }
-    })
+    next(vm => {})
   }
 }
 </script>

+ 17 - 13
src/views/bulkManagement/bulkWarehousingOrder/list.vue

@@ -99,6 +99,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ x: 1120, y: tableHeight }"
+        :defaultLoadData="false"
         bordered>
         <!-- 散件单号 -->
         <template slot="sparePartsPurchaseNo" slot-scope="text, record">
@@ -334,17 +335,19 @@ export default {
         }
       })
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+      this.openModal = false
+      this.getSupplierList()
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 270
     }
   },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
-  },
   watch: {
     advanced (newValue, oldValue) {
       const _this = this
@@ -353,20 +356,21 @@ export default {
       }, 400)
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.openModal = false
-      vm.getSupplierList()
-      if (!vm.disabled) {
-        vm.$refs.table.refresh()
-      }
-    })
+    next(vm => {})
   }
 }
 </script>

+ 10 - 4
src/views/customerManagement/customerInfo/edit.vue

@@ -339,12 +339,18 @@ export default {
     }
   },
   mounted () {
-    this.initPage()
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.initPage()
+    }
+  },
+  activated () {
+    // 如果是新页签打开或者进入新的子页(例:存在列表第2条数据编辑页页签时再打开第4条数据的编辑页),则重置当前页面
+    if (this.$store.state.app.isNewTab || !this.$store.state.app.isNewSubTab) {
+      this.initPage()
+    }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.initPage()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 17 - 13
src/views/customerManagement/customerInfo/list.vue

@@ -88,6 +88,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ x: 1220, y: tableHeight }"
+        :defaultLoadData="false"
         bordered>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
@@ -323,17 +324,19 @@ export default {
         }
       })
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+      this.getArea('province')
+      this.getCustTypeList()
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 235
     }
   },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
-  },
   watch: {
     advanced (newValue, oldValue) {
       const _this = this
@@ -342,20 +345,21 @@ export default {
       }, 400)
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getArea('province')
-      vm.getCustTypeList()
-      if (!vm.disabled) {
-        vm.$refs.table.refresh()
-      }
-    })
+    next(vm => {})
   }
 }
 </script>

+ 13 - 8
src/views/notice/list.vue

@@ -196,28 +196,33 @@ export default {
       this.itemId = ''
       this.openModal = false
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+      this.openModal = false
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 210
     }
   },
   mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
   },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.openModal = false
-      vm.handelSearch(1)
-    })
+    next(vm => {})
   }
 }
 </script>

+ 18 - 4
src/views/power/role/roleList.vue

@@ -39,6 +39,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ y: tableHeight }"
+        :defaultLoadData="false"
         bordered>
         <!-- 启用禁用 -->
         <span slot="status" slot-scope="text, record">
@@ -216,16 +217,29 @@ export default {
         }
       })
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 235
     }
   },
   mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.reset()
+    }
+  },
+  activated () {
+    // 如果是新页签打开,则重置当前页面
+    if (this.$store.state.app.isNewTab) {
+      this.pageInit()
+      this.reset()
+    }
   }
 }
 </script>

+ 18 - 4
src/views/power/user/userList.vue

@@ -38,6 +38,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ x: 1200, y: tableHeight }"
+        :defaultLoadData="false"
         bordered>
         <span slot="status" slot-scope="text, record">
           <a-switch v-if="$hasPermissions('B_powerMD_user_enable') && record.superAdmin!=1" checkedChildren="启用" unCheckedChildren="禁用" v-model="record.loginFlag" @change="changeFlagHandle(text, record)"/>
@@ -221,16 +222,29 @@ export default {
         }
       })
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 235
     }
   },
   mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.reset()
+    }
+  },
+  activated () {
+    // 如果是新页签打开,则重置当前页面
+    if (this.$store.state.app.isNewTab) {
+      this.pageInit()
+      this.reset()
+    }
   }
 }
 </script>

+ 12 - 14
src/views/productManagement/newProduct/detail.vue

@@ -21,7 +21,6 @@
             <a-descriptions-item label="商品尺寸:">{{ (detailsData && detailsData.size) || '--' }}</a-descriptions-item>
             <a-descriptions-item label="重量:">{{ (detailsData && detailsData.weight) || '--' }}</a-descriptions-item>
             <a-descriptions-item label="计量单位:">{{ (detailsData && detailsData.unit) || '--' }}</a-descriptions-item>
-            <!-- <a-descriptions-item label="适用车型:">{{ productTypeName || '--' }}</a-descriptions-item> -->
           </a-descriptions>
           <div class="productDetail">
             <h4>产品介绍</h4>
@@ -37,13 +36,6 @@
             <div slot="nextArrow" slot-scope="props" class="custom-slick-arrow" style="right: 10px"><a-icon type="right-circle" /></div>
             <div><img :src="detailsData.productMsg" /></div>
           </a-carousel>
-          <!-- <div class="sycxImg">
-            <p>适用车型图片</p>
-            <div>
-              <img src="../../../assets/avatar2.jpg" />
-              <div>江陵凯瑞200</div>
-            </div>
-          </div> -->
         </div>
       </div>
     </div>
@@ -82,14 +74,20 @@ export default {
     }
   },
   mounted () {
-    this.itemId = this.$route.params.sn
-    this.getDetail()
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.itemId = this.$route.params.sn
+      this.getDetail()
+    }
+  },
+  activated () {
+    // 如果是新页签打开或者进入新的子页(例:存在列表第2条数据编辑页页签时再打开第4条数据的编辑页),则重置当前页面
+    if (this.$store.state.app.isNewTab || !this.$store.state.app.isNewSubTab) {
+      this.itemId = this.$route.params.sn
+      this.getDetail()
+    }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.itemId = vm.$route.params.sn
-      vm.getDetail()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 16 - 11
src/views/productManagement/newProduct/list.vue

@@ -222,17 +222,19 @@ export default {
         }
       })
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+      this.getProductBrand()
+      this.getProductType()
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 215
     }
   },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
-  },
   watch: {
     advanced (newValue, oldValue) {
       const _this = this
@@ -241,18 +243,21 @@ export default {
       }, 400)
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.$refs.table.refresh(true)
-      vm.getProductBrand()
-      vm.getProductType()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 18 - 11
src/views/productManagement/priceChangeRecord/list.vue

@@ -77,6 +77,7 @@
       :columns="columns"
       :data="loadData"
       :scroll="{ x: 1760, y: tableHeight }"
+      :defaultLoadData="false"
       bordered>
       <!-- 产品分类 -->
       <template slot="productType" slot-scope="text, record">
@@ -316,17 +317,20 @@ export default {
         }
       })
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+      this.getColumns()
+      this.getProductBrand()
+      this.getProductType()
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 233
     }
   },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
-  },
   watch: {
     advanced (newValue, oldValue) {
       const _this = this
@@ -335,18 +339,21 @@ export default {
       }, 400)
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getColumns()
-      vm.getProductBrand()
-      vm.getProductType()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 14 - 9
src/views/productManagement/productBrand/list.vue

@@ -25,7 +25,6 @@
       <!-- 操作按钮 -->
       <div class="table-operator">
         <a-button v-if="$hasPermissions('B_product_dealerProductBrand_add')" id="productBrandList-add" type="primary" class="button-error" @click="handleEdit()">新增</a-button>
-        <!-- <a-button id="productBrandList-import" @click="handleImport">导入品牌</a-button> -->
       </div>
       <!-- 列表 -->
       <s-table
@@ -37,6 +36,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ y: tableHeight }"
+		:defaultLoadData="false"
         bordered>
         <!-- 状态 -->
         <template slot="enabledFlag" slot-scope="text, record">
@@ -152,24 +152,29 @@ export default {
         }
       })
     },
-    //  导入
-    handleImport () {},
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 235
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
-  },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
   }
 }
 </script>

+ 12 - 6
src/views/productManagement/productCategory/list.vue

@@ -16,6 +16,7 @@
         :showPagination="false"
         :defaultExpandedRowKeys="defaultExpandedRowKeys"
         :scroll="{ y: tableHeight }"
+        :defaultLoadData="false"
         bordered>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
@@ -94,12 +95,6 @@ export default {
       nowData: null //  当前记录数据
     }
   },
-  activated () {
-    // 如果是新页签打开,则重置当前页面
-    if (this.$store.state.app.isNewTab) {
-      this.$refs.table.refresh(true)
-    }
-  },
   methods: {
     //  新增子级
     handleAdd (row) {
@@ -164,6 +159,17 @@ export default {
         })
       }
     }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.$refs.table.refresh(true)
+    }
+  },
+  activated () {
+    // 如果是新页签打开,则重置当前页面
+    if (this.$store.state.app.isNewTab) {
+      this.$refs.table.refresh(true)
+    }
   }
 }
 </script>

+ 6 - 6
src/views/productManagement/productInfo/edit.vue

@@ -306,18 +306,18 @@ export default {
     }
   },
   mounted () {
-    this.pageInit()
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+    }
   },
   activated () {
-    // 如果是新页签打开,则重置当前页面
-    if (this.$store.state.app.isNewTab) {
+    // 如果是新页签打开或者进入新的子页(例:存在列表第2条数据编辑页页签时再打开第4条数据的编辑页),则重置当前页面
+    if (this.$store.state.app.isNewTab || !this.$store.state.app.isNewSubTab) {
       this.pageInit()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      // vm.pageInit()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 17 - 13
src/views/productManagement/productInfo/list.vue

@@ -88,6 +88,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ x: 1300, y: tableHeight }"
+        :defaultLoadData="false"
         bordered>
         <!-- 产品分类 -->
         <template slot="productType" slot-scope="text, record">
@@ -320,17 +321,19 @@ export default {
         }
       })
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+      this.getProductBrand()
+      this.getProductType()
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 235
     }
   },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
-  },
   watch: {
     advanced (newValue, oldValue) {
       const _this = this
@@ -339,20 +342,21 @@ export default {
       }, 400)
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getProductBrand()
-      vm.getProductType()
-      if (!vm.disabled) {
-        vm.$refs.table.refresh()
-      }
-    })
+    next(vm => {})
   }
 }
 </script>

+ 18 - 14
src/views/productManagement/productInfoJg/list.vue

@@ -82,6 +82,7 @@
       :columns="columns"
       :data="loadData"
       :scroll="{ x: 1540, y: tableHeight }"
+      :defaultLoadData="false"
       bordered>
       <!-- 产品图片 -->
       <template slot="imageUrl" slot-scope="text, record">
@@ -274,18 +275,20 @@ export default {
         }
       })
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+      this.getColumns()
+      this.getProductBrand()
+      this.getProductType()
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 195
     }
   },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
-    this.getColumns()
-  },
   watch: {
     advanced (newValue, oldValue) {
       const _this = this
@@ -294,20 +297,21 @@ export default {
       }, 400)
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getProductBrand()
-      vm.getProductType()
-      if (!vm.disabled) {
-        vm.getColumns()
-      }
-    })
+    next(vm => {})
   }
 }
 </script>

+ 13 - 5
src/views/reportData/chainCustomerReport/list.vue

@@ -316,20 +316,28 @@ export default {
           this.linkageGroupData = []
         }
       })
+    },
+    pageInit () {
+      this.getLinkageGroup()
+      this.getArea('province')
+      this.getProductType()
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
     }
   },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getLinkageGroup()
-      vm.getArea('province')
-      vm.getProductType()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 13 - 5
src/views/reportData/chainReceivedSendStorageReport/list.vue

@@ -300,20 +300,28 @@ export default {
           this.linkageGroupData = []
         }
       })
+    },
+    pageInit () {
+      this.getLinkageGroup()
+      this.getProductBrand()
+      this.getProductType()
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
     }
   },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getLinkageGroup()
-      vm.getProductBrand()
-      vm.getProductType()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 17 - 9
src/views/reportData/chainSalesDetailReport/list.vue

@@ -475,24 +475,32 @@ export default {
           }
         }
       })
+    },
+    pageInit () {
+      this.getLinkageGroup()
+      this.getArea('province')
+      this.getCustTypeList()
+      this.getSettleStyleList()
+      this.getProductBrand()
+      this.getProductType()
+      this.getWarehouseCascade()
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
     }
   },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getLinkageGroup()
-      vm.getArea('province')
-      vm.getCustTypeList()
-      vm.getSettleStyleList()
-      vm.getProductBrand()
-      vm.getProductType()
-      vm.getWarehouseCascade()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 14 - 6
src/views/reportData/chainSalesReport/list.vue

@@ -340,21 +340,29 @@ export default {
           }
         }
       })
+    },
+    pageInit () {
+      this.getLinkageGroup()
+      this.getArea('province')
+      this.getCustTypeList()
+      this.getSettleStyleList()
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
     }
   },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getLinkageGroup()
-      vm.getArea('province')
-      vm.getCustTypeList()
-      vm.getSettleStyleList()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 13 - 5
src/views/reportData/chainStockReport/list.vue

@@ -301,20 +301,28 @@ export default {
           this.linkageGroupData = []
         }
       })
+    },
+    pageInit () {
+      this.getLinkageGroup()
+      this.getProductBrand()
+      this.getProductType()
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
     }
   },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getLinkageGroup()
-      vm.getProductBrand()
-      vm.getProductType()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 12 - 4
src/views/reportData/customerReport/list.vue

@@ -287,19 +287,27 @@ export default {
           }
         }
       })
+    },
+    pageInit () {
+      this.getArea('province')
+      this.getProductType()
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
     }
   },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getArea('province')
-      vm.getProductType()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 12 - 4
src/views/reportData/receivedSendStorageReport/list.vue

@@ -267,19 +267,27 @@ export default {
       return (
         option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
       )
+    },
+    pageInit () {
+      this.getProductBrand()
+      this.getProductType()
+    }
+  },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
     }
   },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.getProductBrand()
-      vm.getProductType()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 12 - 7
src/views/reportData/stockExpenditureReport/list.vue

@@ -260,25 +260,30 @@ export default {
       this.tableData = []
       this.totalData = null
       this.chartInit()
+    },
+    pageInit () {
+      window.onresize = () => {
+        return (() => {
+          this.chart1.resize()
+        })()
+      }
     }
   },
   mounted () {
-    window.onresize = () => {
-      return (() => {
-        this.chart1.resize()
-      })()
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
     }
   },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.chartInit()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 12 - 7
src/views/reportData/stockIncomeReport/list.vue

@@ -260,25 +260,30 @@ export default {
       this.tableData = []
       this.totalData = null
       this.chartInit()
+    },
+    pageInit () {
+      window.onresize = () => {
+        return (() => {
+          this.chart1.resize()
+        })()
+      }
     }
   },
   mounted () {
-    window.onresize = () => {
-      return (() => {
-        this.chart1.resize()
-      })()
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
     }
   },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      vm.chartInit()
-    })
+    next(vm => {})
   }
 }
 </script>

+ 14 - 6
src/views/storeManagement/bind/list.vue

@@ -36,6 +36,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ y: tableHeight }"
+        :defaultLoadData="false"
         bordered>
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
@@ -142,22 +143,29 @@ export default {
         }
       })
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 235
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
-  },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
   }
 }
 </script>

+ 14 - 6
src/views/storeManagement/userAuthorization/list.vue

@@ -41,6 +41,7 @@
         :columns="columns"
         :data="loadData"
         :scroll="{ y: tableHeight }"
+        :defaultLoadData="false"
         bordered>
         <!-- 授权账号 -->
         <template slot="loginName" slot-scope="text, record">
@@ -152,22 +153,29 @@ export default {
         }
       })
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 235
     }
   },
+  mounted () {
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
+  },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
-  },
-  mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
   }
 }
 </script>

+ 13 - 9
src/views/supplierManagement/supplierInfo/list.vue

@@ -40,6 +40,7 @@
       :columns="columns"
       :data="loadData"
       :scroll="{ x: 1310, y: tableHeight }"
+      :defaultLoadData="false"
       bordered>
       <!-- 操作 -->
       <template slot="action" slot-scope="text, record">
@@ -125,29 +126,32 @@ export default {
       this.openModal = false
       this.$refs.table.refresh(true)
     },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 235
     }
   },
   mounted () {
-    const _this = this
-    this.$nextTick(() => { // 页面渲染完成后的回调
-      _this.setTableH()
-    })
+    if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.pageInit()
+      this.resetSearchForm()
+    }
   },
   activated () {
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
+      this.pageInit()
       this.resetSearchForm()
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {
-      if (!vm.disabled) {
-        vm.$refs.table.refresh()
-      }
-    })
+    next(vm => {})
   }
 }
 </script>