浏览代码

外贸产品

chenrui 2 月之前
父节点
当前提交
5d411eca80

二进制
public/templ/外贸产品查询模板.xlsx


+ 54 - 0
src/api/productForeign.js

@@ -0,0 +1,54 @@
+import { axios } from '@/utils/request'
+
+//  外贸产品  列表  有分页
+export const productForeignList = (params) => {
+  const url = `/productForeign/queryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('列表查询')
+    }
+  })
+}
+
+// 外贸产品  查询列表
+export const productForeignQueryList = params => {
+  return axios({
+    url: '/productForeign/queryList',
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('导入产品列表')
+    }
+  })
+}
+
+// 外贸产品  导出查询项
+export const productForeignExport = (params) => {
+  return axios({
+    url: '/productForeign/productExport',
+    data: params,
+    method: 'post',
+    responseType: 'blob',
+    headers: {
+      'module': encodeURIComponent('导出查询项')
+    }
+  })
+}
+
+// 外贸产品  列表导出
+export const foreignProductListExport = (params) => {
+  return axios({
+    url: '/productForeign/productListExport',
+    data: params,
+    method: 'post',
+    responseType: 'blob',
+    headers: {
+      'module': encodeURIComponent('导出')
+    }
+  })
+}

+ 381 - 356
src/config/productManagement.js

@@ -7,361 +7,386 @@ import {
 } from '@/layouts'
 
 export default {
-        path: '/productManagement',
-        redirect: '/productManagement/productInfo',
-        component: PageView,
-        meta: {
-          title: '产品管理',
-          icon: 'shopping',
-          permission: 'M_productManagement'
+  path: '/productManagement',
+  redirect: '/productManagement/productInfo',
+  component: PageView,
+  meta: {
+    title: '产品管理',
+    icon: 'shopping',
+    permission: 'M_productManagement'
+  },
+  children: [
+    {
+      path: '/productManagement/productInfo',
+      redirect: '/productManagement/productInfo/list',
+      name: 'productInfo',
+      component: BlankLayout,
+      meta: {
+        title: '产品列表',
+        icon: 'gold',
+        permission: 'M_productInfoList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'productInfoList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productInfo/list.vue'),
+          meta: {
+            title: '产品列表',
+            icon: 'gold',
+            hidden: true,
+            permission: 'M_productInfoList'
+          }
+        },
+        {
+          path: 'add',
+          name: 'productInfoAdd',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productInfo/edit.vue'),
+          meta: {
+            title: '新增产品',
+            icon: 'gold',
+            hidden: true
+            // permission: 'B_goodsManage_edit'
+          }
         },
-        children: [
-          {
-            path: '/productManagement/productInfo',
-            redirect: '/productManagement/productInfo/list',
-            name: 'productInfo',
-            component: BlankLayout,
-            meta: {
-              title: '产品列表',
-              icon: 'gold',
-              permission: 'M_productInfoList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'productInfoList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productInfo/list.vue'),
-                meta: {
-                  title: '产品列表',
-                  icon: 'gold',
-                  hidden: true,
-                  permission: 'M_productInfoList'
-                }
-              },
-              {
-                path: 'add',
-                name: 'productInfoAdd',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productInfo/edit.vue'),
-                meta: {
-                  title: '新增产品',
-                  icon: 'gold',
-                  hidden: true
-                  // permission: 'B_goodsManage_edit'
-                }
-              },
-              {
-                path: 'edit/:id/:sn',
-                name: 'productInfoEdit',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productInfo/edit.vue'),
-                meta: {
-                  title: '编辑产品',
-                  icon: 'gold',
-                  hidden: true
-                  // permission: 'B_goodsManage_edit'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/productPricing',
-            redirect: '/productManagement/productPricing/list',
-            name: 'productPricing',
-            component: BlankLayout,
-            meta: {
-              title: '产品定价',
-              icon: 'transaction',
-              permission: 'M_productPricingList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'productPricingList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productPricing/list.vue'),
-                meta: {
-                  title: '产品定价列表',
-                  icon: 'transaction',
-                  hidden: true,
-                  permission: 'M_productPricingList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/productLaunchAudit',
-            redirect: '/productManagement/productLaunchAudit/list',
-            name: 'productLaunchAudit',
-            component: BlankLayout,
-            meta: {
-              title: '产品上线审核',
-              icon: 'rise',
-              permission: 'M_productLaunchAuditList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'productLaunchAuditList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productLaunchAudit/list.vue'),
-                meta: {
-                  title: '产品上线审核列表',
-                  icon: 'rise',
-                  hidden: true,
-                  permission: 'M_productLaunchAuditList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/newProduct',
-            redirect: '/productManagement/newProduct/list/onlineInfo/1',
-            name: 'productLaunchInfo',
-            component: BlankLayout,
-            meta: {
-              title: '产品上线信息',
-              icon: 'rise',
-              permission: 'M_productLaunchInfoList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list/:type/:onlineFalg',
-                name: 'productLaunchInfoList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/newProduct/list.vue'),
-                meta: {
-                  title: '产品上线信息列表',
-                  icon: 'rise',
-                  hidden: true,
-                  permission: 'M_productLaunchInfoList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/productOfflineAudit',
-            redirect: '/productManagement/productOfflineAudit/list',
-            name: 'productOfflineAudit',
-            component: BlankLayout,
-            meta: {
-              title: '产品下线审核',
-              icon: 'fall',
-              permission: 'M_productOfflineAuditList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'productOfflineAuditList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productOfflineAudit/list.vue'),
-                meta: {
-                  title: '产品下线审核列表',
-                  icon: 'fall',
-                  hidden: true,
-                  permission: 'M_productOfflineAuditList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/productNotOnline',
-            redirect: '/productManagement/productNotOnline/list',
-            name: 'productNotOnline',
-            component: BlankLayout,
-            meta: {
-              title: '产品状态信息',
-              icon: 'fall',
-              permission: 'M_productNotOnlineList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'productNotOnlineList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productNotOnline/list.vue'),
-                meta: {
-                  title: '产品状态信息列表',
-                  icon: 'fall',
-                  hidden: true,
-                  permission: 'M_productNotOnlineList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/priceChangeRecord',
-            redirect: '/productManagement/priceChangeRecord/list',
-            name: 'priceChangeRecord',
-            component: BlankLayout,
-            meta: {
-              title: '价格变更记录',
-              icon: 'profile',
-              permission: 'M_priceChangeRecordList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'priceChangeRecordList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/priceChangeRecord/list.vue'),
-                meta: {
-                  title: '价格变更记录列表',
-                  icon: 'profile',
-                  hidden: true,
-                  permission: 'M_priceChangeRecordList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/productUniversal',
-            redirect: '/productManagement/productUniversal/list',
-            name: 'productUniversal',
-            component: BlankLayout,
-            meta: {
-              title: '通用产品管理',
-              icon: 'deployment-unit',
-              permission: 'M_productUniversalList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'productUniversalList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productUniversal/list.vue'),
-                meta: {
-                  title: '通用产品列表',
-                  icon: 'deployment-unit',
-                  hidden: true,
-                  permission: 'M_productUniversalList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/productLevel',
-            redirect: '/productManagement/productLevel/list',
-            name: 'productLevel',
-            component: BlankLayout,
-            meta: {
-              title: '产品级别管理',
-              icon: 'fund',
-              permission: 'M_productLevelList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'productLevelList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productLevel/list.vue'),
-                meta: {
-                  title: '产品级别列表',
-                  icon: 'fund',
-                  hidden: true,
-                  permission: 'M_productLevelList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/productBrand',
-            redirect: '/productManagement/productBrand/list',
-            name: 'productBrand',
-            component: BlankLayout,
-            meta: {
-              title: '产品品牌管理',
-              icon: 'file-ppt',
-              permission: 'M_productBrandList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'productBrandList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productBrand/list.vue'),
-                meta: {
-                  title: '产品品牌列表',
-                  icon: 'file-ppt',
-                  hidden: true,
-                  permission: 'M_productBrandList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/productCategory',
-            redirect: '/productManagement/productCategory/list',
-            name: 'productCategory',
-            component: BlankLayout,
-            meta: {
-              title: '产品分类管理',
-              icon: 'radar-chart',
-              permission: 'M_productCategoryList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'productCategoryList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productCategory/list.vue'),
-                meta: {
-                  title: '产品分类列表',
-                  icon: 'radar-chart',
-                  hidden: true,
-                  permission: 'M_productCategoryList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/shelfNoManage',
-            redirect: '/productManagement/shelfNoManage/list',
-            name: 'shelfNoManage',
-            component: BlankLayout,
-            meta: {
-              title: '货位编号管理',
-              icon: 'radar-chart',
-              permission: 'M_shelfNoManageList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'shelfNoManageList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/shelfNoManage/list.vue'),
-                meta: {
-                  title: '货位编号管理',
-                  icon: 'radar-chart',
-                  hidden: true,
-                  permission: 'M_shelfNoManageList'
-                }
-              }
-            ]
-          },
-          {
-            path: '/productManagement/productSourcePath',
-            redirect: '/productManagement/productSourcePath/list',
-            name: 'productSourcePath',
-            component: BlankLayout,
-            meta: {
-              title: '唯一码追溯列表',
-              icon: 'radar-chart',
-              permission: 'M_productSourcePathList'
-            },
-            hideChildrenInMenu: true,
-            children: [
-              {
-                path: 'list',
-                name: 'productSourcePathList',
-                component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productSourcePath/list.vue'),
-                meta: {
-                  title: '唯一码追溯列表',
-                  icon: 'radar-chart',
-                  hidden: true,
-                  permission: 'M_productSourcePathList'
-                }
-              }
-            ]
+        {
+          path: 'edit/:id/:sn',
+          name: 'productInfoEdit',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productInfo/edit.vue'),
+          meta: {
+            title: '编辑产品',
+            icon: 'gold',
+            hidden: true
+            // permission: 'B_goodsManage_edit'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/productPricing',
+      redirect: '/productManagement/productPricing/list',
+      name: 'productPricing',
+      component: BlankLayout,
+      meta: {
+        title: '产品定价',
+        icon: 'transaction',
+        permission: 'M_productPricingList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'productPricingList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productPricing/list.vue'),
+          meta: {
+            title: '产品定价列表',
+            icon: 'transaction',
+            hidden: true,
+            permission: 'M_productPricingList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/productLaunchAudit',
+      redirect: '/productManagement/productLaunchAudit/list',
+      name: 'productLaunchAudit',
+      component: BlankLayout,
+      meta: {
+        title: '产品上线审核',
+        icon: 'rise',
+        permission: 'M_productLaunchAuditList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'productLaunchAuditList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productLaunchAudit/list.vue'),
+          meta: {
+            title: '产品上线审核列表',
+            icon: 'rise',
+            hidden: true,
+            permission: 'M_productLaunchAuditList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/newProduct',
+      redirect: '/productManagement/newProduct/list/onlineInfo/1',
+      name: 'productLaunchInfo',
+      component: BlankLayout,
+      meta: {
+        title: '产品上线信息',
+        icon: 'rise',
+        permission: 'M_productLaunchInfoList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list/:type/:onlineFalg',
+          name: 'productLaunchInfoList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/newProduct/list.vue'),
+          meta: {
+            title: '产品上线信息列表',
+            icon: 'rise',
+            hidden: true,
+            permission: 'M_productLaunchInfoList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/productOfflineAudit',
+      redirect: '/productManagement/productOfflineAudit/list',
+      name: 'productOfflineAudit',
+      component: BlankLayout,
+      meta: {
+        title: '产品下线审核',
+        icon: 'fall',
+        permission: 'M_productOfflineAuditList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'productOfflineAuditList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productOfflineAudit/list.vue'),
+          meta: {
+            title: '产品下线审核列表',
+            icon: 'fall',
+            hidden: true,
+            permission: 'M_productOfflineAuditList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/productNotOnline',
+      redirect: '/productManagement/productNotOnline/list',
+      name: 'productNotOnline',
+      component: BlankLayout,
+      meta: {
+        title: '产品状态信息',
+        icon: 'fall',
+        permission: 'M_productNotOnlineList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'productNotOnlineList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productNotOnline/list.vue'),
+          meta: {
+            title: '产品状态信息列表',
+            icon: 'fall',
+            hidden: true,
+            permission: 'M_productNotOnlineList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/priceChangeRecord',
+      redirect: '/productManagement/priceChangeRecord/list',
+      name: 'priceChangeRecord',
+      component: BlankLayout,
+      meta: {
+        title: '价格变更记录',
+        icon: 'profile',
+        permission: 'M_priceChangeRecordList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'priceChangeRecordList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/priceChangeRecord/list.vue'),
+          meta: {
+            title: '价格变更记录列表',
+            icon: 'profile',
+            hidden: true,
+            permission: 'M_priceChangeRecordList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/productUniversal',
+      redirect: '/productManagement/productUniversal/list',
+      name: 'productUniversal',
+      component: BlankLayout,
+      meta: {
+        title: '通用产品管理',
+        icon: 'deployment-unit',
+        permission: 'M_productUniversalList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'productUniversalList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productUniversal/list.vue'),
+          meta: {
+            title: '通用产品列表',
+            icon: 'deployment-unit',
+            hidden: true,
+            permission: 'M_productUniversalList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/productLevel',
+      redirect: '/productManagement/productLevel/list',
+      name: 'productLevel',
+      component: BlankLayout,
+      meta: {
+        title: '产品级别管理',
+        icon: 'fund',
+        permission: 'M_productLevelList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'productLevelList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productLevel/list.vue'),
+          meta: {
+            title: '产品级别列表',
+            icon: 'fund',
+            hidden: true,
+            permission: 'M_productLevelList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/productBrand',
+      redirect: '/productManagement/productBrand/list',
+      name: 'productBrand',
+      component: BlankLayout,
+      meta: {
+        title: '产品品牌管理',
+        icon: 'file-ppt',
+        permission: 'M_productBrandList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'productBrandList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productBrand/list.vue'),
+          meta: {
+            title: '产品品牌列表',
+            icon: 'file-ppt',
+            hidden: true,
+            permission: 'M_productBrandList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/productCategory',
+      redirect: '/productManagement/productCategory/list',
+      name: 'productCategory',
+      component: BlankLayout,
+      meta: {
+        title: '产品分类管理',
+        icon: 'radar-chart',
+        permission: 'M_productCategoryList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'productCategoryList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productCategory/list.vue'),
+          meta: {
+            title: '产品分类列表',
+            icon: 'radar-chart',
+            hidden: true,
+            permission: 'M_productCategoryList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/shelfNoManage',
+      redirect: '/productManagement/shelfNoManage/list',
+      name: 'shelfNoManage',
+      component: BlankLayout,
+      meta: {
+        title: '货位编号管理',
+        icon: 'radar-chart',
+        permission: 'M_shelfNoManageList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'shelfNoManageList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/shelfNoManage/list.vue'),
+          meta: {
+            title: '货位编号管理',
+            icon: 'radar-chart',
+            hidden: true,
+            permission: 'M_shelfNoManageList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/productSourcePath',
+      redirect: '/productManagement/productSourcePath/list',
+      name: 'productSourcePath',
+      component: BlankLayout,
+      meta: {
+        title: '唯一码追溯列表',
+        icon: 'radar-chart',
+        permission: 'M_productSourcePathList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'productSourcePathList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/productSourcePath/list.vue'),
+          meta: {
+            title: '唯一码追溯列表',
+            icon: 'radar-chart',
+            hidden: true,
+            permission: 'M_productSourcePathList'
+          }
+        }
+      ]
+    },
+    {
+      path: '/productManagement/foreignTradeGoods',
+      redirect: '/productManagement/foreignTradeGoods/list',
+      name: 'foreignTradeGoods',
+      component: BlankLayout,
+      meta: {
+        title: '外贸产品',
+        icon: 'radar-chart'
+        // permission: 'M_foreignTradeGoodsList'
+      },
+      hideChildrenInMenu: true,
+      children: [
+        {
+          path: 'list',
+          name: 'foreignTradeGoodsList',
+          component: () => import(/* webpackChunkName: "productManagement" */ '@/views/productManagement/foreignTradeGoods/list.vue'),
+          meta: {
+            title: '外贸产品',
+            icon: 'radar-chart',
+            hidden: true
+            // permission: 'M_foreignTradeGoodsList'
           }
-        ]
-      }
+        }
+      ]
+    }
+  ]
+}

+ 182 - 0
src/views/productManagement/foreignTradeGoods/chooseImportModal.vue

@@ -0,0 +1,182 @@
+<template>
+  <a-modal
+    centered
+    class="chooseImport-modal"
+    :footer="null"
+    :maskClosable="false"
+    title="导入"
+    v-model="isShow"
+    @cancel="isShow=false"
+    width="75%">
+    <div class="chooseImport-con">
+      <p class="">查询数据{{ loadData.length }}条</p>
+      <a-table
+        class="sTable"
+        ref="table"
+        size="small"
+        rowClassName="red-text"
+        :rowKey="(record) => record.allocateSn"
+        :columns="nowColumns"
+        :dataSource="loadData"
+        :loading="loading"
+        :scroll="{ y: 500 }"
+        :pagination="false"
+        bordered>
+      </a-table>
+      <!-- 按钮 -->
+      <div class="btn-con">
+        <a-button
+          id="chooseImport-cancel"
+          size="large"
+          class="button-cancel"
+          @click="isShow=false"
+          style="padding: 0 40px;margin-left: 15px;">取消</a-button>
+        <a-button
+          type="primary"
+          id="chooseImport-error"
+          size="large"
+          class="button-error"
+          @click="handleExport"
+          style="padding: 0 40px;margin-left: 15px;">导出</a-button>
+      </div>
+    </div>
+  </a-modal>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import { hdExportExcel } from '@/libs/exportExcel'
+// 接口
+import { productForeignQueryList, productForeignExport } from '@/api/productForeign'
+export default {
+  name: 'ChooseImportModal',
+  mixins: [commonMixin],
+  props: {
+    openModal: { //  弹框显示状态
+      type: Boolean,
+      default: false
+    },
+    paramsData: {
+      type: Object,
+      default: () => {
+        return {}
+      }
+    }
+  },
+  data () {
+    const _this = this
+    return {
+      isShow: this.openModal, //  是否打开弹框
+      nowColumns: [
+        { title: '序号', dataIndex: 'no', width: '6%', align: 'center' },
+        { title: '查询码', dataIndex: 'queryCode', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '外贸产品编码', dataIndex: 'productForeignCode', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '箭冠产品编码', dataIndex: 'productCode', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: 'OE码', dataIndex: 'oeCode', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '大厂码',
+          children: [
+            {
+              title: 'MANN No.', dataIndex: 'mannCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' }
+            },
+            {
+              title: 'MAHLE No.', dataIndex: 'mahleCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' }
+            },
+            {
+              title: 'VIC No.', dataIndex: 'vicCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' }
+            },
+            {
+              title: 'FRAM NO.', dataIndex: 'framCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' }
+            },
+            {
+              title: 'WIX No.', dataIndex: 'wixCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' }
+            }
+          ]
+        },
+        { title: '产品尺寸', dataIndex: 'size', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '主材料', dataIndex: 'material', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '含盒报价', dataIndex: 'priceFreeBox', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
+        { title: '无盒报价', dataIndex: 'priceWithBox', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } }
+      ],
+      loadData: [],
+      loading: false
+    }
+  },
+  methods: {
+    getData () {
+      const _this = this
+      _this.loading = true
+      const params = {
+        path: _this.paramsData.path
+      }
+      productForeignQueryList(params).then(res => {
+        _this.loading = false
+        if (res.status == 200) {
+          if (res.data && res.data.length > 0) {
+            res.data.map((item, index) => {
+              item.no = index + 1
+            })
+          }
+          _this.loadData = res.data || []
+        }
+      })
+    },
+    // 导出
+    handleExport () {
+      const _this = this
+      if (_this.loadData.length < 1) {
+        _this.$message.info('暂无可导出的产品~')
+        return
+      }
+      _this.spinning = true
+      const newLoadData = _this.loadData.map(item => {
+        if (item.productEntity) {
+          item.productName = item.productEntity.name
+          item.productCode = item.productEntity.code
+          item.productOrigCode = item.productEntity.origCode
+          item.productTypeName1 = item.productEntity.productTypeName1
+          item.productTypeName2 = item.productEntity.productTypeName2
+          item.productTypeName3 = item.productEntity.productTypeName3
+        }
+        return item
+      })
+      hdExportExcel(productForeignExport, newLoadData, '外贸产品', function () {
+        _this.spinning = false
+      })
+    }
+  },
+  watch: {
+    //  父页面传过来的弹框状态
+    openModal (newValue, oldValue) {
+      this.isShow = newValue
+    },
+    //  重定义的弹框状态
+    isShow (newValue, oldValue) {
+      if (!newValue) {
+        this.$emit('close')
+        this.loadData = []
+      } else {
+        this.getData()
+      }
+    }
+  }
+}
+</script>
+
+<style lang="less" scoped>
+
+  .chooseImport-modal{
+    .chooseImport-con{
+      /deep/.red-text{
+        white-space: pre-line;
+      }
+      .btn-con{
+        text-align: center;
+        margin: 30px 0 20px;
+        .button-cancel,.button-error{
+          font-size: 12px;
+        }
+      }
+    }
+  }
+</style>

+ 190 - 0
src/views/productManagement/foreignTradeGoods/importGuideModal.vue

@@ -0,0 +1,190 @@
+<template>
+  <a-modal
+    centered
+    class="importGuide-modal"
+    :footer="null"
+    :maskClosable="false"
+    title="批量查询"
+    v-model="isShow"
+    @cancel="isShow=false"
+    :width="750">
+    <div class="importGuide-con">
+      <div class="explain-con">
+        <div class="explain-item">
+          <div class="explain-tit">
+            <span>1</span>准备导入
+          </div>
+          <ul>
+            <li>1)请先下载查询模板,输入查询码</li>
+            <li>2)最多可查询500条数据</li>
+            <li>
+              <a :href="filePath" style="margin: 5px 0 0;display: block;">
+                <a-icon type="download" style="padding-right: 5px;" />下载导入模板
+              </a>
+            </li>
+          </ul>
+        </div>
+        <div class="explain-item">
+          <div class="explain-tit">
+            <span>2</span>上传数据文件
+          </div>
+          <p>目前支持的文件类型*.xls,*.xlsx.</p>
+          <div style="overflow: hidden;padding-left: 23px;">
+            <Upload
+              id="importGuide-attachList"
+              ref="importUpload"
+              :maxNums="1"
+              fileType="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,application/vnd.ms-excel"
+              uploadType="import"
+              :action="attachAction"
+              :uploadParams="uploadParams"
+              upText="添加文件"
+              @change="changeImport"></Upload>
+          </div>
+        </div>
+      </div>
+      <!-- 按钮 -->
+      <div class="btn-con">
+        <a-button
+          type="primary"
+          id="importGuide-nextStep"
+          size="large"
+          class="button-primary"
+          @click="handlerNextStep"
+          style="padding: 0 60px;">查询</a-button>
+        <a-button
+          id="importGuide-cancel"
+          size="large"
+          class="button-cancel"
+          @click="isShow=false"
+          style="padding: 0 60px;margin-left: 15px;">取消</a-button>
+      </div>
+    </div>
+    <!-- 导入 -->
+    <chooseImportModal :openModal="openImportModal" :paramsData="paramsData" @close="handleClose" @ok="hanldeOk" />
+  </a-modal>
+</template>
+
+<script>
+import ChooseImportModal from './chooseImportModal.vue'
+import { Upload } from '@/components'
+export default {
+  name: 'ImportGuideModal',
+  components: { ChooseImportModal, Upload },
+  props: {
+    openModal: { //  弹框显示状态
+      type: Boolean,
+      default: false
+    },
+    params: {
+      type: Object,
+      default: null
+    }
+  },
+  data () {
+    return {
+      isShow: this.openModal, //  是否打开弹框
+      openImportModal: false, //  导入
+      attachAction: process.env.VUE_APP_API_BASE_URL + '/upload',
+      paramsData: null,
+      uploadParams: {
+        savePathType: 'local'
+      },
+      exportLoading: false,
+      filePath: location.protocol + '//' + location.host + '/templ/外贸产品查询模板.xlsx'
+    }
+  },
+  methods: {
+    // 查询
+    handlerNextStep () {
+      if (this.paramsData) {
+        this.openImportModal = true
+      } else {
+        this.$message.warning('添加文件后再进行查询操作!')
+      }
+    },
+    // 上传文件  change
+    changeImport (file) {
+      if (file) {
+        this.paramsData = {
+          path: file
+        }
+      }
+    },
+    // 导入
+    hanldeOk (obj) {
+      if (obj && obj.length > 0) {
+        this.$emit('ok', obj)
+        this.isShow = false
+      }
+    },
+    // 关闭
+    handleClose () {
+      this.openImportModal = false
+      this.isShow = false
+    }
+  },
+  watch: {
+    //  父页面传过来的弹框状态
+    openModal (newValue, oldValue) {
+      this.isShow = newValue
+    },
+    //  重定义的弹框状态
+    isShow (newValue, oldValue) {
+      if (!newValue) {
+        this.$emit('close')
+        this.paramsData = null
+        this.$refs.importUpload.setFileList('')
+      }
+    }
+  }
+}
+</script>
+
+<style lang="less" scoped>
+  .importGuide-modal{
+    .importGuide-con{
+      .explain-con{
+        .explain-item{
+          margin-bottom: 10px;
+          .explain-tit{
+            font-weight: bold;
+            span{
+              display: inline-block;
+              width: 18px;
+              height: 18px;
+              line-height: 16px;
+              text-align: center;
+              margin-right: 5px;
+              border-radius: 50%;
+              border: 1px solid rgba(0, 0, 0, 0.3);
+            }
+          }
+          p{
+            margin: 8px 0;
+            padding-left: 23px;
+          }
+          ul{
+            list-style: none;
+            padding: 0;
+            padding-left: 23px;
+            margin: 0;
+            li{
+              line-height: 26px;
+            }
+          }
+        }
+        #importGuide-attachList{
+          width: 100%;
+        }
+      }
+      .btn-con{
+        margin: 10px 0 20px;
+        text-align: center;
+        .button-cancel{
+          font-size: 12px;
+        }
+      }
+    }
+  }
+</style>

+ 228 - 0
src/views/productManagement/foreignTradeGoods/list.vue

@@ -0,0 +1,228 @@
+<template>
+  <div>
+    <a-card size="small" :bordered="false" class="foreignTradeGoods-wrap searchBoxNormal">
+      <!-- 搜索条件 -->
+      <div ref="tableSearch" class="table-page-search-wrapper">
+        <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
+          <a-row :gutter="15">
+            <a-col :md="6" :sm="24">
+              <a-form-item label="外贸产品编码/箭冠产品编码">
+                <a-input id="foreignTradeGoods-productCode" v-model.trim="queryParam.productCode" allowClear placeholder="请输入外贸产品编码/箭冠产品编码"/>
+              </a-form-item>
+            </a-col>
+            <a-col :md="6" :sm="24">
+              <a-form-item label="OE码">
+                <a-input id="foreignTradeGoods-oeCode" v-model.trim="queryParam.oeCode" allowClear placeholder="请输入OE码"/>
+              </a-form-item>
+            </a-col>
+            <a-col :md="6" :sm="24">
+              <a-form-item label="大厂码">
+                <a-input id="foreignTradeGoods-queryBigCode " v-model.trim="queryParam.queryBigCode " allowClear placeholder="请输入大厂码"/>
+              </a-form-item>
+            </a-col>
+            <a-col :md="6" :sm="24" style="margin-bottom: 10px;">
+              <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="foreignTradeGoods-refresh">查询</a-button>
+              <a-button style="margin-left: 5px" @click="resetSearchForm" :disabled="disabled" id="foreignTradeGoods-reset">重置</a-button>
+              <a-button
+                style="margin-left: 5px;"
+                v-if="$hasPermissions('B_foreignTradeGood_export')"
+                type="primary"
+                class="button-warning"
+                @click="handleExport"
+                :disabled="disabled"
+                :loading="exportLoading"
+                id="foreignTradeGoods-export">导出</a-button>
+            </a-col>
+          </a-row>
+        </a-form>
+      </div>
+    </a-card>
+    <a-card size="small" :bordered="false">
+      <a-spin :spinning="spinning" tip="Loading...">
+        <!-- 操作按钮-->
+        <div class="table-operator">
+          <!-- v-if="$hasPermissions('B_foreignTradeGood_search')" -->
+          <a-button
+
+            id="foreignTradeGoods-batchAudit"
+            type="primary"
+            @click="openGuideModal = true"
+          >批量查询</a-button>
+        </div>
+        <s-table
+          class="sTable fixPagination"
+          ref="table"
+          rowClassName="red-text"
+          :style="{ height: tableHeight+70+'px' }"
+          size="small"
+          :rowKey="(record) => record.no"
+          rowKeyName="no"
+          :columns="columns"
+          :data="loadData"
+          :pageSize="30"
+          :scroll="{ y: tableHeight-30 }"
+          :defaultLoadData="false"
+          bordered>
+        </s-table>
+      </a-spin>
+      <!-- 批量查询 -->
+      <importGuideModal :openModal="openGuideModal" @close="openGuideModal=false" />
+      <!-- 导出提示框 -->
+      <reportModal :visible="showExport" @close="showExport=false"></reportModal>
+    </a-card>
+  </div>
+</template>
+
+<script>
+import { commonMixin } from '@/utils/mixin'
+// 组件
+import { STable, VSelect } from '@/components'
+import productTypeAll from '@/views/common/productTypeAll.js'
+import { hdExportExcel } from '@/libs/exportExcel'
+import ImportGuideModal from './importGuideModal.vue'
+import reportModal from '@/views/common/reportModal.vue'
+// 接口
+import { productForeignList, foreignProductListExport } from '@/api/productForeign'
+export default {
+  name: 'ForeignTradeGoods',
+  mixins: [commonMixin],
+  components: { STable, VSelect, productTypeAll, ImportGuideModal, reportModal },
+  data () {
+    const _this = this
+    return {
+      spinning: false,
+      openGuideModal: false, // 批量查询  弹窗
+      disabled: false, //  查询、重置按钮是否可操作
+      tableHeight: 0, // 表格高度
+      queryParam: { //  查询条件
+        productName: undefined, //  产品名称
+        productCode: undefined, // 产品编码
+        productTypeSn1: undefined, //  产品一级分类
+        productTypeSn2: undefined, //  产品二级分类
+        productTypeSn3: undefined, //  产品三级分类
+        oeCode: undefined, // oe码
+        queryBigCode: undefined, // 大厂码
+        material: undefined// 主材料
+      },
+      productType: [], // 产品分类
+      exportLoading: false, // 导出 loading
+      showExport: false, // 导出弹窗
+      columns: [
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '外贸产品编码', dataIndex: 'productForeignCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '箭冠产品编码', dataIndex: 'productCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: 'OE码', dataIndex: 'oeCode', width: '9%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '大厂码',
+          children: [
+            {
+              title: 'MANN No.', dataIndex: 'mannCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' }
+            },
+            {
+              title: 'MAHLE No.', dataIndex: 'mahleCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' }
+            },
+            {
+              title: 'VIC No.', dataIndex: 'vicCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' }
+            },
+            {
+              title: 'FRAM NO.', dataIndex: 'framCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' }
+            },
+            {
+              title: 'WIX No.', dataIndex: 'wixCode', width: '10%', align: 'center', customRender: function (text) { return text || '--' }
+            }
+          ]
+        },
+        { title: '产品尺寸', dataIndex: 'size', width: '9%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '主材料', dataIndex: 'material', width: '9%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '含盒报价', dataIndex: 'priceFreeBox', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
+        { title: '无盒报价', dataIndex: 'priceWithBox', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } }
+      ],
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        this.spinning = true
+        return productForeignList(Object.assign(parameter, this.queryParam)).then(res => {
+          let data
+          if (res.status == 200) {
+            data = res.data
+            const no = (data.pageNo - 1) * data.pageSize
+            for (var i = 0; i < data.list.length; i++) {
+              data.list[i].no = no + i + 1
+            }
+            this.disabled = false
+          }
+          this.spinning = false
+          return data
+        })
+      }
+    }
+  },
+  methods: {
+    //  重置
+    resetSearchForm () {
+      this.queryParam = {
+        productName: undefined, //  产品名称
+        productCode: undefined, // 产品编码
+        productTypeSn1: undefined, //  产品一级分类
+        productTypeSn2: undefined, //  产品二级分类
+        productTypeSn3: undefined, //  产品三级分类
+        oeCode: undefined, // oe码
+        queryBigCode: undefined, // 大厂码
+        material: undefined// 主材料
+      }
+      this.productType = []
+      this.$refs.table.refresh(true)
+    },
+    //  导出
+    handleExport () {
+      const _this = this
+      const params = this.queryParam
+      _this.spinning = true
+      _this.exportLoading = true
+      _this.showExport = true
+      hdExportExcel(foreignProductListExport, params, '外贸产品', function () {
+        _this.spinning = false
+        _this.exportLoading = false
+      })
+    },
+    //  产品分类  change
+    changeProductType (val, opt) {
+      this.queryParam.productTypeSn1 = val[0] ? val[0] : undefined
+      this.queryParam.productTypeSn2 = val[1] ? val[1] : undefined
+      this.queryParam.productTypeSn3 = val[2] ? val[2] : undefined
+    },
+    pageInit () {
+      const _this = this
+      this.$nextTick(() => { // 页面渲染完成后的回调
+        _this.setTableH()
+      })
+    },
+    setTableH () {
+      const tableSearchH = this.$refs.tableSearch.offsetHeight
+      this.tableHeight = window.innerHeight - tableSearchH - 240
+    }
+  },
+  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.pageFromInfo = from
+    })
+  }
+}
+</script>
+<style lang="less" scoped>
+/deep/.red-text{
+        white-space: pre-line;
+      }
+</style>