lilei 2 年之前
父節點
當前提交
2c1b91d440
共有 3 個文件被更改,包括 12 次插入2 次删除
  1. 10 0
      src/config/router.config.js
  2. 1 1
      src/views/Home.vue
  3. 1 1
      src/views/productManagement/newProduct/modal.vue

+ 10 - 0
src/config/router.config.js

@@ -91,6 +91,16 @@ export const asyncRouterMap = [
                 },
                 hidden: true
               },
+              {
+                path: '/newProduct/list/:onlineFalg',
+                name: 'oldProductList',
+                component: () => import(/* webpackChunkName: "home" */ '@/views/productManagement/newProduct/list'),
+                meta: {
+                  title: '下线产品列表',
+                  icon: 'home'
+                },
+                hidden: true
+              },
               // 产品详情
               {
                 path: '/viewProduct/:sn',

+ 1 - 1
src/views/Home.vue

@@ -83,7 +83,7 @@ export default {
     // 查看更多产品
     seeMore () {
       this.openNewProduct = false
-      this.$router.push({ name: 'newProductList', params: { onlineFalg: this.onlineFalg } })
+      this.$router.push({ name: this.onlineFalg == 1 ? 'newProductList' : 'oldProductList', params: { onlineFalg: this.onlineFalg } })
     },
     // 关闭弹框
     cancelProductTips () {

+ 1 - 1
src/views/productManagement/newProduct/modal.vue

@@ -15,7 +15,7 @@
         bordered>
       </s-table>
       <div style="padding-top: 15px;">
-        <a-button @click="viewMore" block type="primary" ghost>查看更多新品</a-button>
+        <a-button @click="viewMore" block type="primary" ghost>查看更多{{onlineFalg==1?'新品':'下线产品'}}</a-button>
       </div>
     </a-spin>
   </div>