commit f88c3868a76ed1316c6798dad37eb39274a420f4 Author: chuzhixin <1204505056@qq.com> Date: Tue Sep 29 14:27:57 2020 +0800 🎉🎉🎉仓库重置到2020年9月29日,Vue2.6最后一个版本,之前版本不再支持,具体请查阅文档,Vue 3.0版本即将发布请耐心等待!!! diff --git a/.browserslistrc b/.browserslistrc new file mode 100644 index 0000000..f23b837 --- /dev/null +++ b/.browserslistrc @@ -0,0 +1,4 @@ +> 1% +last 2 versions +not dead + diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..4039ff1 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,12 @@ +root = true + +[*] +charset = utf-8 +end_of_line = lf +indent_size = 2 +indent_style = space +insert_final_newline = true +trim_trailing_whitespace = true + +[*.md] +trim_trailing_whitespace = false diff --git a/.eslintignore b/.eslintignore new file mode 100644 index 0000000..1ef592b --- /dev/null +++ b/.eslintignore @@ -0,0 +1,5 @@ +src/assets +src/icons +public +dist +node_modules diff --git a/.eslintrc.js b/.eslintrc.js new file mode 100644 index 0000000..0760a63 --- /dev/null +++ b/.eslintrc.js @@ -0,0 +1,26 @@ +module.exports = { + root: true, + env: { + node: true, + }, + extends: ["plugin:vue/recommended", "@vue/prettier"], + rules: { + "no-console": process.env.NODE_ENV === "production" ? "warn" : "off", + "no-debugger": process.env.NODE_ENV === "production" ? "warn" : "off", + "vue/no-v-html": "off", + }, + parserOptions: { + parser: "babel-eslint", + }, + overrides: [ + { + files: [ + "**/__tests__/*.{j,t}s?(x)", + "**/tests/unit/**/*.spec.{j,t}s?(x)", + ], + env: { + jest: true, + }, + }, + ], +}; diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..b9edb39 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,10 @@ +*.html text eol=lf +*.css text eol=lf +*.js text eol=lf +*.scss text eol=lf +*.vue text eol=lf +*.hbs text eol=lf +*.sh text eol=lf +*.md text eol=lf +*.json text eol=lf +*.yml text eol=lf diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 0000000..f12c307 --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1,2 @@ +patreon: chuzhixin + diff --git a/.github/ISSUE_TEMPLATE/---------------.md b/.github/ISSUE_TEMPLATE/---------------.md new file mode 100644 index 0000000..a2bb8d0 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/---------------.md @@ -0,0 +1,16 @@ +--- +name: 问题提问(不按规范提问不解答) +about: 详细描述你的问题 +title: '' +labels: '' +assignees: '' + +--- + +#### 出现的问题 + +#### 操作了什么以后出现了的 + +#### 详细的报错截图、控制台截图 + +#### 是否已经百度过了、是否已经努力尝试解决了 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b06c22b --- /dev/null +++ b/.gitignore @@ -0,0 +1,20 @@ +.DS_Store +node_modules +dist +.env.local +.env.*.local +npm-debug.log* +yarn-debug.log* +yarn-error.log* +.idea +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? +public/video +*.zip +*.7z +/src/layouts/components/zx-layouts +/zx-templates +/package-lock.json diff --git a/.stylelintrc.js b/.stylelintrc.js new file mode 100644 index 0000000..f521455 --- /dev/null +++ b/.stylelintrc.js @@ -0,0 +1,3 @@ +module.exports = { + extends: ["stylelint-config-recess-order", "stylelint-config-prettier"], +}; diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..896f53d --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,52 @@ +{ + "[vue]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + }, + "editor.quickSuggestions": { + "strings": true + }, + "workbench.colorTheme": "One Monokai", + "editor.tabSize": 2, + "editor.detectIndentation": false, + "emmet.triggerExpansionOnTab": true, + "editor.formatOnSave": true, + "javascript.format.enable": true, + "git.enableSmartCommit": true, + "git.autofetch": true, + "git.confirmSync": false, + "[json]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + }, + "liveServer.settings.donotShowInfoMsg": true, + "explorer.confirmDelete": false, + "javascript.updateImportsOnFileMove.enabled": "always", + "typescript.updateImportsOnFileMove.enabled": "always", + "files.exclude": { + "**/.idea": true + }, + "editor.codeActionsOnSave": { + "source.fixAll.stylelint": true, + "source.fixAll.eslint": true + }, + "[javascript]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + }, + "[scss]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + }, + "[jsonc]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + }, + "[html]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + }, + "editor.suggest.snippetsPreventQuickSuggestions": false, + "prettier.htmlWhitespaceSensitivity": "ignore", + "prettier.vueIndentScriptAndStyle": true, + "docthis.authorName": "chuzhixin 1204505056@qq.com", + "docthis.includeAuthorTag": true, + "docthis.includeDescriptionTag": true, + "docthis.enableHungarianNotationEvaluation": true, + "docthis.inferTypesFromNames": true, + "vetur.format.defaultFormatter.html": "prettier" +} diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..a612ad9 --- /dev/null +++ b/LICENSE @@ -0,0 +1,373 @@ +Mozilla Public License Version 2.0 +================================== + +1. Definitions +-------------- + +1.1. "Contributor" + means each individual or legal entity that creates, contributes to + the creation of, or owns Covered Software. + +1.2. "Contributor Version" + means the combination of the Contributions of others (if any) used + by a Contributor and that particular Contributor's Contribution. + +1.3. "Contribution" + means Covered Software of a particular Contributor. + +1.4. "Covered Software" + means Source Code Form to which the initial Contributor has attached + the notice in Exhibit A, the Executable Form of such Source Code + Form, and Modifications of such Source Code Form, in each case + including portions thereof. + +1.5. "Incompatible With Secondary Licenses" + means + + (a) that the initial Contributor has attached the notice described + in Exhibit B to the Covered Software; or + + (b) that the Covered Software was made available under the terms of + version 1.1 or earlier of the License, but not also under the + terms of a Secondary License. + +1.6. "Executable Form" + means any form of the work other than Source Code Form. + +1.7. "Larger Work" + means a work that combines Covered Software with other material, in + a separate file or files, that is not Covered Software. + +1.8. "License" + means this document. + +1.9. "Licensable" + means having the right to grant, to the maximum extent possible, + whether at the time of the initial grant or subsequently, any and + all of the rights conveyed by this License. + +1.10. "Modifications" + means any of the following: + + (a) any file in Source Code Form that results from an addition to, + deletion from, or modification of the contents of Covered + Software; or + + (b) any new file in Source Code Form that contains any Covered + Software. + +1.11. "Patent Claims" of a Contributor + means any patent claim(s), including without limitation, method, + process, and apparatus claims, in any patent Licensable by such + Contributor that would be infringed, but for the grant of the + License, by the making, using, selling, offering for sale, having + made, import, or transfer of either its Contributions or its + Contributor Version. + +1.12. "Secondary License" + means either the GNU General Public License, Version 2.0, the GNU + Lesser General Public License, Version 2.1, the GNU Affero General + Public License, Version 3.0, or any later versions of those + licenses. + +1.13. "Source Code Form" + means the form of the work preferred for making modifications. + +1.14. "You" (or "Your") + means an individual or a legal entity exercising rights under this + License. For legal entities, "You" includes any entity that + controls, is controlled by, or is under common control with You. For + purposes of this definition, "control" means (a) the power, direct + or indirect, to cause the direction or management of such entity, + whether by contract or otherwise, or (b) ownership of more than + fifty percent (50%) of the outstanding shares or beneficial + ownership of such entity. + +2. License Grants and Conditions +-------------------------------- + +2.1. Grants + +Each Contributor hereby grants You a world-wide, royalty-free, +non-exclusive license: + +(a) under intellectual property rights (other than patent or trademark) + Licensable by such Contributor to use, reproduce, make available, + modify, display, perform, distribute, and otherwise exploit its + Contributions, either on an unmodified basis, with Modifications, or + as part of a Larger Work; and + +(b) under Patent Claims of such Contributor to make, use, sell, offer + for sale, have made, import, and otherwise transfer either its + Contributions or its Contributor Version. + +2.2. Effective Date + +The licenses granted in Section 2.1 with respect to any Contribution +become effective for each Contribution on the date the Contributor first +distributes such Contribution. + +2.3. Limitations on Grant Scope + +The licenses granted in this Section 2 are the only rights granted under +this License. No additional rights or licenses will be implied from the +distribution or licensing of Covered Software under this License. +Notwithstanding Section 2.1(b) above, no patent license is granted by a +Contributor: + +(a) for any code that a Contributor has removed from Covered Software; + or + +(b) for infringements caused by: (i) Your and any other third party's + modifications of Covered Software, or (ii) the combination of its + Contributions with other software (except as part of its Contributor + Version); or + +(c) under Patent Claims infringed by Covered Software in the absence of + its Contributions. + +This License does not grant any rights in the trademarks, service marks, +or logos of any Contributor (except as may be necessary to comply with +the notice requirements in Section 3.4). + +2.4. Subsequent Licenses + +No Contributor makes additional grants as a result of Your choice to +distribute the Covered Software under a subsequent version of this +License (see Section 10.2) or under the terms of a Secondary License (if +permitted under the terms of Section 3.3). + +2.5. Representation + +Each Contributor represents that the Contributor believes its +Contributions are its original creation(s) or it has sufficient rights +to grant the rights to its Contributions conveyed by this License. + +2.6. Fair Use + +This License is not intended to limit any rights You have under +applicable copyright doctrines of fair use, fair dealing, or other +equivalents. + +2.7. Conditions + +Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted +in Section 2.1. + +3. Responsibilities +------------------- + +3.1. Distribution of Source Form + +All distribution of Covered Software in Source Code Form, including any +Modifications that You create or to which You contribute, must be under +the terms of this License. You must inform recipients that the Source +Code Form of the Covered Software is governed by the terms of this +License, and how they can obtain a copy of this License. You may not +attempt to alter or restrict the recipients' rights in the Source Code +Form. + +3.2. Distribution of Executable Form + +If You distribute Covered Software in Executable Form then: + +(a) such Covered Software must also be made available in Source Code + Form, as described in Section 3.1, and You must inform recipients of + the Executable Form how they can obtain a copy of such Source Code + Form by reasonable means in a timely manner, at a charge no more + than the cost of distribution to the recipient; and + +(b) You may distribute such Executable Form under the terms of this + License, or sublicense it under different terms, provided that the + license for the Executable Form does not attempt to limit or alter + the recipients' rights in the Source Code Form under this License. + +3.3. Distribution of a Larger Work + +You may create and distribute a Larger Work under terms of Your choice, +provided that You also comply with the requirements of this License for +the Covered Software. If the Larger Work is a combination of Covered +Software with a work governed by one or more Secondary Licenses, and the +Covered Software is not Incompatible With Secondary Licenses, this +License permits You to additionally distribute such Covered Software +under the terms of such Secondary License(s), so that the recipient of +the Larger Work may, at their option, further distribute the Covered +Software under the terms of either this License or such Secondary +License(s). + +3.4. Notices + +You may not remove or alter the substance of any license notices +(including copyright notices, patent notices, disclaimers of warranty, +or limitations of liability) contained within the Source Code Form of +the Covered Software, except that You may alter any license notices to +the extent required to remedy known factual inaccuracies. + +3.5. Application of Additional Terms + +You may choose to offer, and to charge a fee for, warranty, support, +indemnity or liability obligations to one or more recipients of Covered +Software. However, You may do so only on Your own behalf, and not on +behalf of any Contributor. You must make it absolutely clear that any +such warranty, support, indemnity, or liability obligation is offered by +You alone, and You hereby agree to indemnify every Contributor for any +liability incurred by such Contributor as a result of warranty, support, +indemnity or liability terms You offer. You may include additional +disclaimers of warranty and limitations of liability specific to any +jurisdiction. + +4. Inability to Comply Due to Statute or Regulation +--------------------------------------------------- + +If it is impossible for You to comply with any of the terms of this +License with respect to some or all of the Covered Software due to +statute, judicial order, or regulation then You must: (a) comply with +the terms of this License to the maximum extent possible; and (b) +describe the limitations and the code they affect. Such description must +be placed in a text file included with all distributions of the Covered +Software under this License. Except to the extent prohibited by statute +or regulation, such description must be sufficiently detailed for a +recipient of ordinary skill to be able to understand it. + +5. Termination +-------------- + +5.1. The rights granted under this License will terminate automatically +if You fail to comply with any of its terms. However, if You become +compliant, then the rights granted under this License from a particular +Contributor are reinstated (a) provisionally, unless and until such +Contributor explicitly and finally terminates Your grants, and (b) on an +ongoing basis, if such Contributor fails to notify You of the +non-compliance by some reasonable means prior to 60 days after You have +come back into compliance. Moreover, Your grants from a particular +Contributor are reinstated on an ongoing basis if such Contributor +notifies You of the non-compliance by some reasonable means, this is the +first time You have received notice of non-compliance with this License +from such Contributor, and You become compliant prior to 30 days after +Your receipt of the notice. + +5.2. If You initiate litigation against any entity by asserting a patent +infringement claim (excluding declaratory judgment actions, +counter-claims, and cross-claims) alleging that a Contributor Version +directly or indirectly infringes any patent, then the rights granted to +You by any and all Contributors for the Covered Software under Section +2.1 of this License shall terminate. + +5.3. In the event of termination under Sections 5.1 or 5.2 above, all +end user license agreements (excluding distributors and resellers) which +have been validly granted by You or Your distributors under this License +prior to termination shall survive termination. + +************************************************************************ +* * +* 6. Disclaimer of Warranty * +* ------------------------- * +* * +* Covered Software is provided under this License on an "as is" * +* basis, without warranty of any kind, either expressed, implied, or * +* statutory, including, without limitation, warranties that the * +* Covered Software is free of defects, merchantable, fit for a * +* particular purpose or non-infringing. The entire risk as to the * +* quality and performance of the Covered Software is with You. * +* Should any Covered Software prove defective in any respect, You * +* (not any Contributor) assume the cost of any necessary servicing, * +* repair, or correction. This disclaimer of warranty constitutes an * +* essential part of this License. No use of any Covered Software is * +* authorized under this License except under this disclaimer. * +* * +************************************************************************ + +************************************************************************ +* * +* 7. Limitation of Liability * +* -------------------------- * +* * +* Under no circumstances and under no legal theory, whether tort * +* (including negligence), contract, or otherwise, shall any * +* Contributor, or anyone who distributes Covered Software as * +* permitted above, be liable to You for any direct, indirect, * +* special, incidental, or consequential damages of any character * +* including, without limitation, damages for lost profits, loss of * +* goodwill, work stoppage, computer failure or malfunction, or any * +* and all other commercial damages or losses, even if such party * +* shall have been informed of the possibility of such damages. This * +* limitation of liability shall not apply to liability for death or * +* personal injury resulting from such party's negligence to the * +* extent applicable law prohibits such limitation. Some * +* jurisdictions do not allow the exclusion or limitation of * +* incidental or consequential damages, so this exclusion and * +* limitation may not apply to You. * +* * +************************************************************************ + +8. Litigation +------------- + +Any litigation relating to this License may be brought only in the +courts of a jurisdiction where the defendant maintains its principal +place of business and such litigation shall be governed by laws of that +jurisdiction, without reference to its conflict-of-law provisions. +Nothing in this Section shall prevent a party's ability to bring +cross-claims or counter-claims. + +9. Miscellaneous +---------------- + +This License represents the complete agreement concerning the subject +matter hereof. If any provision of this License is held to be +unenforceable, such provision shall be reformed only to the extent +necessary to make it enforceable. Any law or regulation which provides +that the language of a contract shall be construed against the drafter +shall not be used to construe this License against a Contributor. + +10. Versions of the License +--------------------------- + +10.1. New Versions + +Mozilla Foundation is the license steward. Except as provided in Section +10.3, no one other than the license steward has the right to modify or +publish new versions of this License. Each version will be given a +distinguishing version number. + +10.2. Effect of New Versions + +You may distribute the Covered Software under the terms of the version +of the License under which You originally received the Covered Software, +or under the terms of any subsequent version published by the license +steward. + +10.3. Modified Versions + +If you create software not governed by this License, and you want to +create a new license for such software, you may create and use a +modified version of this License if you rename the license and remove +any references to the name of the license steward (except to note that +such modified license differs from this License). + +10.4. Distributing Source Code Form that is Incompatible With Secondary +Licenses + +If You choose to distribute Source Code Form that is Incompatible With +Secondary Licenses under the terms of this version of the License, the +notice described in Exhibit B of this License must be attached. + +Exhibit A - Source Code Form License Notice +------------------------------------------- + + This Source Code Form is subject to the terms of the Mozilla Public + License, v. 2.0. If a copy of the MPL was not distributed with this + file, You can obtain one at http://mozilla.org/MPL/2.0/. + +If it is not possible or desirable to put the notice in a particular +file, then You may include the notice in a location (such as a LICENSE +file in a relevant directory) where a recipient would be likely to look +for such a notice. + +You may add additional accurate notices of copyright ownership. + +Exhibit B - "Incompatible With Secondary Licenses" Notice +--------------------------------------------------------- + + This Source Code Form is "Incompatible With Secondary Licenses", as + defined by the Mozilla Public License, v. 2.0. diff --git a/README-DCLOUD.md b/README-DCLOUD.md new file mode 100644 index 0000000..2236200 --- /dev/null +++ b/README-DCLOUD.md @@ -0,0 +1,43 @@ +
+

vue-admin-beautiful

+

一款基于 vue+element-ui 的绝佳的通用型、中后台前端框架

+

An excellent general-purpose, middle and background front-end framework based on Vue + element UI

+
+ +[![](https://img.shields.io/github/stars/chuzhixin/vue-admin-beautiful?style=flat-square&label=Stars&logo=github) +](https://github.com/chuzhixin/vue-admin-beautiful) + +## 演示地址 + +### - [🚀 演示地址:vue-admin-beautiful (横向纵向布局无缝切换)](https://chu1204505056.gitee.io/vue-admin-beautiful/?hmsr=%E6%8F%92%E4%BB%B6%E5%B8%82%E5%9C%BA&hmpl=&hmcu=&hmkw=&hmci=) + +### - [🚀 vue-admin-beautiful-pro 版演示地址](https://chu1204505056.gitee.io/vue-admin-beautiful-pro/?hmsr=%E6%8F%92%E4%BB%B6%E5%B8%82%E5%9C%BA&hmpl=&hmcu=&hmkw=&hmci=) + +### - [🚀 vue-admin-beautiful-mini vue3.0 预览版地址](https://chu1204505056.gitee.io/vue-admin-beautiful-mini/?hmsr=%E6%8F%92%E4%BB%B6%E5%B8%82%E5%9C%BA&hmpl=&hmcu=&hmkw=&hmci=) + +## vue-admin-beautiful 前端讨论群-1 972435319 + +不管您加或者不加,您都可以享受到开源的代码,感谢您的支持和信任,群内提供 vue-admin-beautiful-template 基础版本和详细的基础使用文档适合框架快速入门 + +![img](https://chu1204505056.gitee.io/vabBooks/img/ewm.png) + +## 安装 + +```bash +# 克隆项目 +git clone https://github.com/chuzhixin/vue-admin-beautiful.git +# 进入项目目录 +npm vue-admin-beautiful +# 安装依赖 +npm i +# 本地开发 启动项目 +cnpm run serve +``` + +#### github 标星增长量统计 + +[![Stargazers over time](https://starcharts.herokuapp.com/chuzhixin/vue-admin-beautiful.svg)](https://github.com/chuzhixin/vue-admin-beautiful) + +#### 开发者评级 + +[![chuzhixin's github stats](https://github-readme-stats.vercel.app/api?username=chuzhixin)](https://github.com/chuzhixin/vue-admin-beautiful) diff --git a/README.md b/README.md new file mode 100644 index 0000000..66d502c --- /dev/null +++ b/README.md @@ -0,0 +1,321 @@ +# + +
+

vue-admin-beautiful

+

一款基于 vue+element-ui 的绝佳的通用型、中后台前端框架

+

An excellent general-purpose, middle and background front-end framework based on Vue + element UI

+
+ +![image](https://repository-images.githubusercontent.com/249342059/8ff9d000-bef5-11ea-837f-8c265b79e3db) + +## vue-admin-beautiful 前端讨论群-1 972435319 + +不管您加或者不加,您都可以享受到开源的代码,感谢您的支持和信任,群内提供 vue-admin-beautiful-template 基础版本和详细的基础使用文档适合框架快速入门 + +![img](https://gitee.com/chu1204505056/vabBooks/raw/gh-pages/img/ewm.png) + +## 🎉🎉🎉 基于 vue3.0 的 vue-admin-beautiful-mini 正在快马加鞭的开发,敬请期待!!! + +## 地址 + +### - [🎉 演示地址 1:vue-admin-beautiful](http://beautiful.panm.cn/vue-admin-beautiful/?hmsr=github&hmpl=&hmcu=&hmkw=&hmci=) + +### - [🎉 演示地址 2:vue-admin-beautiful](https://chu1204505056.gitee.io/vue-admin-beautiful/?hmsr=github&hmpl=&hmcu=&hmkw=&hmci=) + +### - [🚀 pro 版演示地址 1:vue-admin-beautiful-pro](http://beautiful.panm.cn/vue-admin-beautiful-pro/?hmsr=github&hmpl=&hmcu=&hmkw=&hmci=) + +### - [🚀 pro 版演示地址 2:vue-admin-beautiful-pro](https://chu1204505056.gitee.io/vue-admin-beautiful-pro/?hmsr=github&hmpl=&hmcu=&hmkw=&hmci=) + +### - [🌐 github 仓库地址](https://github.com/chuzhixin/vue-admin-beautiful/?hmsr=github&hmpl=&hmcu=&hmkw=&hmci=) + +### - [🌐 码云仓库地址](https://gitee.com/chu1204505056/vue-admin-beautiful/?hmsr=github&hmpl=&hmcu=&hmkw=&hmci=) + +### - [🌐 vue3.0 版本研发进度展示(基础版本已全部贯通、适配电脑、手机、平板)](https://chu1204505056.gitee.io/vue-admin-beautiful-mini/?hmsr=github&hmpl=&hmcu=&hmkw=&hmci=) + +## 安装 + +```bash +# 克隆项目 +git clone https://github.com/chuzhixin/vue-admin-beautiful.git +# 进入项目目录 +cd vue-admin-beautiful +# 安装依赖 +npm i +# 本地开发 启动项目 +npm run serve +``` + +## install + +```bash +# Clone project +git clone https://github.com/chuzhixin/vue-admin-beautiful.git +# Enter project directory +cd vue-admin-beautiful +# Installation dependency +npm i +# Start project +npm run serve +``` + +## 友情链接 + +### - [uView 文档(超棒的移动跨端框架,文档详细,上手容易)](https://uviewui.com/) + +### - [Element UI 表单设计及代码生成器(可视化表单设计器,一键生成 element 表单)](https://github.com/JakHuang/form-generator/) + +### - [luch-request(基于 Promise 开发的 uni-app 跨平台、项目级别的请求库,它有更小的体积,易用的 api,方便简单的自定义能力)](https://www.quanzhan.co/luch-request/) + +### - [umyui 文档(开发者准备的基于 Vue 2.0 的桌面端组件库; 流畅渲染表格万级数据)](http://www.umyui.com/) + +## setting.js 配置 + +- 说明:这里有好多你会用到的配置项。 +- 位置:src/config/settings.js +- 注意:此处可能不是最新代码具体可查看[github 最新的 settings.js 配置](https://github.com/chuzhixin/vue-admin-beautiful/blob/master/src/config/settings.js) +- 示例代码: + +```js +/** + * @copyright chuzhixin 1204505056@qq.com + * @description 全局变量配置 + */ +module.exports = { + // 开发以及部署时的URL + publicPath: "", + // 生产环境构建文件的目录名 + outputDir: "dist", + // 放置生成的静态资源 (js、css、img、fonts) 的 (相对于 outputDir 的) 目录。 + assetsDir: "static", + // 开发环境每次保存时是否输出为eslint编译警告 + lintOnSave: true, + // 进行编译的依赖 + transpileDependencies: ["vue-echarts", "resize-detector", "zx-layouts"], + // 默认的接口地址 如果是开发环境和生产环境走vab-mock-server,当然你也可以选择自己配置成需要的接口地址 + baseURL: + process.env.NODE_ENV === "development" + ? "vab-mock-server" + : "vab-mock-server", + //标题 (包括初次加载雪花屏的标题 页面的标题 浏览器的标题) + title: "vue-admin-beautiful", + //简写 + abbreviation: "vab", + //开发环境端口号 + devPort: "80", + //版本号 + version: process.env.VUE_APP_VERSION, + //烦请保留package.json作者信息 保留版权可免费商用 + copyright: process.env.VUE_APP_AUTHOR, + //是否显示页面底部版权信息,建议您显示,当然您也可以选择不显示,不管您是付费用户还是未付费用户您都有选择显示或者不显示的权利 + footerCopyright: process.env.NODE_ENV !== "development" ? true : false, + //是否显示右上角github图标 + githubCorner: process.env.NODE_ENV !== "development" ? true : false, + //是否显示顶部进度条 + progressBar: true, + //缓存路由的最大数量 + keepAliveMaxNum: 99, + // 路由模式,可选值为 history 或 hash + routerMode: "hash", + //不经过token校验的路由 + routesWhiteList: ["/login", "/register", "/404", "/401"], + //加载时显示文字 + loadingText: "正在加载中...", + //token名称 + tokenName: "accessToken", + //token在localStorage、sessionStorage、cookie存储的key的名称 + tokenTableName: "vue-admin-beautiful", + //token存储位置localStorage sessionStorage cookie + storage: "localStorage", + //token失效回退到登录页时是否记录本次的路由 + recordRoute: true, + //是否显示logo,不显示时设置false,显示时请填写remixIcon图标名称,暂时只支持设置remixIcon + logo: "vuejs-fill", + //是否国定头部 固定fixed 不固定noFixed + header: "fixed", + //横纵布局 horizontal vertical + layout: "vertical", + //是否开启主题配置按钮 + themeBar: true, + //是否显示多标签页 + tagsBar: true, + //是否显示骨架屏 + skeleton: false, + //配后端数据的接收方式application/json;charset=UTF-8或者application/x-www-form-urlencoded;charset=UTF-8 + contentType: "application/json;charset=UTF-8", + //消息框消失时间 + messageDuration: 3000, + //最长请求时间 + requestTimeout: 5000, + //操作正常code + successCode: 200, + //登录失效code + invalidCode: 402, + //无权限code + noPermissionCode: 401, + //是否显示在页面高亮错误 + errorLog: ["development", "test", "production"], + //是否开启登录拦截 + loginInterception: true, + //是否开启登录RSA加密 + loginRSA: false, + //是否依据mock数据生成webstorm HTTP Request请求文件 + httpRequestFile: false, + //intelligence和all两种方式,前者后端权限只控制permissions不控制view文件的import(前后端配合,减轻后端工作量),all方式完全交给后端前端只负责加载 + authentication: "intelligence", + //vertical布局时是否只保持一个子菜单的展开 + uniqueOpened: true, + //vertical布局时默认展开的菜单path,使用逗号隔开建议只展开一个 + defaultOopeneds: ["/vab"], + //需要加loading层的请求,防止重复提交 + debounce: ["doEdit"], + //需要自动注入并加载的模块 + providePlugin: { maptalks: "maptalks", "window.maptalks": "maptalks" }, + //npm run build时是否自动生成7z压缩包 + build7z: false, + //代码生成机生成在view下的文件夹名称 + templateFolder: "project", +}; +``` + +## variables.scss 配置 + +- 说明:这里可以修改你项目的配色方案,简单修改即可实现风格大变。 +- 位置:src/styles/variables.scss +- 注意:此处可能不是最新代码具体可查看[github 最新的 variables.scss 配置](https://github.com/chuzhixin/vue-admin-beautiful/blob/master/src/styles/variables.scss) + +```scss +/** + * @copyright chuzhixin 1204505056@qq.com + * @description 全局主题变量配置,VIP文档内提供多种好看的配色方案(ant-design风格、layui风格、iview风格),请查看VIP文档主题配置篇 + */ +/* stylelint-disable */ +@charset "utf-8"; +//框架默认主题色 +$base-color-default: #1890ff; +//默认层级 +$base-z-index: 999; +//横向布局纵向布局时菜单背景色 +$base-menu-background: #001529; +//菜单文字颜色 +$base-menu-color: hsla(0, 0%, 100%, 0.95); +//菜单选中文字颜色 +$base-menu-color-active: hsla(0, 0%, 100%, 0.95); +//菜单选中背景色 +$base-menu-background-active: $base-color-default; +//标题颜色 +$base-title-color: #fff; +//字体大小配置 +$base-font-size-small: 12px; +$base-font-size-default: 14px; +$base-font-size-big: 16px; +$base-font-size-bigger: 18px; +$base-font-size-max: 22px; +$base-font-color: #606266; +$base-color-blue: $base-color-default; +$base-color-green: #13ce66; +$base-color-white: #fff; +$base-color-black: #000; +$base-color-yellow: #ffba00; +$base-color-orange: #ff6700; +$base-color-red: #ff4d4f; +$base-color-gray: rgba(0, 0, 0, 0.65); +$base-main-width: 1279px; +$base-border-radius: 2px; +$base-border-color: #dcdfe6; +//输入框高度 +$base-input-height: 32px; +//默认paddiing +$base-padding: 20px; +//默认阴影 +$base-box-shadow: 0 1px 4px rgba(0, 21, 41, 0.08); +//横向布局时top-bar、logo、一级菜单的高度 +$base-top-bar-height: 65px; +//纵向布局时logo的高度 +$base-logo-height: 75px; +//顶部nav-bar的高度 +$base-nav-bar-height: 60px; +//顶部多标签页tags-bar的高度 +$base-tags-bar-height: 55px; +//顶部多标签页tags-bar中每一个item的高度 +$base-tag-item-height: 34px; +//菜单li标签的高度 +$base-menu-item-height: 50px; +//app-main的高度 +$base-app-main-height: calc( + 100vh - #{$base-nav-bar-height} - #{$base-tags-bar-height} - + #{$base-padding} - #{$base-padding} - 55px - 30px +); +//纵向布局时左侧导航未折叠时的宽度 +$base-left-menu-width: 230px; +//纵向布局时左侧导航未折叠时右侧内容的宽度 +$base-right-content-width: calc(100% - #{$base-left-menu-width}); +//纵向布局时左侧导航已折叠时的宽度 +$base-left-menu-width-min: 65px; +//纵向布局时左侧导航已折叠时右侧内容的宽度 +$base-right-content-width-min: calc(100% - #{$base-left-menu-width-min}); +//默认动画 +$base-transition: all 0.2s; +//默认动画时长 +$base-transition-time: 0.2s; + +:export { + //菜单文字颜色变量导出 + menu-color: $base-menu-color; + //菜单选中文字颜色变量导出 + menu-color-active: $base-menu-color-active; + //菜单背景色变量导出 + menu-background: $base-menu-background; + //菜单选中背景色变量导出 + menu-background-active: $base-menu-background-active; + //多标签页选中背景色变量导出 + tag-background-active: $base-color-blue; + //默认按钮背景色变量导出 + button-background: $base-color-blue; + //分页选中背景色变量导出 + pagination-background-active: $base-color-blue; +} +``` + +## element-ui 组件尺寸配置 + +- 说明:这里可以修改你 element-ui 组件尺寸,element-ui 组件的尺寸一共分为 large、default、small 、mini,本项目默认使用的是 small。 +- 位置:src/plugins/element.js +- 示例代码: + +```js +import Vue from "vue"; +import ElementUI from "element-ui"; +import "element-ui/lib/theme-chalk/display.css"; + +import "@/styles/element-variables.scss"; + +Vue.use(ElementUI, { + size: "small", // element-ui组件的尺寸一共分为large、default、small 、mini +}); +``` + +## 付费技术支持,商务合作 + +### 联系:QQ 1204505056 + +## 捐赠 + +![img](https://chu1204505056.gitee.io/vabBooks/img/donation.png) + +#### github 标星增长量统计 + +[![Stargazers over time](https://starcharts.herokuapp.com/chuzhixin/vue-admin-beautiful.svg)](https://github.com/chuzhixin/vue-admin-beautiful) + +#### 开发者评级 + +[![chuzhixin's github stats](https://github-readme-stats.vercel.app/api?username=chuzhixin)](https://github.com/chuzhixin/vue-admin-beautiful) + +## 关于框架的声明 + +框架在保留作者版权信息的前提下可免费用于商业使用,框架所有代码包含 npm 包中的源码内容均为免费开放,如果您愿意支持我、或者希望完全变成自己的版权信息,需支付 299 元,如果您愿意加入 VIP 群学习需支付 100 元,这一切都是在您自愿的基础上,如果您觉得框架一文不值,请直接略过,高抬贵手放我一马,不要恶意刷差评,希望每个使用 vue-admin-beautiful 的人无论过程怎样,结局都是美好的,联系方式 QQ 1204505056 + +## vue-admin-beautiful 前端讨论群-2 1139183756 + +不管您加或者不加,您都可以享受到开源的代码,感谢您的支持和信任,群内提供 vue-admin-beautiful-template 基础版本和详细的基础使用文档适合框架快速入门 + +![img](https://gitee.com/chu1204505056/vabBooks/raw/gh-pages/img/ewm_2.png) diff --git a/SECURITY.md b/SECURITY.md new file mode 100644 index 0000000..034e848 --- /dev/null +++ b/SECURITY.md @@ -0,0 +1,21 @@ +# Security Policy + +## Supported Versions + +Use this section to tell people about which versions of your project are +currently being supported with security updates. + +| Version | Supported | +| ------- | ------------------ | +| 5.1.x | :white_check_mark: | +| 5.0.x | :x: | +| 4.0.x | :white_check_mark: | +| < 4.0 | :x: | + +## Reporting a Vulnerability + +Use this section to tell people how to report a vulnerability. + +Tell them where to go, how often they can expect to get an update on a +reported vulnerability, what to expect if the vulnerability is accepted or +declined, etc. diff --git a/babel.config.js b/babel.config.js new file mode 100644 index 0000000..162a3ea --- /dev/null +++ b/babel.config.js @@ -0,0 +1,3 @@ +module.exports = { + presets: ["@vue/cli-plugin-babel/preset"], +}; diff --git a/deploy.sh b/deploy.sh new file mode 100644 index 0000000..07c7ef6 --- /dev/null +++ b/deploy.sh @@ -0,0 +1,17 @@ +#!/usr/bin/env bash +set -e +npm run build +cd dist +touch .nojekyll +git init +git add -A +git commit -m '🎉🎉🎉仓库重置到2020年9月29日,Vue2.6最后一个版本,之前版本不再支持,具体请查阅文档,Vue 3.0版本请耐心等待!!!' +git push -f "https://${access_token}@gitee.com/chu1204505056/vue-admin-beautiful.git" master:gh-pages +start "https://gitee.com/chu1204505056/vue-admin-beautiful/pages" +git push -f "https://${access_token}@github.com/chuzhixin/vue-admin-beautiful.git" master:gh-pages +cd - +exec /bin/bash + + + + diff --git a/http/mock.http b/http/mock.http new file mode 100644 index 0000000..9f437b5 --- /dev/null +++ b/http/mock.http @@ -0,0 +1,70 @@ + +###/changeLog/getList###mockServer +POST http://localhost:80/mock-server/changeLog/getList +Content-Type: application/x-www-form-urlencoded +### +mockServer +###/colorfulIcon/list### +POST http://localhost:80/mock-server/colorfulIcon/list +Content-Type: application/x-www-form-urlencoded +###mockServer + +###/menu/navigate### +POST http://localhost:80/mock-server/menu/navigate +Content-Type: application/x-www-form-urlenmockServer +### + +###/icon/list### +POST http://localhost:80/mock-server/icon/mockServer +Content-Type: application/x-www-form-urlencoded +### + +###/face/list###mockServer +POST http://localhost:80/mock-server/face/list +Content-Type: application/x-www-form-urlencoded +### +mockServer +###/table/list### +POST http://localhost:80/mock-server/table/list +Content-Type: application/x-www-form-urlencoded +###mockServer + +###/remixicon/getList### +POST http://localhost:80/mock-server/remixicon/getList +Content-Type: application/x-www-form-urlenmockServer +### + +###/publicKey### +POST http://localhost:80/mock-server/pumockServer +Content-Type: application/x-www-form-urlencoded +### + +###/tree/list###mockServer +POST http://localhost:80/mock-server/tree/list +Content-Type: application/x-www-form-urlencoded +### +mockServer +###/upload### +POST http://localhost:80/mock-server/upload +Content-Type: application/x-www-form-urlencoded +###mockServer + +###/login### +POST http://localhost:80/mock-server/login +Content-Type: application/x-www-form-urlenmockServer +### + +###/waterfall/list### +POST http://localhost:80/mock-server/waterfall/list +Content-Type: application/x-www-form-urlencoded +### + +###/logout### +POST http://localhost:80/mock-server/logout +Content-Type: application/x-www-form-urlencoded +### + +###/userInfo### +POST http://localhost:80/mock-server/userInfo +Content-Type: application/x-www-form-urlencoded +### diff --git a/license.md b/license.md new file mode 100644 index 0000000..a612ad9 --- /dev/null +++ b/license.md @@ -0,0 +1,373 @@ +Mozilla Public License Version 2.0 +================================== + +1. Definitions +-------------- + +1.1. "Contributor" + means each individual or legal entity that creates, contributes to + the creation of, or owns Covered Software. + +1.2. "Contributor Version" + means the combination of the Contributions of others (if any) used + by a Contributor and that particular Contributor's Contribution. + +1.3. "Contribution" + means Covered Software of a particular Contributor. + +1.4. "Covered Software" + means Source Code Form to which the initial Contributor has attached + the notice in Exhibit A, the Executable Form of such Source Code + Form, and Modifications of such Source Code Form, in each case + including portions thereof. + +1.5. "Incompatible With Secondary Licenses" + means + + (a) that the initial Contributor has attached the notice described + in Exhibit B to the Covered Software; or + + (b) that the Covered Software was made available under the terms of + version 1.1 or earlier of the License, but not also under the + terms of a Secondary License. + +1.6. "Executable Form" + means any form of the work other than Source Code Form. + +1.7. "Larger Work" + means a work that combines Covered Software with other material, in + a separate file or files, that is not Covered Software. + +1.8. "License" + means this document. + +1.9. "Licensable" + means having the right to grant, to the maximum extent possible, + whether at the time of the initial grant or subsequently, any and + all of the rights conveyed by this License. + +1.10. "Modifications" + means any of the following: + + (a) any file in Source Code Form that results from an addition to, + deletion from, or modification of the contents of Covered + Software; or + + (b) any new file in Source Code Form that contains any Covered + Software. + +1.11. "Patent Claims" of a Contributor + means any patent claim(s), including without limitation, method, + process, and apparatus claims, in any patent Licensable by such + Contributor that would be infringed, but for the grant of the + License, by the making, using, selling, offering for sale, having + made, import, or transfer of either its Contributions or its + Contributor Version. + +1.12. "Secondary License" + means either the GNU General Public License, Version 2.0, the GNU + Lesser General Public License, Version 2.1, the GNU Affero General + Public License, Version 3.0, or any later versions of those + licenses. + +1.13. "Source Code Form" + means the form of the work preferred for making modifications. + +1.14. "You" (or "Your") + means an individual or a legal entity exercising rights under this + License. For legal entities, "You" includes any entity that + controls, is controlled by, or is under common control with You. For + purposes of this definition, "control" means (a) the power, direct + or indirect, to cause the direction or management of such entity, + whether by contract or otherwise, or (b) ownership of more than + fifty percent (50%) of the outstanding shares or beneficial + ownership of such entity. + +2. License Grants and Conditions +-------------------------------- + +2.1. Grants + +Each Contributor hereby grants You a world-wide, royalty-free, +non-exclusive license: + +(a) under intellectual property rights (other than patent or trademark) + Licensable by such Contributor to use, reproduce, make available, + modify, display, perform, distribute, and otherwise exploit its + Contributions, either on an unmodified basis, with Modifications, or + as part of a Larger Work; and + +(b) under Patent Claims of such Contributor to make, use, sell, offer + for sale, have made, import, and otherwise transfer either its + Contributions or its Contributor Version. + +2.2. Effective Date + +The licenses granted in Section 2.1 with respect to any Contribution +become effective for each Contribution on the date the Contributor first +distributes such Contribution. + +2.3. Limitations on Grant Scope + +The licenses granted in this Section 2 are the only rights granted under +this License. No additional rights or licenses will be implied from the +distribution or licensing of Covered Software under this License. +Notwithstanding Section 2.1(b) above, no patent license is granted by a +Contributor: + +(a) for any code that a Contributor has removed from Covered Software; + or + +(b) for infringements caused by: (i) Your and any other third party's + modifications of Covered Software, or (ii) the combination of its + Contributions with other software (except as part of its Contributor + Version); or + +(c) under Patent Claims infringed by Covered Software in the absence of + its Contributions. + +This License does not grant any rights in the trademarks, service marks, +or logos of any Contributor (except as may be necessary to comply with +the notice requirements in Section 3.4). + +2.4. Subsequent Licenses + +No Contributor makes additional grants as a result of Your choice to +distribute the Covered Software under a subsequent version of this +License (see Section 10.2) or under the terms of a Secondary License (if +permitted under the terms of Section 3.3). + +2.5. Representation + +Each Contributor represents that the Contributor believes its +Contributions are its original creation(s) or it has sufficient rights +to grant the rights to its Contributions conveyed by this License. + +2.6. Fair Use + +This License is not intended to limit any rights You have under +applicable copyright doctrines of fair use, fair dealing, or other +equivalents. + +2.7. Conditions + +Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted +in Section 2.1. + +3. Responsibilities +------------------- + +3.1. Distribution of Source Form + +All distribution of Covered Software in Source Code Form, including any +Modifications that You create or to which You contribute, must be under +the terms of this License. You must inform recipients that the Source +Code Form of the Covered Software is governed by the terms of this +License, and how they can obtain a copy of this License. You may not +attempt to alter or restrict the recipients' rights in the Source Code +Form. + +3.2. Distribution of Executable Form + +If You distribute Covered Software in Executable Form then: + +(a) such Covered Software must also be made available in Source Code + Form, as described in Section 3.1, and You must inform recipients of + the Executable Form how they can obtain a copy of such Source Code + Form by reasonable means in a timely manner, at a charge no more + than the cost of distribution to the recipient; and + +(b) You may distribute such Executable Form under the terms of this + License, or sublicense it under different terms, provided that the + license for the Executable Form does not attempt to limit or alter + the recipients' rights in the Source Code Form under this License. + +3.3. Distribution of a Larger Work + +You may create and distribute a Larger Work under terms of Your choice, +provided that You also comply with the requirements of this License for +the Covered Software. If the Larger Work is a combination of Covered +Software with a work governed by one or more Secondary Licenses, and the +Covered Software is not Incompatible With Secondary Licenses, this +License permits You to additionally distribute such Covered Software +under the terms of such Secondary License(s), so that the recipient of +the Larger Work may, at their option, further distribute the Covered +Software under the terms of either this License or such Secondary +License(s). + +3.4. Notices + +You may not remove or alter the substance of any license notices +(including copyright notices, patent notices, disclaimers of warranty, +or limitations of liability) contained within the Source Code Form of +the Covered Software, except that You may alter any license notices to +the extent required to remedy known factual inaccuracies. + +3.5. Application of Additional Terms + +You may choose to offer, and to charge a fee for, warranty, support, +indemnity or liability obligations to one or more recipients of Covered +Software. However, You may do so only on Your own behalf, and not on +behalf of any Contributor. You must make it absolutely clear that any +such warranty, support, indemnity, or liability obligation is offered by +You alone, and You hereby agree to indemnify every Contributor for any +liability incurred by such Contributor as a result of warranty, support, +indemnity or liability terms You offer. You may include additional +disclaimers of warranty and limitations of liability specific to any +jurisdiction. + +4. Inability to Comply Due to Statute or Regulation +--------------------------------------------------- + +If it is impossible for You to comply with any of the terms of this +License with respect to some or all of the Covered Software due to +statute, judicial order, or regulation then You must: (a) comply with +the terms of this License to the maximum extent possible; and (b) +describe the limitations and the code they affect. Such description must +be placed in a text file included with all distributions of the Covered +Software under this License. Except to the extent prohibited by statute +or regulation, such description must be sufficiently detailed for a +recipient of ordinary skill to be able to understand it. + +5. Termination +-------------- + +5.1. The rights granted under this License will terminate automatically +if You fail to comply with any of its terms. However, if You become +compliant, then the rights granted under this License from a particular +Contributor are reinstated (a) provisionally, unless and until such +Contributor explicitly and finally terminates Your grants, and (b) on an +ongoing basis, if such Contributor fails to notify You of the +non-compliance by some reasonable means prior to 60 days after You have +come back into compliance. Moreover, Your grants from a particular +Contributor are reinstated on an ongoing basis if such Contributor +notifies You of the non-compliance by some reasonable means, this is the +first time You have received notice of non-compliance with this License +from such Contributor, and You become compliant prior to 30 days after +Your receipt of the notice. + +5.2. If You initiate litigation against any entity by asserting a patent +infringement claim (excluding declaratory judgment actions, +counter-claims, and cross-claims) alleging that a Contributor Version +directly or indirectly infringes any patent, then the rights granted to +You by any and all Contributors for the Covered Software under Section +2.1 of this License shall terminate. + +5.3. In the event of termination under Sections 5.1 or 5.2 above, all +end user license agreements (excluding distributors and resellers) which +have been validly granted by You or Your distributors under this License +prior to termination shall survive termination. + +************************************************************************ +* * +* 6. Disclaimer of Warranty * +* ------------------------- * +* * +* Covered Software is provided under this License on an "as is" * +* basis, without warranty of any kind, either expressed, implied, or * +* statutory, including, without limitation, warranties that the * +* Covered Software is free of defects, merchantable, fit for a * +* particular purpose or non-infringing. The entire risk as to the * +* quality and performance of the Covered Software is with You. * +* Should any Covered Software prove defective in any respect, You * +* (not any Contributor) assume the cost of any necessary servicing, * +* repair, or correction. This disclaimer of warranty constitutes an * +* essential part of this License. No use of any Covered Software is * +* authorized under this License except under this disclaimer. * +* * +************************************************************************ + +************************************************************************ +* * +* 7. Limitation of Liability * +* -------------------------- * +* * +* Under no circumstances and under no legal theory, whether tort * +* (including negligence), contract, or otherwise, shall any * +* Contributor, or anyone who distributes Covered Software as * +* permitted above, be liable to You for any direct, indirect, * +* special, incidental, or consequential damages of any character * +* including, without limitation, damages for lost profits, loss of * +* goodwill, work stoppage, computer failure or malfunction, or any * +* and all other commercial damages or losses, even if such party * +* shall have been informed of the possibility of such damages. This * +* limitation of liability shall not apply to liability for death or * +* personal injury resulting from such party's negligence to the * +* extent applicable law prohibits such limitation. Some * +* jurisdictions do not allow the exclusion or limitation of * +* incidental or consequential damages, so this exclusion and * +* limitation may not apply to You. * +* * +************************************************************************ + +8. Litigation +------------- + +Any litigation relating to this License may be brought only in the +courts of a jurisdiction where the defendant maintains its principal +place of business and such litigation shall be governed by laws of that +jurisdiction, without reference to its conflict-of-law provisions. +Nothing in this Section shall prevent a party's ability to bring +cross-claims or counter-claims. + +9. Miscellaneous +---------------- + +This License represents the complete agreement concerning the subject +matter hereof. If any provision of this License is held to be +unenforceable, such provision shall be reformed only to the extent +necessary to make it enforceable. Any law or regulation which provides +that the language of a contract shall be construed against the drafter +shall not be used to construe this License against a Contributor. + +10. Versions of the License +--------------------------- + +10.1. New Versions + +Mozilla Foundation is the license steward. Except as provided in Section +10.3, no one other than the license steward has the right to modify or +publish new versions of this License. Each version will be given a +distinguishing version number. + +10.2. Effect of New Versions + +You may distribute the Covered Software under the terms of the version +of the License under which You originally received the Covered Software, +or under the terms of any subsequent version published by the license +steward. + +10.3. Modified Versions + +If you create software not governed by this License, and you want to +create a new license for such software, you may create and use a +modified version of this License if you rename the license and remove +any references to the name of the license steward (except to note that +such modified license differs from this License). + +10.4. Distributing Source Code Form that is Incompatible With Secondary +Licenses + +If You choose to distribute Source Code Form that is Incompatible With +Secondary Licenses under the terms of this version of the License, the +notice described in Exhibit B of this License must be attached. + +Exhibit A - Source Code Form License Notice +------------------------------------------- + + This Source Code Form is subject to the terms of the Mozilla Public + License, v. 2.0. If a copy of the MPL was not distributed with this + file, You can obtain one at http://mozilla.org/MPL/2.0/. + +If it is not possible or desirable to put the notice in a particular +file, then You may include the notice in a location (such as a LICENSE +file in a relevant directory) where a recipient would be likely to look +for such a notice. + +You may add additional accurate notices of copyright ownership. + +Exhibit B - "Incompatible With Secondary Licenses" Notice +--------------------------------------------------------- + + This Source Code Form is "Incompatible With Secondary Licenses", as + defined by the Mozilla Public License, v. 2.0. diff --git a/mock/controller/ad.js b/mock/controller/ad.js new file mode 100644 index 0000000..961b9d7 --- /dev/null +++ b/mock/controller/ad.js @@ -0,0 +1,19 @@ +const data = [ + { + title: "vue-admin-beautiful-pro beta版本已发布,点我提前体验", + url: "https://chu1204505056.gitee.io/vue-admin-beautiful-pro/#/index", + }, +]; +module.exports = [ + { + url: "/ad/getList", + type: "get", + response() { + return { + code: 200, + msg: "success", + data, + }; + }, + }, +]; diff --git a/mock/controller/blacklist.js b/mock/controller/blacklist.js new file mode 100644 index 0000000..6ad29c4 --- /dev/null +++ b/mock/controller/blacklist.js @@ -0,0 +1,87 @@ +const data = [ + { + name: "奉/fendou飘逸的梦", + qq: "812770127", + excuse: "上来就开骂,不可原谅", + }, + { + name: "江荻", + qq: "2324945654", + excuse: "上来就开骂,不可原谅", + }, + { + name: "Diamond", + qq: "494904935", + excuse: "跟我道歉可以选择原谅", + }, + { + name: "Mr、无涯", + qq: "2198457489", + excuse: "已原谅", + }, + { + name: "玩世不恭丶江小白", + qq: "1779263221", + excuse: "睁眼说瞎话", + }, + { + name: "福州客家网络科技有限公司(潘芳林等兄弟二人)", + qq: "1409198410、1778486252", + excuse: + "剽窃、破解框架授权并发布到网上还伪装成善人,公开道歉并尊重我的劳动成果可以选择原谅", + }, + { + name: "willina", + qq: "405522648", + excuse: + "上来就开骂道:You and your git submit are just a rubbish,不可原谅", + }, + { + name: "7(赵海鹏)", + qq: "252334666", + excuse: "欺骗两个善良的小姑娘,做完项目不付70%的尾款,强烈抵制", + }, + { + name: "生活,一半记忆.一半继续", + qq: "252667193", + excuse: "30多岁,不学无术,造谣抹黑,不可原谅", + }, + { + name: "AIRLOO", + qq: "5971794", + excuse: "已原谅", + }, + { + name: "master Z", + qq: "1832819123", + excuse: "不尊重别人的劳动成果,认为开源就得无偿替他服务,不可原谅", + }, + { + name: "想象中。。。", + qq: "329492979", + excuse: "不尊重别人的劳动成果,认为开源就得无偿替他服务,不可原谅", + }, + { + name: "苏潍—菏泽微智科技", + qq: "328580081", + excuse: "无言以对", + }, + { + name: "罗阳", + qq: "1320168680", + excuse: "不尊重别人的劳动成果,认为开源就得无偿替他服务,不可原谅", + }, +]; +module.exports = [ + { + url: "/blacklist/getList", + type: "post", + response() { + return { + code: 200, + msg: "success", + data, + }; + }, + }, +]; diff --git a/mock/controller/changeLog.js b/mock/controller/changeLog.js new file mode 100644 index 0000000..47992fa --- /dev/null +++ b/mock/controller/changeLog.js @@ -0,0 +1,200 @@ +const data = [ + { + content: "在github上获得了第一个star,感恩一位名叫Bequiet2014的github用户", + timestamp: "2020-03-23", + }, + { + content: "增加更换主题功能", + timestamp: "2020-04-10", + }, + { + content: "大幅精简代码", + timestamp: "2020-04-14", + }, + { + content: "修复群友反馈的bug", + timestamp: "2020-04-16", + }, + { + content: "剔除maptalks", + timestamp: "2020-04-17", + }, + { + content: + "换行符统一修改为lf 支持苹果 linux windows协同开发 强制开启最严格eslint规则 不要哭 严格是有好处的", + timestamp: "2020-04-17", + }, + { + content: "彻底完成手机端适配,记录这一天熬夜到了晚上三点", + timestamp: "2020-04-18", + }, + { + content: + "删除babel-polyfill 提高打包速度 减少压缩体积(放弃ie是这个项目做出的最伟大的决定)", + timestamp: "2020-04-18", + }, + { + content: "源码精简至800k", + timestamp: "2020-04-19", + }, + { + content: "添加视频播放器组件", + timestamp: "2020-04-20", + }, + { + content: "修复路由懒加载 完善主题配色", + timestamp: "2020-04-22", + }, + { + content: "修复全局axios拦截 加快动画展示效果 修改登录页样式", + timestamp: "2020-04-24", + }, + { + content: "简化权限与登录逻辑 更新mockServer", + timestamp: "2020-04-25", + }, + { + content: "优化登录退出逻辑 代码更清晰 退出不再重载网页 改为重载路由形式", + timestamp: "2020-04-26", + }, + { + content: "无端的指责只会让我更加努力 修复sidebar 简化permission", + timestamp: "2020-04-28", + }, + { + content: "又是一个深夜 实现了表格增删改查的一键生成", + timestamp: "2020-04-30", + }, + { + content: "大幅优化tagsview标签动画", + timestamp: "2020-05-02", + }, + { + content: "三种图标组件实现mock模拟分页", + timestamp: "2020-05-03", + }, + { + content: "添加了markdown编辑器组件", + timestamp: "2020-05-04", + }, + { + content: "添加stylelint-plus自动规整排序样式", + timestamp: "2020-05-06", + }, + { + content: "添加商城模板", + timestamp: "2020-05-12", + }, + { + content: "github标星超过1000 感恩", + timestamp: "2020-05-13", + }, + { + content: "添加验证码组件", + timestamp: "2020-05-14", + }, + { + content: "修复横向菜单bug", + timestamp: "2020-05-16", + }, + { + content: "又被人骂了 挺好的 让我下定决心重写了tagsBar", + timestamp: "2020-05-20", + }, + { + content: "仿ant-design 添加雪花屏", + timestamp: "2020-05-26", + }, + { + content: "添加人员管理模块", + timestamp: "2020-06-02", + }, + { + content: "github标星超过2000 感恩", + timestamp: "2020-06-03", + }, + { + content: "添加炫酷地图组件", + timestamp: "2020-06-11", + }, + { + content: "抽离更多公共配置,框架使用更顺手", + timestamp: "2020-06-19", + }, + { + content: "彻底完成了tagsbar多标签页的重构", + timestamp: "2020-06-22", + }, + { + content: "感恩github标星过3.0K 祝大家端午节快乐", + timestamp: "2020-06-25", + }, + { + content: "彻底重构了SideBar与TopBar 大幅精简dom渲染逻辑 全球首发", + timestamp: "2020-06-25", + }, + { + content: "添加菜单管理", + timestamp: "2020-07-7", + }, + { + content: "首次采用sass-loader 9.0写法,感谢github用户 shaonialife", + timestamp: "2020-07-7", + }, + { + content: "添加vue-amap组件", + timestamp: "2020-07-11", + }, + { + content: "修改zx-layouts引入方式", + timestamp: "2020-07-15", + }, + { + content: + "记录这一天vue-admin-beautiful在插件市场、百度已花费超过1万元广告费用,希望一切都值得", + timestamp: "2020-07-18", + }, + { + content: "主题配置添加海洋之心、绿荫草场、荣耀典藏、暗黑之子模式", + timestamp: "2020-07-18", + }, + { + content: "全局axios请求全面支持Status Code拦截处理", + timestamp: "2020-07-29", + }, + { + content: "重构全局loadding加载代码", + timestamp: "2020-07-31", + }, + { + content: "升级stylelint自动排序功能", + timestamp: "2020-08-25", + }, + { + content: "修复视频播放器组件重载路由失效的bug", + timestamp: "2020-09-03", + }, + { + content: "修复极个别情况image-loader打包报错", + timestamp: "2020-09-18", + }, + { + content: "全网首个基于vue3.0开发的admin框架已发布,具体请访问github", + timestamp: "2020-09-22", + }, +]; + +module.exports = [ + { + url: "/changeLog/getList", + type: "post", + response() { + return { + code: 200, + msg: "success", + totalCount: 999, + data: data, + }; + }, + }, +]; diff --git a/mock/controller/colorfulIcon.js b/mock/controller/colorfulIcon.js new file mode 100644 index 0000000..e32a5dd --- /dev/null +++ b/mock/controller/colorfulIcon.js @@ -0,0 +1,328 @@ +const data = [ + "alphabetical_sorting", + "advance", + "address_book", + "alphabetical_sorting", + "advertising", + "alarm_clock", + "area_chart", + "approval", + "answers", + "approve", + "assistant", + "audio_file", + "automotive", + "automatic", + "bad_decision", + "bar_chart", + "bearish", + "biomass", + "biohazard", + "binoculars", + "bookmark", + "briefcase", + "biotech", + "broken_link", + "business", + "bullish", + "business_contact", + "businesswoman", + "cable_release", + "calculator", + "businessman", + "calendar", + "butting_in", + "call_transfer", + "callback", + "camcorder", + "camera", + "camcorder_pro", + "cancel", + "camera_addon", + "camera_identificatio", + "capacitor", + "candle_sticks", + "checkmark", + "circuit", + "charge_battery", + "clear_filters", + "clapperboard", + "clock", + "close_up_mode", + "collaboration", + "cell_phone", + "collapse", + "collect", + "cloth", + "combo_chart", + "comments", + "conference_call", + "compact_camera", + "contacts", + "copyleft", + "copyright", + "crystal_oscillator", + "cursor", + "currency_exchange", + "customer_support", + "dam", + "data_backup", + "data_configuration", + "data_encryption", + "data_protection", + "data_recovery", + "database", + "data_sheet", + "debt", + "decision", + "delete_column", + "delete_database", + "department", + "delete_row", + "deployment", + "dislike", + "disapprove", + "disclaimer", + "display", + "document", + "do_not_insert", + "do_not_mix", + "do_not_inhale", + "donate", + "down", + "doughnut_chart", + "down_left", + "down_right", + "download", + "edit_image", + "electrical_sensor", + "electrical_threshold", + "electricity", + "electro_devices", + "electronics", + "empty_battery", + "empty_filter", + "empty_trash", + "end_call", + "engineering", + "entering_heaven_aliv", + "expand", + "export", + "expired", + "factory", + "factory_breakdown", + "external", + "faq", + "feed_in", + "file", + "feedback", + "film", + "filled_filter", + "filing_cabinet", + "film_reel", + "flash_auto", + "fine_print", + "flash_off", + "flash_on", + "flow_chart", + "folder", + "frame", + "full_battery", + "full_trash", + "gallery", + "generic_sorting_asc", + "generic_sorting_desc", + "genealogy", + "globe", + "good_decision", + "headset", + "grid", + "graduation_cap", + "heat_map", + "high_priority", + "high_battery", + "image_file", + "home", + "idea", + "import", + "in_transit", + "integrated_webcam", + "inspection", + "invite", + "internal", + "ipad", + "info", + "iphone", + "kindle", + "key", + "landscape", + "left", + "left_down", + "left_up", + "leave", + "like_placeholder", + "light_at_the_end_of_", + "library", + "line_chart", + "link", + "like", + "lock", + "list", + "lock_landscape", + "low_battery", + "lock_portrait", + "low_priority", + "make_decision", + "medium_priority", + "manager", + "menu", + "middle_battery", + "minus", + "missed_call", + "mind_map", + "mms", + "multiple_cameras", + "money_transfer", + "music", + "multiple_devices", + "multiple_smartphones", + "multiple_inputs", + "negative_dynamic", + "neutral_decision", + "night_landscape", + "news", + "neutral_trading", + "night_portrait", + "no_idea", + "next", + "no_video", + "nook", + "ok", + "org_unit", + "opened_folder", + "old_time_camera", + "online_support", + "organization", + "package", + "paid", + "parallel_tasks", + "overtime", + "panorama", + "phone", + "phone_android", + "photo_reel", + "pie_chart", + "picture", + "planner", + "plus", + "podium_with_audience", + "podium_without_speak", + "podium_with_speaker", + "previous", + "portrait_mode", + "positive_dynamic", + "privacy", + "process", + "puzzle", + "questions", + "print", + "radar_plot", + "rating", + "ratings", + "reading", + "redo", + "reading_ebook", + "refresh", + "registered_trademark", + "right", + "reuse", + "remove_image", + "right_down", + "right_up", + "rotate_to_portrait", + "rules", + "rotate_camera", + "rotate_to_landscape", + "ruler", + "scatter_plot", + "search", + "safe", + "self_service_kiosk", + "selfie", + "serial_tasks", + "sales_performance", + "settings", + "services", + "share", + "shipped", + "sim_card", + "shop", + "service_mark", + "sim_card_chip", + "signature", + "smartphone_tablet", + "sound_recording_copy", + "sms", + "speaker", + "slr_back_side", + "start", + "stack_of_photos", + "statistics", + "sports_mode", + "support", + "synchronize", + "switch_camera", + "survey", + "tablet_android", + "template", + "trademark", + "todo_list", + "touchscreen_smartpho", + "timeline", + "tree_structure", + "undo", + "up_left", + "two_smartphones", + "unlock", + "up", + "up_right", + "upload", + "video_call", + "video_file", + "view_details", + "video_projector", + "vip", + "voice_presentation", + "webcam", + "voicemail", + "workflow", + "about", + "accept_database", + "add_image", + "add_column", + "add_database", + "add_row", +]; +module.exports = [ + { + url: "/colorfulIcon/getList", + type: "post", + response(config) { + const { title, pageNo = 1, pageSize = 72 } = config.body; + let mockList = data.filter((item) => { + if (title && item.indexOf(title) < 0) return false; + return true; + }); + const pageList = mockList.filter( + (item, index) => + index < pageSize * pageNo && index >= pageSize * (pageNo - 1) + ); + return { + code: 200, + msg: "success", + totalCount: mockList.length, + data: pageList, + }; + }, + }, +]; diff --git a/mock/controller/goodsDetail.js b/mock/controller/goodsDetail.js new file mode 100644 index 0000000..9548163 --- /dev/null +++ b/mock/controller/goodsDetail.js @@ -0,0 +1,42 @@ +const { mock } = require("mockjs"); + +module.exports = [ + { + url: "/goodsDetail/getList", + type: "post", + response(config) { + return { + code: 200, + msg: "success", + totalCount: 999, + data: mock({ + "data|10": [ + { + id: "@id", + }, + ], + }).data, + }; + }, + }, + { + url: "/goodsDetail/doEdit", + type: "post", + response(config) { + return { + code: 200, + msg: "模拟保存成功", + }; + }, + }, + { + url: "/goodsDetail/doDelete", + type: "post", + response(config) { + return { + code: 200, + msg: "模拟删除成功", + }; + }, + }, +]; diff --git a/mock/controller/goodsList.js b/mock/controller/goodsList.js new file mode 100644 index 0000000..9f2420d --- /dev/null +++ b/mock/controller/goodsList.js @@ -0,0 +1,43 @@ +const { mock } = require("mockjs"); + +const List = []; +const count = 999; +let num = 0; +for (let i = 0; i < count; i++) { + List.push( + mock({ + uuid: "@uuid", + image: `https://picsum.photos/300/600?random=${num++}`, + title: "@ctitle", + description: "@csentence", + link: "https://www.baidu.com", + price: "@integer(100, 500)", + "status|1": [1, 0], + "isRecommend|1": [1, 0], + }) + ); +} + +module.exports = [ + { + url: "/goodsList/getList", + type: "post", + response(config) { + const { title = "", pageNo = 1, pageSize = 20 } = config.body; + let mockList = List.filter((item) => { + if (title && item.title.indexOf(title) < 0) return false; + return true; + }); + const pageList = mockList.filter( + (item, index) => + index < pageSize * pageNo && index >= pageSize * (pageNo - 1) + ); + return { + code: 200, + msg: "success", + totalCount: count, + data: pageList, + }; + }, + }, +]; diff --git a/mock/controller/icon.js b/mock/controller/icon.js new file mode 100644 index 0000000..b772706 --- /dev/null +++ b/mock/controller/icon.js @@ -0,0 +1,989 @@ +const data = [ + "ad", + "address-book", + "address-card", + "adjust", + "air-freshener", + "align-center", + "align-justify", + "align-left", + "align-right", + "allergies", + "ambulance", + "american-sign-language-interpreting", + "anchor", + "angle-double-down", + "angle-double-left", + "angle-double-right", + "angle-double-up", + "angle-down", + "angle-left", + "angle-right", + "angle-up", + "angry", + "ankh", + "apple-alt", + "archive", + "archway", + "arrow-alt-circle-down", + "arrow-alt-circle-left", + "arrow-alt-circle-right", + "arrow-alt-circle-up", + "arrow-circle-down", + "arrow-circle-left", + "arrow-circle-right", + "arrow-circle-up", + "arrow-down", + "arrow-left", + "arrow-right", + "arrow-up", + "arrows-alt", + "arrows-alt-h", + "arrows-alt-v", + "assistive-listening-systems", + "asterisk", + "at", + "atlas", + "atom", + "audio-description", + "award", + "baby", + "baby-carriage", + "backspace", + "backward", + "bacon", + "bahai", + "balance-scale", + "balance-scale-left", + "balance-scale-right", + "ban", + "band-aid", + "barcode", + "bars", + "baseball-ball", + "basketball-ball", + "bath", + "battery-empty", + "battery-full", + "battery-half", + "battery-quarter", + "battery-three-quarters", + "bed", + "beer", + "bell", + "bell-slash", + "bezier-curve", + "bible", + "bicycle", + "biking", + "binoculars", + "biohazard", + "birthday-cake", + "blender", + "blender-phone", + "blind", + "blog", + "bold", + "bolt", + "bomb", + "bone", + "bong", + "book", + "book-dead", + "book-medical", + "book-open", + "book-reader", + "bookmark", + "border-all", + "border-none", + "border-style", + "bowling-ball", + "box", + "box-open", + "boxes", + "braille", + "brain", + "bread-slice", + "briefcase", + "briefcase-medical", + "broadcast-tower", + "broom", + "brush", + "bug", + "building", + "bullhorn", + "bullseye", + "burn", + "bus", + "bus-alt", + "business-time", + "calculator", + "calendar", + "calendar-alt", + "calendar-check", + "calendar-day", + "calendar-minus", + "calendar-plus", + "calendar-times", + "calendar-week", + "camera", + "camera-retro", + "campground", + "candy-cane", + "cannabis", + "capsules", + "car", + "car-alt", + "car-battery", + "car-crash", + "car-side", + "caravan", + "caret-down", + "caret-left", + "caret-right", + "caret-square-down", + "caret-square-left", + "caret-square-right", + "caret-square-up", + "caret-up", + "carrot", + "cart-arrow-down", + "cart-plus", + "cash-register", + "cat", + "certificate", + "chair", + "chalkboard", + "chalkboard-teacher", + "charging-station", + "chart-area", + "chart-bar", + "chart-line", + "chart-pie", + "check", + "check-circle", + "check-double", + "check-square", + "cheese", + "chess", + "chess-bishop", + "chess-board", + "chess-king", + "chess-knight", + "chess-pawn", + "chess-queen", + "chess-rook", + "chevron-circle-down", + "chevron-circle-left", + "chevron-circle-right", + "chevron-circle-up", + "chevron-down", + "chevron-left", + "chevron-right", + "chevron-up", + "child", + "church", + "circle", + "circle-notch", + "city", + "clinic-medical", + "clipboard", + "clipboard-check", + "clipboard-list", + "clock", + "clone", + "closed-captioning", + "cloud", + "cloud-download-alt", + "cloud-meatball", + "cloud-moon", + "cloud-moon-rain", + "cloud-rain", + "cloud-showers-heavy", + "cloud-sun", + "cloud-sun-rain", + "cloud-upload-alt", + "cocktail", + "code", + "code-branch", + "coffee", + "cog", + "cogs", + "coins", + "columns", + "comment", + "comment-alt", + "comment-dollar", + "comment-dots", + "comment-medical", + "comment-slash", + "comments", + "comments-dollar", + "compact-disc", + "compass", + "compress", + "compress-alt", + "compress-arrows-alt", + "concierge-bell", + "cookie", + "cookie-bite", + "copy", + "copyright", + "couch", + "credit-card", + "crop", + "crop-alt", + "cross", + "crosshairs", + "crow", + "crown", + "crutch", + "cube", + "cubes", + "cut", + "database", + "deaf", + "democrat", + "desktop", + "dharmachakra", + "diagnoses", + "dice", + "dice-d20", + "dice-d6", + "dice-five", + "dice-four", + "dice-one", + "dice-six", + "dice-three", + "dice-two", + "digital-tachograph", + "directions", + "divide", + "dizzy", + "dna", + "dog", + "dollar-sign", + "dolly", + "dolly-flatbed", + "donate", + "door-closed", + "door-open", + "dot-circle", + "dove", + "download", + "drafting-compass", + "dragon", + "draw-polygon", + "drum", + "drum-steelpan", + "drumstick-bite", + "dumbbell", + "dumpster", + "dumpster-fire", + "dungeon", + "edit", + "egg", + "eject", + "ellipsis-h", + "ellipsis-v", + "envelope", + "envelope-open", + "envelope-open-text", + "envelope-square", + "equals", + "eraser", + "ethernet", + "euro-sign", + "exchange-alt", + "exclamation", + "exclamation-circle", + "exclamation-triangle", + "expand", + "expand-alt", + "expand-arrows-alt", + "external-link-alt", + "external-link-square-alt", + "eye", + "eye-dropper", + "eye-slash", + "fan", + "fast-backward", + "fast-forward", + "fax", + "feather", + "feather-alt", + "female", + "fighter-jet", + "file", + "file-alt", + "file-archive", + "file-audio", + "file-code", + "file-contract", + "file-csv", + "file-download", + "file-excel", + "file-export", + "file-image", + "file-import", + "file-invoice", + "file-invoice-dollar", + "file-medical", + "file-medical-alt", + "file-pdf", + "file-powerpoint", + "file-prescription", + "file-signature", + "file-upload", + "file-video", + "file-word", + "fill", + "fill-drip", + "film", + "filter", + "fingerprint", + "fire", + "fire-alt", + "fire-extinguisher", + "first-aid", + "fish", + "fist-raised", + "flag", + "flag-checkered", + "flag-usa", + "flask", + "flushed", + "folder", + "folder-minus", + "folder-open", + "folder-plus", + "font", + "football-ball", + "forward", + "frog", + "frown", + "frown-open", + "funnel-dollar", + "futbol", + "gamepad", + "gas-pump", + "gavel", + "gem", + "genderless", + "ghost", + "gift", + "gifts", + "glass-cheers", + "glass-martini", + "glass-martini-alt", + "glass-whiskey", + "glasses", + "globe", + "globe-africa", + "globe-americas", + "globe-asia", + "globe-europe", + "golf-ball", + "gopuram", + "graduation-cap", + "greater-than", + "greater-than-equal", + "grimace", + "grin", + "grin-alt", + "grin-beam", + "grin-beam-sweat", + "grin-hearts", + "grin-squint", + "grin-squint-tears", + "grin-stars", + "grin-tears", + "grin-tongue", + "grin-tongue-squint", + "grin-tongue-wink", + "grin-wink", + "grip-horizontal", + "grip-lines", + "grip-lines-vertical", + "grip-vertical", + "guitar", + "h-square", + "hamburger", + "hammer", + "hamsa", + "hand-holding", + "hand-holding-heart", + "hand-holding-usd", + "hand-lizard", + "hand-middle-finger", + "hand-paper", + "hand-peace", + "hand-point-down", + "hand-point-left", + "hand-point-right", + "hand-point-up", + "hand-pointer", + "hand-rock", + "hand-scissors", + "hand-spock", + "hands", + "hands-helping", + "handshake", + "hanukiah", + "hard-hat", + "hashtag", + "hat-cowboy", + "hat-cowboy-side", + "hat-wizard", + "hdd", + "heading", + "headphones", + "headphones-alt", + "headset", + "heart", + "heart-broken", + "heartbeat", + "helicopter", + "highlighter", + "hiking", + "hippo", + "history", + "hockey-puck", + "holly-berry", + "home", + "horse", + "horse-head", + "hospital", + "hospital-alt", + "hospital-symbol", + "hot-tub", + "hotdog", + "hotel", + "hourglass", + "hourglass-end", + "hourglass-half", + "hourglass-start", + "house-damage", + "hryvnia", + "i-cursor", + "ice-cream", + "icicles", + "icons", + "id-badge", + "id-card", + "id-card-alt", + "igloo", + "image", + "images", + "inbox", + "indent", + "industry", + "infinity", + "info", + "info-circle", + "italic", + "jedi", + "joint", + "journal-whills", + "kaaba", + "key", + "keyboard", + "khanda", + "kiss", + "kiss-beam", + "kiss-wink-heart", + "kiwi-bird", + "landmark", + "language", + "laptop", + "laptop-code", + "laptop-medical", + "laugh", + "laugh-beam", + "laugh-squint", + "laugh-wink", + "layer-group", + "leaf", + "lemon", + "less-than", + "less-than-equal", + "level-down-alt", + "level-up-alt", + "life-ring", + "lightbulb", + "link", + "lira-sign", + "list", + "list-alt", + "list-ol", + "list-ul", + "location-arrow", + "lock", + "lock-open", + "long-arrow-alt-down", + "long-arrow-alt-left", + "long-arrow-alt-right", + "long-arrow-alt-up", + "low-vision", + "luggage-cart", + "magic", + "magnet", + "mail-bulk", + "male", + "map", + "map-marked", + "map-marked-alt", + "map-marker", + "map-marker-alt", + "map-pin", + "map-signs", + "marker", + "mars", + "mars-double", + "mars-stroke", + "mars-stroke-h", + "mars-stroke-v", + "mask", + "medal", + "medkit", + "meh", + "meh-blank", + "meh-rolling-eyes", + "memory", + "menorah", + "mercury", + "meteor", + "microchip", + "microphone", + "microphone-alt", + "microphone-alt-slash", + "microphone-slash", + "microscope", + "minus", + "minus-circle", + "minus-square", + "mitten", + "mobile", + "mobile-alt", + "money-bill", + "money-bill-alt", + "money-bill-wave", + "money-bill-wave-alt", + "money-check", + "money-check-alt", + "monument", + "moon", + "mortar-pestle", + "mosque", + "motorcycle", + "mountain", + "mouse", + "mouse-pointer", + "mug-hot", + "music", + "network-wired", + "neuter", + "newspaper", + "not-equal", + "notes-medical", + "object-group", + "object-ungroup", + "oil-can", + "om", + "otter", + "outdent", + "pager", + "paint-brush", + "paint-roller", + "palette", + "pallet", + "paper-plane", + "paperclip", + "parachute-box", + "paragraph", + "parking", + "passport", + "pastafarianism", + "paste", + "pause", + "pause-circle", + "paw", + "peace", + "pen", + "pen-alt", + "pen-fancy", + "pen-nib", + "pen-square", + "pencil-alt", + "pencil-ruler", + "people-carry", + "pepper-hot", + "percent", + "percentage", + "person-booth", + "phone", + "phone-alt", + "phone-slash", + "phone-square", + "phone-square-alt", + "phone-volume", + "photo-video", + "piggy-bank", + "pills", + "pizza-slice", + "place-of-worship", + "plane", + "plane-arrival", + "plane-departure", + "play", + "play-circle", + "plug", + "plus", + "plus-circle", + "plus-square", + "podcast", + "poll", + "poll-h", + "poo", + "poo-storm", + "poop", + "portrait", + "pound-sign", + "power-off", + "pray", + "praying-hands", + "prescription", + "prescription-bottle", + "prescription-bottle-alt", + "print", + "procedures", + "project-diagram", + "puzzle-piece", + "qrcode", + "question", + "question-circle", + "quidditch", + "quote-left", + "quote-right", + "quran", + "radiation", + "radiation-alt", + "rainbow", + "random", + "receipt", + "record-vinyl", + "recycle", + "redo", + "redo-alt", + "registered", + "remove-format", + "reply", + "reply-all", + "republican", + "restroom", + "retweet", + "ribbon", + "ring", + "road", + "robot", + "rocket", + "route", + "rss", + "rss-square", + "ruble-sign", + "ruler", + "ruler-combined", + "ruler-horizontal", + "ruler-vertical", + "running", + "rupee-sign", + "sad-cry", + "sad-tear", + "satellite", + "satellite-dish", + "save", + "school", + "screwdriver", + "scroll", + "sd-card", + "search", + "search-dollar", + "search-location", + "search-minus", + "search-plus", + "seedling", + "server", + "shapes", + "share", + "share-alt", + "share-alt-square", + "share-square", + "shekel-sign", + "shield-alt", + "ship", + "shipping-fast", + "shoe-prints", + "shopping-bag", + "shopping-basket", + "shopping-cart", + "shower", + "shuttle-van", + "sign", + "sign-in-alt", + "sign-language", + "sign-out-alt", + "signal", + "signature", + "sim-card", + "sitemap", + "skating", + "skiing", + "skiing-nordic", + "skull", + "skull-crossbones", + "slash", + "sleigh", + "sliders-h", + "smile", + "smile-beam", + "smile-wink", + "smog", + "smoking", + "smoking-ban", + "sms", + "snowboarding", + "snowflake", + "snowman", + "snowplow", + "socks", + "solar-panel", + "sort", + "sort-alpha-down", + "sort-alpha-down-alt", + "sort-alpha-up", + "sort-alpha-up-alt", + "sort-amount-down", + "sort-amount-down-alt", + "sort-amount-up", + "sort-amount-up-alt", + "sort-down", + "sort-numeric-down", + "sort-numeric-down-alt", + "sort-numeric-up", + "sort-numeric-up-alt", + "sort-up", + "spa", + "space-shuttle", + "spell-check", + "spider", + "spinner", + "splotch", + "spray-can", + "square", + "square-full", + "square-root-alt", + "stamp", + "star", + "star-and-crescent", + "star-half", + "star-half-alt", + "star-of-david", + "star-of-life", + "step-backward", + "step-forward", + "stethoscope", + "sticky-note", + "stop", + "stop-circle", + "stopwatch", + "store", + "store-alt", + "stream", + "street-view", + "strikethrough", + "stroopwafel", + "subscript", + "subway", + "suitcase", + "suitcase-rolling", + "sun", + "superscript", + "surprise", + "swatchbook", + "swimmer", + "swimming-pool", + "synagogue", + "sync", + "sync-alt", + "syringe", + "table", + "table-tennis", + "tablet", + "tablet-alt", + "tablets", + "tachometer-alt", + "tag", + "tags", + "tape", + "tasks", + "taxi", + "teeth", + "teeth-open", + "temperature-high", + "temperature-low", + "tenge", + "terminal", + "text-height", + "text-width", + "th", + "th-large", + "th-list", + "theater-masks", + "thermometer", + "thermometer-empty", + "thermometer-full", + "thermometer-half", + "thermometer-quarter", + "thermometer-three-quarters", + "thumbs-down", + "thumbs-up", + "thumbtack", + "ticket-alt", + "times", + "times-circle", + "tint", + "tint-slash", + "tired", + "toggle-off", + "toggle-on", + "toilet", + "toilet-paper", + "toolbox", + "tools", + "tooth", + "torah", + "torii-gate", + "tractor", + "trademark", + "traffic-light", + "trailer", + "train", + "tram", + "transgender", + "transgender-alt", + "trash", + "trash-alt", + "trash-restore", + "trash-restore-alt", + "tree", + "trophy", + "truck", + "truck-loading", + "truck-monster", + "truck-moving", + "truck-pickup", + "tshirt", + "tty", + "tv", + "umbrella", + "umbrella-beach", + "underline", + "undo", + "undo-alt", + "universal-access", + "university", + "unlink", + "unlock", + "unlock-alt", + "upload", + "user", + "user-alt", + "user-alt-slash", + "user-astronaut", + "user-check", + "user-circle", + "user-clock", + "user-cog", + "user-edit", + "user-friends", + "user-graduate", + "user-injured", + "user-lock", + "user-md", + "user-minus", + "user-ninja", + "user-nurse", + "user-plus", + "user-secret", + "user-shield", + "user-slash", + "user-tag", + "user-tie", + "user-times", + "users", + "users-cog", + "utensil-spoon", + "utensils", + "vector-square", + "venus", + "venus-double", + "venus-mars", + "vial", + "vials", + "video", + "video-slash", + "vihara", + "voicemail", + "volleyball-ball", + "volume-down", + "volume-mute", + "volume-off", + "volume-up", + "vote-yea", + "vr-cardboard", + "walking", + "wallet", + "warehouse", + "water", + "wave-square", + "weight", + "weight-hanging", + "wheelchair", + "wifi", + "wind", + "window-close", + "window-maximize", + "window-minimize", + "window-restore", + "wine-bottle", + "wine-glass", + "wine-glass-alt", + "won-sign", + "wrench", + "x-ray", + "yen-sign", + "yin-yang", +]; +module.exports = [ + { + url: "/icon/getList", + type: "post", + response(config) { + const { title, pageNo = 1, pageSize = 72 } = config.body; + let mockList = data.filter((item) => { + if (title && item.indexOf(title) < 0) return false; + return true; + }); + const pageList = mockList.filter( + (item, index) => + index < pageSize * pageNo && index >= pageSize * (pageNo - 1) + ); + return { + code: 200, + msg: "success", + totalCount: mockList.length, + data: pageList, + }; + }, + }, +]; diff --git a/mock/controller/menuManagement.js b/mock/controller/menuManagement.js new file mode 100644 index 0000000..9a2520d --- /dev/null +++ b/mock/controller/menuManagement.js @@ -0,0 +1,51 @@ +module.exports = [ + { + url: "/menuManagement/getTree", + type: "post", + response(config) { + return { + code: 200, + msg: "success", + totalCount: 999, + data: [ + { + id: "root", + label: "全部角色", + children: [ + { + id: "@id", + permission: "admin", + label: "admin角色", + }, + { + id: "@id", + permission: "editor", + label: "editor角色", + }, + ], + }, + ], + }; + }, + }, + { + url: "/menuManagement/doEdit", + type: "post", + response(config) { + return { + code: 200, + msg: "模拟保存成功", + }; + }, + }, + { + url: "/menuManagement/doDelete", + type: "post", + response(config) { + return { + code: 200, + msg: "模拟删除成功", + }; + }, + }, +]; diff --git a/mock/controller/notice.js b/mock/controller/notice.js new file mode 100644 index 0000000..8ab5c6f --- /dev/null +++ b/mock/controller/notice.js @@ -0,0 +1,38 @@ +const data = [ + { + title: "究竟是什么样的终点,才配得上这一路的颠沛流离。。。", + closable: false, + type: "success", + }, + { + title: + "作者寄语:感谢Star,感恩相遇,愿世间美好与我们环环相扣,加油!屏幕前的我们,打破桎梏,坚守初心。其实人生改变命运的机会并没有太多,我们并不是不优秀,我们也并不是一无是处,我们也希望驻足山巅被众人仰望,也许我们缺少的只是一个机会,缺少的只是生命中的导师,我希望这个框架帮助到更多的人,希望有一天,我们面试的时候不再胆怯,希望有一天别人看到的不仅仅是你的努力,还有你的功成名就,出人头地。", + closable: false, + type: "warning", + }, + { + title: + "鸣谢:尤雨溪、蒋豪群、element-ui、唐金州、花裤衩、贤心、iView、uView的开源项目给我带来的很多的灵感,弱小的人才习惯嘲讽与否定,内心强大的人从不吝啬赞美与鼓励,人生在世,得到每个人的认可几乎是痴心妄想,我也只是一条略懂前端的咸鱼,可我仍一直怀揣着改变世界的梦想,希望我们每个人,不管过程怎样,结局都是美好的。", + closable: false, + type: "success", + }, + { + title: + "随笔:我一直在寻找开源的真谛,我一直再想什么是开源,我一开始觉得免费就是开源,好像又不是。我理解的开源是:你也开源,我也开源,大家一起贡献,相互帮助。我最担心的事情是:我一个小人物,去伺候一众的伸手党,我想,这不是开源该有的氛围。我还太年轻,不懂什么是格局,我只知道,无私的帮助他人,能给我带来快乐,却不能给我带来收入,当然,有时候,快乐对我来说就已经足够了。可惜我是一个人,没有精力帮助到每一个人,可惜这个世界需要赚钱,才能过上平凡的生活,可惜了我的梦想,这个物欲横流的时代,理想主义的我们,即使内心坚决如铁,也似乎寸步难行。", + closable: false, + type: "success", + }, +]; +module.exports = [ + { + url: "/notice/getList", + type: "post", + response() { + return { + code: 200, + msg: "success", + data, + }; + }, + }, +]; diff --git a/mock/controller/personalCenter.js b/mock/controller/personalCenter.js new file mode 100644 index 0000000..776969f --- /dev/null +++ b/mock/controller/personalCenter.js @@ -0,0 +1,42 @@ +const { mock } = require("mockjs"); + +module.exports = [ + { + url: "/personalCenter/getList", + type: "post", + response(config) { + return { + code: 200, + msg: "success", + totalCount: 999, + data: mock({ + "data|10": [ + { + id: "@id", + }, + ], + }).data, + }; + }, + }, + { + url: "/personalCenter/doEdit", + type: "post", + response(config) { + return { + code: 200, + msg: "模拟保存成功", + }; + }, + }, + { + url: "/personalCenter/doDelete", + type: "post", + response(config) { + return { + code: 200, + msg: "模拟删除成功", + }; + }, + }, +]; diff --git a/mock/controller/remixIcon.js b/mock/controller/remixIcon.js new file mode 100644 index 0000000..abe57eb --- /dev/null +++ b/mock/controller/remixIcon.js @@ -0,0 +1,2296 @@ +const data = [ + "24-hours-fill", + "24-hours-line", + "4k-fill", + "4k-line", + "a-b", + "account-box-fill", + "account-box-line", + "account-circle-fill", + "account-circle-line", + "account-pin-box-fill", + "account-pin-box-line", + "account-pin-circle-fill", + "account-pin-circle-line", + "add-box-fill", + "add-box-line", + "add-circle-fill", + "add-circle-line", + "add-fill", + "add-line", + "admin-fill", + "admin-line", + "advertisement-fill", + "advertisement-line", + "airplay-fill", + "airplay-line", + "alarm-fill", + "alarm-line", + "alarm-warning-fill", + "alarm-warning-line", + "album-fill", + "album-line", + "alert-fill", + "alert-line", + "aliens-fill", + "aliens-line", + "align-bottom", + "align-center", + "align-justify", + "align-left", + "align-right", + "align-top", + "align-vertically", + "alipay-fill", + "alipay-line", + "amazon-fill", + "amazon-line", + "anchor-fill", + "anchor-line", + "ancient-gate-fill", + "ancient-gate-line", + "ancient-pavilion-fill", + "ancient-pavilion-line", + "android-fill", + "android-line", + "angularjs-fill", + "angularjs-line", + "anticlockwise-2-fill", + "anticlockwise-2-line", + "anticlockwise-fill", + "anticlockwise-line", + "app-store-fill", + "app-store-line", + "apple-fill", + "apple-line", + "apps-2-fill", + "apps-2-line", + "apps-fill", + "apps-line", + "archive-drawer-fill", + "archive-drawer-line", + "archive-fill", + "archive-line", + "arrow-down-circle-fill", + "arrow-down-circle-line", + "arrow-down-fill", + "arrow-down-line", + "arrow-down-s-fill", + "arrow-down-s-line", + "arrow-drop-down-fill", + "arrow-drop-down-line", + "arrow-drop-left-fill", + "arrow-drop-left-line", + "arrow-drop-right-fill", + "arrow-drop-right-line", + "arrow-drop-up-fill", + "arrow-drop-up-line", + "arrow-go-back-fill", + "arrow-go-back-line", + "arrow-go-forward-fill", + "arrow-go-forward-line", + "arrow-left-circle-fill", + "arrow-left-circle-line", + "arrow-left-down-fill", + "arrow-left-down-line", + "arrow-left-fill", + "arrow-left-line", + "arrow-left-right-fill", + "arrow-left-right-line", + "arrow-left-s-fill", + "arrow-left-s-line", + "arrow-left-up-fill", + "arrow-left-up-line", + "arrow-right-circle-fill", + "arrow-right-circle-line", + "arrow-right-down-fill", + "arrow-right-down-line", + "arrow-right-fill", + "arrow-right-line", + "arrow-right-s-fill", + "arrow-right-s-line", + "arrow-right-up-fill", + "arrow-right-up-line", + "arrow-up-circle-fill", + "arrow-up-circle-line", + "arrow-up-down-fill", + "arrow-up-down-line", + "arrow-up-fill", + "arrow-up-line", + "arrow-up-s-fill", + "arrow-up-s-line", + "artboard-2-fill", + "artboard-2-line", + "artboard-fill", + "artboard-line", + "article-fill", + "article-line", + "aspect-ratio-fill", + "aspect-ratio-line", + "asterisk", + "at-fill", + "at-line", + "attachment-2", + "attachment-fill", + "attachment-line", + "auction-fill", + "auction-line", + "award-fill", + "award-line", + "baidu-fill", + "baidu-line", + "ball-pen-fill", + "ball-pen-line", + "bank-card-2-fill", + "bank-card-2-line", + "bank-card-fill", + "bank-card-line", + "bank-fill", + "bank-line", + "bar-chart-2-fill", + "bar-chart-2-line", + "bar-chart-box-fill", + "bar-chart-box-line", + "bar-chart-fill", + "bar-chart-grouped-fill", + "bar-chart-grouped-line", + "bar-chart-horizontal-fill", + "bar-chart-horizontal-line", + "bar-chart-line", + "barcode-box-fill", + "barcode-box-line", + "barcode-fill", + "barcode-line", + "barricade-fill", + "barricade-line", + "base-station-fill", + "base-station-line", + "basketball-fill", + "basketball-line", + "battery-2-charge-fill", + "battery-2-charge-line", + "battery-2-fill", + "battery-2-line", + "battery-charge-fill", + "battery-charge-line", + "battery-fill", + "battery-line", + "battery-low-fill", + "battery-low-line", + "battery-saver-fill", + "battery-saver-line", + "battery-share-fill", + "battery-share-line", + "bear-smile-fill", + "bear-smile-line", + "behance-fill", + "behance-line", + "bell-fill", + "bell-line", + "bike-fill", + "bike-line", + "bilibili-fill", + "bilibili-line", + "bill-fill", + "bill-line", + "billiards-fill", + "billiards-line", + "bit-coin-fill", + "bit-coin-line", + "blaze-fill", + "blaze-line", + "bluetooth-connect-fill", + "bluetooth-connect-line", + "bluetooth-fill", + "bluetooth-line", + "blur-off-fill", + "blur-off-line", + "body-scan-fill", + "body-scan-line", + "bold", + "book-2-fill", + "book-2-line", + "book-3-fill", + "book-3-line", + "book-fill", + "book-line", + "book-mark-fill", + "book-mark-line", + "book-open-fill", + "book-open-line", + "book-read-fill", + "book-read-line", + "booklet-fill", + "booklet-line", + "bookmark-2-fill", + "bookmark-2-line", + "bookmark-3-fill", + "bookmark-3-line", + "bookmark-fill", + "bookmark-line", + "boxing-fill", + "boxing-line", + "braces-fill", + "braces-line", + "brackets-fill", + "brackets-line", + "briefcase-2-fill", + "briefcase-2-line", + "briefcase-3-fill", + "briefcase-3-line", + "briefcase-4-fill", + "briefcase-4-line", + "briefcase-5-fill", + "briefcase-5-line", + "briefcase-fill", + "briefcase-line", + "bring-forward", + "bring-to-front", + "broadcast-fill", + "broadcast-line", + "brush-2-fill", + "brush-2-line", + "brush-3-fill", + "brush-3-line", + "brush-4-fill", + "brush-4-line", + "brush-fill", + "brush-line", + "bubble-chart-fill", + "bubble-chart-line", + "bug-2-fill", + "bug-2-line", + "bug-fill", + "bug-line", + "building-2-fill", + "building-2-line", + "building-3-fill", + "building-3-line", + "building-4-fill", + "building-4-line", + "building-fill", + "building-line", + "bus-2-fill", + "bus-2-line", + "bus-fill", + "bus-line", + "bus-wifi-fill", + "bus-wifi-line", + "cactus-fill", + "cactus-line", + "cake-2-fill", + "cake-2-line", + "cake-3-fill", + "cake-3-line", + "cake-fill", + "cake-line", + "calculator-fill", + "calculator-line", + "calendar-2-fill", + "calendar-2-line", + "calendar-check-fill", + "calendar-check-line", + "calendar-event-fill", + "calendar-event-line", + "calendar-fill", + "calendar-line", + "calendar-todo-fill", + "calendar-todo-line", + "camera-2-fill", + "camera-2-line", + "camera-3-fill", + "camera-3-line", + "camera-fill", + "camera-lens-fill", + "camera-lens-line", + "camera-line", + "camera-off-fill", + "camera-off-line", + "camera-switch-fill", + "camera-switch-line", + "capsule-fill", + "capsule-line", + "car-fill", + "car-line", + "car-washing-fill", + "car-washing-line", + "caravan-fill", + "caravan-line", + "cast-fill", + "cast-line", + "cellphone-fill", + "cellphone-line", + "celsius-fill", + "celsius-line", + "centos-fill", + "centos-line", + "character-recognition-fill", + "character-recognition-line", + "charging-pile-2-fill", + "charging-pile-2-line", + "charging-pile-fill", + "charging-pile-line", + "chat-1-fill", + "chat-1-line", + "chat-2-fill", + "chat-2-line", + "chat-3-fill", + "chat-3-line", + "chat-4-fill", + "chat-4-line", + "chat-check-fill", + "chat-check-line", + "chat-delete-fill", + "chat-delete-line", + "chat-download-fill", + "chat-download-line", + "chat-follow-up-fill", + "chat-follow-up-line", + "chat-forward-fill", + "chat-forward-line", + "chat-heart-fill", + "chat-heart-line", + "chat-history-fill", + "chat-history-line", + "chat-new-fill", + "chat-new-line", + "chat-off-fill", + "chat-off-line", + "chat-poll-fill", + "chat-poll-line", + "chat-private-fill", + "chat-private-line", + "chat-quote-fill", + "chat-quote-line", + "chat-settings-fill", + "chat-settings-line", + "chat-smile-2-fill", + "chat-smile-2-line", + "chat-smile-3-fill", + "chat-smile-3-line", + "chat-smile-fill", + "chat-smile-line", + "chat-upload-fill", + "chat-upload-line", + "chat-voice-fill", + "chat-voice-line", + "check-double-fill", + "check-double-line", + "check-fill", + "check-line", + "checkbox-blank-circle-fill", + "checkbox-blank-circle-line", + "checkbox-blank-fill", + "checkbox-blank-line", + "checkbox-circle-fill", + "checkbox-circle-line", + "checkbox-fill", + "checkbox-indeterminate-fill", + "checkbox-indeterminate-line", + "checkbox-line", + "checkbox-multiple-blank-fill", + "checkbox-multiple-blank-line", + "checkbox-multiple-fill", + "checkbox-multiple-line", + "china-railway-fill", + "china-railway-line", + "chrome-fill", + "chrome-line", + "clapperboard-fill", + "clapperboard-line", + "clipboard-fill", + "clipboard-line", + "clockwise-2-fill", + "clockwise-2-line", + "clockwise-fill", + "clockwise-line", + "close-circle-fill", + "close-circle-line", + "close-fill", + "close-line", + "closed-captioning-fill", + "closed-captioning-line", + "cloud-fill", + "cloud-line", + "cloud-off-fill", + "cloud-off-line", + "cloud-windy-fill", + "cloud-windy-line", + "cloudy-2-fill", + "cloudy-2-line", + "cloudy-fill", + "cloudy-line", + "code-box-fill", + "code-box-line", + "code-fill", + "code-line", + "code-s-fill", + "code-s-line", + "code-s-slash-fill", + "code-s-slash-line", + "code-view", + "codepen-fill", + "codepen-line", + "coin-fill", + "coin-line", + "coins-fill", + "coins-line", + "collage-fill", + "collage-line", + "command-fill", + "command-line", + "community-fill", + "community-line", + "compass-2-fill", + "compass-2-line", + "compass-3-fill", + "compass-3-line", + "compass-4-fill", + "compass-4-line", + "compass-discover-fill", + "compass-discover-line", + "compass-fill", + "compass-line", + "compasses-2-fill", + "compasses-2-line", + "compasses-fill", + "compasses-line", + "computer-fill", + "computer-line", + "contacts-book-2-fill", + "contacts-book-2-line", + "contacts-book-fill", + "contacts-book-line", + "contacts-book-upload-fill", + "contacts-book-upload-line", + "contacts-fill", + "contacts-line", + "contrast-2-fill", + "contrast-2-line", + "contrast-drop-2-fill", + "contrast-drop-2-line", + "contrast-drop-fill", + "contrast-drop-line", + "contrast-fill", + "contrast-line", + "copper-coin-fill", + "copper-coin-line", + "copper-diamond-fill", + "copper-diamond-line", + "copyleft-fill", + "copyleft-line", + "copyright-fill", + "copyright-line", + "coreos-fill", + "coreos-line", + "coupon-2-fill", + "coupon-2-line", + "coupon-3-fill", + "coupon-3-line", + "coupon-4-fill", + "coupon-4-line", + "coupon-5-fill", + "coupon-5-line", + "coupon-fill", + "coupon-line", + "cpu-fill", + "cpu-line", + "creative-commons-by-fill", + "creative-commons-by-line", + "creative-commons-fill", + "creative-commons-line", + "creative-commons-nc-fill", + "creative-commons-nc-line", + "creative-commons-nd-fill", + "creative-commons-nd-line", + "creative-commons-sa-fill", + "creative-commons-sa-line", + "creative-commons-zero-fill", + "creative-commons-zero-line", + "criminal-fill", + "criminal-line", + "crop-2-fill", + "crop-2-line", + "crop-fill", + "crop-line", + "css3-fill", + "css3-line", + "cup-fill", + "cup-line", + "currency-fill", + "currency-line", + "cursor-fill", + "cursor-line", + "customer-service-2-fill", + "customer-service-2-line", + "customer-service-fill", + "customer-service-line", + "dashboard-2-fill", + "dashboard-2-line", + "dashboard-3-fill", + "dashboard-3-line", + "dashboard-fill", + "dashboard-line", + "database-2-fill", + "database-2-line", + "database-fill", + "database-line", + "delete-back-2-fill", + "delete-back-2-line", + "delete-back-fill", + "delete-back-line", + "delete-bin-2-fill", + "delete-bin-2-line", + "delete-bin-3-fill", + "delete-bin-3-line", + "delete-bin-4-fill", + "delete-bin-4-line", + "delete-bin-5-fill", + "delete-bin-5-line", + "delete-bin-6-fill", + "delete-bin-6-line", + "delete-bin-7-fill", + "delete-bin-7-line", + "delete-bin-fill", + "delete-bin-line", + "delete-column", + "delete-row", + "device-fill", + "device-line", + "device-recover-fill", + "device-recover-line", + "dingding-fill", + "dingding-line", + "direction-fill", + "direction-line", + "disc-fill", + "disc-line", + "discord-fill", + "discord-line", + "discuss-fill", + "discuss-line", + "dislike-fill", + "dislike-line", + "disqus-fill", + "disqus-line", + "divide-fill", + "divide-line", + "donut-chart-fill", + "donut-chart-line", + "door-closed-fill", + "door-closed-line", + "door-fill", + "door-line", + "door-lock-box-fill", + "door-lock-box-line", + "door-lock-fill", + "door-lock-line", + "door-open-fill", + "door-open-line", + "dossier-fill", + "dossier-line", + "douban-fill", + "douban-line", + "double-quotes-l", + "double-quotes-r", + "download-2-fill", + "download-2-line", + "download-cloud-2-fill", + "download-cloud-2-line", + "download-cloud-fill", + "download-cloud-line", + "download-fill", + "download-line", + "draft-fill", + "draft-line", + "drag-drop-fill", + "drag-drop-line", + "drag-move-2-fill", + "drag-move-2-line", + "drag-move-fill", + "drag-move-line", + "dribbble-fill", + "dribbble-line", + "drive-fill", + "drive-line", + "drizzle-fill", + "drizzle-line", + "drop-fill", + "drop-line", + "dropbox-fill", + "dropbox-line", + "dual-sim-1-fill", + "dual-sim-1-line", + "dual-sim-2-fill", + "dual-sim-2-line", + "dv-fill", + "dv-line", + "dvd-fill", + "dvd-line", + "e-bike-2-fill", + "e-bike-2-line", + "e-bike-fill", + "e-bike-line", + "earth-fill", + "earth-line", + "earthquake-fill", + "earthquake-line", + "edge-fill", + "edge-line", + "edit-2-fill", + "edit-2-line", + "edit-box-fill", + "edit-box-line", + "edit-circle-fill", + "edit-circle-line", + "edit-fill", + "edit-line", + "eject-fill", + "eject-line", + "emotion-2-fill", + "emotion-2-line", + "emotion-fill", + "emotion-happy-fill", + "emotion-happy-line", + "emotion-laugh-fill", + "emotion-laugh-line", + "emotion-line", + "emotion-normal-fill", + "emotion-normal-line", + "emotion-sad-fill", + "emotion-sad-line", + "emotion-unhappy-fill", + "emotion-unhappy-line", + "empathize-fill", + "empathize-line", + "emphasis-cn", + "emphasis", + "english-input", + "equalizer-fill", + "equalizer-line", + "eraser-fill", + "eraser-line", + "error-warning-fill", + "error-warning-line", + "evernote-fill", + "evernote-line", + "exchange-box-fill", + "exchange-box-line", + "exchange-cny-fill", + "exchange-cny-line", + "exchange-dollar-fill", + "exchange-dollar-line", + "exchange-fill", + "exchange-funds-fill", + "exchange-funds-line", + "exchange-line", + "external-link-fill", + "external-link-line", + "eye-2-fill", + "eye-2-line", + "eye-close-fill", + "eye-close-line", + "eye-fill", + "eye-line", + "eye-off-fill", + "eye-off-line", + "facebook-box-fill", + "facebook-box-line", + "facebook-circle-fill", + "facebook-circle-line", + "facebook-fill", + "facebook-line", + "fahrenheit-fill", + "fahrenheit-line", + "feedback-fill", + "feedback-line", + "file-2-fill", + "file-2-line", + "file-3-fill", + "file-3-line", + "file-4-fill", + "file-4-line", + "file-add-fill", + "file-add-line", + "file-chart-2-fill", + "file-chart-2-line", + "file-chart-fill", + "file-chart-line", + "file-cloud-fill", + "file-cloud-line", + "file-code-fill", + "file-code-line", + "file-copy-2-fill", + "file-copy-2-line", + "file-copy-fill", + "file-copy-line", + "file-damage-fill", + "file-damage-line", + "file-download-fill", + "file-download-line", + "file-edit-fill", + "file-edit-line", + "file-excel-2-fill", + "file-excel-2-line", + "file-excel-fill", + "file-excel-line", + "file-fill", + "file-forbid-fill", + "file-forbid-line", + "file-gif-fill", + "file-gif-line", + "file-history-fill", + "file-history-line", + "file-hwp-fill", + "file-hwp-line", + "file-info-fill", + "file-info-line", + "file-line", + "file-list-2-fill", + "file-list-2-line", + "file-list-3-fill", + "file-list-3-line", + "file-list-fill", + "file-list-line", + "file-lock-fill", + "file-lock-line", + "file-mark-fill", + "file-mark-line", + "file-music-fill", + "file-music-line", + "file-paper-2-fill", + "file-paper-2-line", + "file-paper-fill", + "file-paper-line", + "file-pdf-fill", + "file-pdf-line", + "file-ppt-2-fill", + "file-ppt-2-line", + "file-ppt-fill", + "file-ppt-line", + "file-reduce-fill", + "file-reduce-line", + "file-search-fill", + "file-search-line", + "file-settings-fill", + "file-settings-line", + "file-shield-2-fill", + "file-shield-2-line", + "file-shield-fill", + "file-shield-line", + "file-shred-fill", + "file-shred-line", + "file-text-fill", + "file-text-line", + "file-transfer-fill", + "file-transfer-line", + "file-unknow-fill", + "file-unknow-line", + "file-upload-fill", + "file-upload-line", + "file-user-fill", + "file-user-line", + "file-warning-fill", + "file-warning-line", + "file-word-2-fill", + "file-word-2-line", + "file-word-fill", + "file-word-line", + "file-zip-fill", + "file-zip-line", + "film-fill", + "film-line", + "filter-2-fill", + "filter-2-line", + "filter-3-fill", + "filter-3-line", + "filter-fill", + "filter-line", + "filter-off-fill", + "filter-off-line", + "find-replace-fill", + "find-replace-line", + "finder-fill", + "finder-line", + "fingerprint-2-fill", + "fingerprint-2-line", + "fingerprint-fill", + "fingerprint-line", + "fire-fill", + "fire-line", + "firefox-fill", + "firefox-line", + "first-aid-kit-fill", + "first-aid-kit-line", + "flag-2-fill", + "flag-2-line", + "flag-fill", + "flag-line", + "flashlight-fill", + "flashlight-line", + "flask-fill", + "flask-line", + "flight-land-fill", + "flight-land-line", + "flight-takeoff-fill", + "flight-takeoff-line", + "flood-fill", + "flood-line", + "flow-chart", + "flutter-fill", + "flutter-line", + "focus-2-fill", + "focus-2-line", + "focus-3-fill", + "focus-3-line", + "focus-fill", + "focus-line", + "foggy-fill", + "foggy-line", + "folder-2-fill", + "folder-2-line", + "folder-3-fill", + "folder-3-line", + "folder-4-fill", + "folder-4-line", + "folder-5-fill", + "folder-5-line", + "folder-add-fill", + "folder-add-line", + "folder-chart-2-fill", + "folder-chart-2-line", + "folder-chart-fill", + "folder-chart-line", + "folder-download-fill", + "folder-download-line", + "folder-fill", + "folder-forbid-fill", + "folder-forbid-line", + "folder-history-fill", + "folder-history-line", + "folder-info-fill", + "folder-info-line", + "folder-keyhole-fill", + "folder-keyhole-line", + "folder-line", + "folder-lock-fill", + "folder-lock-line", + "folder-music-fill", + "folder-music-line", + "folder-open-fill", + "folder-open-line", + "folder-received-fill", + "folder-received-line", + "folder-reduce-fill", + "folder-reduce-line", + "folder-settings-fill", + "folder-settings-line", + "folder-shared-fill", + "folder-shared-line", + "folder-shield-2-fill", + "folder-shield-2-line", + "folder-shield-fill", + "folder-shield-line", + "folder-transfer-fill", + "folder-transfer-line", + "folder-unknow-fill", + "folder-unknow-line", + "folder-upload-fill", + "folder-upload-line", + "folder-user-fill", + "folder-user-line", + "folder-warning-fill", + "folder-warning-line", + "folder-zip-fill", + "folder-zip-line", + "folders-fill", + "folders-line", + "font-color", + "font-size-2", + "font-size", + "football-fill", + "football-line", + "footprint-fill", + "footprint-line", + "forbid-2-fill", + "forbid-2-line", + "forbid-fill", + "forbid-line", + "format-clear", + "fridge-fill", + "fridge-line", + "fullscreen-exit-fill", + "fullscreen-exit-line", + "fullscreen-fill", + "fullscreen-line", + "function-fill", + "function-line", + "functions", + "funds-box-fill", + "funds-box-line", + "funds-fill", + "funds-line", + "gallery-fill", + "gallery-line", + "gallery-upload-fill", + "gallery-upload-line", + "game-fill", + "game-line", + "gamepad-fill", + "gamepad-line", + "gas-station-fill", + "gas-station-line", + "gatsby-fill", + "gatsby-line", + "genderless-fill", + "genderless-line", + "ghost-2-fill", + "ghost-2-line", + "ghost-fill", + "ghost-line", + "ghost-smile-fill", + "ghost-smile-line", + "gift-2-fill", + "gift-2-line", + "gift-fill", + "gift-line", + "git-branch-fill", + "git-branch-line", + "git-commit-fill", + "git-commit-line", + "git-merge-fill", + "git-merge-line", + "git-pull-request-fill", + "git-pull-request-line", + "git-repository-commits-fill", + "git-repository-commits-line", + "git-repository-fill", + "git-repository-line", + "git-repository-private-fill", + "git-repository-private-line", + "github-fill", + "github-line", + "gitlab-fill", + "gitlab-line", + "global-fill", + "global-line", + "globe-fill", + "globe-line", + "goblet-fill", + "goblet-line", + "google-fill", + "google-line", + "google-play-fill", + "google-play-line", + "government-fill", + "government-line", + "gps-fill", + "gps-line", + "gradienter-fill", + "gradienter-line", + "grid-fill", + "grid-line", + "group-2-fill", + "group-2-line", + "group-fill", + "group-line", + "guide-fill", + "guide-line", + "h-1", + "h-2", + "h-3", + "h-4", + "h-5", + "h-6", + "hail-fill", + "hail-line", + "hammer-fill", + "hammer-line", + "hand-coin-fill", + "hand-coin-line", + "hand-heart-fill", + "hand-heart-line", + "hand-sanitizer-fill", + "hand-sanitizer-line", + "handbag-fill", + "handbag-line", + "hard-drive-2-fill", + "hard-drive-2-line", + "hard-drive-fill", + "hard-drive-line", + "hashtag", + "haze-2-fill", + "haze-2-line", + "haze-fill", + "haze-line", + "hd-fill", + "hd-line", + "heading", + "headphone-fill", + "headphone-line", + "health-book-fill", + "health-book-line", + "heart-2-fill", + "heart-2-line", + "heart-3-fill", + "heart-3-line", + "heart-add-fill", + "heart-add-line", + "heart-fill", + "heart-line", + "heart-pulse-fill", + "heart-pulse-line", + "hearts-fill", + "hearts-line", + "heavy-showers-fill", + "heavy-showers-line", + "history-fill", + "history-line", + "home-2-fill", + "home-2-line", + "home-3-fill", + "home-3-line", + "home-4-fill", + "home-4-line", + "home-5-fill", + "home-5-line", + "home-6-fill", + "home-6-line", + "home-7-fill", + "home-7-line", + "home-8-fill", + "home-8-line", + "home-fill", + "home-gear-fill", + "home-gear-line", + "home-heart-fill", + "home-heart-line", + "home-line", + "home-smile-2-fill", + "home-smile-2-line", + "home-smile-fill", + "home-smile-line", + "home-wifi-fill", + "home-wifi-line", + "honor-of-kings-fill", + "honor-of-kings-line", + "honour-fill", + "honour-line", + "hospital-fill", + "hospital-line", + "hotel-bed-fill", + "hotel-bed-line", + "hotel-fill", + "hotel-line", + "hotspot-fill", + "hotspot-line", + "hq-fill", + "hq-line", + "html5-fill", + "html5-line", + "ie-fill", + "ie-line", + "image-2-fill", + "image-2-line", + "image-add-fill", + "image-add-line", + "image-edit-fill", + "image-edit-line", + "image-fill", + "image-line", + "inbox-archive-fill", + "inbox-archive-line", + "inbox-fill", + "inbox-line", + "inbox-unarchive-fill", + "inbox-unarchive-line", + "increase-decrease-fill", + "increase-decrease-line", + "indent-decrease", + "indent-increase", + "indeterminate-circle-fill", + "indeterminate-circle-line", + "information-fill", + "information-line", + "infrared-thermometer-fill", + "infrared-thermometer-line", + "ink-bottle-fill", + "ink-bottle-line", + "input-cursor-move", + "input-method-fill", + "input-method-line", + "insert-column-left", + "insert-column-right", + "insert-row-bottom", + "insert-row-top", + "instagram-fill", + "instagram-line", + "install-fill", + "install-line", + "invision-fill", + "invision-line", + "italic", + "kakao-talk-fill", + "kakao-talk-line", + "key-2-fill", + "key-2-line", + "key-fill", + "key-line", + "keyboard-box-fill", + "keyboard-box-line", + "keyboard-fill", + "keyboard-line", + "keynote-fill", + "keynote-line", + "knife-blood-fill", + "knife-blood-line", + "knife-fill", + "knife-line", + "landscape-fill", + "landscape-line", + "layout-2-fill", + "layout-2-line", + "layout-3-fill", + "layout-3-line", + "layout-4-fill", + "layout-4-line", + "layout-5-fill", + "layout-5-line", + "layout-6-fill", + "layout-6-line", + "layout-bottom-2-fill", + "layout-bottom-2-line", + "layout-bottom-fill", + "layout-bottom-line", + "layout-column-fill", + "layout-column-line", + "layout-fill", + "layout-grid-fill", + "layout-grid-line", + "layout-left-2-fill", + "layout-left-2-line", + "layout-left-fill", + "layout-left-line", + "layout-line", + "layout-masonry-fill", + "layout-masonry-line", + "layout-right-2-fill", + "layout-right-2-line", + "layout-right-fill", + "layout-right-line", + "layout-row-fill", + "layout-row-line", + "layout-top-2-fill", + "layout-top-2-line", + "layout-top-fill", + "layout-top-line", + "leaf-fill", + "leaf-line", + "lifebuoy-fill", + "lifebuoy-line", + "lightbulb-fill", + "lightbulb-flash-fill", + "lightbulb-flash-line", + "lightbulb-line", + "line-chart-fill", + "line-chart-line", + "line-fill", + "line-height", + "line-line", + "link-m", + "link-unlink-m", + "link-unlink", + "link", + "linkedin-box-fill", + "linkedin-box-line", + "linkedin-fill", + "linkedin-line", + "links-fill", + "links-line", + "list-check-2", + "list-check", + "list-ordered", + "list-settings-fill", + "list-settings-line", + "list-unordered", + "live-fill", + "live-line", + "loader-2-fill", + "loader-2-line", + "loader-3-fill", + "loader-3-line", + "loader-4-fill", + "loader-4-line", + "loader-5-fill", + "loader-5-line", + "loader-fill", + "loader-line", + "lock-2-fill", + "lock-2-line", + "lock-fill", + "lock-line", + "lock-password-fill", + "lock-password-line", + "lock-unlock-fill", + "lock-unlock-line", + "login-box-fill", + "login-box-line", + "login-circle-fill", + "login-circle-line", + "logout-box-fill", + "logout-box-line", + "logout-box-r-fill", + "logout-box-r-line", + "logout-circle-fill", + "logout-circle-line", + "logout-circle-r-fill", + "logout-circle-r-line", + "luggage-cart-fill", + "luggage-cart-line", + "luggage-deposit-fill", + "luggage-deposit-line", + "lungs-fill", + "lungs-line", + "mac-fill", + "mac-line", + "macbook-fill", + "macbook-line", + "magic-fill", + "magic-line", + "mail-add-fill", + "mail-add-line", + "mail-check-fill", + "mail-check-line", + "mail-close-fill", + "mail-close-line", + "mail-download-fill", + "mail-download-line", + "mail-fill", + "mail-forbid-fill", + "mail-forbid-line", + "mail-line", + "mail-lock-fill", + "mail-lock-line", + "mail-open-fill", + "mail-open-line", + "mail-send-fill", + "mail-send-line", + "mail-settings-fill", + "mail-settings-line", + "mail-star-fill", + "mail-star-line", + "mail-unread-fill", + "mail-unread-line", + "mail-volume-fill", + "mail-volume-line", + "map-2-fill", + "map-2-line", + "map-fill", + "map-line", + "map-pin-2-fill", + "map-pin-2-line", + "map-pin-3-fill", + "map-pin-3-line", + "map-pin-4-fill", + "map-pin-4-line", + "map-pin-5-fill", + "map-pin-5-line", + "map-pin-add-fill", + "map-pin-add-line", + "map-pin-fill", + "map-pin-line", + "map-pin-range-fill", + "map-pin-range-line", + "map-pin-time-fill", + "map-pin-time-line", + "map-pin-user-fill", + "map-pin-user-line", + "mark-pen-fill", + "mark-pen-line", + "markdown-fill", + "markdown-line", + "markup-fill", + "markup-line", + "mastercard-fill", + "mastercard-line", + "mastodon-fill", + "mastodon-line", + "medal-2-fill", + "medal-2-line", + "medal-fill", + "medal-line", + "medicine-bottle-fill", + "medicine-bottle-line", + "medium-fill", + "medium-line", + "men-fill", + "men-line", + "mental-health-fill", + "mental-health-line", + "menu-2-fill", + "menu-2-line", + "menu-3-fill", + "menu-3-line", + "menu-4-fill", + "menu-4-line", + "menu-5-fill", + "menu-5-line", + "menu-add-fill", + "menu-add-line", + "menu-fill", + "menu-fold-fill", + "menu-fold-line", + "menu-line", + "menu-unfold-fill", + "menu-unfold-line", + "merge-cells-horizontal", + "merge-cells-vertical", + "message-2-fill", + "message-2-line", + "message-3-fill", + "message-3-line", + "message-fill", + "message-line", + "messenger-fill", + "messenger-line", + "meteor-fill", + "meteor-line", + "mic-2-fill", + "mic-2-line", + "mic-fill", + "mic-line", + "mic-off-fill", + "mic-off-line", + "mickey-fill", + "mickey-line", + "microscope-fill", + "microscope-line", + "microsoft-fill", + "microsoft-line", + "mind-map", + "mini-program-fill", + "mini-program-line", + "mist-fill", + "mist-line", + "money-cny-box-fill", + "money-cny-box-line", + "money-cny-circle-fill", + "money-cny-circle-line", + "money-dollar-box-fill", + "money-dollar-box-line", + "money-dollar-circle-fill", + "money-dollar-circle-line", + "money-euro-box-fill", + "money-euro-box-line", + "money-euro-circle-fill", + "money-euro-circle-line", + "money-pound-box-fill", + "money-pound-box-line", + "money-pound-circle-fill", + "money-pound-circle-line", + "moon-clear-fill", + "moon-clear-line", + "moon-cloudy-fill", + "moon-cloudy-line", + "moon-fill", + "moon-foggy-fill", + "moon-foggy-line", + "moon-line", + "more-2-fill", + "more-2-line", + "more-fill", + "more-line", + "motorbike-fill", + "motorbike-line", + "mouse-fill", + "mouse-line", + "movie-2-fill", + "movie-2-line", + "movie-fill", + "movie-line", + "music-2-fill", + "music-2-line", + "music-fill", + "music-line", + "mv-fill", + "mv-line", + "navigation-fill", + "navigation-line", + "netease-cloud-music-fill", + "netease-cloud-music-line", + "netflix-fill", + "netflix-line", + "newspaper-fill", + "newspaper-line", + "node-tree", + "notification-2-fill", + "notification-2-line", + "notification-3-fill", + "notification-3-line", + "notification-4-fill", + "notification-4-line", + "notification-badge-fill", + "notification-badge-line", + "notification-fill", + "notification-line", + "notification-off-fill", + "notification-off-line", + "npmjs-fill", + "npmjs-line", + "number-0", + "number-1", + "number-2", + "number-3", + "number-4", + "number-5", + "number-6", + "number-7", + "number-8", + "number-9", + "numbers-fill", + "numbers-line", + "nurse-fill", + "nurse-line", + "oil-fill", + "oil-line", + "omega", + "open-arm-fill", + "open-arm-line", + "open-source-fill", + "open-source-line", + "opera-fill", + "opera-line", + "order-play-fill", + "order-play-line", + "organization-chart", + "outlet-2-fill", + "outlet-2-line", + "outlet-fill", + "outlet-line", + "page-separator", + "pages-fill", + "pages-line", + "paint-brush-fill", + "paint-brush-line", + "paint-fill", + "paint-line", + "palette-fill", + "palette-line", + "pantone-fill", + "pantone-line", + "paragraph", + "parent-fill", + "parent-line", + "parentheses-fill", + "parentheses-line", + "parking-box-fill", + "parking-box-line", + "parking-fill", + "parking-line", + "passport-fill", + "passport-line", + "patreon-fill", + "patreon-line", + "pause-circle-fill", + "pause-circle-line", + "pause-fill", + "pause-line", + "pause-mini-fill", + "pause-mini-line", + "paypal-fill", + "paypal-line", + "pen-nib-fill", + "pen-nib-line", + "pencil-fill", + "pencil-line", + "pencil-ruler-2-fill", + "pencil-ruler-2-line", + "pencil-ruler-fill", + "pencil-ruler-line", + "percent-fill", + "percent-line", + "phone-camera-fill", + "phone-camera-line", + "phone-fill", + "phone-find-fill", + "phone-find-line", + "phone-line", + "phone-lock-fill", + "phone-lock-line", + "picture-in-picture-2-fill", + "picture-in-picture-2-line", + "picture-in-picture-exit-fill", + "picture-in-picture-exit-line", + "picture-in-picture-fill", + "picture-in-picture-line", + "pie-chart-2-fill", + "pie-chart-2-line", + "pie-chart-box-fill", + "pie-chart-box-line", + "pie-chart-fill", + "pie-chart-line", + "pin-distance-fill", + "pin-distance-line", + "ping-pong-fill", + "ping-pong-line", + "pinterest-fill", + "pinterest-line", + "pinyin-input", + "pixelfed-fill", + "pixelfed-line", + "plane-fill", + "plane-line", + "plant-fill", + "plant-line", + "play-circle-fill", + "play-circle-line", + "play-fill", + "play-line", + "play-list-2-fill", + "play-list-2-line", + "play-list-add-fill", + "play-list-add-line", + "play-list-fill", + "play-list-line", + "play-mini-fill", + "play-mini-line", + "playstation-fill", + "playstation-line", + "plug-2-fill", + "plug-2-line", + "plug-fill", + "plug-line", + "polaroid-2-fill", + "polaroid-2-line", + "polaroid-fill", + "polaroid-line", + "police-car-fill", + "police-car-line", + "price-tag-2-fill", + "price-tag-2-line", + "price-tag-3-fill", + "price-tag-3-line", + "price-tag-fill", + "price-tag-line", + "printer-cloud-fill", + "printer-cloud-line", + "printer-fill", + "printer-line", + "product-hunt-fill", + "product-hunt-line", + "profile-fill", + "profile-line", + "projector-2-fill", + "projector-2-line", + "projector-fill", + "projector-line", + "psychotherapy-fill", + "psychotherapy-line", + "pulse-fill", + "pulse-line", + "pushpin-2-fill", + "pushpin-2-line", + "pushpin-fill", + "pushpin-line", + "qq-fill", + "qq-line", + "qr-code-fill", + "qr-code-line", + "qr-scan-2-fill", + "qr-scan-2-line", + "qr-scan-fill", + "qr-scan-line", + "question-answer-fill", + "question-answer-line", + "question-fill", + "question-line", + "question-mark", + "questionnaire-fill", + "questionnaire-line", + "quill-pen-fill", + "quill-pen-line", + "radar-fill", + "radar-line", + "radio-2-fill", + "radio-2-line", + "radio-button-fill", + "radio-button-line", + "radio-fill", + "radio-line", + "rainbow-fill", + "rainbow-line", + "rainy-fill", + "rainy-line", + "reactjs-fill", + "reactjs-line", + "record-circle-fill", + "record-circle-line", + "record-mail-fill", + "record-mail-line", + "recycle-fill", + "recycle-line", + "red-packet-fill", + "red-packet-line", + "reddit-fill", + "reddit-line", + "refresh-fill", + "refresh-line", + "refund-2-fill", + "refund-2-line", + "refund-fill", + "refund-line", + "registered-fill", + "registered-line", + "remixicon-fill", + "remixicon-line", + "remote-control-2-fill", + "remote-control-2-line", + "remote-control-fill", + "remote-control-line", + "repeat-2-fill", + "repeat-2-line", + "repeat-fill", + "repeat-line", + "repeat-one-fill", + "repeat-one-line", + "reply-all-fill", + "reply-all-line", + "reply-fill", + "reply-line", + "reserved-fill", + "reserved-line", + "rest-time-fill", + "rest-time-line", + "restart-fill", + "restart-line", + "restaurant-2-fill", + "restaurant-2-line", + "restaurant-fill", + "restaurant-line", + "rewind-fill", + "rewind-line", + "rewind-mini-fill", + "rewind-mini-line", + "rhythm-fill", + "rhythm-line", + "riding-fill", + "riding-line", + "road-map-fill", + "road-map-line", + "roadster-fill", + "roadster-line", + "robot-fill", + "robot-line", + "rocket-2-fill", + "rocket-2-line", + "rocket-fill", + "rocket-line", + "rotate-lock-fill", + "rotate-lock-line", + "rounded-corner", + "route-fill", + "route-line", + "router-fill", + "router-line", + "rss-fill", + "rss-line", + "ruler-2-fill", + "ruler-2-line", + "ruler-fill", + "ruler-line", + "run-fill", + "run-line", + "safari-fill", + "safari-line", + "safe-2-fill", + "safe-2-line", + "safe-fill", + "safe-line", + "sailboat-fill", + "sailboat-line", + "save-2-fill", + "save-2-line", + "save-3-fill", + "save-3-line", + "save-fill", + "save-line", + "scales-2-fill", + "scales-2-line", + "scales-3-fill", + "scales-3-line", + "scales-fill", + "scales-line", + "scan-2-fill", + "scan-2-line", + "scan-fill", + "scan-line", + "scissors-2-fill", + "scissors-2-line", + "scissors-cut-fill", + "scissors-cut-line", + "scissors-fill", + "scissors-line", + "screenshot-2-fill", + "screenshot-2-line", + "screenshot-fill", + "screenshot-line", + "sd-card-fill", + "sd-card-line", + "sd-card-mini-fill", + "sd-card-mini-line", + "search-2-fill", + "search-2-line", + "search-eye-fill", + "search-eye-line", + "search-fill", + "search-line", + "secure-payment-fill", + "secure-payment-line", + "seedling-fill", + "seedling-line", + "send-backward", + "send-plane-2-fill", + "send-plane-2-line", + "send-plane-fill", + "send-plane-line", + "send-to-back", + "sensor-fill", + "sensor-line", + "separator", + "server-fill", + "server-line", + "service-fill", + "service-line", + "settings-2-fill", + "settings-2-line", + "settings-3-fill", + "settings-3-line", + "settings-4-fill", + "settings-4-line", + "settings-5-fill", + "settings-5-line", + "settings-6-fill", + "settings-6-line", + "settings-fill", + "settings-line", + "shape-2-fill", + "shape-2-line", + "shape-fill", + "shape-line", + "share-box-fill", + "share-box-line", + "share-circle-fill", + "share-circle-line", + "share-fill", + "share-forward-2-fill", + "share-forward-2-line", + "share-forward-box-fill", + "share-forward-box-line", + "share-forward-fill", + "share-forward-line", + "share-line", + "shield-check-fill", + "shield-check-line", + "shield-cross-fill", + "shield-cross-line", + "shield-fill", + "shield-flash-fill", + "shield-flash-line", + "shield-keyhole-fill", + "shield-keyhole-line", + "shield-line", + "shield-star-fill", + "shield-star-line", + "shield-user-fill", + "shield-user-line", + "ship-2-fill", + "ship-2-line", + "ship-fill", + "ship-line", + "shirt-fill", + "shirt-line", + "shopping-bag-2-fill", + "shopping-bag-2-line", + "shopping-bag-3-fill", + "shopping-bag-3-line", + "shopping-bag-fill", + "shopping-bag-line", + "shopping-basket-2-fill", + "shopping-basket-2-line", + "shopping-basket-fill", + "shopping-basket-line", + "shopping-cart-2-fill", + "shopping-cart-2-line", + "shopping-cart-fill", + "shopping-cart-line", + "showers-fill", + "showers-line", + "shuffle-fill", + "shuffle-line", + "shut-down-fill", + "shut-down-line", + "side-bar-fill", + "side-bar-line", + "signal-tower-fill", + "signal-tower-line", + "signal-wifi-1-fill", + "signal-wifi-1-line", + "signal-wifi-2-fill", + "signal-wifi-2-line", + "signal-wifi-3-fill", + "signal-wifi-3-line", + "signal-wifi-error-fill", + "signal-wifi-error-line", + "signal-wifi-fill", + "signal-wifi-line", + "signal-wifi-off-fill", + "signal-wifi-off-line", + "sim-card-2-fill", + "sim-card-2-line", + "sim-card-fill", + "sim-card-line", + "single-quotes-l", + "single-quotes-r", + "sip-fill", + "sip-line", + "skip-back-fill", + "skip-back-line", + "skip-back-mini-fill", + "skip-back-mini-line", + "skip-forward-fill", + "skip-forward-line", + "skip-forward-mini-fill", + "skip-forward-mini-line", + "skull-2-fill", + "skull-2-line", + "skull-fill", + "skull-line", + "skype-fill", + "skype-line", + "slack-fill", + "slack-line", + "slice-fill", + "slice-line", + "slideshow-2-fill", + "slideshow-2-line", + "slideshow-3-fill", + "slideshow-3-line", + "slideshow-4-fill", + "slideshow-4-line", + "slideshow-fill", + "slideshow-line", + "smartphone-fill", + "smartphone-line", + "snapchat-fill", + "snapchat-line", + "snowy-fill", + "snowy-line", + "sort-asc", + "sort-desc", + "sound-module-fill", + "sound-module-line", + "soundcloud-fill", + "soundcloud-line", + "space-ship-fill", + "space-ship-line", + "space", + "spam-2-fill", + "spam-2-line", + "spam-3-fill", + "spam-3-line", + "spam-fill", + "spam-line", + "speaker-2-fill", + "speaker-2-line", + "speaker-3-fill", + "speaker-3-line", + "speaker-fill", + "speaker-line", + "spectrum-fill", + "spectrum-line", + "speed-fill", + "speed-line", + "speed-mini-fill", + "speed-mini-line", + "split-cells-horizontal", + "split-cells-vertical", + "spotify-fill", + "spotify-line", + "spy-fill", + "spy-line", + "stack-fill", + "stack-line", + "stack-overflow-fill", + "stack-overflow-line", + "stackshare-fill", + "stackshare-line", + "star-fill", + "star-half-fill", + "star-half-line", + "star-half-s-fill", + "star-half-s-line", + "star-line", + "star-s-fill", + "star-s-line", + "star-smile-fill", + "star-smile-line", + "steam-fill", + "steam-line", + "steering-2-fill", + "steering-2-line", + "steering-fill", + "steering-line", + "stethoscope-fill", + "stethoscope-line", + "sticky-note-2-fill", + "sticky-note-2-line", + "sticky-note-fill", + "sticky-note-line", + "stock-fill", + "stock-line", + "stop-circle-fill", + "stop-circle-line", + "stop-fill", + "stop-line", + "stop-mini-fill", + "stop-mini-line", + "store-2-fill", + "store-2-line", + "store-3-fill", + "store-3-line", + "store-fill", + "store-line", + "strikethrough-2", + "strikethrough", + "subscript-2", + "subscript", + "subtract-fill", + "subtract-line", + "subway-fill", + "subway-line", + "subway-wifi-fill", + "subway-wifi-line", + "suitcase-2-fill", + "suitcase-2-line", + "suitcase-3-fill", + "suitcase-3-line", + "suitcase-fill", + "suitcase-line", + "sun-cloudy-fill", + "sun-cloudy-line", + "sun-fill", + "sun-foggy-fill", + "sun-foggy-line", + "sun-line", + "superscript-2", + "superscript", + "surgical-mask-fill", + "surgical-mask-line", + "surround-sound-fill", + "surround-sound-line", + "survey-fill", + "survey-line", + "swap-box-fill", + "swap-box-line", + "swap-fill", + "swap-line", + "switch-fill", + "switch-line", + "sword-fill", + "sword-line", + "syringe-fill", + "syringe-line", + "t-box-fill", + "t-box-line", + "t-shirt-2-fill", + "t-shirt-2-line", + "t-shirt-air-fill", + "t-shirt-air-line", + "t-shirt-fill", + "t-shirt-line", + "table-2", + "table-alt-fill", + "table-alt-line", + "table-fill", + "table-line", + "tablet-fill", + "tablet-line", + "takeaway-fill", + "takeaway-line", + "taobao-fill", + "taobao-line", + "tape-fill", + "tape-line", + "task-fill", + "task-line", + "taxi-fill", + "taxi-line", + "taxi-wifi-fill", + "taxi-wifi-line", + "team-fill", + "team-line", + "telegram-fill", + "telegram-line", + "temp-cold-fill", + "temp-cold-line", + "temp-hot-fill", + "temp-hot-line", + "terminal-box-fill", + "terminal-box-line", + "terminal-fill", + "terminal-line", + "terminal-window-fill", + "terminal-window-line", + "test-tube-fill", + "test-tube-line", + "text-direction-l", + "text-direction-r", + "text-spacing", + "text-wrap", + "text", + "thermometer-fill", + "thermometer-line", + "thumb-down-fill", + "thumb-down-line", + "thumb-up-fill", + "thumb-up-line", + "thunderstorms-fill", + "thunderstorms-line", + "ticket-2-fill", + "ticket-2-line", + "ticket-fill", + "ticket-line", + "time-fill", + "time-line", + "timer-2-fill", + "timer-2-line", + "timer-fill", + "timer-flash-fill", + "timer-flash-line", + "timer-line", + "todo-fill", + "todo-line", + "toggle-fill", + "toggle-line", + "tools-fill", + "tools-line", + "tornado-fill", + "tornado-line", + "trademark-fill", + "trademark-line", + "traffic-light-fill", + "traffic-light-line", + "train-fill", + "train-line", + "train-wifi-fill", + "train-wifi-line", + "translate-2", + "translate", + "travesti-fill", + "travesti-line", + "treasure-map-fill", + "treasure-map-line", + "trello-fill", + "trello-line", + "trophy-fill", + "trophy-line", + "truck-fill", + "truck-line", + "tumblr-fill", + "tumblr-line", + "tv-2-fill", + "tv-2-line", + "tv-fill", + "tv-line", + "twitch-fill", + "twitch-line", + "twitter-fill", + "twitter-line", + "typhoon-fill", + "typhoon-line", + "u-disk-fill", + "u-disk-line", + "ubuntu-fill", + "ubuntu-line", + "umbrella-fill", + "umbrella-line", + "underline", + "uninstall-fill", + "uninstall-line", + "unsplash-fill", + "unsplash-line", + "upload-2-fill", + "upload-2-line", + "upload-cloud-2-fill", + "upload-cloud-2-line", + "upload-cloud-fill", + "upload-cloud-line", + "upload-fill", + "upload-line", + "usb-fill", + "usb-line", + "user-2-fill", + "user-2-line", + "user-3-fill", + "user-3-line", + "user-4-fill", + "user-4-line", + "user-5-fill", + "user-5-line", + "user-6-fill", + "user-6-line", + "user-add-fill", + "user-add-line", + "user-fill", + "user-follow-fill", + "user-follow-line", + "user-heart-fill", + "user-heart-line", + "user-line", + "user-location-fill", + "user-location-line", + "user-received-2-fill", + "user-received-2-line", + "user-received-fill", + "user-received-line", + "user-search-fill", + "user-search-line", + "user-settings-fill", + "user-settings-line", + "user-shared-2-fill", + "user-shared-2-line", + "user-shared-fill", + "user-shared-line", + "user-smile-fill", + "user-smile-line", + "user-star-fill", + "user-star-line", + "user-unfollow-fill", + "user-unfollow-line", + "user-voice-fill", + "user-voice-line", + "video-add-fill", + "video-add-line", + "video-chat-fill", + "video-chat-line", + "video-download-fill", + "video-download-line", + "video-fill", + "video-line", + "video-upload-fill", + "video-upload-line", + "vidicon-2-fill", + "vidicon-2-line", + "vidicon-fill", + "vidicon-line", + "vimeo-fill", + "vimeo-line", + "vip-crown-2-fill", + "vip-crown-2-line", + "vip-crown-fill", + "vip-crown-line", + "vip-diamond-fill", + "vip-diamond-line", + "vip-fill", + "vip-line", + "virus-fill", + "virus-line", + "visa-fill", + "visa-line", + "voice-recognition-fill", + "voice-recognition-line", + "voiceprint-fill", + "voiceprint-line", + "volume-down-fill", + "volume-down-line", + "volume-mute-fill", + "volume-mute-line", + "volume-off-vibrate-fill", + "volume-off-vibrate-line", + "volume-up-fill", + "volume-up-line", + "volume-vibrate-fill", + "volume-vibrate-line", + "vuejs-fill", + "vuejs-line", + "walk-fill", + "walk-line", + "wallet-2-fill", + "wallet-2-line", + "wallet-3-fill", + "wallet-3-line", + "wallet-fill", + "wallet-line", + "water-flash-fill", + "water-flash-line", + "webcam-fill", + "webcam-line", + "wechat-2-fill", + "wechat-2-line", + "wechat-fill", + "wechat-line", + "wechat-pay-fill", + "wechat-pay-line", + "weibo-fill", + "weibo-line", + "whatsapp-fill", + "whatsapp-line", + "wheelchair-fill", + "wheelchair-line", + "wifi-fill", + "wifi-line", + "wifi-off-fill", + "wifi-off-line", + "window-2-fill", + "window-2-line", + "window-fill", + "window-line", + "windows-fill", + "windows-line", + "windy-fill", + "windy-line", + "wireless-charging-fill", + "wireless-charging-line", + "women-fill", + "women-line", + "wubi-input", + "xbox-fill", + "xbox-line", + "xing-fill", + "xing-line", + "youtube-fill", + "youtube-line", + "zcool-fill", + "zcool-line", + "zhihu-fill", + "zhihu-line", + "zoom-in-fill", + "zoom-in-line", + "zoom-out-fill", + "zoom-out-line", + "zzz-fill", + "zzz-line", +]; +module.exports = [ + { + url: "/remixIcon/getList", + type: "post", + response(config) { + const { title, pageNo = 1, pageSize = 72 } = config.body; + let mockList = data.filter((item) => { + if (title && item.indexOf(title) < 0) return false; + return true; + }); + const pageList = mockList.filter( + (item, index) => + index < pageSize * pageNo && index >= pageSize * (pageNo - 1) + ); + return { + code: 200, + msg: "success", + totalCount: mockList.length, + data: pageList, + }; + }, + }, +]; diff --git a/mock/controller/roleManagement.js b/mock/controller/roleManagement.js new file mode 100644 index 0000000..f1f30d8 --- /dev/null +++ b/mock/controller/roleManagement.js @@ -0,0 +1,53 @@ +const totalCount = 2; +const List = [ + { + id: "@id", + permission: "admin", + }, + { + id: "@id", + permission: "editor", + }, +]; +module.exports = [ + { + url: "/roleManagement/getList", + type: "post", + response(config) { + const { title = "", pageNo = 1, pageSize = 20 } = config.body; + let mockList = List.filter((item) => { + return !(title && item.title.indexOf(title) < 0); + }); + const pageList = mockList.filter( + (item, index) => + index < pageSize * pageNo && index >= pageSize * (pageNo - 1) + ); + return { + code: 200, + msg: "success", + totalCount, + data: pageList, + }; + }, + }, + { + url: "/roleManagement/doEdit", + type: "post", + response() { + return { + code: 200, + msg: "模拟保存成功", + }; + }, + }, + { + url: "/roleManagement/doDelete", + type: "post", + response() { + return { + code: 200, + msg: "模拟删除成功", + }; + }, + }, +]; diff --git a/mock/controller/router.js b/mock/controller/router.js new file mode 100644 index 0000000..fd7026c --- /dev/null +++ b/mock/controller/router.js @@ -0,0 +1,390 @@ +const data = [ + { + path: "/", + component: "Layout", + redirect: "index", + children: [ + { + path: "index", + name: "Index", + component: "views/index/index", + meta: { + title: "首页", + icon: "home", + affix: true, + }, + }, + ], + }, + { + path: "/personalCenter", + component: "Layout", + hidden: true, + redirect: "personalCenter", + children: [ + { + path: "personalCenter", + name: "PersonalCenter", + component: "views/personalCenter/index", + meta: { + title: "个人中心", + }, + }, + ], + }, + { + path: "/personnelManagement", + component: "Layout", + redirect: "noRedirect", + name: "PersonnelManagement", + meta: { title: "人员", icon: "users-cog", permissions: ["admin"] }, + children: [ + { + path: "userManagement", + name: "UserManagement", + component: "views/personnelManagement/userManagement/index", + meta: { title: "用户管理" }, + }, + { + path: "roleManagement", + name: "RoleManagement", + component: "views/personnelManagement/roleManagement/index", + meta: { title: "角色管理" }, + }, + { + path: "menuManagement", + name: "MenuManagement", + component: "views/personnelManagement/menuManagement/index", + meta: { title: "菜单管理", badge: "New" }, + }, + ], + }, + { + path: "/vab", + component: "Layout", + redirect: "noRedirect", + name: "Vab", + alwaysShow: true, + meta: { title: "组件", icon: "cloud" }, + children: [ + { + path: "permissions", + name: "Permission", + component: "views/vab/permissions/index", + meta: { + title: "权限控制", + permissions: ["admin", "editor"], + badge: "New", + }, + }, + { + path: "icon", + component: "EmptyLayout", + redirect: "noRedirect", + name: "Icon", + meta: { + title: "图标", + permissions: ["admin"], + }, + children: [ + { + path: "awesomeIcon", + name: "AwesomeIcon", + component: "views/vab/icon/index", + meta: { title: "常规图标" }, + }, + { + path: "remixIcon", + name: "RemixIcon", + component: "views/vab/icon/remixIcon", + meta: { title: "小清新图标" }, + }, + { + path: "colorfulIcon", + name: "ColorfulIcon", + component: "views/vab/icon/colorfulIcon", + meta: { title: "多彩图标" }, + }, + ], + }, + { + path: "table", + component: "EmptyLayout", + redirect: "noRedirect", + name: "Table", + meta: { + title: "表格", + permissions: ["admin"], + }, + children: [ + { + path: "comprehensiveTable", + name: "ComprehensiveTable", + component: "views/vab/table/index", + meta: { title: "综合表格" }, + }, + { + path: "inlineEditTable", + name: "InlineEditTable", + component: "views/vab/table/inlineEditTable", + meta: { title: "行内编辑" }, + }, + ], + }, + { + path: "map", + name: "Map", + component: "views/vab/map/index", + meta: { title: "地图", permissions: ["admin"], badge: "Pro" }, + }, + { + path: "webSocket", + name: "WebSocket", + component: "views/vab/webSocket/index", + meta: { title: "webSocket", permissions: ["admin"] }, + }, + { + path: "form", + name: "Form", + component: "views/vab/form/index", + meta: { title: "表单", permissions: ["admin"] }, + }, + { + path: "element", + name: "Element", + component: "views/vab/element/index", + meta: { title: "常用组件", permissions: ["admin"] }, + }, + { + path: "tree", + name: "Tree", + component: "views/vab/tree/index", + meta: { title: "树", permissions: ["admin"] }, + }, + { + path: "card", + name: "Card", + component: "views/vab/card/index", + meta: { title: "卡片", permissions: ["admin"] }, + }, + + { + path: "betterScroll", + name: "BetterScroll", + component: "views/vab/betterScroll/index", + meta: { + title: "滚动侦测", + permissions: ["admin"], + }, + }, + { + path: "verify", + name: "Verify", + component: "views/vab/verify/index", + meta: { title: "验证码", permissions: ["admin"] }, + }, + { + path: "menu1", + component: "views/vab/nested/menu1/index", + name: "Menu1", + alwaysShow: true, + meta: { + title: "嵌套路由 1", + permissions: ["admin"], + }, + children: [ + { + path: "menu1-1", + name: "Menu1-1", + alwaysShow: true, + meta: { title: "嵌套路由 1-1" }, + component: "views/vab/nested/menu1/menu1-1/index", + + children: [ + { + path: "menu1-1-1", + name: "Menu1-1-1", + meta: { title: "嵌套路由 1-1-1" }, + component: "views/vab/nested/menu1/menu1-1/menu1-1-1/index", + }, + ], + }, + ], + }, + { + path: "magnifier", + name: "Magnifier", + component: "views/vab/magnifier/index", + meta: { title: "放大镜", permissions: ["admin"] }, + }, + { + path: "echarts", + name: "Echarts", + component: "views/vab/echarts/index", + meta: { title: "图表", permissions: ["admin"] }, + }, + + { + path: "loading", + name: "Loading", + component: "views/vab/loading/index", + meta: { title: "loading", permissions: ["admin"] }, + }, + { + path: "player", + name: "Player", + component: "views/vab/player/index", + meta: { title: "视频播放器", permissions: ["admin"] }, + }, + { + path: "markdownEditor", + name: "MarkdownEditor", + component: "views/vab/markdownEditor/index", + meta: { title: "markdown编辑器", permissions: ["admin"] }, + }, + { + path: "editor", + name: "Editor", + component: "views/vab/editor/index", + meta: { title: "富文本编辑器", permissions: ["admin"], badge: "New" }, + }, + { + path: "qrCode", + name: "QrCode", + component: "views/vab/qrCode/index", + meta: { title: "二维码", permissions: ["admin"] }, + }, + { + path: "backToTop", + name: "BackToTop", + component: "views/vab/backToTop/index", + meta: { title: "返回顶部", permissions: ["admin"] }, + }, + { + path: "lodash", + name: "Lodash", + component: "views/vab/lodash/index", + meta: { title: "lodash", permissions: ["admin"] }, + }, + { + path: "imgComparison", + name: "ImgComparison", + component: "views/vab/imgComparison/index", + meta: { title: "图像拖拽比对", permissions: ["admin"] }, + }, + { + path: "codeGenerator", + name: "CodeGenerator", + component: "views/vab/codeGenerator/index", + meta: { title: "代码生成机", permissions: ["admin"] }, + }, + { + path: "markdown", + name: "Markdown", + component: "views/vab/markdown/index", + meta: { title: "markdown阅读器", permissions: ["admin"] }, + }, + { + path: "smallComponents", + name: "SmallComponents", + component: "views/vab/smallComponents/index", + meta: { title: "小组件", permissions: ["admin"] }, + }, + + { + path: "upload", + name: "Upload", + component: "views/vab/upload/index", + meta: { title: "上传", permissions: ["admin"] }, + }, + { + path: "sticky", + name: "Sticky", + component: "views/vab/sticky/index", + meta: { title: "sticky吸附", permissions: ["admin"] }, + }, + { + path: "log", + name: "Log", + component: "views/vab/errorLog/index", + meta: { title: "错误日志模拟", permissions: ["admin"] }, + }, + { + path: "more", + name: "More", + component: "views/vab/more/index", + meta: { title: "更多组件", permissions: ["admin"] }, + }, + ], + }, + { + path: "/mall", + component: "Layout", + redirect: "noRedirect", + name: "Mall", + meta: { + title: "商城", + icon: "shopping-cart", + permissions: ["admin"], + }, + + children: [ + { + path: "pay", + name: "Pay", + component: "views/mall/pay/index", + meta: { + title: "支付", + noKeepAlive: true, + }, + children: null, + }, + { + path: "goodsList", + name: "GoodsList", + component: "views/mall/goodsList/index", + meta: { + title: "商品列表", + }, + }, + { + path: "goodsDetail", + name: "GoodsDetail", + component: "views/mall/goodsDetail/index", + meta: { + title: "商品详情", + }, + }, + ], + }, + { + path: "/error", + component: "EmptyLayout", + redirect: "noRedirect", + name: "Error", + meta: { title: "错误页", icon: "bug" }, + children: [ + { + path: "401", + name: "Error401", + component: "views/401", + meta: { title: "401" }, + }, + { + path: "404", + name: "Error404", + component: "views/404", + meta: { title: "404" }, + }, + ], + }, +]; +module.exports = [ + { + url: "/menu/navigate", + type: "post", + response() { + return { code: 200, msg: "success", data: data }; + }, + }, +]; diff --git a/mock/controller/table.js b/mock/controller/table.js new file mode 100644 index 0000000..fa4c38e --- /dev/null +++ b/mock/controller/table.js @@ -0,0 +1,88 @@ +const { mock } = require("mockjs"); +const { handleRandomImage } = require("../utils"); + +const List = []; +const count = 999; +for (let i = 0; i < count; i++) { + List.push( + mock({ + uuid: "@uuid", + id: "@id", + title: "@csentence(1, 2)", + "status|1": ["published", "draft", "deleted"], + author: "@cname", + datetime: "@datetime", + pageViews: "@integer(300, 5000)", + img: handleRandomImage(200, 200), + smallImg: handleRandomImage(40, 40), + switch: "@boolean", + percent: "@integer(80,99)", + }) + ); +} + +module.exports = [ + { + url: "/table/getList", + type: "post", + response(config) { + if (!config.body) { + return { + code: 200, + msg: "success", + totalCount: count, + data: mock({ + "data|50": [ + { + id: "@id", + title: "@csentence(1, 2)", + "status|1": ["published", "draft", "deleted"], + author: "@cname", + datetime: "@datetime", + pageViews: "@integer(300, 5000)", + img: handleRandomImage(200, 200), + smallImg: handleRandomImage(40, 40), + switch: "@boolean", + percent: "@integer(80,99)", + }, + ], + }).data, + }; + } + const { title = "", pageNo = 1, pageSize = 20 } = config.body; + let mockList = List.filter((item) => { + return !(title && item.title.indexOf(title) < 0); + }); + const pageList = mockList.filter( + (item, index) => + index < pageSize * pageNo && index >= pageSize * (pageNo - 1) + ); + return { + code: 200, + msg: "success", + totalCount: count, + data: pageList, + }; + }, + }, + { + url: "/table/doEdit", + type: "post", + response() { + return { + code: 200, + msg: "模拟保存成功", + }; + }, + }, + { + url: "/table/doDelete", + type: "post", + response() { + return { + code: 200, + msg: "模拟删除成功", + }; + }, + }, +]; diff --git a/mock/controller/tree.js b/mock/controller/tree.js new file mode 100644 index 0000000..d0efd8d --- /dev/null +++ b/mock/controller/tree.js @@ -0,0 +1,54 @@ +const data = [ + { + id: "1", + parentId: "0", + name: "vue-admin-beautiful科技有限公司", + title: "vue-admin-beautiful科技有限公司", + text: "vue-admin-beautiful科技有限公司", + value: "1", + rank: 1, + children: [ + { + id: "32816b88ff72423f960e7d492a386131", + parentId: "1", + name: "1103工作室", + title: "1103工作室", + text: "1103工作室", + value: "32816b88ff72423f960e7d492a386131", + rank: 2, + children: [ + { + id: "9e11afc35d55475fb0bd3164b9684cbe", + parentId: "32816b88ff72423f960e7d492a386131", + name: "前端牛逼plus小组", + title: "前端牛逼plus小组", + text: "前端牛逼plus小组", + value: "9e11afc35d55475fb0bd3164b9684cbe", + rank: 3, + children: [ + { + id: "4cc1b04635e4444292526c5391699077", + parentId: "9e11afc35d55475fb0bd3164b9684cbe", + name: "组员chuzhixin", + title: "组员chuzhixin", + text: "组员chuzhixin", + value: "4cc1b04635e4444292526c5391699077", + rank: 4, + children: [], + }, + ], + }, + ], + }, + ], + }, +]; +module.exports = [ + { + url: "/tree/list", + type: "post", + response() { + return { code: 200, msg: "success", data }; + }, + }, +]; diff --git a/mock/controller/upload.js b/mock/controller/upload.js new file mode 100644 index 0000000..a6f9ab0 --- /dev/null +++ b/mock/controller/upload.js @@ -0,0 +1,14 @@ +const data = []; +module.exports = [ + { + url: "/upload", + type: "post", + response(config) { + return { + code: 200, + msg: "success", + data: data, + }; + }, + }, +]; diff --git a/mock/controller/user.js b/mock/controller/user.js new file mode 100644 index 0000000..de02fec --- /dev/null +++ b/mock/controller/user.js @@ -0,0 +1,95 @@ +const accessTokens = { + admin: "admin-accessToken", + editor: "editor-accessToken", + test: "test-accessToken", +}; + +module.exports = [ + { + url: "/publicKey", + type: "post", + response() { + return { + code: 200, + msg: "success", + data: { + mockServer: true, + publicKey: + "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDBT2vr+dhZElF73FJ6xiP181txKWUSNLPQQlid6DUJhGAOZblluafIdLmnUyKE8mMHhT3R+Ib3ssZcJku6Hn72yHYj/qPkCGFv0eFo7G+GJfDIUeDyalBN0QsuiE/XzPHJBuJDfRArOiWvH0BXOv5kpeXSXM8yTt5Na1jAYSiQ/wIDAQAB", + }, + }; + }, + }, + { + url: "/login", + type: "post", + response(config) { + const { username } = config.body; + const accessToken = accessTokens[username]; + if (!accessToken) { + return { + code: 500, + msg: "帐户或密码不正确。", + }; + } + return { + code: 200, + msg: "success", + data: { accessToken }, + }; + }, + }, + { + url: "/register", + type: "post", + response() { + return { + code: 200, + msg: "模拟注册成功", + }; + }, + }, + { + url: "/userInfo", + type: "post", + response(config) { + const { accessToken } = config.body; + let permissions = ["admin"]; + let username = "admin"; + if ("admin-accessToken" === accessToken) { + permissions = ["admin"]; + username = "admin"; + } + if ("editor-accessToken" === accessToken) { + permissions = ["editor"]; + username = "editor"; + } + if ("test-accessToken" === accessToken) { + permissions = ["admin", "editor"]; + username = "test"; + } + return { + code: 200, + msg: "success", + data: { + permissions, + username, + "avatar|1": [ + "https://i.gtimg.cn/club/item/face/img/2/15922_100.gif", + "https://i.gtimg.cn/club/item/face/img/8/15918_100.gif", + ], + }, + }; + }, + }, + { + url: "/logout", + type: "post", + response() { + return { + code: 200, + msg: "success", + }; + }, + }, +]; diff --git a/mock/controller/userManagement.js b/mock/controller/userManagement.js new file mode 100644 index 0000000..30749eb --- /dev/null +++ b/mock/controller/userManagement.js @@ -0,0 +1,70 @@ +const totalCount = 3; +const List = [ + { + id: "@id", + username: "admin", + password: "admin", + email: "@email", + permissions: ["admin"], + datatime: "@datetime", + }, + { + id: "@id", + username: "editor", + password: "editor", + email: "@email", + permissions: ["editor"], + datatime: "@datetime", + }, + { + id: "@id", + username: "test", + password: "test", + email: "@email", + permissions: ["admin", "editor"], + datatime: "@datetime", + }, +]; +module.exports = [ + { + url: "/userManagement/getList", + type: "post", + response(config) { + const { title = "", pageNo = 1, pageSize = 20 } = config.body; + let mockList = List.filter((item) => { + if (title && item.title.indexOf(title) < 0) return false; + return true; + }); + const pageList = mockList.filter( + (item, index) => + index < pageSize * pageNo && index >= pageSize * (pageNo - 1) + ); + return { + code: 200, + msg: "success", + totalCount, + data: pageList, + }; + }, + }, + { + url: "/userManagement/doEdit", + type: "post", + response() { + return { + code: 200, + msg: "模拟保存成功", + }; + }, + }, + { + url: "/userManagement/doDelete", + type: "post", + response() { + return { + code: 200, + msg: "模拟删除成功", + }; + }, + }, +]; diff --git a/mock/index.js b/mock/index.js new file mode 100644 index 0000000..68566c0 --- /dev/null +++ b/mock/index.js @@ -0,0 +1,16 @@ +/** + * @copyright chuzhixin 1204505056@qq.com + * @description 导入所有 controller 模块,npm run serve时在node环境中自动输出controller文件夹下Mock接口,请勿修改。 + */ + +const { handleMockArray } = require("./utils"); + +const mocks = []; +const mockArray = handleMockArray(); +mockArray.forEach((item) => { + const obj = require(item); + mocks.push(...obj); +}); +module.exports = { + mocks, +}; diff --git a/mock/mockServer.js b/mock/mockServer.js new file mode 100644 index 0000000..23944fd --- /dev/null +++ b/mock/mockServer.js @@ -0,0 +1,94 @@ +const chokidar = require("chokidar"); +const bodyParser = require("body-parser"); +const chalk = require("chalk"); +const path = require("path"); +const Mock = require("mockjs"); +const { baseURL } = require("../src/config/settings"); +const mockDir = path.join(process.cwd(), "mock"); + +/** + * + * @param app + * @returns {{mockStartIndex: number, mockRoutesLength: number}} + */ +const registerRoutes = (app) => { + let mockLastIndex; + const { mocks } = require("./index.js"); + const mocksForServer = mocks.map((route) => { + return responseFake(route.url, route.type, route.response); + }); + for (const mock of mocksForServer) { + app[mock.type](mock.url, mock.response); + mockLastIndex = app._router.stack.length; + } + const mockRoutesLength = Object.keys(mocksForServer).length; + return { + mockRoutesLength: mockRoutesLength, + mockStartIndex: mockLastIndex - mockRoutesLength, + }; +}; + +/** + * + * @param url + * @param type + * @param respond + * @returns {{response(*=, *=): void, type: (*|string), url: RegExp}} + */ +const responseFake = (url, type, respond) => { + return { + url: new RegExp(`${baseURL}${url}`), + type: type || "get", + response(req, res) { + res.status(200); + if (JSON.stringify(req.body) !== "{}") { + console.log(chalk.green(`> 请求地址:${req.path}`)); + console.log(chalk.green(`> 请求参数:${JSON.stringify(req.body)}\n`)); + } else { + console.log(chalk.green(`> 请求地址:${req.path}\n`)); + } + res.json( + Mock.mock(respond instanceof Function ? respond(req, res) : respond) + ); + }, + }; +}; +/** + * + * @param app + */ +module.exports = (app) => { + app.use(bodyParser.json()); + app.use( + bodyParser.urlencoded({ + extended: true, + }) + ); + + const mockRoutes = registerRoutes(app); + let mockRoutesLength = mockRoutes.mockRoutesLength; + let mockStartIndex = mockRoutes.mockStartIndex; + chokidar + .watch(mockDir, { + ignored: /mock-server/, + ignoreInitial: true, + }) + .on("all", (event) => { + if (event === "change" || event === "add") { + try { + app._router.stack.splice(mockStartIndex, mockRoutesLength); + + Object.keys(require.cache).forEach((item) => { + if (item.includes(mockDir)) { + delete require.cache[require.resolve(item)]; + } + }); + const mockRoutes = registerRoutes(app); + mockRoutesLength = mockRoutes.mockRoutesLength; + mockStartIndex = mockRoutes.mockStartIndex; + } catch (error) { + console.log(chalk.red(error)); + } + } + }); +}; diff --git a/mock/utils/index.js b/mock/utils/index.js new file mode 100644 index 0000000..9f04d42 --- /dev/null +++ b/mock/utils/index.js @@ -0,0 +1,43 @@ +const { Random } = require("mockjs"); +const { join } = require("path"); +const fs = require("fs"); + +/** + * @copyright chuzhixin 1204505056@qq.com + * @description 随机生成图片url。 + * @param width + * @param height + * @returns {string} + */ +function handleRandomImage(width = 50, height = 50) { + return `https://picsum.photos/${width}/${height}?random=${Random.guid()}`; +} + +/** + * @copyright chuzhixin 1204505056@qq.com + * @description 处理所有 controller 模块,npm run serve时在node环境中自动输出controller文件夹下Mock接口,请勿修改。 + * @returns {[]} + */ +function handleMockArray() { + const mockArray = []; + const getFiles = (jsonPath) => { + const jsonFiles = []; + const findJsonFile = (path) => { + const files = fs.readdirSync(path); + files.forEach((item) => { + const fPath = join(path, item); + const stat = fs.statSync(fPath); + if (stat.isDirectory() === true) findJsonFile(item); + if (stat.isFile() === true) jsonFiles.push(item); + }); + }; + findJsonFile(jsonPath); + jsonFiles.forEach((item) => mockArray.push(`./controller/${item}`)); + }; + getFiles("mock/controller"); + return mockArray; +} +module.exports = { + handleRandomImage, + handleMockArray, +}; diff --git a/package.json b/package.json new file mode 100644 index 0000000..5ab4110 --- /dev/null +++ b/package.json @@ -0,0 +1,132 @@ +{ + "name": "vue-admin-beautiful", + "version": "1.0.0", + "author": "chuzhixin 1204505056@qq.com", + "participants": [], + "homepage": "https://chu1204505056.gitee.io/vue-admin-beautiful", + "publishConfig": { + "registry": "https://npm.pkg.github.com/" + }, + "scripts": { + "serve": "vue-cli-service serve", + "build": "vue-cli-service build", + "build:report": "vue-cli-service build --report", + "globle": "npm install -g cnpm --registry=https://registry.npm.taobao.org&&cnpm i rimraf npm-check-updates nrm -g&&rimraf node_modules&&cnpm i", + "lint": "vue-cli-service lint --fix", + "lint:style": "stylelint-config-prettier-check", + "inspect": "vue-cli-service inspect", + "template": "plop", + "clear": "rimraf node_modules&&cnpm i&&increase-memory-limit", + "use:npm": "nrm use npm", + "use:taobao": "nrm use taobao", + "update": "ncu -u --concurrency 10 --timeout 80000&&cnpm i", + "update:globle": "ncu -g --concurrency 10 --timeout 80000", + "svgo": "svgo -f src/remixIcon/svg --config=svgo.yml", + "push": "start ./push.sh", + "deploy": "start ./deploy.sh", + "increase-memory-limit": "increase-memory-limit" + }, + "repository": { + "type": "git", + "url": "git+https://github.com/chuzhixin/vue-admin-beautiful.git" + }, + "husky": { + "hooks": { + "pre-commit": "lint-staged" + } + }, + "lint-staged": { + "src/**/*.{js,vue}": [ + "eslint --fix", + "git add" + ] + }, + "dependencies": { + "axios": "^0.20.0", + "better-scroll": "^2.0.4", + "clipboard": "^2.0.6", + "codemirror": "^5.58.1", + "core-js": "^3.6.5", + "dayjs": "^1.9.0", + "echarts": "^4.9.0", + "echarts-wordcloud": "^1.1.3", + "element-ui": "^2.13.2", + "file-saver": "^2.0.2", + "js-cookie": "^2.2.1", + "jsencrypt": "^3.0.0-rc.1", + "jsonlint": "^1.6.3", + "lodash": "^4.17.20", + "maptalks": "^0.49.1", + "mapv": "^2.0.57", + "nprogress": "^0.2.0", + "qs": "^6.9.4", + "screenfull": "^5.0.2", + "vue": "^2.6.12", + "vue-amap": "^0.5.10", + "vue-echarts": "^5.0.0-beta.0", + "vue-qart": "^2.2.0", + "vue-router": "^3.4.5", + "vuedraggable": "^2.24.1", + "vuex": "^3.5.1", + "zx-comparison": "^1.0.3", + "zx-count": "^0.3.7", + "zx-icon": "^1.1.9", + "zx-keel": "^0.9.4", + "zx-layouts": "^0.6.13", + "zx-magnifie": "^0.4.0", + "zx-markdown-editor": "^0.0.2", + "zx-player": "^1.0.1", + "zx-quill": "^0.0.2", + "zx-templates": "^0.0.22", + "zx-verify": "^0.0.2" + }, + "devDependencies": { + "@babel/register": "^7.11.5", + "@vue/cli-plugin-babel": "^4.5.6", + "@vue/cli-plugin-eslint": "^4.5.6", + "@vue/cli-plugin-router": "^4.5.6", + "@vue/cli-plugin-vuex": "^4.5.6", + "@vue/cli-service": "^4.5.6", + "@vue/eslint-config-prettier": "^6.0.0", + "autoprefixer": "^10.0.1", + "babel-eslint": "^10.1.0", + "babel-plugin-dynamic-import-node": "^2.3.3", + "compression-webpack-plugin": "^6.0.2", + "eslint": "^7.10.0", + "eslint-plugin-prettier": "^3.1.4", + "eslint-plugin-vue": "^6.2.2", + "filemanager-webpack-plugin": "^2.0.5", + "husky": "^4.3.0", + "image-webpack-loader": "^7.0.1", + "increase-memory-limit": "^1.0.7", + "lint-staged": "^10.4.0", + "mockjs": "^1.1.0", + "plop": "^2.7.4", + "prettier": "^2.1.2", + "sass": "^1.26.11", + "sass-loader": "^10.0.2", + "script-loader": "^0.7.2", + "stylelint": "^13.7.2", + "stylelint-config-prettier": "^8.0.2", + "stylelint-config-recess-order": "^2.1.0", + "svg-sprite-loader": "^5.0.0", + "svgo": "^1.3.2", + "vue-template-compiler": "^2.6.12", + "webpackbar": "^4.0.0" + }, + "keywords": [ + "vue", + "admin", + "dashboard", + "element-ui", + "vue-admin", + "element-admin", + "boilerplate", + "admin-template", + "management-system" + ], + "engines": { + "node": ">=8.9", + "npm": ">= 3.0.0" + } +} diff --git a/plopfile.js b/plopfile.js new file mode 100644 index 0000000..8fe16ee --- /dev/null +++ b/plopfile.js @@ -0,0 +1,13 @@ +const viewGenerator = require("zx-templates/view/prompt"); +const curdGenerator = require("zx-templates/curd/prompt"); +const componentGenerator = require("zx-templates/component/prompt"); +const mockGenerator = require("zx-templates/mock/prompt"); +const vuexGenerator = require("zx-templates/vuex/prompt"); + +module.exports = (plop) => { + plop.setGenerator("view", viewGenerator); + plop.setGenerator("curd", curdGenerator); + plop.setGenerator("component", componentGenerator); + plop.setGenerator("mock&api", mockGenerator); + plop.setGenerator("vuex", vuexGenerator); +}; diff --git a/prettier.config.js b/prettier.config.js new file mode 100644 index 0000000..a7628ac --- /dev/null +++ b/prettier.config.js @@ -0,0 +1,16 @@ +module.exports = { + printWidth: 80, + tabWidth: 2, + useTabs: false, + semi: true, + singleQuote: false, + quoteProps: "as-needed", + jsxSingleQuote: false, + trailingComma: "es5", + bracketSpacing: true, + jsxBracketSameLine: false, + arrowParens: "always", + htmlWhitespaceSensitivity: "ignore", + vueIndentScriptAndStyle: true, + endOfLine: "lf", +}; diff --git a/public/favicon.ico b/public/favicon.ico new file mode 100644 index 0000000..7c31c49 Binary files /dev/null and b/public/favicon.ico differ diff --git a/public/favicon_backup.ico b/public/favicon_backup.ico new file mode 100644 index 0000000..df36fcf Binary files /dev/null and b/public/favicon_backup.ico differ diff --git a/public/index.html b/public/index.html new file mode 100644 index 0000000..b876b3c --- /dev/null +++ b/public/index.html @@ -0,0 +1,52 @@ + + + + + + + + <%= VUE_APP_TITLE %> + + + + + + + + +
+
+
+ + + + + + +
+

<%= VUE_APP_TITLE %>

+
+
+ + + diff --git a/public/static/css/loading.css b/public/static/css/loading.css new file mode 100644 index 0000000..a7433cc --- /dev/null +++ b/public/static/css/loading.css @@ -0,0 +1,96 @@ +.first-loading-wrp { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + height: 90vh; + min-height: 90vh; +} + +.first-loading-wrp > h1 { + font-size: 30px; + font-weight: bolder; +} + +.first-loading-wrp .loading-wrp { + display: flex; + align-items: center; + justify-content: center; + padding: 98px; +} + +.dot { + position: relative; + box-sizing: border-box; + display: inline-block; + width: 64px; + height: 64px; + font-size: 64px; + transform: rotate(45deg); + animation: antRotate 1.2s infinite linear; +} + +.dot i { + position: absolute; + display: block; + width: 28px; + height: 28px; + background-color: #1890ff; + border-radius: 100%; + opacity: 0.3; + transform: scale(0.75); + transform-origin: 50% 50%; + animation: antSpinMove 1s infinite linear alternate; +} + +.dot i:nth-child(1) { + top: 0; + left: 0; +} + +.dot i:nth-child(2) { + top: 0; + right: 0; + -webkit-animation-delay: 0.4s; + animation-delay: 0.4s; +} + +.dot i:nth-child(3) { + right: 0; + bottom: 0; + -webkit-animation-delay: 0.8s; + animation-delay: 0.8s; +} + +.dot i:nth-child(4) { + bottom: 0; + left: 0; + -webkit-animation-delay: 1.2s; + animation-delay: 1.2s; +} + +@keyframes antRotate { + to { + -webkit-transform: rotate(405deg); + transform: rotate(405deg); + } +} + +@-webkit-keyframes antRotate { + to { + -webkit-transform: rotate(405deg); + transform: rotate(405deg); + } +} + +@keyframes antSpinMove { + to { + opacity: 1; + } +} + +@-webkit-keyframes antSpinMove { + to { + opacity: 1; + } +} diff --git a/push.sh b/push.sh new file mode 100644 index 0000000..ab6163e --- /dev/null +++ b/push.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env bash +set -e +git init +git add -A +git commit -m '🎉🎉🎉仓库重置到2020年9月29日,Vue2.6最后一个版本,之前版本不再支持,具体请查阅文档,Vue 3.0版本即将发布请耐心等待!!!' +git push -f "https://${access_token}@github.com/chuzhixin/vue-admin-beautiful.git" master +exec /bin/bash + + + + diff --git a/src/App.vue b/src/App.vue new file mode 100644 index 0000000..eb848ae --- /dev/null +++ b/src/App.vue @@ -0,0 +1,12 @@ + + + diff --git a/src/api/ad.js b/src/api/ad.js new file mode 100644 index 0000000..cb8411e --- /dev/null +++ b/src/api/ad.js @@ -0,0 +1,9 @@ +import request from "@/utils/request"; + +export function getList(data) { + return request({ + url: "/ad/getList", + method: "get", + data, + }); +} diff --git a/src/api/blacklist.js b/src/api/blacklist.js new file mode 100644 index 0000000..41c7621 --- /dev/null +++ b/src/api/blacklist.js @@ -0,0 +1,9 @@ +import request from "@/utils/request"; + +export function getList(data) { + return request({ + url: "/blacklist/getList", + method: "post", + data, + }); +} diff --git a/src/api/changeLog.js b/src/api/changeLog.js new file mode 100644 index 0000000..61936c7 --- /dev/null +++ b/src/api/changeLog.js @@ -0,0 +1,9 @@ +import request from "@/utils/request"; + +export function getList(data) { + return request({ + url: "/changeLog/getList", + method: "post", + data, + }); +} diff --git a/src/api/colorfulIcon.js b/src/api/colorfulIcon.js new file mode 100644 index 0000000..1144767 --- /dev/null +++ b/src/api/colorfulIcon.js @@ -0,0 +1,9 @@ +import request from "@/utils/request"; + +export function getIconList(data) { + return request({ + url: "/colorfulIcon/getList", + method: "post", + data, + }); +} diff --git a/src/api/github.js b/src/api/github.js new file mode 100644 index 0000000..f2e01a9 --- /dev/null +++ b/src/api/github.js @@ -0,0 +1,20 @@ +import request from "axios"; + +export function getRepos(params) { + return request({ + url: "https://api.github.com/repos/chuzhixin/vue-admin-beautiful", + method: "get", + params, + timeout: 10000, + }); +} + +export function getStargazers(params) { + return request({ + url: + "https://api.github.com/repos/chuzhixin/vue-admin-beautiful/stargazers", + method: "get", + params, + timeout: 10000, + }); +} diff --git a/src/api/goodsDetail.js b/src/api/goodsDetail.js new file mode 100644 index 0000000..4540689 --- /dev/null +++ b/src/api/goodsDetail.js @@ -0,0 +1,9 @@ +import request from "@/utils/request"; + +export function getList(data) { + return request({ + url: "/goodsDetail/getList", + method: "post", + data, + }); +} diff --git a/src/api/goodsList.js b/src/api/goodsList.js new file mode 100644 index 0000000..5bd5d28 --- /dev/null +++ b/src/api/goodsList.js @@ -0,0 +1,9 @@ +import request from "@/utils/request"; + +export function getList(data) { + return request({ + url: "/goodsList/getList", + method: "post", + data, + }); +} diff --git a/src/api/icon.js b/src/api/icon.js new file mode 100644 index 0000000..ec62152 --- /dev/null +++ b/src/api/icon.js @@ -0,0 +1,9 @@ +import request from "@/utils/request"; + +export function getIconList(data) { + return request({ + url: "/icon/getList", + method: "post", + data, + }); +} diff --git a/src/api/markdown.js b/src/api/markdown.js new file mode 100644 index 0000000..5197ec8 --- /dev/null +++ b/src/api/markdown.js @@ -0,0 +1,8 @@ +import request from "axios"; + +export function getList() { + return request({ + url: "https://cdn.jsdelivr.net/gh/prettier/prettier@master/docs/options.md", + method: "get", + }); +} diff --git a/src/api/menuManagement.js b/src/api/menuManagement.js new file mode 100644 index 0000000..c68d851 --- /dev/null +++ b/src/api/menuManagement.js @@ -0,0 +1,25 @@ +import request from "@/utils/request"; + +export function getTree(data) { + return request({ + url: "/menuManagement/getTree", + method: "post", + data, + }); +} + +export function doEdit(data) { + return request({ + url: "/menuManagement/doEdit", + method: "post", + data, + }); +} + +export function doDelete(data) { + return request({ + url: "/menuManagement/doDelete", + method: "post", + data, + }); +} diff --git a/src/api/notice.js b/src/api/notice.js new file mode 100644 index 0000000..a528ebb --- /dev/null +++ b/src/api/notice.js @@ -0,0 +1,8 @@ +import request from "@/utils/request"; + +export function getNoticeList() { + return request({ + url: "/notice/getList", + method: "post", + }); +} diff --git a/src/api/personalCenter.js b/src/api/personalCenter.js new file mode 100644 index 0000000..3626f68 --- /dev/null +++ b/src/api/personalCenter.js @@ -0,0 +1,25 @@ +import request from "@/utils/request"; + +export function getList(data) { + return request({ + url: "/personalCenter/getList", + method: "post", + data, + }); +} + +export function doEdit(data) { + return request({ + url: "/personalCenter/doEdit", + method: "post", + data, + }); +} + +export function doDelete(data) { + return request({ + url: "/personalCenter/doDelete", + method: "post", + data, + }); +} diff --git a/src/api/publicKey.js b/src/api/publicKey.js new file mode 100644 index 0000000..a4c1853 --- /dev/null +++ b/src/api/publicKey.js @@ -0,0 +1,8 @@ +import request from "@/utils/request"; + +export function getPublicKey() { + return request({ + url: "/publicKey", + method: "post", + }); +} diff --git a/src/api/remixIcon.js b/src/api/remixIcon.js new file mode 100644 index 0000000..5483110 --- /dev/null +++ b/src/api/remixIcon.js @@ -0,0 +1,9 @@ +import request from "@/utils/request"; + +export function getIconList(data) { + return request({ + url: "/remixIcon/getList", + method: "post", + data, + }); +} diff --git a/src/api/roleManagement.js b/src/api/roleManagement.js new file mode 100644 index 0000000..500645b --- /dev/null +++ b/src/api/roleManagement.js @@ -0,0 +1,25 @@ +import request from "@/utils/request"; + +export function getList(data) { + return request({ + url: "/roleManagement/getList", + method: "post", + data, + }); +} + +export function doEdit(data) { + return request({ + url: "/roleManagement/doEdit", + method: "post", + data, + }); +} + +export function doDelete(data) { + return request({ + url: "/roleManagement/doDelete", + method: "post", + data, + }); +} diff --git a/src/api/router.js b/src/api/router.js new file mode 100644 index 0000000..563bfe3 --- /dev/null +++ b/src/api/router.js @@ -0,0 +1,9 @@ +import request from "@/utils/request"; + +export function getRouterList(data) { + return request({ + url: "/menu/navigate", + method: "post", + data, + }); +} diff --git a/src/api/table.js b/src/api/table.js new file mode 100644 index 0000000..5e60896 --- /dev/null +++ b/src/api/table.js @@ -0,0 +1,25 @@ +import request from "@/utils/request"; + +export function getList(data) { + return request({ + url: "/table/getList", + method: "post", + data, + }); +} + +export function doEdit(data) { + return request({ + url: "/table/doEdit", + method: "post", + data, + }); +} + +export function doDelete(data) { + return request({ + url: "/table/doDelete", + method: "post", + data, + }); +} diff --git a/src/api/tree.js b/src/api/tree.js new file mode 100644 index 0000000..471a49b --- /dev/null +++ b/src/api/tree.js @@ -0,0 +1,9 @@ +import request from "@/utils/request"; + +export function getTreeList(data) { + return request({ + url: "/tree/list", + method: "post", + data, + }); +} diff --git a/src/api/user.js b/src/api/user.js new file mode 100644 index 0000000..9367d89 --- /dev/null +++ b/src/api/user.js @@ -0,0 +1,38 @@ +import request from "@/utils/request"; +import { encryptedData } from "@/utils/encrypt"; +import { loginRSA, tokenName } from "@/config/settings"; + +export async function login(data) { + if (loginRSA) { + data = await encryptedData(data); + } + return request({ + url: "/login", + method: "post", + data, + }); +} + +export function getUserInfo(accessToken) { + return request({ + url: "/userInfo", + method: "post", + data: { + [tokenName]: accessToken, + }, + }); +} + +export function logout() { + return request({ + url: "/logout", + method: "post", + }); +} + +export function register() { + return request({ + url: "/register", + method: "post", + }); +} diff --git a/src/api/userManagement.js b/src/api/userManagement.js new file mode 100644 index 0000000..ce923d6 --- /dev/null +++ b/src/api/userManagement.js @@ -0,0 +1,25 @@ +import request from "@/utils/request"; + +export function getList(data) { + return request({ + url: "/userManagement/getList", + method: "post", + data, + }); +} + +export function doEdit(data) { + return request({ + url: "/userManagement/doEdit", + method: "post", + data, + }); +} + +export function doDelete(data) { + return request({ + url: "/userManagement/doDelete", + method: "post", + data, + }); +} diff --git a/src/assets/comparison/left.jpg b/src/assets/comparison/left.jpg new file mode 100644 index 0000000..f5133cf Binary files /dev/null and b/src/assets/comparison/left.jpg differ diff --git a/src/assets/comparison/right.jpg b/src/assets/comparison/right.jpg new file mode 100644 index 0000000..625a53f Binary files /dev/null and b/src/assets/comparison/right.jpg differ diff --git a/src/assets/error_images/401.png b/src/assets/error_images/401.png new file mode 100644 index 0000000..90bbf6e Binary files /dev/null and b/src/assets/error_images/401.png differ diff --git a/src/assets/error_images/404.png b/src/assets/error_images/404.png new file mode 100644 index 0000000..14fa725 Binary files /dev/null and b/src/assets/error_images/404.png differ diff --git a/src/assets/error_images/cloud.png b/src/assets/error_images/cloud.png new file mode 100644 index 0000000..247c06b Binary files /dev/null and b/src/assets/error_images/cloud.png differ diff --git a/src/assets/ewm.png b/src/assets/ewm.png new file mode 100644 index 0000000..a97a6ad Binary files /dev/null and b/src/assets/ewm.png differ diff --git a/src/assets/login_images/background.jpg b/src/assets/login_images/background.jpg new file mode 100644 index 0000000..87ac496 Binary files /dev/null and b/src/assets/login_images/background.jpg differ diff --git a/src/assets/pro.png b/src/assets/pro.png new file mode 100644 index 0000000..09bcef5 Binary files /dev/null and b/src/assets/pro.png differ diff --git a/src/assets/qr_logo/lqr_logo.png b/src/assets/qr_logo/lqr_logo.png new file mode 100644 index 0000000..f81db46 Binary files /dev/null and b/src/assets/qr_logo/lqr_logo.png differ diff --git a/src/colorfulIcon/index.js b/src/colorfulIcon/index.js new file mode 100644 index 0000000..245c2b2 --- /dev/null +++ b/src/colorfulIcon/index.js @@ -0,0 +1,17 @@ +import Vue from "vue"; +import { ColorfullIcon } from "@/layouts/components"; + +Vue.component("vab-colorful-icon", ColorfullIcon); +const req = require.context("./svg", false, /\.svg$/), + requireAll = (requireContext) => { + /*let a = requireContext.keys().map(requireContext); + let arr = []; + for (let i = 0; i < a.length; i++) { + console.log(); + let icon = a[i].default.id; + arr.push(icon); + } + console.log(JSON.stringify(arr));*/ + return requireContext.keys().map(requireContext); + }; +requireAll(req); diff --git a/src/colorfulIcon/svg/alphabetical_sorting.svg b/src/colorfulIcon/svg/alphabetical_sorting.svg new file mode 100644 index 0000000..3cfa035 --- /dev/null +++ b/src/colorfulIcon/svg/alphabetical_sorting.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/colorfulIcon/svg/vab.svg b/src/colorfulIcon/svg/vab.svg new file mode 100644 index 0000000..5c46271 --- /dev/null +++ b/src/colorfulIcon/svg/vab.svg @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + diff --git a/src/components/JsonEditor/index.vue b/src/components/JsonEditor/index.vue new file mode 100644 index 0000000..f72dc51 --- /dev/null +++ b/src/components/JsonEditor/index.vue @@ -0,0 +1,111 @@ + + + + + diff --git a/src/views/vab/codeGenerator/components/snippetTable.js b/src/views/vab/codeGenerator/components/snippetTable.js new file mode 100644 index 0000000..0ce4ba5 --- /dev/null +++ b/src/views/vab/codeGenerator/components/snippetTable.js @@ -0,0 +1,154 @@ +import { genTableColumnSnippet } from "./snippetTableColumn"; + +export const genTableSnippet = (headers = "getList") => { + return ` + + + +`; +}; diff --git a/src/views/vab/codeGenerator/components/snippetTableColumn.js b/src/views/vab/codeGenerator/components/snippetTableColumn.js new file mode 100644 index 0000000..6b39700 --- /dev/null +++ b/src/views/vab/codeGenerator/components/snippetTableColumn.js @@ -0,0 +1,40 @@ +const timeFieldNeedHandle = { + created_at: true, + create_time: true, + updated_at: true, + update_time: true, + start_time: true, + end_time: true, +}; +const genTableColumnSnippetSimple = (key, label) => { + return ``; +}; + +const genTabeleColumnSinppetTemplate = (key, label) => { + let val = ""; + if (timeFieldNeedHandle[key]) { + val = `parseTime(row.${key})`; + } else { + val = `row.${key}`; + } + return ` + + `; +}; + +export const genTableColumnSnippet = (headers) => { + return headers + .filter((header) => { + return header.show; + }) + .map((header) => { + if (timeFieldNeedHandle[header.key] || header.opt === "template") { + return genTabeleColumnSinppetTemplate(header.key, header.label); + } else { + return genTableColumnSnippetSimple(header.key, header.label); + } + }) + .join("\n "); +}; diff --git a/src/views/vab/codeGenerator/index.vue b/src/views/vab/codeGenerator/index.vue new file mode 100644 index 0000000..3af1ebe --- /dev/null +++ b/src/views/vab/codeGenerator/index.vue @@ -0,0 +1,36 @@ + + + diff --git a/src/views/vab/echarts/index.vue b/src/views/vab/echarts/index.vue new file mode 100644 index 0000000..9c03214 --- /dev/null +++ b/src/views/vab/echarts/index.vue @@ -0,0 +1,652 @@ + + + + + diff --git a/src/views/vab/editor/index.vue b/src/views/vab/editor/index.vue new file mode 100644 index 0000000..07264c5 --- /dev/null +++ b/src/views/vab/editor/index.vue @@ -0,0 +1,128 @@ + + + + diff --git a/src/views/vab/element/index.vue b/src/views/vab/element/index.vue new file mode 100644 index 0000000..b126c15 --- /dev/null +++ b/src/views/vab/element/index.vue @@ -0,0 +1,254 @@ + + + + + diff --git a/src/views/vab/errorLog/components/ErrorTest.vue b/src/views/vab/errorLog/components/ErrorTest.vue new file mode 100644 index 0000000..a64aadd --- /dev/null +++ b/src/views/vab/errorLog/components/ErrorTest.vue @@ -0,0 +1,13 @@ + + + diff --git a/src/views/vab/errorLog/index.vue b/src/views/vab/errorLog/index.vue new file mode 100644 index 0000000..67cf725 --- /dev/null +++ b/src/views/vab/errorLog/index.vue @@ -0,0 +1,28 @@ + + + diff --git a/src/views/vab/form/index.vue b/src/views/vab/form/index.vue new file mode 100644 index 0000000..3b5bdb2 --- /dev/null +++ b/src/views/vab/form/index.vue @@ -0,0 +1,111 @@ + + + diff --git a/src/views/vab/icon/colorfulIcon.vue b/src/views/vab/icon/colorfulIcon.vue new file mode 100644 index 0000000..f199989 --- /dev/null +++ b/src/views/vab/icon/colorfulIcon.vue @@ -0,0 +1,155 @@ + + + + + diff --git a/src/views/vab/icon/index.vue b/src/views/vab/icon/index.vue new file mode 100644 index 0000000..1a162f2 --- /dev/null +++ b/src/views/vab/icon/index.vue @@ -0,0 +1,141 @@ + + + + + diff --git a/src/views/vab/icon/remixIcon.vue b/src/views/vab/icon/remixIcon.vue new file mode 100644 index 0000000..9ca38c0 --- /dev/null +++ b/src/views/vab/icon/remixIcon.vue @@ -0,0 +1,153 @@ + + + + + diff --git a/src/views/vab/imgComparison/index.vue b/src/views/vab/imgComparison/index.vue new file mode 100644 index 0000000..dbd14b5 --- /dev/null +++ b/src/views/vab/imgComparison/index.vue @@ -0,0 +1,53 @@ + + + diff --git a/src/views/vab/loading/index.vue b/src/views/vab/loading/index.vue new file mode 100644 index 0000000..509edee --- /dev/null +++ b/src/views/vab/loading/index.vue @@ -0,0 +1,71 @@ + + + + + diff --git a/src/views/vab/lodash/index.vue b/src/views/vab/lodash/index.vue new file mode 100644 index 0000000..9e0676e --- /dev/null +++ b/src/views/vab/lodash/index.vue @@ -0,0 +1,211 @@ + + + + diff --git a/src/views/vab/magnifier/index.vue b/src/views/vab/magnifier/index.vue new file mode 100644 index 0000000..733b48a --- /dev/null +++ b/src/views/vab/magnifier/index.vue @@ -0,0 +1,35 @@ + + + diff --git a/src/views/vab/map/index.vue b/src/views/vab/map/index.vue new file mode 100644 index 0000000..a493949 --- /dev/null +++ b/src/views/vab/map/index.vue @@ -0,0 +1,115 @@ + + + + diff --git a/src/views/vab/markdown/index.vue b/src/views/vab/markdown/index.vue new file mode 100644 index 0000000..b073566 --- /dev/null +++ b/src/views/vab/markdown/index.vue @@ -0,0 +1,68 @@ + + + diff --git a/src/views/vab/markdownEditor/index.vue b/src/views/vab/markdownEditor/index.vue new file mode 100644 index 0000000..a8c5190 --- /dev/null +++ b/src/views/vab/markdownEditor/index.vue @@ -0,0 +1,51 @@ + + + diff --git a/src/views/vab/more/index.vue b/src/views/vab/more/index.vue new file mode 100644 index 0000000..f946ca4 --- /dev/null +++ b/src/views/vab/more/index.vue @@ -0,0 +1,142 @@ + + + + diff --git a/src/views/vab/nested/menu1/index.vue b/src/views/vab/nested/menu1/index.vue new file mode 100644 index 0000000..43702fc --- /dev/null +++ b/src/views/vab/nested/menu1/index.vue @@ -0,0 +1,7 @@ + diff --git a/src/views/vab/nested/menu1/menu1-1/index.vue b/src/views/vab/nested/menu1/menu1-1/index.vue new file mode 100644 index 0000000..4e4684b --- /dev/null +++ b/src/views/vab/nested/menu1/menu1-1/index.vue @@ -0,0 +1,13 @@ + + diff --git a/src/views/vab/nested/menu1/menu1-1/menu1-1-1/index.vue b/src/views/vab/nested/menu1/menu1-1/menu1-1-1/index.vue new file mode 100644 index 0000000..6b2f87c --- /dev/null +++ b/src/views/vab/nested/menu1/menu1-1/menu1-1-1/index.vue @@ -0,0 +1,15 @@ + + diff --git a/src/views/vab/permissions/index.vue b/src/views/vab/permissions/index.vue new file mode 100644 index 0000000..5fb8548 --- /dev/null +++ b/src/views/vab/permissions/index.vue @@ -0,0 +1,166 @@ + + + diff --git a/src/views/vab/player/index.vue b/src/views/vab/player/index.vue new file mode 100644 index 0000000..916a9f4 --- /dev/null +++ b/src/views/vab/player/index.vue @@ -0,0 +1,73 @@ + + + diff --git a/src/views/vab/qrCode/index.vue b/src/views/vab/qrCode/index.vue new file mode 100644 index 0000000..9579278 --- /dev/null +++ b/src/views/vab/qrCode/index.vue @@ -0,0 +1,46 @@ + + + + + diff --git a/src/views/vab/smallComponents/index.vue b/src/views/vab/smallComponents/index.vue new file mode 100644 index 0000000..e82d26d --- /dev/null +++ b/src/views/vab/smallComponents/index.vue @@ -0,0 +1,110 @@ + + + + diff --git a/src/views/vab/sticky/index.vue b/src/views/vab/sticky/index.vue new file mode 100644 index 0000000..4de9cf2 --- /dev/null +++ b/src/views/vab/sticky/index.vue @@ -0,0 +1,314 @@ + + + + diff --git a/src/views/vab/table/components/TableEdit.vue b/src/views/vab/table/components/TableEdit.vue new file mode 100644 index 0000000..aabae6f --- /dev/null +++ b/src/views/vab/table/components/TableEdit.vue @@ -0,0 +1,75 @@ + + + diff --git a/src/views/vab/table/index.vue b/src/views/vab/table/index.vue new file mode 100644 index 0000000..579c70d --- /dev/null +++ b/src/views/vab/table/index.vue @@ -0,0 +1,264 @@ + + + diff --git a/src/views/vab/table/inlineEditTable.vue b/src/views/vab/table/inlineEditTable.vue new file mode 100644 index 0000000..b0e7939 --- /dev/null +++ b/src/views/vab/table/inlineEditTable.vue @@ -0,0 +1,109 @@ + + + diff --git a/src/views/vab/tree/index.vue b/src/views/vab/tree/index.vue new file mode 100644 index 0000000..67b4757 --- /dev/null +++ b/src/views/vab/tree/index.vue @@ -0,0 +1,478 @@ + + + diff --git a/src/views/vab/upload/index.vue b/src/views/vab/upload/index.vue new file mode 100644 index 0000000..f5c4cc9 --- /dev/null +++ b/src/views/vab/upload/index.vue @@ -0,0 +1,34 @@ + + + diff --git a/src/views/vab/verify/index.vue b/src/views/vab/verify/index.vue new file mode 100644 index 0000000..52fce2d --- /dev/null +++ b/src/views/vab/verify/index.vue @@ -0,0 +1,35 @@ + + + diff --git a/src/views/vab/webSocket/index.vue b/src/views/vab/webSocket/index.vue new file mode 100644 index 0000000..b2b30cc --- /dev/null +++ b/src/views/vab/webSocket/index.vue @@ -0,0 +1,87 @@ + + + diff --git a/svgo.yml b/svgo.yml new file mode 100644 index 0000000..31ca449 --- /dev/null +++ b/svgo.yml @@ -0,0 +1,4 @@ +plugins: + - removeAttrs: + attrs: + - "fill-rule" diff --git a/vue.config.js b/vue.config.js new file mode 100644 index 0000000..da25fbb --- /dev/null +++ b/vue.config.js @@ -0,0 +1,216 @@ +const path = require("path"); +const { + publicPath, + assetsDir, + outputDir, + lintOnSave, + transpileDependencies, + title, + abbreviation, + devPort, + providePlugin, + build7z, + donation, +} = require("./src/config/settings"); +const { + webpackBarName, + webpackBanner, + donationConsole, +} = require("zx-layouts"); + +if (donation) donationConsole(); +const { version, author } = require("./package.json"); +const Webpack = require("webpack"); +const WebpackBar = require("webpackbar"); +const FileManagerPlugin = require("filemanager-webpack-plugin"); +const dayjs = require("dayjs"); +const date = dayjs().format("YYYY_M_D"); +const time = dayjs().format("YYYY-M-D HH:mm:ss"); +const CompressionWebpackPlugin = require("compression-webpack-plugin"); +const productionGzipExtensions = ["html", "js", "css", "svg"]; +process.env.VUE_APP_TITLE = title || "vue-admin-beautiful"; +process.env.VUE_APP_AUTHOR = author || "chuzhixin 1204505056@qq.com"; +process.env.VUE_APP_UPDATE_TIME = time; +process.env.VUE_APP_VERSION = version; + +const resolve = (dir) => { + return path.join(__dirname, dir); +}; + +const mockServer = () => { + if (process.env.NODE_ENV === "development") { + return require("./mock/mockServer.js"); + } else { + return ""; + } +}; + +module.exports = { + publicPath, + assetsDir, + outputDir, + lintOnSave, + transpileDependencies, + devServer: { + hot: true, + port: devPort, + open: true, + noInfo: false, + overlay: { + warnings: true, + errors: true, + }, + after: mockServer(), + }, + configureWebpack() { + return { + resolve: { + alias: { + "@": resolve("src"), + }, + }, + plugins: [ + new Webpack.ProvidePlugin(providePlugin), + new WebpackBar({ + name: webpackBarName, + }), + ], + }; + }, + chainWebpack(config) { + /* config.plugins.delete("preload"); + config.plugins.delete("prefetch"); */ + config.module + .rule("svg") + .exclude.add(resolve("src/remixIcon")) + .add(resolve("src/colorfulIcon")) + .end(); + + config.module + .rule("remixIcon") + .test(/\.svg$/) + .include.add(resolve("src/remixIcon")) + .end() + .use("svg-sprite-loader") + .loader("svg-sprite-loader") + .options({ symbolId: "remix-icon-[name]" }) + .end(); + + config.module + .rule("colorfulIcon") + .test(/\.svg$/) + .include.add(resolve("src/colorfulIcon")) + .end() + .use("svg-sprite-loader") + .loader("svg-sprite-loader") + .options({ symbolId: "colorful-icon-[name]" }) + .end(); + + config.when(process.env.NODE_ENV === "development", (config) => { + config.devtool("source-map"); + }); + config.when(process.env.NODE_ENV !== "development", (config) => { + config.performance.set("hints", false); + config.devtool("none"); + config.optimization.splitChunks({ + chunks: "all", + cacheGroups: { + libs: { + name: "chunk-libs", + test: /[\\/]node_modules[\\/]/, + priority: 10, + chunks: "initial", + }, + elementUI: { + name: "chunk-elementUI", + priority: 20, + test: /[\\/]node_modules[\\/]_?element-ui(.*)/, + }, + fortawesome: { + name: "chunk-fortawesome", + priority: 20, + test: /[\\/]node_modules[\\/]_?@fortawesome(.*)/, + }, + commons: { + name: "chunk-commons", + test: resolve("src/components"), + minChunks: 3, + priority: 5, + reuseExistingChunk: true, + }, + }, + }); + config + .plugin("banner") + .use(Webpack.BannerPlugin, [`${webpackBanner}${time}`]) + .end(); + config + .plugin("compression") + .use(CompressionWebpackPlugin, [ + { + filename: "[path].gz[query]", + algorithm: "gzip", + test: new RegExp( + "\\.(" + productionGzipExtensions.join("|") + ")$" + ), + threshold: 8192, + minRatio: 0.8, + }, + ]) + .end(); + config.module + .rule("images") + .use("image-webpack-loader") + .loader("image-webpack-loader") + .options({ + bypassOnDebug: true, + }) + .end(); + }); + + if (build7z) { + config.when(process.env.NODE_ENV === "production", (config) => { + config + .plugin("fileManager") + .use(FileManagerPlugin, [ + { + onEnd: { + delete: [`./${outputDir}/video`, `./${outputDir}/data`], + archive: [ + { + source: `./${outputDir}`, + destination: `./${outputDir}/${abbreviation}_${outputDir}_${date}.7z`, + }, + ], + }, + }, + ]) + .end(); + }); + } + }, + runtimeCompiler: true, + productionSourceMap: false, + css: { + requireModuleExtension: true, + sourceMap: true, + loaderOptions: { + scss: { + /*sass-loader 8.0语法 */ + //prependData: '@import "~@/styles/variables.scss";', + + /*sass-loader 9.0写法,感谢github用户 shaonialife*/ + additionalData(content, loaderContext) { + const { resourcePath, rootContext } = loaderContext; + const relativePath = path.relative(rootContext, resourcePath); + if ( + relativePath.replace(/\\/g, "/") !== "src/styles/variables.scss" + ) { + return '@import "~@/styles/variables.scss";' + content; + } + return content; + }, + }, + }, + }, +}; diff --git a/webstorm.config.js b/webstorm.config.js new file mode 100644 index 0000000..6ec934d --- /dev/null +++ b/webstorm.config.js @@ -0,0 +1,3 @@ +"use strict"; +const webpackConfig = require("@vue/cli-service/webpack.config.js"); +module.exports = webpackConfig;