Skip to content

Commit a4467e3

Browse files
committed
Merge branch 'v2' into develop
2 parents 2a30731 + 24cd6bb commit a4467e3

File tree

140 files changed

+2654
-2067
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

140 files changed

+2654
-2067
lines changed

admin/.babelrc

Lines changed: 0 additions & 12 deletions
This file was deleted.

admin/.env.development

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# just a flag
2+
ENV = 'development'
3+
4+
# base api
5+
VUE_APP_BASE_API = 'http://127.0.0.1:8000'
6+
7+
# vue-cli uses the VUE_CLI_BABEL_TRANSPILE_MODULES environment variable,
8+
# to control whether the babel-plugin-dynamic-import-node plugin is enabled.
9+
# It only does one thing by converting all import() to require().
10+
# This configuration can significantly increase the speed of hot updates,
11+
# when you have a large number of pages.
12+
# Detail: https://github.com/vuejs/vue-cli/blob/dev/packages/@vue/babel-preset-app/index.js
13+
14+
VUE_CLI_BABEL_TRANSPILE_MODULES = true
15+
VUE_APP_WEBSOCKET = 'ws://127.0.0.1:5200'

admin/.env.production

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# just a flag
2+
ENV = 'production'
3+
4+
# base api
5+
VUE_APP_BASE_API = 'https://www.guke1.com'
6+
VUE_APP_WEBSOCKET = 'wss://www.guke1.com/ws'
7+

admin/.env.staging

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
NODE_ENV = production
2+
3+
# just a flag
4+
ENV = 'staging'
5+
6+
# base api
7+
VUE_APP_BASE_API = '/stage-api'
8+

admin/.eslintignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
build/*.js
2-
config/*.js
32
src/assets
3+
public
4+
dist

admin/.eslintrc.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,10 @@ module.exports = {
2121
"allowFirstLine": false
2222
}
2323
}],
24+
"vue/singleline-html-element-content-newline": "off",
25+
"vue/multiline-html-element-content-newline":"off",
2426
"vue/name-property-casing": ["error", "PascalCase"],
27+
"vue/no-v-html": "off",
2528
'accessor-pairs': 2,
2629
'arrow-spacing': [2, {
2730
'before': true,
@@ -44,7 +47,7 @@ module.exports = {
4447
'curly': [2, 'multi-line'],
4548
'dot-location': [2, 'property'],
4649
'eol-last': 2,
47-
'eqeqeq': [2, 'allow-null'],
50+
'eqeqeq': ["error", "always", {"null": "ignore"}],
4851
'generator-star-spacing': [2, {
4952
'before': true,
5053
'after': true
@@ -73,7 +76,7 @@ module.exports = {
7376
'no-class-assign': 2,
7477
'no-cond-assign': 2,
7578
'no-const-assign': 2,
76-
'no-control-regex': 2,
79+
'no-control-regex': 0,
7780
'no-delete-var': 2,
7881
'no-dupe-args': 2,
7982
'no-dupe-class-members': 2,
@@ -193,4 +196,3 @@ module.exports = {
193196
'array-bracket-spacing': [2, 'never']
194197
}
195198
}
196-

admin/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ npm-debug.log*
55
yarn-debug.log*
66
yarn-error.log*
77
package-lock.json
8+
tests/**/coverage/
89

910
# Editor directories and files
1011
.idea

admin/.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
language: node_js
2-
node_js: stable
2+
node_js: 10
33
script: npm run test
44
notifications:
55
email: false

admin/README.md

Lines changed: 86 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,96 @@
1-
# vue-admin
1+
# vue-admin-template
22

3-
## 安装
3+
> 这是一个极简的 vue admin 管理后台。它只包含了 Element UI & axios & iconfont & permission control & lint,这些搭建后台必要的东西。
4+
5+
[线上地址](http://panjiachen.github.io/vue-admin-template)
6+
7+
[国内访问](https://panjiachen.gitee.io/vue-admin-template)
8+
9+
目前版本为 `v4.0+` 基于 `vue-cli` 进行构建,若你想使用旧版本,可以切换分支到[tag/3.11.0](https://github.com/PanJiaChen/vue-admin-template/tree/tag/3.11.0),它不依赖 `vue-cli`
10+
11+
## Extra
12+
13+
如果你想要根据用户角色来动态生成侧边栏和 router,你可以使用该分支[permission-control](https://github.com/PanJiaChen/vue-admin-template/tree/permission-control)
14+
15+
## 相关项目
16+
17+
[vue-element-admin](https://github.com/PanJiaChen/vue-element-admin)
18+
19+
[electron-vue-admin](https://github.com/PanJiaChen/electron-vue-admin)
20+
21+
[vue-typescript-admin-template](https://github.com/Armour/vue-typescript-admin-template)
22+
23+
写了一个系列的教程配套文章,如何从零构建后一个完整的后台项目:
24+
25+
- [手摸手,带你用 vue 撸后台 系列一(基础篇)](https://juejin.im/post/59097cd7a22b9d0065fb61d2)
26+
- [手摸手,带你用 vue 撸后台 系列二(登录权限篇)](https://juejin.im/post/591aa14f570c35006961acac)
27+
- [手摸手,带你用 vue 撸后台 系列三 (实战篇)](https://juejin.im/post/593121aa0ce4630057f70d35)
28+
- [手摸手,带你用 vue 撸后台 系列四(vueAdmin 一个极简的后台基础模板,专门针对本项目的文章,算作是一篇文档)](https://juejin.im/post/595b4d776fb9a06bbe7dba56)
29+
- [手摸手,带你封装一个 vue component](https://segmentfault.com/a/1190000009090836)
30+
31+
## Build Setup
432

533
```bash
6-
# Clone 项目
7-
git clone https://gitee.com/lisgroup/vueBus.git
34+
# 克隆项目
35+
git clone https://github.com/PanJiaChen/vue-admin-template.git
836

9-
# 切换目录
10-
cd vueBus/admin
37+
# 进入项目目录
38+
cd vue-admin-template
1139

12-
# 安装 npm 包
40+
# 安装依赖
1341
npm install
1442

15-
# 启动测试服务,默认 http://localhost:9090
43+
# 建议不要直接使用 cnpm 安装以来,会有各种诡异的 bug。可以通过如下操作解决 npm 下载速度慢的问题
44+
npm install --registry=https://registry.npm.taobao.org
45+
46+
# 启动服务
1647
npm run dev
48+
```
49+
50+
浏览器访问 [http://localhost:/task9090](http://localhost:/task9090)
51+
52+
## 发布
53+
54+
```bash
55+
# 构建测试环境
56+
npm run build:stage
57+
58+
# 构建生产环境
59+
npm run build:prod
60+
```
61+
62+
## 其它
63+
64+
```bash
65+
# 预览发布环境效果
66+
npm run preview
67+
68+
# 预览发布环境效果 + 静态资源分析
69+
npm run preview -- --report
70+
71+
# 代码格式检查
72+
npm run lint
73+
74+
# 代码格式检查并自动修复
75+
npm run lint -- --fix
76+
```
77+
78+
更多信息请参考 [使用文档](https://panjiachen.github.io/vue-element-admin-site/zh/)
79+
80+
## Demo
81+
82+
![demo](https://github.com/PanJiaChen/PanJiaChen.github.io/blob/master/images/demo.gif)
83+
84+
## Browsers support
85+
86+
Modern browsers and Internet Explorer 10+.
87+
88+
| [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/edge/edge_48x48.png" alt="IE / Edge" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)</br>IE / Edge | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/firefox/firefox_48x48.png" alt="Firefox" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)</br>Firefox | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/chrome/chrome_48x48.png" alt="Chrome" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)</br>Chrome | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/safari/safari_48x48.png" alt="Safari" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)</br>Safari |
89+
| --------- | --------- | --------- | --------- |
90+
| IE10, IE11, Edge| last 2 versions| last 2 versions| last 2 versions
91+
92+
## License
1793

18-
# Build for production with minification
19-
npm run build
94+
[MIT](https://github.com/PanJiaChen/vue-admin-template/blob/master/LICENSE) license.
2095

21-
# Build for production and view the bundle analyzer report
22-
npm run build --report
23-
```
96+
Copyright (c) 2017-present PanJiaChen

admin/babel.config.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
module.exports = {
2+
presets: [
3+
'@vue/app'
4+
]
5+
}

0 commit comments

Comments
 (0)