Jelajahi Sumber

首次提交,渠道管理基础框架 -zzx

zouzexu 7 bulan lalu
induk
melakukan
e333823ee1

+ 0 - 82
README.md

@@ -1,83 +1 @@
-# mall-admin-web
-<p>
-  <a href="#公众号"><img src="http://macro-oss.oss-cn-shenzhen.aliyuncs.com/mall/badge/%E5%85%AC%E4%BC%97%E5%8F%B7-macrozheng-blue.svg" alt="公众号"></a>
-  <a href="#公众号"><img src="http://macro-oss.oss-cn-shenzhen.aliyuncs.com/mall/badge/%E4%BA%A4%E6%B5%81-%E5%BE%AE%E4%BF%A1%E7%BE%A4-2BA245.svg" alt="交流"></a>
-  <a href="https://github.com/macrozheng/mall"><img src="http://macro-oss.oss-cn-shenzhen.aliyuncs.com/mall/badge/%E5%90%8E%E5%8F%B0%E9%A1%B9%E7%9B%AE-mall-blue.svg" alt="后台项目"></a>
-  <a href="https://github.com/macrozheng/mall-swarm"><img src="http://macro-oss.oss-cn-shenzhen.aliyuncs.com/mall/badge/Cloud%E7%89%88%E6%9C%AC-mall--swarm-brightgreen.svg" alt="SpringCloud版本"></a>
-  <a href="https://gitee.com/macrozheng/mall-admin-web"><img src="http://macro-oss.oss-cn-shenzhen.aliyuncs.com/mall/badge/%E7%A0%81%E4%BA%91-%E9%A1%B9%E7%9B%AE%E5%9C%B0%E5%9D%80-orange.svg" alt="码云"></a>
-</p>
 
-## 前言
-
-该项目为前后端分离项目的前端部分,后端项目`mall`地址:[传送门](https://github.com/macrozheng/mall) 。
-
-## 项目介绍
-
-`mall-admin-web`是一个电商后台管理系统的前端项目,基于Vue+Element实现。主要包括商品管理、订单管理、会员管理、促销管理、运营管理、内容管理、统计报表、财务管理、权限管理、设置等功能。
-
-### 项目演示
-
-项目在线演示地址:[https://www.macrozheng.com/admin/](https://www.macrozheng.com/admin/)
-
-![后台管理系统功能演示](http://img.macrozheng.com/mall/project/mall_admin_show.png)
-
-### 技术选型
-
-| 技术              | 说明                  | 官网                                                         |
-| ----------------- | --------------------- | ------------------------------------------------------------ |
-| Vue               | 前端框架              | [https://vuejs.org/](https://vuejs.org/)                     |
-| Vue-router        | 路由框架              | [https://router.vuejs.org/](https://router.vuejs.org/)       |
-| Vuex              | 全局状态管理框架      | [https://vuex.vuejs.org/](https://vuex.vuejs.org/)           |
-| Element           | 前端UI框架            | [https://element.eleme.io/](https://element.eleme.io/)       |
-| Axios             | 前端HTTP框架          | [https://github.com/axios/axios](https://github.com/axios/axios) |
-| v-charts          | 基于Echarts的图表框架 | [https://v-charts.js.org/](https://v-charts.js.org/)         |
-| Js-cookie         | cookie管理工具        | [https://github.com/js-cookie/js-cookie](https://github.com/js-cookie/js-cookie) |
-| nprogress         | 进度条控件            | [https://github.com/rstacruz/nprogress](https://github.com/rstacruz/nprogress) |
-| vue-element-admin | 项目脚手架参考        | [https://github.com/PanJiaChen/vue-element-admin](https://github.com/PanJiaChen/vue-element-admin) |
-
-### 项目布局
-
-``` lua
-src -- 源码目录
-├── api -- axios网络请求定义
-├── assets -- 静态图片资源文件
-├── components -- 通用组件封装
-├── icons -- svg矢量图片文件
-├── router -- vue-router路由配置
-├── store -- vuex的状态管理
-├── styles -- 全局css样式
-├── utils -- 工具类
-└── views -- 前端页面
-    ├── home -- 首页
-    ├── layout -- 通用页面加载框架
-    ├── login -- 登录页
-    ├── oms -- 订单模块页面
-    ├── pms -- 商品模块页面
-    └── sms -- 营销模块页面
-```
-
-## 搭建步骤
-- 下载node并安装:[https://nodejs.org/dist/v12.14.0/node-v12.14.0-x64.msi](https://nodejs.org/dist/v12.14.0/node-v12.14.0-x64.msi);
-- 该项目为前后端分离项目,访问本地访问接口需搭建后台环境,搭建请参考后端项目[传送门](https://github.com/macrozheng/mall);
-- 访问在线接口无需搭建后台环境,只需将`config/dev.env.js`文件中的`BASE_API`改为[https://admin-api.macrozheng.com](https://admin-api.macrozheng.com)即可;
-- 如果你对接的是[mall-swarm](https://github.com/macrozheng/mall-swarm) 微服务后台的话,所有接口都需要通过网关访问,需要将`config/dev.env.js`文件中的`BASE_API`改为[http://localhost:8201/mall-admin](http://localhost:8201/mall-admin) ;
-- 克隆源代码到本地,使用IDEA打开,并完成编译;
-- 在IDEA命令行中运行命令:`npm install`,下载相关依赖;
-- 在IDEA命令行中运行命令:`npm run dev`,运行项目;
-- 访问地址:[http://localhost:8090](http://localhost:8090) 即可打开后台管理系统页面;
-- 具体部署过程请参考:[mall前端项目的安装与部署](https://www.macrozheng.com/mall/deploy/mall_deploy_web.html)
-- 前端自动化部署请参考:[使用Jenkins一键打包部署前端应用,就是这么6!](https://www.macrozheng.com/mall/reference/jenkins_vue.html)
-
-## 公众号
-
-学习不走弯路,关注公众号「**macrozheng**」,回复「**学习路线**」,获取mall项目专属学习路线!
-
-加微信群交流,公众号后台回复「**加群**」即可。
-
-![公众号图片](http://macro-oss.oss-cn-shenzhen.aliyuncs.com/mall/banner/qrcode_for_macrozheng_258.jpg)
-
-## 许可证
-
-[Apache License 2.0](https://github.com/macrozheng/mall-admin-web/blob/master/LICENSE)
-
-Copyright (c) 2018-2024 macrozheng

+ 1 - 1
config/dev.env.js

@@ -4,5 +4,5 @@ const prodEnv = require('./prod.env')
 
 module.exports = merge(prodEnv, {
   NODE_ENV: '"development"',
-  BASE_API: '"http://localhost:8080"'
+  BASE_API: '"http://192.168.2.47:8080"'
 })

+ 1 - 1
index.html

@@ -3,7 +3,7 @@
   <head>
     <meta charset="utf-8">
     <meta name="viewport" content="width=device-width,initial-scale=1.0">
-    <title>mall-admin-web</title>
+    <title>中数电动渠道管理后台</title>
     <!-- Google tag (gtag.js) -->
     <script async src="https://www.googletagmanager.com/gtag/js?id=G-73YJPXJTLX"></script>
     <script>

File diff ditekan karena terlalu besar
+ 249 - 663
package-lock.json


+ 2 - 2
package.json

@@ -1,7 +1,7 @@
 {
-  "name": "mall-admin-web",
+  "name": "channel-admin",
   "version": "1.0.0",
-  "description": "mall后台管理前端",
+  "description": "channel后台管理前端",
   "author": "macro",
   "private": true,
   "scripts": {

+ 1 - 1
src/components/Breadcrumb/index.vue

@@ -29,7 +29,7 @@ export default {
       let matched = this.$route.matched.filter(item => item.name)
       const first = matched[0]
       if (first && first.name !== 'home') {
-        matched = [{ path: '/home', meta: { title: '首页' }}].concat(matched)
+        matched = [{ path: '/', meta: { title: '' }}].concat(matched)
       }
       this.levelList = matched
     }

File diff ditekan karena terlalu besar
+ 0 - 0
src/icons/svg/channel.svg


+ 1 - 0
src/icons/svg/eye-open.svg

@@ -0,0 +1 @@
+<svg class="icon" viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg" width="128" height="128"><defs><style/></defs><path d="M512 128q69.675 0 135.51 21.163t115.498 54.997 93.483 74.837 73.685 82.006 51.67 74.837 32.17 54.827L1024 512q-2.347 4.992-6.315 13.483T998.87 560.17t-31.658 51.669-44.331 59.99-56.832 64.34-69.504 60.16-82.347 51.5-94.848 34.687T512 896q-69.675 0-135.51-21.163t-115.498-54.826-93.483-74.326-73.685-81.493-51.67-74.496-32.17-54.997L0 513.707q2.347-4.992 6.315-13.483t18.816-34.816 31.658-51.84 44.331-60.33 56.832-64.683 69.504-60.331 82.347-51.84 94.848-34.816T512 128.085zm0 85.333q-46.677 0-91.648 12.331t-81.152 31.83-70.656 47.146-59.648 54.485-48.853 57.686-37.675 52.821-26.325 43.99q12.33 21.674 26.325 43.52t37.675 52.351 48.853 57.003 59.648 53.845T339.2 767.02t81.152 31.488T512 810.667t91.648-12.331 81.152-31.659 70.656-46.848 59.648-54.186 48.853-57.344 37.675-52.651T927.957 512q-12.33-21.675-26.325-43.648t-37.675-52.65-48.853-57.345-59.648-54.186-70.656-46.848-81.152-31.659T512 213.334zm0 128q70.656 0 120.661 50.006T682.667 512 632.66 632.661 512 682.667 391.339 632.66 341.333 512t50.006-120.661T512 341.333zm0 85.334q-35.328 0-60.33 25.002T426.666 512t25.002 60.33T512 597.334t60.33-25.002T597.334 512t-25.002-60.33T512 426.666z"/></svg>

+ 1 - 0
src/icons/svg/icon-user.svg

@@ -0,0 +1 @@
+<svg t="1730950069462" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="8810" width="200" height="200"><path d="M0.000205 113.868959v796.262082A113.663955 113.663955 0 0 0 113.868959 1023.999795h796.262082A114.073554 114.073554 0 0 0 1023.999795 910.131041V113.868959A114.073554 114.073554 0 0 0 910.131041 0.000205H113.868959A113.663955 113.663955 0 0 0 0.000205 113.868959z m682.598127 227.532709A170.598332 170.598332 0 1 1 512 170.598537a170.393532 170.393532 0 0 1 170.598332 170.803131z m-511.999795 455.065418c0-113.868754 227.532709-176.332729 341.401463-176.332729s341.401463 61.439975 341.401463 176.332729v56.934377H170.598537v-56.934377z" fill="#2836FE" p-id="8811"></path></svg>

+ 0 - 1
src/icons/svg/login-mall.svg

@@ -1 +0,0 @@
-<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1542852993843" class="icon" style="" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2043" xmlns:xlink="http://www.w3.org/1999/xlink" width="54" height="54"><defs><style type="text/css"></style></defs><path d="M825.6 554.666667c-64 0-121.6-38.4-155.733333-89.6C633.6 516.266667 576 554.666667 512 554.666667s-121.6-38.4-155.733333-89.6C320 516.266667 264.533333 554.666667 198.4 554.666667 89.6 554.666667 0 465.066667 0 356.266667v-8.533334L151.466667 0h721.066666L1024 345.6v8.533333c0 110.933333-89.6 200.533333-198.4 200.533334z m-200.533333-219.733334h85.333333c0 61.866667 51.2 134.4 113.066667 134.4 59.733333 0 108.8-46.933333 113.066666-104.533333L817.066667 85.333333H206.933333L85.333333 364.8c4.266667 57.6 53.333333 104.533333 113.066667 104.533333 64 0 113.066667-74.666667 113.066667-134.4h85.333333c0 61.866667 51.2 134.4 113.066667 134.4 66.133333 0 115.2-74.666667 115.2-134.4zM810.666667 1021.866667H213.333333c-83.2 0-149.333333-64-149.333333-142.933334V595.2h85.333333v283.733333c0 32 27.733333 57.6 64 57.6h597.333334c34.133333 0 64-25.6 64-57.6V595.2h85.333333v283.733333c0 78.933333-66.133333 142.933333-149.333333 142.933334z" p-id="2044"></path></svg>

+ 16 - 269
src/router/index.js

@@ -22,292 +22,39 @@ export const constantRouterMap = [
   {path: '/login', component: () => import('@/views/login/index'), hidden: true},
   {path: '/404', component: () => import('@/views/404'), hidden: true},
   {
-    path: '',
+    path: '/channel',
     component: Layout,
-    redirect: '/home',
-    meta: {title: '首页', icon: 'home'},
+    redirect: '/channel/info',
+    meta: {title: '渠道管理', icon: 'home'},
     children: [{
-      path: 'home',
-      name: 'home',
-      component: () => import('@/views/home/index'),
-      meta: {title: '仪表盘', icon: 'dashboard'}
+      path: 'info',
+      name: 'info',
+      component: () => import('@/views/channel/info/index'),
+      meta: {title: '渠道基础信息', icon: 'dashboard'}
     },
     {
-      name: 'document',
-      path: 'https://www.macrozheng.com',
-      meta: {title: '学习教程', icon: 'document'}
+      path: 'useCondition',
+      name: 'useCondition',
+      component: () => import('@/views/channel/useCondition/index'),
+      meta: {title: '渠道使用情况', icon: 'dashboard'}
     },
     {
-      name: 'video',
-      path: 'https://www.macrozheng.com/mall/catalog/mall_video.html',
-      meta: {title: '视频教程', icon: 'video'}
+      path: 'upCheck',
+      name: 'upCheck',
+      component: () => import('@/views/channel/upCheck/index'),
+      meta: {title: '渠道上账情况', icon: 'dashboard'}
     },
     ]
   }
 ]
 
 export const asyncRouterMap = [
-  {
-    path: '/pms',
-    component: Layout,
-    redirect: '/pms/product',
-    name: 'pms',
-    meta: {title: '商品', icon: 'product'},
-    children: [{
-      path: 'product',
-      name: 'product',
-      component: () => import('@/views/pms/product/index'),
-      meta: {title: '商品列表', icon: 'product-list'}
-    },
-      {
-        path: 'addProduct',
-        name: 'addProduct',
-        component: () => import('@/views/pms/product/add'),
-        meta: {title: '添加商品', icon: 'product-add'}
-      },
-      {
-        path: 'updateProduct',
-        name: 'updateProduct',
-        component: () => import('@/views/pms/product/update'),
-        meta: {title: '修改商品', icon: 'product-add'},
-        hidden: true
-      },
-      {
-        path: 'productCate',
-        name: 'productCate',
-        component: () => import('@/views/pms/productCate/index'),
-        meta: {title: '商品分类', icon: 'product-cate'}
-      },
-      {
-        path: 'addProductCate',
-        name: 'addProductCate',
-        component: () => import('@/views/pms/productCate/add'),
-        meta: {title: '添加商品分类'},
-        hidden: true
-      },
-      {
-        path: 'updateProductCate',
-        name: 'updateProductCate',
-        component: () => import('@/views/pms/productCate/update'),
-        meta: {title: '修改商品分类'},
-        hidden: true
-      },
-      {
-        path: 'productAttr',
-        name: 'productAttr',
-        component: () => import('@/views/pms/productAttr/index'),
-        meta: {title: '商品类型', icon: 'product-attr'}
-      },
-      {
-        path: 'productAttrList',
-        name: 'productAttrList',
-        component: () => import('@/views/pms/productAttr/productAttrList'),
-        meta: {title: '商品属性列表'},
-        hidden: true
-      },
-      {
-        path: 'addProductAttr',
-        name: 'addProductAttr',
-        component: () => import('@/views/pms/productAttr/addProductAttr'),
-        meta: {title: '添加商品属性'},
-        hidden: true
-      },
-      {
-        path: 'updateProductAttr',
-        name: 'updateProductAttr',
-        component: () => import('@/views/pms/productAttr/updateProductAttr'),
-        meta: {title: '修改商品属性'},
-        hidden: true
-      },
-      {
-        path: 'brand',
-        name: 'brand',
-        component: () => import('@/views/pms/brand/index'),
-        meta: {title: '品牌管理', icon: 'product-brand'}
-      },
-      {
-        path: 'addBrand',
-        name: 'addBrand',
-        component: () => import('@/views/pms/brand/add'),
-        meta: {title: '添加品牌'},
-        hidden: true
-      },
-      {
-        path: 'updateBrand',
-        name: 'updateBrand',
-        component: () => import('@/views/pms/brand/update'),
-        meta: {title: '编辑品牌'},
-        hidden: true
-      }
-    ]
-  },
-  {
-    path: '/oms',
-    component: Layout,
-    redirect: '/oms/order',
-    name: 'oms',
-    meta: {title: '订单', icon: 'order'},
-    children: [
-      {
-        path: 'order',
-        name: 'order',
-        component: () => import('@/views/oms/order/index'),
-        meta: {title: '订单列表', icon: 'product-list'}
-      },
-      {
-        path: 'orderDetail',
-        name: 'orderDetail',
-        component: () => import('@/views/oms/order/orderDetail'),
-        meta: {title: '订单详情'},
-        hidden:true
-      },
-      {
-        path: 'deliverOrderList',
-        name: 'deliverOrderList',
-        component: () => import('@/views/oms/order/deliverOrderList'),
-        meta: {title: '发货列表'},
-        hidden:true
-      },
-      {
-        path: 'orderSetting',
-        name: 'orderSetting',
-        component: () => import('@/views/oms/order/setting'),
-        meta: {title: '订单设置', icon: 'order-setting'}
-      },
-      {
-        path: 'returnApply',
-        name: 'returnApply',
-        component: () => import('@/views/oms/apply/index'),
-        meta: {title: '退货申请处理', icon: 'order-return'}
-      },
-      {
-        path: 'returnReason',
-        name: 'returnReason',
-        component: () => import('@/views/oms/apply/reason'),
-        meta: {title: '退货原因设置', icon: 'order-return-reason'}
-      },
-      {
-        path: 'returnApplyDetail',
-        name: 'returnApplyDetail',
-        component: () => import('@/views/oms/apply/applyDetail'),
-        meta: {title: '退货原因详情'},
-        hidden:true
-      }
-    ]
-  },
-  {
-    path:'/sms',
-    component: Layout,
-    redirect: '/sms/coupon',
-    name: 'sms',
-    meta: {title: '营销', icon: 'sms'},
-    children: [
-      {
-        path: 'flash',
-        name: 'flash',
-        component: () => import('@/views/sms/flash/index'),
-        meta: {title: '秒杀活动列表', icon: 'sms-flash'}
-      },
-      {
-        path: 'flashSession',
-        name: 'flashSession',
-        component: () => import('@/views/sms/flash/sessionList'),
-        meta: {title: '秒杀时间段列表'},
-        hidden:true
-      },
-      {
-        path: 'selectSession',
-        name: 'selectSession',
-        component: () => import('@/views/sms/flash/selectSessionList'),
-        meta: {title: '秒杀时间段选择'},
-        hidden:true
-      },
-      {
-        path: 'flashProductRelation',
-        name: 'flashProductRelation',
-        component: () => import('@/views/sms/flash/productRelationList'),
-        meta: {title: '秒杀商品列表'},
-        hidden:true
-      },
-      {
-        path: 'coupon',
-        name: 'coupon',
-        component: () => import('@/views/sms/coupon/index'),
-        meta: {title: '优惠券列表', icon: 'sms-coupon'}
-      },
-      {
-        path: 'addCoupon',
-        name: 'addCoupon',
-        component: () => import('@/views/sms/coupon/add'),
-        meta: {title: '添加优惠券'},
-        hidden:true
-      },
-      {
-        path: 'updateCoupon',
-        name: 'updateCoupon',
-        component: () => import('@/views/sms/coupon/update'),
-        meta: {title: '修改优惠券'},
-        hidden:true
-      },
-      {
-        path: 'couponHistory',
-        name: 'couponHistory',
-        component: () => import('@/views/sms/coupon/history'),
-        meta: {title: '优惠券领取详情'},
-        hidden:true
-      },
-      {
-        path: 'brand',
-        name: 'homeBrand',
-        component: () => import('@/views/sms/brand/index'),
-        meta: {title: '品牌推荐', icon: 'product-brand'}
-      },
-      {
-        path: 'new',
-        name: 'homeNew',
-        component: () => import('@/views/sms/new/index'),
-        meta: {title: '新品推荐', icon: 'sms-new'}
-      },
-      {
-        path: 'hot',
-        name: 'homeHot',
-        component: () => import('@/views/sms/hot/index'),
-        meta: {title: '人气推荐', icon: 'sms-hot'}
-      },
-      {
-        path: 'subject',
-        name: 'homeSubject',
-        component: () => import('@/views/sms/subject/index'),
-        meta: {title: '专题推荐', icon: 'sms-subject'}
-      },
-      {
-        path: 'advertise',
-        name: 'homeAdvertise',
-        component: () => import('@/views/sms/advertise/index'),
-        meta: {title: '广告列表', icon: 'sms-ad'}
-      },
-      {
-        path: 'addAdvertise',
-        name: 'addHomeAdvertise',
-        component: () => import('@/views/sms/advertise/add'),
-        meta: {title: '添加广告'},
-        hidden:true
-      },
-      {
-        path: 'updateAdvertise',
-        name: 'updateHomeAdvertise',
-        component: () => import('@/views/sms/advertise/update'),
-        meta: {title: '编辑广告'},
-        hidden:true
-      }
-    ]
-  },
   {
     path:'/ums',
     component: Layout,
     redirect: '/ums/admin',
     name: 'ums',
-    meta: {title: '权限', icon: 'ums'},
+    meta: {title: '权限管理', icon: 'ums'},
     children: [
       {
         path: 'admin',

+ 1 - 1
src/styles/index.scss

@@ -137,7 +137,7 @@ a:hover {
 }
 
 .color-main {
-  color: #409EFF;
+  color: #2836FE;
 }
 
 .color-success {

+ 419 - 0
src/views/channel/info/index.vue

@@ -0,0 +1,419 @@
+<template>
+   
+  <div class="app-container">
+    <el-card class="filter-container" shadow="never">
+      <div>
+        <i class="el-icon-search"></i>
+        <span>筛选搜索</span>
+        <el-button
+          style="float: right"
+          type="primary"
+          @click="handleSearchList()"
+          size="small"
+        >
+          查询搜索
+        </el-button>
+        <el-button
+          style="float: right; margin-right: 15px"
+          @click="handleResetSearch()"
+          size="small"
+        >
+          重置
+        </el-button>
+      </div>
+      <div style="margin-top: 15px">
+        <el-form
+          :inline="true"
+          :model="listQuery"
+          size="small"
+          label-width="140px"
+        >
+          <el-form-item label="渠道名称:">
+            <el-input
+              v-model="listQuery.keyword"
+              class="input-width"
+              placeholder="请输入渠道名称"
+              clearable
+            ></el-input>
+          </el-form-item>
+          <el-form-item label="创建时间:">
+            <el-date-picker
+              v-model="date"
+              size="small"
+              value-format="yyyy-MM-dd"
+              class="item-width-350 ml10"
+              type="datetimerange"
+              range-separator="至"
+              start-placeholder="开始日期"
+              end-placeholder="结束日期"
+            >
+            </el-date-picker>
+          </el-form-item>
+        </el-form>
+      </div>
+    </el-card>
+    <el-card class="operate-container" shadow="never">
+      <i class="el-icon-tickets"></i>
+      <span>数据列表</span>
+      <el-button
+        size="mini"
+        class="btn-add"
+        @click="handleAdd()"
+        style="margin-left: 20px"
+        >添加</el-button
+      >
+    </el-card>
+    <div class="table-container">
+      <el-table
+        ref="adminTable"
+        :data="list"
+        style="width: 100%"
+        v-loading="listLoading"
+        border
+      >
+        <el-table-column label="渠道编号" width="100" align="center">
+          <template slot-scope="scope">
+            {{'--'}}
+          </template>
+        </el-table-column>
+        <el-table-column label="渠道名称" align="center">
+          <template slot-scope="scope">
+            {{'--'}}
+          </template>
+        </el-table-column>
+        <el-table-column label="联系人" align="center">
+          <template slot-scope="scope">
+            {{'--'}}
+          </template>
+        </el-table-column>
+        <el-table-column label="手机号" align="center">
+          <template slot-scope="scope">
+            {{'--'}}
+          </template>
+        </el-table-column>
+        <el-table-column label="渠道服务费/元" width="160" align="center">
+          <template slot-scope="scope">
+            {{'--'}}
+          </template>
+        </el-table-column>
+        <el-table-column label="使用状态" width="160" align="center">
+          <template slot-scope="scope">
+            {{'--'}}
+          </template>
+        </el-table-column>
+        <el-table-column label="创建人" width="140" align="center">
+          <template slot-scope="scope">
+            {{'--'}}
+          </template>
+        </el-table-column>
+        <el-table-column label="创建时间" width="140" align="center">
+          <template slot-scope="scope">
+            {{'--'}}
+          </template>
+        </el-table-column>
+        <el-table-column label="更新人" width="140" align="center">
+          <template slot-scope="scope">
+            {{'--'}}
+          </template>
+        </el-table-column>
+        <el-table-column label="更新时间" width="140" align="center">
+          <template slot-scope="scope">
+            {{'--'}}
+          </template>
+        </el-table-column>
+        <el-table-column label="操作" width="180" align="center">
+          <template slot-scope="scope">
+            <el-button
+              size="mini"
+              type="primary"
+              plain
+              @click="handleUpdate(scope.$index, scope.row)"
+            >
+              编辑
+            </el-button>
+          </template>
+        </el-table-column>
+      </el-table>
+    </div>
+    <div class="pagination-container">
+      <el-pagination
+        background
+        @size-change="handleSizeChange"
+        @current-change="handleCurrentChange"
+        layout="total, sizes,prev, pager, next,jumper"
+        :current-page.sync="listQuery.pageNum"
+        :page-size="listQuery.pageSize"
+        :page-sizes="[10, 15, 20]"
+        :total="total"
+      >
+      </el-pagination>
+    </div>
+    <el-dialog
+      :title="isEdit ? '编辑' : '添加'"
+      :visible.sync="dialogVisible"
+      width="40%"
+    >
+      <el-form :model="admin" ref="adminForm" label-width="150px" size="small">
+        <el-form-item label="渠道编号:">
+          <el-input v-model="admin.username" style="width: 250px"></el-input>
+        </el-form-item>
+        <el-form-item label="渠道名称:">
+          <el-input v-model="admin.nickName" style="width: 250px"></el-input>
+        </el-form-item>
+        <el-form-item label="联系人:">
+          <el-input v-model="admin.email" style="width: 250px"></el-input>
+        </el-form-item>
+        <el-form-item label="手机号:">
+          <el-input
+            v-model="admin.password"
+            type="number"
+            style="width: 250px"
+          ></el-input>
+        </el-form-item>
+        <el-form-item label="渠道服务费:">
+          <el-input
+            v-model="admin.note"
+            type="text"
+            :rows="5"
+            style="width: 250px"
+          ></el-input>
+          <div>当前平台服务费为0.1</div>
+        </el-form-item>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisible = false" size="small">取 消</el-button>
+        <el-button type="primary" @click="handleDialogConfirm()" size="small"
+          >确 定</el-button
+        >
+      </span>
+    </el-dialog>
+    <el-dialog title="分配角色" :visible.sync="allocDialogVisible" width="30%">
+      <el-select
+        v-model="allocRoleIds"
+        multiple
+        placeholder="请选择"
+        size="small"
+        style="width: 80%"
+      >
+        <el-option
+          v-for="item in allRoleList"
+          :key="item.id"
+          :label="item.name"
+          :value="item.id"
+        >
+        </el-option>
+      </el-select>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="allocDialogVisible = false" size="small"
+          >取 消</el-button
+        >
+        <el-button
+          type="primary"
+          @click="handleAllocDialogConfirm()"
+          size="small"
+          >确 定</el-button
+        >
+      </span>
+    </el-dialog>
+  </div>
+</template>
+<script>
+import {
+  fetchList,
+  createAdmin,
+  updateAdmin,
+  updateStatus,
+  deleteAdmin,
+  getRoleByAdmin,
+  allocRole,
+} from "@/api/login";
+import { fetchAllRoleList } from "@/api/role";
+import { formatDate } from "@/utils/date";
+
+const defaultListQuery = {
+  pageNum: 1,
+  pageSize: 10,
+  keyword: null,
+};
+const defaultAdmin = {
+  id: null,
+  username: null,
+  password: null,
+  nickName: null,
+  email: null,
+  note: null,
+  status: 1,
+};
+export default {
+  name: "adminList",
+  data() {
+    return {
+      date:'',
+      listQuery: Object.assign({}, defaultListQuery),
+      list: null,
+      total: null,
+      listLoading: false,
+      dialogVisible: false,
+      admin: Object.assign({}, defaultAdmin),
+      isEdit: false,
+      allocDialogVisible: false,
+      allocRoleIds: [],
+      allRoleList: [],
+      allocAdminId: null,
+    };
+  },
+  created() {
+    this.getList();
+    this.getAllRoleList();
+  },
+  filters: {
+    formatDateTime(time) {
+      if (time == null || time === "") {
+        return "N/A";
+      }
+      let date = new Date(time);
+      return formatDate(date, "yyyy-MM-dd hh:mm:ss");
+    },
+  },
+  methods: {
+    handleResetSearch() {
+      this.listQuery = Object.assign({}, defaultListQuery);
+    },
+    handleSearchList() {
+      this.listQuery.pageNum = 1;
+      this.getList();
+    },
+    handleSizeChange(val) {
+      this.listQuery.pageNum = 1;
+      this.listQuery.pageSize = val;
+      this.getList();
+    },
+    handleCurrentChange(val) {
+      this.listQuery.pageNum = val;
+      this.getList();
+    },
+    handleAdd() {
+      this.dialogVisible = true;
+      this.isEdit = false;
+      this.admin = Object.assign({}, defaultAdmin);
+    },
+    handleStatusChange(index, row) {
+      this.$confirm("是否要修改该状态?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          updateStatus(row.id, { status: row.status }).then((response) => {
+            this.$message({
+              type: "success",
+              message: "修改成功!",
+            });
+          });
+        })
+        .catch(() => {
+          this.$message({
+            type: "info",
+            message: "取消修改",
+          });
+          this.getList();
+        });
+    },
+    handleDelete(index, row) {
+      this.$confirm("是否要删除该用户?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      }).then(() => {
+        deleteAdmin(row.id).then((response) => {
+          this.$message({
+            type: "success",
+            message: "删除成功!",
+          });
+          this.getList();
+        });
+      });
+    },
+    handleUpdate(index, row) {
+      this.dialogVisible = true;
+      this.isEdit = true;
+      this.admin = Object.assign({}, row);
+    },
+    handleDialogConfirm() {
+      this.$confirm("是否要确认?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      }).then(() => {
+        if (this.isEdit) {
+          updateAdmin(this.admin.id, this.admin).then((response) => {
+            this.$message({
+              message: "修改成功!",
+              type: "success",
+            });
+            this.dialogVisible = false;
+            this.getList();
+          });
+        } else {
+          createAdmin(this.admin).then((response) => {
+            this.$message({
+              message: "添加成功!",
+              type: "success",
+            });
+            this.dialogVisible = false;
+            this.getList();
+          });
+        }
+      });
+    },
+    handleAllocDialogConfirm() {
+      this.$confirm("是否要确认?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      }).then(() => {
+        let params = new URLSearchParams();
+        params.append("adminId", this.allocAdminId);
+        params.append("roleIds", this.allocRoleIds);
+        allocRole(params).then((response) => {
+          this.$message({
+            message: "分配成功!",
+            type: "success",
+          });
+          this.allocDialogVisible = false;
+        });
+      });
+    },
+    handleSelectRole(index, row) {
+      this.allocAdminId = row.id;
+      this.allocDialogVisible = true;
+      this.getRoleListByAdmin(row.id);
+    },
+    getList() {
+      this.listLoading = true;
+      fetchList(this.listQuery).then((response) => {
+        this.listLoading = false;
+        this.list = response.data.list;
+        this.total = response.data.total;
+      });
+    },
+    getAllRoleList() {
+      fetchAllRoleList().then((response) => {
+        this.allRoleList = response.data;
+      });
+    },
+    getRoleListByAdmin(adminId) {
+      getRoleByAdmin(adminId).then((response) => {
+        let allocRoleList = response.data;
+        this.allocRoleIds = [];
+        if (allocRoleList != null && allocRoleList.length > 0) {
+          for (let i = 0; i < allocRoleList.length; i++) {
+            this.allocRoleIds.push(allocRoleList[i].id);
+          }
+        }
+      });
+    },
+  },
+};
+</script>
+<style></style>

+ 166 - 0
src/views/channel/upCheck/index.vue

@@ -0,0 +1,166 @@
+<template>
+     
+    <div class="app-container">
+        <el-card class="filter-container" shadow="never">
+            <div>
+                <i class="el-icon-search"></i>
+                <span>筛选搜索</span>
+                <el-button style="float: right" type="primary" @click="handleSearchList()" size="small">
+                    查询搜索
+                </el-button>
+                <el-button style="float: right; margin-right: 15px" @click="handleResetSearch()" size="small">
+                    重置
+                </el-button>
+            </div>
+            <div style="margin-top: 15px">
+                <el-form :inline="true" :model="listQuery" size="small" label-width="140px">
+                    <el-form-item label="渠道名称:">
+                        <el-input v-model="listQuery.keyword" class="input-width" placeholder="请输入渠道名称"
+                            clearable></el-input>
+                    </el-form-item>
+                    <el-form-item label="操作时间:">
+                        <el-date-picker v-model="date" size="small" value-format="yyyy-MM-dd"
+                            class="item-width-350 ml10" type="datetimerange" range-separator="至"
+                            start-placeholder="开始日期" end-placeholder="结束日期">
+                        </el-date-picker>
+                    </el-form-item>
+                </el-form>
+            </div>
+        </el-card>
+        <el-card class="operate-container" shadow="never">
+            <i class="el-icon-tickets"></i>
+            <span>数据列表</span>
+        </el-card>
+        <div class="table-container">
+            <el-table ref="adminTable" :data="list" style="width: 100%" v-loading="listLoading" border>
+                <el-table-column label="渠道编号" width="100" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="渠道名称" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="渠道上账金额/元" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="操作人" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="操作时间" width="160" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+            </el-table>
+        </div>
+        <div class="pagination-container">
+            <el-pagination background @size-change="handleSizeChange" @current-change="handleCurrentChange"
+                layout="total, sizes,prev, pager, next,jumper" :current-page.sync="listQuery.pageNum"
+                :page-size="listQuery.pageSize" :page-sizes="[10, 15, 20]" :total="total">
+            </el-pagination>
+        </div>
+    </div>
+</template>
+<script>
+import {
+    fetchList,
+    getRoleByAdmin,
+} from "@/api/login";
+import { fetchAllRoleList } from "@/api/role";
+import { formatDate } from "@/utils/date";
+
+const defaultListQuery = {
+    pageNum: 1,
+    pageSize: 10,
+    keyword: null,
+};
+const defaultAdmin = {
+    id: null,
+    username: null,
+    password: null,
+    nickName: null,
+    email: null,
+    note: null,
+    status: 1,
+};
+export default {
+    name: "adminList",
+    data() {
+        return {
+            date: '',
+            listQuery: Object.assign({}, defaultListQuery),
+            list: null,
+            total: null,
+            listLoading: false,
+            admin: Object.assign({}, defaultAdmin),
+            isEdit: false,
+            allocRoleIds: [],
+            allRoleList: [],
+            allocAdminId: null,
+        };
+    },
+    created() {
+        this.getList();
+        this.getAllRoleList();
+    },
+    filters: {
+        formatDateTime(time) {
+            if (time == null || time === "") {
+                return "N/A";
+            }
+            let date = new Date(time);
+            return formatDate(date, "yyyy-MM-dd hh:mm:ss");
+        },
+    },
+    methods: {
+        handleResetSearch() {
+            this.listQuery = Object.assign({}, defaultListQuery);
+        },
+        handleSearchList() {
+            this.listQuery.pageNum = 1;
+            this.getList();
+        },
+        handleSizeChange(val) {
+            this.listQuery.pageNum = 1;
+            this.listQuery.pageSize = val;
+            this.getList();
+        },
+        handleCurrentChange(val) {
+            this.listQuery.pageNum = val;
+            this.getList();
+        },
+        getList() {
+            this.listLoading = true;
+            fetchList(this.listQuery).then((response) => {
+                this.listLoading = false;
+                this.list = response.data.list;
+                this.total = response.data.total;
+            });
+        },
+        getAllRoleList() {
+            fetchAllRoleList().then((response) => {
+                this.allRoleList = response.data;
+            });
+        },
+        getRoleListByAdmin(adminId) {
+            getRoleByAdmin(adminId).then((response) => {
+                let allocRoleList = response.data;
+                this.allocRoleIds = [];
+                if (allocRoleList != null && allocRoleList.length > 0) {
+                    for (let i = 0; i < allocRoleList.length; i++) {
+                        this.allocRoleIds.push(allocRoleList[i].id);
+                    }
+                }
+            });
+        },
+    },
+};
+</script>
+<style></style>

+ 372 - 0
src/views/channel/useCondition/index.vue

@@ -0,0 +1,372 @@
+<template>
+     
+    <div class="app-container">
+        <el-card class="filter-container" shadow="never">
+            <div>
+                <i class="el-icon-search"></i>
+                <span>筛选搜索</span>
+                <el-button style="float: right" type="primary" @click="handleSearchList()" size="small">
+                    查询搜索
+                </el-button>
+                <el-button style="float: right; margin-right: 15px" @click="handleResetSearch()" size="small">
+                    重置
+                </el-button>
+            </div>
+            <div style="margin-top: 15px">
+                <el-form :inline="true" :model="listQuery" size="small" label-width="140px">
+                    <el-form-item label="渠道名称:">
+                        <el-input v-model="listQuery.keyword" class="input-width" placeholder="请输入渠道名称"
+                            clearable></el-input>
+                    </el-form-item>
+                    <el-form-item label="更新时间:">
+                        <el-date-picker v-model="date" size="small" value-format="yyyy-MM-dd"
+                            class="item-width-350 ml10" type="datetimerange" range-separator="至"
+                            start-placeholder="开始日期" end-placeholder="结束日期">
+                        </el-date-picker>
+                    </el-form-item>
+                </el-form>
+            </div>
+        </el-card>
+        <el-card class="operate-container" shadow="never">
+            <i class="el-icon-tickets"></i>
+            <span>数据列表</span>
+        </el-card>
+        <div class="table-container">
+            <el-table ref="adminTable" :data="list" style="width: 100%" v-loading="listLoading" border>
+                <el-table-column label="渠道编号" width="100" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="渠道名称" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="使用状态" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="渠道上账总金额/元" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="渠道应付总金额/元" width="160" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="用户充值总金额/元" width="160" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="用户消费总金额/元" width="140" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="用户退款总金额/元" width="140" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="更新时间" width="140" align="center">
+                    <template slot-scope="scope">
+                        {{ '--' }}
+                    </template>
+                </el-table-column>
+                <el-table-column label="操作" width="180" align="center">
+                    <template slot-scope="scope">
+                        <el-button size="mini" type="primary" plain @click="handleUpdate(scope.$index, scope.row)">
+                            上账
+                        </el-button>
+                        <el-button size="mini" type="primary" plain @click="SettleAccount(scope.$index, scope.row)">
+                            结算
+                        </el-button>
+                        <el-button size="mini" type="primary" plain @click="forbidden">
+                            禁用
+                        </el-button>
+                        <el-button size="mini" type="primary" plain @click="enable">
+                            启用
+                        </el-button>
+                    </template>
+                </el-table-column>
+            </el-table>
+        </div>
+        <div class="pagination-container">
+            <el-pagination background @size-change="handleSizeChange" @current-change="handleCurrentChange"
+                layout="total, sizes,prev, pager, next,jumper" :current-page.sync="listQuery.pageNum"
+                :page-size="listQuery.pageSize" :page-sizes="[10, 15, 20]" :total="total">
+            </el-pagination>
+        </div>
+        <el-dialog title="提示" :visible.sync="forbiddenDialogVisible" width="30%" :before-close="handleClose">
+            <span v-if="isforbidden === false">此操作将会禁用该渠道的所有用户(正在充电的用户,会在本次充电完成后被禁用),使其无法充电,是否继续。</span>
+            <span v-else>该操作会将该渠道禁用的用户,重新启用,是否继续。</span>
+            <span slot="footer" class="dialog-footer">
+                <el-button @click="forbiddenDialogVisible = false">取 消</el-button>
+                <el-button type="primary" @click="forbiddenDialogVisible = false">确 定</el-button>
+            </span>
+        </el-dialog>
+        <el-dialog :title="isEdit ? '渠道上账' : '渠道结算'" :visible.sync="dialogVisible" width="40%">
+            <el-form :model="admin" ref="adminForm" label-width="150px" size="small">
+                <div style="font-size: 18px;font-weight: bold;">渠道信息</div>
+                <el-form-item label="渠道编号:">
+                    <template>{{ 'WQHIAHS124342DSAD' }}</template>
+                </el-form-item>
+                <el-form-item label="渠道名称:">
+                    <template>{{ 'WQHIAHS124342DSAD' }}</template>
+                </el-form-item>
+                <div style="font-size: 18px;font-weight: bold;">使用情况</div>
+                <el-form-item label="渠道上账总金额/元:">
+                    <template> {{ '10.00' }} </template>
+                </el-form-item>
+                <el-form-item label="渠道应付总金额/元:">
+                    <template> {{ '50.00' }} </template>
+                </el-form-item>
+                <el-form-item label="本次上账金额/元:">
+                    <el-input v-model="admin.note" placeholder="请输入上账金额" type="text" :rows="5"
+                        style="width: 250px"></el-input>
+                        <el-checkbox v-model="checked">负数</el-checkbox>
+                </el-form-item>
+                <el-form-item label="上传凭证:">
+                    <el-upload action="https://jsonplaceholder.typicode.com/posts/" list-type="picture-card"
+                        :on-preview="handlePictureCardPreview" :on-remove="handleRemove">
+                        <i class="el-icon-plus"></i>
+                    </el-upload>
+                </el-form-item>
+            </el-form>
+            <span slot="footer" class="dialog-footer">
+                <el-button @click="dialogVisible = false" size="small">取 消</el-button>
+                <el-button type="primary" @click="handleDialogConfirm()" size="small">确 定</el-button>
+            </span>
+        </el-dialog>
+        <el-dialog title="分配角色" :visible.sync="allocDialogVisible" width="30%">
+            <el-select v-model="allocRoleIds" multiple placeholder="请选择" size="small" style="width: 80%">
+                <el-option v-for="item in allRoleList" :key="item.id" :label="item.name" :value="item.id">
+                </el-option>
+            </el-select>
+            <span slot="footer" class="dialog-footer">
+                <el-button @click="allocDialogVisible = false" size="small">取 消</el-button>
+                <el-button type="primary" @click="handleAllocDialogConfirm()" size="small">确 定</el-button>
+            </span>
+        </el-dialog>
+    </div>
+</template>
+<script>
+import {
+    fetchList,
+    createAdmin,
+    updateAdmin,
+    updateStatus,
+    deleteAdmin,
+    getRoleByAdmin,
+    allocRole,
+} from "@/api/login";
+import { fetchAllRoleList } from "@/api/role";
+import { formatDate } from "@/utils/date";
+
+const defaultListQuery = {
+    pageNum: 1,
+    pageSize: 10,
+    keyword: null,
+};
+const defaultAdmin = {
+    id: null,
+    username: null,
+    password: null,
+    nickName: null,
+    email: null,
+    note: null,
+    status: 1,
+};
+export default {
+    name: "adminList",
+    data() {
+        return {
+            date: '',
+            isforbidden: false,
+            forbiddenDialogVisible: false,
+            listQuery: Object.assign({}, defaultListQuery),
+            list: null,
+            total: null,
+            listLoading: false,
+            dialogVisible: false,
+            admin: Object.assign({}, defaultAdmin),
+            isEdit: false,
+            allocDialogVisible: false,
+            allocRoleIds: [],
+            allRoleList: [],
+            allocAdminId: null,
+        };
+    },
+    created() {
+        this.getList();
+        this.getAllRoleList();
+    },
+    filters: {
+        formatDateTime(time) {
+            if (time == null || time === "") {
+                return "N/A";
+            }
+            let date = new Date(time);
+            return formatDate(date, "yyyy-MM-dd hh:mm:ss");
+        },
+    },
+    methods: {
+        // 启用
+        enable() {
+            this.isforbidden = true
+            this.forbiddenDialogVisible = true
+        },
+        // 禁用
+        forbidden() {
+            this.isforbidden = false
+            this.forbiddenDialogVisible = true
+        },
+
+        // 结算
+        SettleAccount() {
+            this.dialogVisible = true;
+            this.isEdit = false;
+            this.admin = Object.assign({}, defaultAdmin);
+        },
+
+        handleResetSearch() {
+            this.listQuery = Object.assign({}, defaultListQuery);
+        },
+        handleSearchList() {
+            this.listQuery.pageNum = 1;
+            this.getList();
+        },
+        handleSizeChange(val) {
+            this.listQuery.pageNum = 1;
+            this.listQuery.pageSize = val;
+            this.getList();
+        },
+        handleCurrentChange(val) {
+            this.listQuery.pageNum = val;
+            this.getList();
+        },
+        handleStatusChange(index, row) {
+            this.$confirm("是否要修改该状态?", "提示", {
+                confirmButtonText: "确定",
+                cancelButtonText: "取消",
+                type: "warning",
+            })
+                .then(() => {
+                    updateStatus(row.id, { status: row.status }).then((response) => {
+                        this.$message({
+                            type: "success",
+                            message: "修改成功!",
+                        });
+                    });
+                })
+                .catch(() => {
+                    this.$message({
+                        type: "info",
+                        message: "取消修改",
+                    });
+                    this.getList();
+                });
+        },
+        handleDelete(index, row) {
+            this.$confirm("是否要删除该用户?", "提示", {
+                confirmButtonText: "确定",
+                cancelButtonText: "取消",
+                type: "warning",
+            }).then(() => {
+                deleteAdmin(row.id).then((response) => {
+                    this.$message({
+                        type: "success",
+                        message: "删除成功!",
+                    });
+                    this.getList();
+                });
+            });
+        },
+        handleUpdate(index, row) {
+            this.dialogVisible = true;
+            this.isEdit = true;
+            this.admin = Object.assign({}, row);
+        },
+        handleDialogConfirm() {
+            this.$confirm("是否要确认?", "提示", {
+                confirmButtonText: "确定",
+                cancelButtonText: "取消",
+                type: "warning",
+            }).then(() => {
+                if (this.isEdit) {
+                    updateAdmin(this.admin.id, this.admin).then((response) => {
+                        this.$message({
+                            message: "修改成功!",
+                            type: "success",
+                        });
+                        this.dialogVisible = false;
+                        this.getList();
+                    });
+                } else {
+                    createAdmin(this.admin).then((response) => {
+                        this.$message({
+                            message: "添加成功!",
+                            type: "success",
+                        });
+                        this.dialogVisible = false;
+                        this.getList();
+                    });
+                }
+            });
+        },
+        handleAllocDialogConfirm() {
+            this.$confirm("是否要确认?", "提示", {
+                confirmButtonText: "确定",
+                cancelButtonText: "取消",
+                type: "warning",
+            }).then(() => {
+                let params = new URLSearchParams();
+                params.append("adminId", this.allocAdminId);
+                params.append("roleIds", this.allocRoleIds);
+                allocRole(params).then((response) => {
+                    this.$message({
+                        message: "分配成功!",
+                        type: "success",
+                    });
+                    this.allocDialogVisible = false;
+                });
+            });
+        },
+        handleSelectRole(index, row) {
+            this.allocAdminId = row.id;
+            this.allocDialogVisible = true;
+            this.getRoleListByAdmin(row.id);
+        },
+        getList() {
+            this.listLoading = true;
+            fetchList(this.listQuery).then((response) => {
+                this.listLoading = false;
+                this.list = response.data.list;
+                this.total = response.data.total;
+            });
+        },
+        getAllRoleList() {
+            fetchAllRoleList().then((response) => {
+                this.allRoleList = response.data;
+            });
+        },
+        getRoleListByAdmin(adminId) {
+            getRoleByAdmin(adminId).then((response) => {
+                let allocRoleList = response.data;
+                this.allocRoleIds = [];
+                if (allocRoleList != null && allocRoleList.length > 0) {
+                    for (let i = 0; i < allocRoleList.length; i++) {
+                        this.allocRoleIds.push(allocRoleList[i].id);
+                    }
+                }
+            });
+        },
+    },
+};
+</script>
+<style></style>

+ 1 - 36
src/views/home/index.vue

@@ -1,33 +1,5 @@
 <template>
   <div class="app-container">
-    <div class="address-layout">
-      <el-row :gutter="20">
-        <el-col :span="6">
-          <div class="out-border">
-            <div class="layout-title">学习教程</div>
-            <div class="color-main address-content">
-              <a href="https://www.macrozheng.com" target="_blank">mall学习教程</a>
-            </div>
-          </div>
-        </el-col>
-        <el-col :span="6">
-          <div class="out-border">
-            <div class="layout-title">视频教程</div>
-            <div class="color-main address-content">
-              <a href="https://www.macrozheng.com/mall/catalog/mall_video.html" target="_blank">mall视频教程(2023)</a>
-            </div>
-          </div>
-        </el-col>
-        <el-col :span="6">
-          <div class="out-border">
-            <div class="layout-title">点Star支持项目</div>
-            <div class="color-main address-content">
-              <a href="https://github.com/macrozheng/mall" target="_blank">mall项目</a>
-            </div>
-          </div>
-        </el-col>
-      </el-row>
-    </div>
     <div class="total-layout">
       <el-row :gutter="20">
         <el-col :span="6">
@@ -61,13 +33,6 @@
         <!--</el-col>-->
       </el-row>
     </div>
-    <el-card class="mine-layout">
-      <div style="text-align: center">
-        <img width="150px" height="150px" src="http://macro-oss.oss-cn-shenzhen.aliyuncs.com/mall/banner/qrcode_for_macrozheng_258.jpg">
-      </div>
-      <div style="text-align: center">mall全套学习教程连载中!</div>
-      <div style="text-align: center;margin-top: 5px"><span class="color-main">关注公号</span>,第一时间获取。</div>
-    </el-card>
     <div class="un-handle-layout">
       <div class="layout-title">待处理事务</div>
       <div class="un-handle-content">
@@ -364,7 +329,7 @@
   }
 
   .total-icon {
-    color: #409EFF;
+    color: #2836FE;
     width: 60px;
     height: 60px;
   }

+ 2 - 1
src/views/layout/components/Navbar.vue

@@ -4,7 +4,8 @@
     <breadcrumb></breadcrumb>
     <el-dropdown class="avatar-container" trigger="click">
       <div class="avatar-wrapper">
-        <img class="user-avatar" :src="avatar">
+        <!-- <svg-icon icon-class="icon-user" class="color-main"></svg-icon> -->
+         <img :src="avatar" class="user-avatar" alt="">
         <i class="el-icon-caret-bottom"></i>
       </div>
       <el-dropdown-menu class="user-dropdown" slot="dropdown">

+ 11 - 42
src/views/login/index.vue

@@ -7,9 +7,9 @@
                ref="loginForm"
                label-position="left">
         <div style="text-align: center">
-          <svg-icon icon-class="login-mall" style="width: 56px;height: 56px;color: #409EFF"></svg-icon>
+          <svg-icon icon-class="channel" style="width: 56px;height: 56px;color: #2836FE"></svg-icon>
         </div>
-        <h2 class="login-title color-main">mall-admin-web</h2>
+        <h2 class="login-title color-main">中数电动渠道管理后台</h2>
         <el-form-item prop="username">
           <el-input name="username"
                     type="text"
@@ -32,36 +32,18 @@
             <svg-icon icon-class="password" class="color-main"></svg-icon>
           </span>
             <span slot="suffix" @click="showPwd">
-            <svg-icon icon-class="eye" class="color-main"></svg-icon>
+            <svg-icon :icon-class="pwdType==='password'?'eye':'eye-open'" class="color-main"></svg-icon>
           </span>
           </el-input>
         </el-form-item>
         <el-form-item style="margin-bottom: 60px;text-align: center">
-          <el-button style="width: 45%" type="primary" :loading="loading" @click.native.prevent="handleLogin">
+          <el-button class="loginBtn" type="primary" :loading="loading" @click.native.prevent="handleLogin">
             登录
           </el-button>
-          <el-button style="width: 45%" type="primary" @click.native.prevent="handleTry">
-            获取体验账号
-          </el-button>
         </el-form-item>
       </el-form>
     </el-card>
     <img :src="login_center_bg" class="login-center-layout">
-    <el-dialog
-      title="公众号二维码"
-      :visible.sync="dialogVisible"
-      :show-close="false"
-      :center="true"
-      width="30%">
-      <div style="text-align: center">
-        <span class="font-title-large"><span class="color-main font-extra-large">关注公众号</span>回复<span class="color-main font-extra-large">体验</span>获取体验账号</span>
-        <br>
-        <img src="http://macro-oss.oss-cn-shenzhen.aliyuncs.com/mall/banner/qrcode_for_macrozheng_258.jpg" width="160" height="160" style="margin-top: 10px">
-      </div>
-      <span slot="footer" class="dialog-footer">
-    <el-button type="primary" @click="dialogConfirm">确定</el-button>
-      </span>
-    </el-dialog>
   </div>
 </template>
 
@@ -99,7 +81,6 @@
         loading: false,
         pwdType: 'password',
         login_center_bg,
-        dialogVisible:false,
         supportDialogVisible:false
       }
     },
@@ -124,17 +105,12 @@
       handleLogin() {
         this.$refs.loginForm.validate(valid => {
           if (valid) {
-            // let isSupport = getSupport();
-            // if(isSupport===undefined||isSupport==null){
-            //   this.dialogVisible =true;
-            //   return;
-            // }
             this.loading = true;
             this.$store.dispatch('Login', this.loginForm).then(() => {
               this.loading = false;
               setCookie("username",this.loginForm.username,15);
               setCookie("password",this.loginForm.password,15);
-              this.$router.push({path: '/'})
+              this.$router.push({path: '/channel'})
             }).catch(() => {
               this.loading = false
             })
@@ -144,17 +120,6 @@
           }
         })
       },
-      handleTry(){
-        this.dialogVisible =true
-      },
-      dialogConfirm(){
-        this.dialogVisible =false;
-        setSupport(true);
-      },
-      dialogCancel(){
-        this.dialogVisible = false;
-        setSupport(false);
-      }
     }
   }
 </script>
@@ -166,15 +131,19 @@
     right: 0;
     width: 360px;
     margin: 140px auto;
-    border-top: 10px solid #409EFF;
+    border-top: 10px solid #2836fe;
   }
 
   .login-title {
     text-align: center;
   }
+  .loginBtn{
+    width:100%;
+    background-color: #2836FE;
+  }
 
   .login-center-layout {
-    background: #409EFF;
+    background: rgba(40, 54, 254, 0.8);
     width: auto;
     height: auto;
     max-width: 100%;

Beberapa file tidak ditampilkan karena terlalu banyak file yang berubah dalam diff ini