sunlupeng 7 місяців тому
батько
коміт
aee73460bc

+ 4 - 0
src/permission.js

@@ -164,6 +164,10 @@ const myRoles = [
   'vip',
   'guest',
 
+  //报表管理
+  'report',
+  'stockReport',
+
   'dictManage', 
   'dictList', 
   'dictDataList', 

+ 0 - 475
src/router/index copy.js

@@ -1,475 +0,0 @@
-import Vue from 'vue'
-import Router from 'vue-router'
-const _import = require('./_import_' + process.env.NODE_ENV)
-// in development-env not use lazy-loading, because lazy-loading too many pages will cause webpack hot update too slow. so only in production use lazy-loading;
-// detail: https://panjiachen.github.io/vue-element-admin-site/#/lazy-loading
-
-Vue.use(Router)
-
-/* Layout */
-import Layout from '../views/layout/Layout'
-
-/** note: submenu only apppear when children.length>=1
-*   detail see  https://panjiachen.github.io/vue-element-admin-site/#/router-and-nav?id=sidebar
-**/
-
-/**
-* hidden: true                   if `hidden:true` will not show in the sidebar(default is false)
-* alwaysShow: true               if set true, will always show the root menu, whatever its child routes length
-*                                if not set alwaysShow, only more than one route under the children
-*                                it will becomes nested mode, otherwise not show the root menu
-* redirect: noredirect           if `redirect:noredirect` will no redirct in the breadcrumb
-* name:'router-name'             the name is used by <keep-alive> (must set!!!)
-* meta : {
-    roles: ['admin','editor']     will control the page roles (you can set multiple roles)
-    title: 'title'               the name show in submenu and breadcrumb (recommend set)
-    icon: 'svg-name'             the icon show in the sidebar,
-    noCache: true                if fasle ,the page will no be cached(default is false)
-  }
-**/
-export const constantRouterMap = [
-  { path: '/login', component: _import('login/index'), hidden: true },
-  { path: '/authredirect', component: _import('login/authredirect'), hidden: true },
-  { path: '/404', component: _import('error/404'), hidden: true },
-  { path: '/401', component: _import('error/401'), hidden: true },
-  {
-    path: '',
-    component: Layout,
-    redirect: 'dashboard',
-    children: [{
-      path: 'dashboard',
-      component: _import('dashboard/index'),
-      name: 'dashboard',
-      meta: { title: '首页', icon: 'dashboard', noCache: true }
-    }]
-  }
-]
-
-export default new Router({
-  // mode: 'history', // require service support
-  scrollBehavior: () => ({ y: 0 }),
-  routes: constantRouterMap
-})
-
-export const asyncRouterMap = [
-  {
-    path: '/activeUsers',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'activeUsers',
-    meta: {
-      title: '活跃用户',
-      icon: 'paihang'
-    },
-    children: [
-      { path: 'activeUsers', component: _import('activeUsers/index'), name: 'activeUsers', meta: { title: '活跃用户', icon: 'paihang', noCache: true }},
-    ]
-  },
-  {
-    path: '/pointsLottery',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'pointsLottery',
-    meta: {
-      title: '积分抽奖',
-      icon: 'paihang'
-    },
-    children: [
-      { path: 'pointsLottery', component: _import('pointsLottery/index'), name: 'pointsLottery', meta: { title: '积分抽奖', icon: 'paihang', noCache: true }},
-    ]
-  },
-  {
-    path: '/pointManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'pointManage',
-    meta: {
-      title: '积分管理',
-      icon: 'jifen'
-    },
-    children: [
-      { path: 'pointInstructions', component: _import('pointManage/pointInstructions'), name: 'pointInstructions', meta: { title: '积分规则说明书', noCache: true }},
-      { path: 'pointRulesList', component: _import('pointManage/pointRulesList'), name: 'pointRulesList', meta: { title: '积分规则列表', noCache: true }},
-      { path: 'pointIndateList', component: _import('pointManage/pointIndateList'), name: 'pointIndateList', meta: { title: '积分有效期列表', noCache: true }},
-      { path: 'pointList', component: _import('pointManage/pointList'), name: 'pointList', meta: { title: '积分列表', noCache: true }},
-      { path: 'pointsDetailList', component: _import('pointManage/pointsDetailList'), name: 'pointsDetailList', meta: { title: '积分明细列表', noCache: true }},
-      { path: 'pointsPlusOrMinus', component: _import('pointManage/pointsPlusOrMinus'), name: 'pointsPlusOrMinus', meta: { title: '积分加减列表', noCache: true }},
-    ]
-  },
-  {
-    path: '/goodsManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'goodsManage',
-    meta: {
-      title: '商品管理',
-      icon: 'shangpin'
-    },
-    children: [
-      { path: 'goodsExchangeRules', component: _import('goodsManage/goodsExchangeRules'), name: 'goodsExchangeRules', meta: { title: '兑换须知', noCache: true }},
-      { path: 'goodsList', component: _import('goodsManage/goodsList'), name: 'goodsList', meta: { title: '商品列表', noCache: true }},
-    ]
-  },
-  {
-    path: '/giftManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'giftManage',
-    meta: {
-      title: '礼品管理',
-      icon: 'lipin'
-    },
-    children: [
-      { path: 'giftExchangeRules', component: _import('giftManage/giftExchangeRules'), name: 'giftExchangeRules', meta: { title: '兑换须知', noCache: true }},
-      { path: 'giftList', component: _import('giftManage/giftList'), name: 'giftList', meta: { title: '礼品列表', noCache: true }},
-    ]
-  },
-  {
-    path: '/welfareManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'welfareManage',
-    meta: {
-      title: '福利管理',
-      icon: 'fuli'
-    },
-    children: [
-      { path: 'welfareList', component: _import('welfareManage/welfareList'), name: 'welfareList', meta: { title: '福利列表', icon: 'lipin', noCache: true }},
-      // { path: 'welfareList', component: _import('welfareManage/welfareList'), name: 'welfareList', meta: { title: '福利列表', noCache: false, hideTag: true, hidden: true}},
-    ]
-  },
-  {
-    path: '/exchangeManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'exchangeManage',
-    meta: {
-      title: '兑换管理',
-      icon: 'duihuan'
-    },
-    children: [
-      { path: 'exchangeList', component: _import('exchangeManage/exchangeList'), name: 'exchangeList', meta: { title: '兑换列表', noCache: true }},
-      { path: 'cancelledList', component: _import('exchangeManage/cancelledList'), name: 'cancelledList', meta: { title: '已作废列表', noCache: true }},
-      { path: 'approvalList', component: _import('exchangeManage/approvalList'), name: 'approvalList', meta: { title: '待审批列表', noCache: true }},
-      { path: 'pasList', component: _import('exchangeManage/pasList'), name: 'pasList', meta: { title: '待发货列表', noCache: true }},
-      { path: 'voidList', component: _import('exchangeManage/voidList'), name: 'voidList', meta: { title: '订单已完成列表', noCache: true }},
-    ]
-  },
-  {
-    path: '/activityManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'activityManage',
-    meta: {
-      title: '活动管理',
-      icon: 'huodong'
-    },
-    children: [
-      { path: 'activityList', component: _import('activityManage/activityList'), name: 'activityList', meta: { title: '活动列表', icon: 'huodong', noCache: true }},
-      // { path: 'activityList', component: _import('activityManage/activityList'), name: 'activityList', meta: { title: '活动列表', noCache: false, hideTag: true, hidden: true}},
-    ]
-  },
-  {
-    path: '/answerGame',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'answerGame',
-    meta: {
-      title: '答题管理',
-      icon: 'huodong'
-    },
-    children: [
-      { path: 'answerList', component: _import('answerGame/answerList'), name: 'answerList', meta: { title: '答题列表', icon: 'huodong', noCache: true }},
-    ]
-  },
-  {
-    path: '/noticeManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'noticeManage',
-    meta: {
-      title: '通知管理',
-      icon: 'tongzhi'
-    },
-    children: [
-      { path: 'noticeList', component: _import('noticeManage/noticeList'), name: 'noticeList', meta: { title: '通知列表', icon: 'tongzhi', noCache: true }},
-      // { path: 'noticeList', component: _import('noticeManage/noticeList'), name: 'noticeList', meta: { title: '通知列表', noCache: false, hideTag: true, hidden: true}},
-    ]
-  },
-  {
-    path: '/ranking',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'ranking',
-    meta: {
-      title: '积分排行',
-      icon: 'paihang'
-    },
-    children: [
-      { path: 'rankingList', component: _import('ranking/rankingList'), name: 'rankingList', meta: { title: '积分排行', icon: 'paihang', noCache: true }},
-    ]
-  },
-  {
-    path: '/medalManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'medalManage',
-    meta: {
-      title: '勋章管理',
-      icon: 'xunzhang'
-    },
-    children: [
-      { path: 'medalList', component: _import('medalManage/medalList'), name: 'medalList', meta: { title: '勋章列表', noCache: true }},
-      { path: 'medalDataList/:id', component: _import('medalManage/medalDataList'), name: 'medalDataList', meta: { title: '勋章等级列表', noCache: false, hideTag: true, hidden: true }},
-    ]
-  },
-  {
-    path: '/raffleManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'raffleManage',
-    meta: {
-      title: '抽奖管理',
-      icon: 'huodong'
-    },
-    children: [
-      { path: 'raffleList', component: _import('raffleManage/raffleList'), name: 'raffleList', meta: { title: '奖池列表', noCache: true }},
-      { path: 'raffleLogsList', component: _import('raffleManage/raffleLogsList'), name: 'raffleLogsList', meta: { title: '抽奖记录', noCache: true }},
-      { path: 'raffleDataList/:id', component: _import('raffleManage/raffleDataList'), name: 'raffleDataList', meta: { title: '奖池奖品', noCache: false, hideTag: true, hidden: true }},
-    ]
-  },
-  {
-    path: '/lotteryManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'lotteryManage',
-    meta: {
-      title: '开奖管理',
-      icon: 'huodong'
-    },
-    children: [
-      { path: 'lotteryList', component: _import('lotteryManage/lotteryList'), name: 'lotteryList', meta: { title: '奖池列表', noCache: true }},
-      { path: 'lotteryLogsList', component: _import('lotteryManage/lotteryLogsList'), name: 'lotteryLogsList', meta: { title: '抽奖记录', noCache: true }},
-      { path: 'lotteryDataList/:id', component: _import('lotteryManage/lotteryDataList'), name: 'lotteryDataList', meta: { title: '奖池奖品', noCache: false, hideTag: true, hidden: true }},
-    ]
-  },
-  {
-    path: '/couponsManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'couponsManage',
-    meta: {
-      title: '兑换卷管理',
-      icon: 'huodong'
-    },
-    children: [
-      { path: 'couponsList', component: _import('couponsManage/couponsList'), name: 'couponsList', meta: { title: '兑换卷列表', icon: 'huodong', noCache: true }},
-    ]
-  },
-  {
-    path: '/commendManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'commendManage',
-    meta: {
-      title: '表彰管理',
-      icon: 'xunzhang'
-    },
-    children: [
-      { path: 'commendList', component: _import('commendManage/commendList'), name: 'commendList', meta: { title: '表彰列表', noCache: true }},
-      { path: 'commendDataList/:id', component: _import('commendManage/commendDataList'), name: 'commendDataList', meta: { title: '表彰人员', noCache: false, hideTag: true, hidden: true }},
-      { path: 'citeList', component: _import('commendManage/citeList'), name: 'citeList', meta: { title: '客户表彰列表', noCache: true }},
-      { path: 'operateCiteList', component: _import('commendManage/operateCiteList'), name: 'operateCiteList', meta: { title: '客户表彰审批列表', noCache: true }},
-      { path: 'ceoCiteList', component: _import('commendManage/ceoCiteList'), name: 'ceoCiteList', meta: { title: '客户表彰确认列表', noCache: true }},
-    ]
-  },
-  {
-    path: '/trainManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'trainManage',
-    meta: {
-      title: '培训管理',
-      icon: 'xunzhang'
-    },
-    children: [
-      { path: 'upLoadFileRules', component: _import('trainManage/upLoadFileRules'), name: 'upLoadFileRules', meta: { title: '培训材料备注', noCache: true }},
-      { path: 'trainList', component: _import('trainManage/trainList'), name: 'trainList', meta: { title: '培训列表', noCache: true }},
-      { path: 'operateTrainList', component: _import('trainManage/operateTrainList'), name: 'operateTrainList', meta: { title: '培训审批列表', noCache: true }},
-      { path: 'ceoTrainList', component: _import('trainManage/ceoTrainList'), name: 'ceoTrainList', meta: { title: '培训确认列表', noCache: true }},
-    ]
-  },
-  {
-    path: '/festivalManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'festivalManage',
-    meta: {
-      title: '节日管理',
-      icon: 'lipin'
-    },
-    children: [
-      { path: 'festivalList', component: _import('festivalManage/festivalList'), name: 'festivalList', meta: { title: '节日列表', icon: 'lipin', noCache: true }},
-    ]
-  },
-  {
-    path: '/certManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'certManage',
-    meta: {
-      title: '证书管理',
-      icon: 'zhengshu'
-    },
-    children: [
-      { path: 'certSetList', component: _import('certManage/certSetList'), name: 'certSetList', meta: { title: '证书配置列表', noCache: true }},
-      { path: 'certRules', component: _import('certManage/certRules'), name: 'certRules', meta: { title: '积分获取规则', noCache: true }},
-      { path: 'certList', component: _import('certManage/certList'), name: 'certList', meta: { title: '证书列表', noCache: true }},
-      
-    ]
-  },
-  {
-    path: '/dictManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'dictManage',
-    meta: {
-      title: '字典管理',
-      icon: 'zidian'
-    },
-    children: [
-      { path: 'dictList', component: _import('dictManage/dictList'), name: 'dictList', meta: { title: '字典列表', noCache: true }},
-      { path: 'dictDataList/:id', component: _import('dictManage/dictDataList'), name: 'dictDataList', meta: { title: '字典数据', noCache: false, hideTag: true, hidden: true }},
-    ]
-  },
-
-  {
-    path: '/postManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'postManage',
-    meta: {
-      title: '帖子管理',
-      icon: 'fuli'
-    },
-    children: [
-      { path: 'postList', component: _import('postManage/postList'), name: 'postList', meta: { title: '帖子列表', noCache: true }},
-      { path: 'postApprovalList', component: _import('postManage/postApprovalList'), name: 'postApprovalList', meta: { title: '回复列表', noCache: true}},
-    ]
-  },
-
-  {
-    path: '/rankingManage',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'rankingManage',
-    meta: {
-      title: '排行管理',
-      icon: 'zhengshu'
-    },
-    children: [
-      { path: 'answerRanking', component: _import('rankingManage/answerRanking'), name: 'answerRanking', meta: { title: '答题排行', noCache: true }},
-      { path: 'gameRanking', component: _import('rankingManage/gameRanking'), name: 'gameRanking', meta: { title: '游戏排行', noCache: true}},
-    ]
-  },
-
-
-
-  {
-    path: '/user',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'userManage',
-    meta: {
-      title: '用户管理',
-      icon: 'people'
-    },
-    children: [
-      { path: 'user', component: _import('user/user'), name: 'user', meta: { title: '联系人', noCache: true }},
-      { path: 'checkUser', component: _import('user/checkUser'), name: 'checkUser', meta: { title: '待审核', noCache: true }},
-      { path: 'approveHistory', component: _import('user/approveHistory'), name: 'approveHistory', meta: { title: '驳回记录', noCache: true }},
-      { path: 'userDetail', component: _import('user/userDetail'), name: 'userDetail', meta: { title: '用户详情', noCache: false, hideTag: true, hidden: true }},
-      { path: 'welfare', component: _import('user/welfare'), name: 'welfare', meta: { title: '用户福利', noCache: true }},
-    ]
-  },
-  {
-    path: '/community',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'communityManage',
-    meta: {
-      title: '圈子管理',
-      icon: 'example'
-    },
-    children: [
-      { path: 'local', component: _import('organize/organizePlace'), name: 'local', meta: { title: '部门专委会', noCache: true }},
-      { path: 'industry', component: _import('organize/organizeTrade'), name: 'industry', meta: { title: '技术专委会', noCache: true }},
-      { path: 'interest', component: _import('organize/organizeInterest'), name: 'interest', meta: { title: '兴趣小组', noCache: true }}
-    ]
-  },
-  {
-    path: '/content',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'contentManage',
-    meta: {
-      title: '内容&互动',
-      icon: 'language'
-    },
-    children: [
-      { path: 'yearLottoNotice', component: _import('content/yearLottoNotice'), name: 'yearLottoNotice', meta: { title: '年会抽奖规则', noCache: true }},
-      { path: 'bannerManage', component: _import('content/banner'), name: 'bannerManage', meta: { title: 'Banner管理', noCache: true }},
-      { path: 'schoolInfo', component: _import('content/index'), name: 'schoolInfo', meta: { title: '公司动态', noCache: true }},
-      { path: 'newsCenter', component: _import('content/newsCenter'), name: 'newsCenter', meta: { title: '新闻中心', noCache: true }},
-      { path: 'customerStories', component: _import('content/customerStories'), name: 'customerStories', meta: { title: '客户案例', noCache: true }},
-      { path: 'alumniInfo', component: _import('content/index'), name: 'alumniInfo', meta: { title: '员工风采', noCache: true }},
-      { path: 'recruitInfo', component: _import('content/index'), name: 'recruitInfo', meta: { title: '招聘季度之星', noCache: true }},
-      { path: 'video', component: _import('content/index'), name: 'video', meta: { title: '年会视频', noCache: true }},
-      { path: 'activityNews', component: _import('content/index'), name: 'activityNews', meta: { title: '公司活动', noCache: true }},
-      { path: 'activity', component: _import('content/index'), name: 'activity', meta: { title: '互动', noCache: true }},
-      { path: 'lecture', component: _import('content/index'), name: 'lecture', meta: { title: '信息中心', noCache: true }},
-      { path: 'reading', component: _import('content/index'), name: 'reading', meta: { title: '季刊', noCache: true }},
-      { path: 'manual', component: _import('content/index'), name: 'manual', meta: { title: '操作手册', noCache: true }},
-      { path: 'rules', component: _import('content/index'), name: 'rules', meta: { title: '规章制度', noCache: true }},
-      { path: 'notice', component: _import('content/index'), name: 'notice', meta: { title: '公告管理', noCache: true }},
-      { path: 'comment', component: _import('content/comment'), name: 'comment', meta: { title: '评论管理', noCache: true }},
-      { path: 'questions', component: _import('content/questions'), name: 'questions', meta: { title: '提问管理', noCache: true }},
-      { path: 'contribute', component: _import('content/contribute'), name: 'contribute', meta: { title: '投稿管理', noCache: true }},
-      { path: 'questionSort', component: _import('content/questionSort'), name: 'questionSort', meta: { title: 'PK类别管理', noCache: true }},
-      { path: 'questionDetail', component: _import('content/questionDetail'), name: 'questionDetail', meta: { title: 'PK题目管理', noCache: true }},
-    ]
-  },
-  {
-    path: '/visitor',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'visitorManage',
-    meta: {
-      title: '访客管理',
-      icon: 'people'
-    },
-    children: [
-      { path: 'visitorList', component: _import('visitor/visitorList'), name: 'visitorList', meta: { title: '访客', noCache: true }},
-      { path: 'visitorDetail', component: _import('visitor/visitorDetail'), name: 'visitorDetail', meta: { title: '访客详情', noCache: false, hideTag: true, hidden: true }}
-      ]
-  },
-  {
-    path: '/sys',
-    component: Layout,
-    redirect: 'noredirect',
-    name: 'sysManage',
-    meta: {
-      title: '系统管理',
-      icon: 'chart'
-    },
-    children: [
-      { path: 'admin', component: _import('sys/admin'), name: 'admin', meta: { title: '管理员', noCache: true }},
-      { path: 'role', component: _import('sys/role'), name: 'role', meta: { title: '角色管理', noCache: true }},
-      // { path: 'message', component: _import('sys/admin'), name: 'message', meta: { title: '系统消息', noCache: true, hideTag: true }}
-      // { path: 'sms', component: _import('sys/admin'), name: 'sms', meta: { title: '短信通知', noCache: true, hideTag: true }},
-      // { path: 'os', component: _import('sys/os'), name: 'os', meta: { title: '对象存储', noCache: true, hideTag: true }}
-    ]
-  },
-
-  { path: '*', redirect: '/404', hidden: true }
-]

+ 14 - 1
src/router/index.js

@@ -38,7 +38,7 @@ export const constantRouterMap = [
     redirect: 'dashboard',
     children: [{
       path: 'dashboard',
-      component: _import('dashboard/index'),
+      component: _import('report/stockReport'),
       name: 'dashboard',
       meta: { title: '首页', icon: 'dashboard', noCache: true }
     }]
@@ -163,6 +163,19 @@ export const asyncRouterMap = [
         { path: 'dictDataList/:id', component: _import('dictManage/dictDataList'), name: 'dictDataList', meta: { title: '字典数据', noCache: false, hideTag: true, hidden: true }},
       ]
     },
+    {
+      path: '/report',
+      component: Layout,
+      redirect: 'noredirect',
+      name: 'report',
+      meta: {
+        title: '报表管理',
+        icon: 'zidian'
+      },
+      children: [
+        { path: 'stockReport', component: _import('report/stockReport'), name: 'stockReport', meta: { title: '库存报表',icon: 'dashboard', noCache: true }},
+      ]
+    },
 
     {
       path: '/sys',

+ 2 - 2
src/views/customer/business.vue

@@ -12,7 +12,7 @@
       <el-button class="filter-item" type="primary" v-waves icon="el-icon-search" @click="handleQuery">查找</el-button>
       <el-button class="filter-item" icon="el-icon-refresh" @click="resetQuery">重置</el-button>
       <el-button class="filter-item" type="primary" icon="el-icon-plus" @click="handleCreate">添加</el-button>
-      <!-- <el-button class="filter-item" v-waves icon="el-icon-download" @click="handleDownload">导出</el-button> -->
+      <el-button class="filter-item" v-waves icon="el-icon-download" @click="handleDownload">导出</el-button>
     </div>
 
     <!-- 查询结果 -->
@@ -261,7 +261,7 @@ export default {
         })
     },
     handleDownload() {
-      window.location.href = process.env.BASE_API + '/product/export';
+      window.location.href = process.env.BASE_API + '/customer-business/export?companyName=' + this.listQuery.companyName;
     },
     changeState(id, status) {
             setState({ id: id, status: status }).then(response => {

+ 8 - 8
src/views/customer/distributor.vue

@@ -16,7 +16,7 @@
       <el-button class="filter-item" type="primary" v-waves icon="el-icon-search" @click="handleQuery">查找</el-button>
       <el-button class="filter-item" icon="el-icon-refresh" @click="resetQuery">重置</el-button>
       <el-button class="filter-item" type="primary" icon="el-icon-plus" @click="handleCreate">添加</el-button>
-      <!-- <el-button class="filter-item" v-waves icon="el-icon-download" @click="handleDownload">导出</el-button> -->
+      <el-button class="filter-item" v-waves icon="el-icon-download" @click="handleDownload">导出</el-button>
     </div>
 
     <!-- 查询结果 -->
@@ -38,7 +38,7 @@
       <el-table-column align="center" min-width="80px" label="合同开始时间" prop="contractStart">
       </el-table-column>
 
-      <el-table-column align="center" min-width="80px" label="合同结束时间" prop="contractDate">
+      <el-table-column align="center" min-width="80px" label="合同结束时间" prop="contractEnd">
       </el-table-column>
 
       <el-table-column align="center" min-width="80px" label="联系人" prop="contactsName">
@@ -91,8 +91,8 @@
         <el-form-item label="合同开始日期" prop="contractStart">
           <el-date-picker style="width: 100%;" v-model="dataForm.contractStart" type="date" placeholder="选择日期" value-format="yyyy-MM-dd"></el-date-picker>
         </el-form-item>
-        <el-form-item label="合同结束日期" prop="contractDate">
-          <el-date-picker style="width: 100%;" v-model="dataForm.contractDate" type="date" placeholder="选择日期" value-format="yyyy-MM-dd"></el-date-picker>
+        <el-form-item label="合同结束日期" prop="contractEnd">
+          <el-date-picker style="width: 100%;" v-model="dataForm.contractEnd" type="date" placeholder="选择日期" value-format="yyyy-MM-dd"></el-date-picker>
         </el-form-item>                
         <el-form-item label="联系人" prop="contactsName" placeholder="请输入">
           <el-input v-model="dataForm.contactsName"></el-input>
@@ -145,7 +145,7 @@ export default {
         companyName: undefined,
         companyLevel: undefined,
         contractStart: undefined,
-        contractDate: undefined,
+        contractEnd: undefined,
         contactsName: undefined,
         contactsPhone: undefined,
       },
@@ -160,7 +160,7 @@ export default {
         companyName: [{ required: true, message: '公司名称不能为空', trigger: 'blur' }],
         companyLevel: [{ required: true, message: '请选择合同开始日期', trigger: 'blur' }],
         contractStart: [{ required: true, message: '请选择分销商等级', trigger: 'blur' }],
-        contractDate: [{ required: true, message: '请选择合同结束日期', trigger: 'blur' }],
+        contractEnd: [{ required: true, message: '请选择合同结束日期', trigger: 'blur' }],
         contactsName: [{ required: true, message: '联系人不能为空', trigger: 'blur' }],
         contactsPhone: [{ required: true, message: '联系电话不能为空', trigger: 'blur' }],
       },
@@ -218,7 +218,7 @@ export default {
         companyName: undefined,
         companyLevel: undefined,
         contractStart: undefined,
-        contractDate: undefined,
+        contractEnd: undefined,
         contactsName: undefined,
         contactsPhone: undefined,
       }
@@ -299,7 +299,7 @@ export default {
         })
     },
     handleDownload() {
-      window.location.href = process.env.BASE_API + '/product/export';
+      window.location.href = process.env.BASE_API + '/customer-distributor/export?companyName=' + this.listQuery.companyName + '&companyLevel=' + this.listQuery.companyLevel;
     },
     changeState(id, status) {
             setState({ id: id, status: status }).then(response => {

+ 2 - 2
src/views/customer/guest.vue

@@ -14,7 +14,7 @@
       <el-button class="filter-item" type="primary" v-waves icon="el-icon-search" @click="handleQuery">查找</el-button>
       <el-button class="filter-item" icon="el-icon-refresh" @click="resetQuery">重置</el-button>
       <el-button class="filter-item" type="primary" icon="el-icon-plus" @click="handleCreate">添加</el-button>
-      <!-- <el-button class="filter-item" v-waves icon="el-icon-download" @click="handleDownload">导出</el-button> -->
+      <el-button class="filter-item" v-waves icon="el-icon-download" @click="handleDownload">导出</el-button>
     </div>
 
     <!-- 查询结果 -->
@@ -258,7 +258,7 @@ export default {
       })
     },
     handleDownload() {
-      window.location.href = process.env.BASE_API + '/product/export';
+      window.location.href = process.env.BASE_API + '/customer-guest/export?customerName=' + this.listQuery.customerName + '&sex=' + this.listQuery.sex + '&customerCode=' + this.listQuery.customerCode;
     },
     changeState(id, status) {
       setState({ id: id, status: status }).then(response => {

+ 2 - 2
src/views/customer/vip.vue

@@ -22,7 +22,7 @@
       <el-button class="filter-item" type="primary" v-waves icon="el-icon-search" @click="handleQuery">查找</el-button>
       <el-button class="filter-item" icon="el-icon-refresh" @click="resetQuery">重置</el-button>
       <el-button class="filter-item" type="primary" icon="el-icon-plus" @click="handleCreate">添加</el-button>
-      <!-- <el-button class="filter-item" v-waves icon="el-icon-download" @click="handleDownload">导出</el-button> -->
+      <el-button class="filter-item" v-waves icon="el-icon-download" @click="handleDownload">导出</el-button>
     </div>
 
     <!-- 查询结果 -->
@@ -311,7 +311,7 @@ export default {
       })
     },
     handleDownload() {
-      window.location.href = process.env.BASE_API + '/product/export';
+      window.location.href = process.env.BASE_API + '/customer-vip/export?customerName=' + this.listQuery.customerName + '&sex=' + this.listQuery.sex + '&registerChannel=' + this.listQuery.registerChannel + '&customerLevel=' + this.listQuery.customerLevel;
     },
     changeState(id, status) {
       setState({ id: id, status: status }).then(response => {

+ 212 - 0
src/views/report/stockReport.vue

@@ -0,0 +1,212 @@
+<template>
+  <div style="height: 100vh;width: 100%;">
+    <iframe src="https://dgtbi.dgtis.com/cboard/cockpit.html?shareid=3kWhLIYY" width="100%" height="100%"></iframe>
+  </div>
+  
+  <!-- <el-row class="panel-group" :gutter="40">
+    <el-col :xs="12" :sm="12" :lg="6" class="card-panel-col">
+      <div class='card-panel' @click="handleSetLineChartData('newVisitis')">
+        <div class="card-panel-icon-wrapper icon-people">
+          <svg-icon icon-class="peoples" class-name="card-panel-icon" />
+        </div>
+        <div class="card-panel-description">
+          <div class="card-panel-text">员工数量</div>
+          <count-to class="card-panel-num" :startVal="0" :endVal="userTotal" :duration="2600"></count-to>
+        </div>
+      </div>
+    </el-col>
+
+    <el-col :xs="12" :sm="12" :lg="6" class="card-panel-col">
+      <div class='card-panel' @click="handleSetLineChartData('newVisitis')">
+        <div class="card-panel-icon-wrapper icon-message">
+          <svg-icon icon-class="people" class-name="card-panel-icon" />
+        </div>
+        <div class="card-panel-description">
+          <div class="card-panel-text">游客数量</div>
+          <count-to class="card-panel-num" :startVal="0" :endVal="visitorsTotal" :duration="2600"></count-to>
+        </div>
+      </div>
+    </el-col>
+
+    <el-col :xs="12" :sm="12" :lg="6" class="card-panel-col">
+      <div class='card-panel' @click="handleSetLineChartData('newVisitis')">
+        <div class="card-panel-icon-wrapper icon-people">
+          <svg-icon icon-class="magnifying-glass" class-name="card-panel-icon" />
+        </div>
+        <div class="card-panel-description">
+          <div class="card-panel-text">待审核数量</div>
+          <count-to class="card-panel-num" :startVal="0" :endVal="awaitAuditTotal" :duration="2600"></count-to>
+        </div>
+      </div>
+    </el-col>
+
+    <el-col :xs="12" :sm="12" :lg="6" class="card-panel-col">
+      <div class='card-panel' @click="handleSetLineChartData('newVisitis')">
+        <div class="card-panel-icon-wrapper icon-shoppingCard">
+          <svg-icon icon-class="user" class-name="card-panel-icon" />
+        </div>
+        <div class="card-panel-description">
+          <div class="card-panel-text">昨日浏览人数</div>
+          <count-to class="card-panel-num" :startVal="0" :endVal="yesterdayTotal" :duration="2600"></count-to>
+        </div>
+      </div>
+    </el-col>
+
+    <el-col :xs="12" :sm="12" :lg="6" class="card-panel-col">
+      <div class='card-panel' @click="handleSetLineChartData('newVisitis')">
+        <div class="card-panel-icon-wrapper icon-shoppingCard">
+          <svg-icon icon-class="group" class-name="card-panel-icon" />
+        </div>
+        <div class="card-panel-description">
+          <div class="card-panel-text">待审核圈子数量</div>
+          <count-to class="card-panel-num" :startVal="0" :endVal="groupTotal" :duration="2600"></count-to>
+        </div>
+      </div>
+    </el-col>
+
+    <el-col :xs="12" :sm="12" :lg="6" class="card-panel-col">
+      <div class='card-panel' @click="handleSetLineChartData('newVisitis')">
+        <div class="card-panel-icon-wrapper icon-shoppingCard">
+          <svg-icon icon-class="raise-your-hand-to-ask" class-name="card-panel-icon" />
+        </div>
+        <div class="card-panel-description">
+          <div class="card-panel-text">提问待回答数量</div>
+          <count-to class="card-panel-num" :startVal="0" :endVal="questionTotal" :duration="2600"></count-to>
+        </div>
+      </div>
+    </el-col>
+
+    <el-col :xs="12" :sm="12" :lg="6" class="card-panel-col">
+      <div class='card-panel' @click="handleSetLineChartData('newVisitis')">
+        <div class="card-panel-icon-wrapper icon-shoppingCard">
+          <svg-icon icon-class="edit" class-name="card-panel-icon" />
+        </div>
+        <div class="card-panel-description">
+          <div class="card-panel-text">今日评论数量</div>
+          <count-to class="card-panel-num" :startVal="0" :endVal="todayTotal" :duration="2600"></count-to>
+        </div>
+      </div>
+    </el-col>
+
+  </el-row> -->
+</template>
+
+<script>
+import { info } from '@/api/dashboard'
+import CountTo from 'vue-count-to'
+
+export default {
+  components: {
+    CountTo
+  },
+  data() {
+    return {
+      userTotal: 0,//校友录数量
+      visitorsTotal: 0,//游客数量
+      awaitAuditTotal: 0,//待审核数量
+      yesterdayTotal: 0,//昨日浏览人数
+      todayTotal:0,//今日评论数量
+      groupTotal:0,//圈子待审核数量
+      questionTotal:0,//提问待回答数量
+      goodsTotal: 0,
+      productTotal: 0,
+      orderTotal: 0
+    }
+  },
+  methods: {
+    handleSetLineChartData(type) {
+      this.$emit('handleSetLineChartData', type)
+    }
+  },
+  created() {
+    info(this.listQuery).then(response => {
+      this.userTotal = response.data.data.userTotal
+      this.visitorsTotal = response.data.data.visitorsTotal
+      this.awaitAuditTotal = response.data.data.awaitAuditTotal
+      this.yesterdayTotal = response.data.data.yesterdayTotal
+      this.todayTotal = response.data.data.todayTotal
+      this.groupTotal = response.data.data.groupTotal
+      this.questionTotal = response.data.data.questionTotal
+      // this.goodsTotal = response.data.data.goodsTotal
+      // this.productTotal = response.data.data.productTotal
+      // this.orderTotal = response.data.data.orderTotal
+    })
+  }
+}
+</script>
+
+<style rel="stylesheet/scss" lang="scss" scoped>
+.panel-group {
+  margin-top: 18px;
+
+  .card-panel-col{
+    margin-bottom: 32px;
+  }
+  .card-panel {
+    height: 108px;
+    cursor: pointer;
+    font-size: 12px;
+    position: relative;
+    overflow: hidden;
+    color: #666;
+    background: #fff;
+    box-shadow: 4px 4px 40px rgba(0, 0, 0, .05);
+    border-color: rgba(0, 0, 0, .05);
+    &:hover {
+      .card-panel-icon-wrapper {
+        color: #fff;
+      }
+      .icon-people {
+         background: #40c9c6;
+      }
+      .icon-message {
+        background: #36a3f7;
+      }
+      .icon-money {
+        background: #f4516c;
+      }
+      .icon-shoppingCard {
+        background: #34bfa3
+      }
+    }
+    .icon-people {
+      color: #40c9c6;
+    }
+    .icon-message {
+      color: #36a3f7;
+    }
+    .icon-money {
+      color: #f4516c;
+    }
+    .icon-shoppingCard {
+      color: #34bfa3
+    }
+    .card-panel-icon-wrapper {
+      float: left;
+      margin: 14px 0 0 14px;
+      padding: 16px;
+      transition: all 0.38s ease-out;
+      border-radius: 6px;
+    }
+    .card-panel-icon {
+      float: left;
+      font-size: 48px;
+    }
+    .card-panel-description {
+      float: right;
+      font-weight: bold;
+      margin: 26px;
+      margin-left: 0px;
+      .card-panel-text {
+        line-height: 18px;
+        color: rgba(0, 0, 0, 0.45);
+        font-size: 16px;
+        margin-bottom: 12px;
+      }
+      .card-panel-num {
+        font-size: 20px;
+      }
+    }
+  }
+}
+</style>