用vue-element-admin测试drone ci
Go to file
Pan 6ff36d82c7 fix next bug 2017-05-25 10:04:19 +08:00
build refine build.js 2017-05-09 18:55:07 +08:00
config add notes 2017-05-08 23:32:36 +08:00
documentImg add iconfont img 2017-05-11 21:48:05 +08:00
gifs update readme 2017-05-22 13:46:11 +08:00
src fix next bug 2017-05-25 10:04:19 +08:00
static Remove tinymce version 2017-05-23 14:39:03 +08:00
.babelrc init 2017-04-18 15:09:13 +08:00
.eslintignore init 2017-04-18 15:09:13 +08:00
.eslintrc.js init 2017-04-18 15:09:13 +08:00
.gitignore init 2017-04-18 15:09:13 +08:00
LICENSE ADD LICENSE 2017-05-12 13:47:15 +08:00
README-en.md Update, remove the duplicated 2017-05-22 23:15:46 +08:00
README.md update readme 2017-05-22 13:46:11 +08:00
favicon.ico init 2017-04-18 15:09:13 +08:00
index.html Remove tinymce version 2017-05-23 14:39:03 +08:00
package.json update element&&vue version 2017-05-16 13:39:14 +08:00

README.md

vue-element-admin

线上地址

English Document

wiki

注意该项目目前使用element-ui@1.3.3版本,所以最低兼容 Vue 2.3.0

前言

这半年来一直在用vue写管理后台目前后台已经有七十多个页面十几种权限但维护成本依然很低所以准备开源分享一下后台开发的经验和成果。目前的技术栈主要的采用vue+element+axios.由于是个人项目所以数据请求都是用了mockjs模拟。注意在次项目基础上改造开发时请移除mock文件。

后续会出一系列的教程配套文章,如如何从零构建后台项目框架,如何做完整的用户系统(如权限验证,二次登录等),如何二次开发组件(如富文本),如何整合七牛等等文章,各种后台开发经验等等。莫急~~

相应需求开了一个qq群 591724180 方便大家交流

如有问题请先看上述问题和Wiki,不能满足欢迎issue和pr~

功能

  • 登录/注销
  • 权限验证
  • 侧边栏
  • 面包屑
  • 富文本编辑器
  • Markdown编辑器
  • JSON编辑器
  • 列表拖拽
  • plitPane
  • Dropzone
  • Sticky
  • CountTo
  • echarts图表
  • 401401错误页面
  • 错误日志
  • 导出excel
  • table example
  • 动态table example
  • 拖拽table example
  • form example
  • 多环境发布
  • dashboard
  • 二次登录
  • 动态侧边栏
  • mock数据

开发

    # 克隆项目
    git clone https://github.com/PanJiaChen/vue-element-admin.git

    # 安装依赖
    npm install
    //or # 建议不要用cnpm  安装有各种诡异的bug 可以通过如下操作解决npm速度慢的问题
    npm install --registry=https://registry.npm.taobao.org

    # 本地开发 开启服务
    npm run dev

浏览器访问 http://localhost:9527

发布

    # 发布测试环境 带webpack ananalyzer
    npm run build:sit-preview

    # 构建生成环境
    npm run build:prod

目录结构

├── build                      // 构建相关  
├── config                     // 配置相关
├── src                        // 源代码
│   ├── api                    // 所有请求
│   ├── assets                 // 主题 字体等静态资源
│   ├── components             // 全局公用组件
│   ├── directive              // 全局指令
│   ├── filtres                // 全局filter
│   ├── mock                   // mock数据
│   ├── router                 // 路由
│   ├── store                  // 全局store管理
│   ├── styles                 // 全局样式
│   ├── utils                  // 全局公用方法
│   ├── view                   // view
│   ├── App.vue                // 入口页面
│   └── main.js                // 入口 加载组件 初始化等
├── static                     // 第三方不打包资源
│   ├── jquery
│   └── Tinymce                // 富文本
├── .babelrc                   // babel-loader 配置
├── eslintrc.js                // eslint 配置项
├── .gitignore                 // git 忽略项
├── favicon.ico                // favicon图标
├── index.html                 // html模板
└── package.json               // package.json

状态管理

后台只有user和app配置相关状态使用vuex存在全局其它数据都由每个业务页面自己管理。

效果图

两步验证登录 支持微信和qq

两步验证 here

真正的动态换肤

真正的动态换肤

可收起侧边栏

enter image description here

table拖拽排序

enter image description here

动态table

enter image description here

上传裁剪头像

enter image description here

错误统计

enter image description here

富文本(整合七牛 打水印等个性化功能)

enter image description here

封装table组件

enter image description here

图表

enter image description here

导出excel

enter image description here

更多demo