├── .editorconfig ├── .env.development ├── .env.production ├── .env.staging ├── .eslintignore ├── .eslintrc.js ├── .github ├── ISSUE_TEMPLATE │ ├── config.yml │ ├── issue-template-bug.md │ ├── issue-template-feature.md │ └── question-report.md ├── pull-request-template.md ├── release-drafter.yml └── workflows │ ├── dist-to-release.yml │ ├── reademe-contributors.yml │ └── release.yml ├── .gitignore ├── Dockerfile ├── LICENSE ├── README.md ├── babel.config.js ├── build └── index.js ├── default.conf ├── jest.config.js ├── jsconfig.json ├── package.json ├── plop-templates ├── component │ ├── index.hbs │ └── prompt.js ├── store │ ├── index.hbs │ └── prompt.js ├── utils.js └── view │ ├── index.hbs │ └── prompt.js ├── plopfile.js ├── postcss.config.js ├── public ├── favicon.ico ├── goldapadmin.ico └── index.html ├── src ├── App.vue ├── api │ ├── dashboards │ │ └── dashboard.js │ ├── log │ │ └── operationLog.js │ ├── personnel │ │ ├── fieldRelation.js │ │ ├── group.js │ │ └── user.js │ └── system │ │ ├── api.js │ │ ├── base.js │ │ ├── menu.js │ │ ├── role.js │ │ └── user.js ├── assets │ ├── 401_images │ │ └── 401.gif │ ├── 404_images │ │ ├── 404.png │ │ └── 404_cloud.png │ ├── backgd-image │ │ ├── aaa.png │ │ └── login.jpeg │ ├── custom-theme │ │ ├── fonts │ │ │ ├── element-icons.ttf │ │ │ └── element-icons.woff │ │ └── index.css │ ├── iconfont │ │ └── font │ │ │ ├── demo.css │ │ │ ├── demo_index.html │ │ │ ├── iconfont.css │ │ │ ├── iconfont.js │ │ │ ├── iconfont.json │ │ │ ├── iconfont.ttf │ │ │ ├── iconfont.woff │ │ │ └── iconfont.woff2 │ └── sidebar-logo │ │ └── goldapadmin.png ├── components │ ├── Breadcrumb │ │ └── index.vue │ ├── Echarts │ │ ├── BarChart.vue │ │ ├── PieChart.vue │ │ └── RadarChart.vue │ ├── ErrorLog │ │ └── index.vue │ ├── GithubCorner │ │ └── index.vue │ ├── Hamburger │ │ └── index.vue │ ├── HeaderSearch │ │ └── index.vue │ ├── IconSelect │ │ ├── index.vue │ │ └── requireIcons.js │ ├── ImageCropper │ │ ├── index.vue │ │ └── utils │ │ │ ├── data2blob.js │ │ │ ├── effectRipple.js │ │ │ ├── language.js │ │ │ └── mimes.js │ ├── JsonEditor │ │ └── index.vue │ ├── MDinput │ │ └── index.vue │ ├── MarkdownEditor │ │ ├── default-options.js │ │ └── index.vue │ ├── Pagination │ │ └── index.vue │ ├── PanThumb │ │ └── index.vue │ ├── RightPanel │ │ └── index.vue │ ├── Screenfull │ │ └── index.vue │ ├── Share │ │ └── DropdownMenu.vue │ ├── SizeSelect │ │ └── index.vue │ ├── Sticky │ │ └── index.vue │ ├── SvgIcon │ │ └── index.vue │ ├── TextHoverEffect │ │ └── Mallki.vue │ ├── ThemePicker │ │ └── index.vue │ ├── Tinymce │ │ ├── components │ │ │ └── EditorImage.vue │ │ ├── dynamicLoadScript.js │ │ ├── index.vue │ │ ├── plugins.js │ │ └── toolbar.js │ ├── Upload │ │ ├── SingleImage.vue │ │ ├── SingleImage2.vue │ │ └── SingleImage3.vue │ └── UploadExcel │ │ └── index.vue ├── directive │ ├── clipboard │ │ ├── clipboard.js │ │ └── index.js │ ├── el-drag-dialog │ │ ├── drag.js │ │ └── index.js │ ├── el-table │ │ ├── adaptive.js │ │ └── index.js │ ├── permission │ │ ├── index.js │ │ └── permission.js │ ├── sticky.js │ └── waves │ │ ├── index.js │ │ ├── waves.css │ │ └── waves.js ├── filters │ └── index.js ├── icons │ ├── index.js │ ├── svg │ │ ├── 404.svg │ │ ├── api1.svg │ │ ├── back-top.svg │ │ ├── bug.svg │ │ ├── chart.svg │ │ ├── clipboard.svg │ │ ├── component.svg │ │ ├── dashboard.svg │ │ ├── documentation.svg │ │ ├── drag.svg │ │ ├── edit.svg │ │ ├── education.svg │ │ ├── email.svg │ │ ├── example.svg │ │ ├── excel.svg │ │ ├── exit-fullscreen.svg │ │ ├── eye-off.svg │ │ ├── eye-on.svg │ │ ├── eye-open.svg │ │ ├── eye.svg │ │ ├── form.svg │ │ ├── fullscreen.svg │ │ ├── guide-2.svg │ │ ├── guide.svg │ │ ├── hamburger.svg │ │ ├── icon.svg │ │ ├── international.svg │ │ ├── language.svg │ │ ├── like.svg │ │ ├── link.svg │ │ ├── list.svg │ │ ├── lock.svg │ │ ├── menu1.svg │ │ ├── message.svg │ │ ├── money.svg │ │ ├── nested.svg │ │ ├── password.svg │ │ ├── pdf.svg │ │ ├── people.svg │ │ ├── peoples.svg │ │ ├── qq.svg │ │ ├── search.svg │ │ ├── shopping.svg │ │ ├── size.svg │ │ ├── skill.svg │ │ ├── star.svg │ │ ├── tab.svg │ │ ├── table.svg │ │ ├── theme.svg │ │ ├── tree-table.svg │ │ ├── tree.svg │ │ ├── user.svg │ │ ├── wechat.svg │ │ └── zip.svg │ └── svgo.yml ├── layout │ ├── components │ │ ├── AppMain.vue │ │ ├── Navbar.vue │ │ ├── Settings │ │ │ └── index.vue │ │ ├── Sidebar │ │ │ ├── FixiOSBug.js │ │ │ ├── Item.vue │ │ │ ├── Link.vue │ │ │ ├── Logo.vue │ │ │ ├── SidebarItem.vue │ │ │ └── index.vue │ │ ├── TagsView │ │ │ ├── ScrollPane.vue │ │ │ └── index.vue │ │ └── index.js │ ├── index.vue │ └── mixin │ │ └── ResizeHandler.js ├── main.js ├── permission.js ├── router │ └── index.js ├── settings.js ├── store │ ├── getters.js │ ├── index.js │ └── modules │ │ ├── app.js │ │ ├── errorLog.js │ │ ├── permission.js │ │ ├── settings.js │ │ ├── tagsView.js │ │ └── user.js ├── styles │ ├── btn.scss │ ├── element-ui.scss │ ├── element-variables.scss │ ├── index.scss │ ├── mixin.scss │ ├── sidebar.scss │ ├── transition.scss │ └── variables.scss ├── utils │ ├── auth.js │ ├── clipboard.js │ ├── error-log.js │ ├── get-page-title.js │ ├── index.js │ ├── open-window.js │ ├── permission.js │ ├── request.js │ ├── scroll-to.js │ └── validate.js ├── vendor │ ├── Export2Excel.js │ └── Export2Zip.js └── views │ ├── changePassword │ └── index.vue │ ├── dashboard │ ├── components │ │ ├── LineChart.vue │ │ ├── PanelGroup.vue │ │ └── mixins │ │ │ └── resize.js │ └── index.vue │ ├── error-page │ ├── 401.vue │ └── 404.vue │ ├── groupUser │ └── userList │ │ └── index.vue │ ├── log │ └── operation-log │ │ └── index.vue │ ├── login │ └── index.vue │ ├── personnel │ ├── fieldRelation │ │ └── index.vue │ ├── group │ │ └── index.vue │ └── user │ │ └── index.vue │ ├── profile │ ├── components │ │ ├── Account.vue │ │ └── UserCard.vue │ └── index.vue │ ├── redirect │ └── index.vue │ └── system │ ├── api │ └── index.vue │ ├── menu │ └── index.vue │ └── role │ └── index.vue ├── tests └── unit │ ├── .eslintrc.js │ ├── components │ ├── Hamburger.spec.js │ └── SvgIcon.spec.js │ └── utils │ ├── formatTime.spec.js │ ├── param2Obj.spec.js │ ├── parseTime.spec.js │ └── validate.spec.js └── vue.config.js /.editorconfig: -------------------------------------------------------------------------------- 1 | # https://editorconfig.org 2 | root = true 3 | 4 | [*] 5 | charset = utf-8 6 | indent_style = space 7 | indent_size = 2 8 | end_of_line = lf 9 | insert_final_newline = true 10 | trim_trailing_whitespace = true 11 | 12 | [*.md] 13 | insert_final_newline = false 14 | trim_trailing_whitespace = false 15 | -------------------------------------------------------------------------------- /.env.development: -------------------------------------------------------------------------------- 1 | # just a flag 2 | ENV = 'development' 3 | 4 | # base api 5 | VUE_APP_BASE_API = 'http://localhost:8888/' 6 | VUE_APP_WS_API = 'ws://localhost:8088' 7 | VUE_APP_PUBLIC_KEY="-----BEGIN DEV PUBLIC KEY-----\nMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDbOYcY8HbDaNM9ooYXoc9s+R5o\nR05ZL1BsVKadQBgOVH/kj7PQuD+ABEFVgB6rJNi287fRuZeZR+MCoG72H+AYsAhR\nsEaB5SuI7gDEstXuTyjhx5bz0wUujbDK4VMgRfPO6MQo+A0c95OadDEvEQDG3KBQ\nwLXapv+ZfsjG7NgdawIDAQAB\n-----END DEV PUBLIC KEY-----" 8 | -------------------------------------------------------------------------------- /.env.production: -------------------------------------------------------------------------------- 1 | # just a flag 2 | ENV = 'production' 3 | 4 | # base api 5 | VUE_APP_BASE_API = 'http://localhost:8888/' 6 | VUE_APP_WS_API = 'ws://localhost:8088' 7 | VUE_APP_PUBLIC_KEY="-----BEGIN PUBLIC KEY-----\nMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDbOYcY8HbDaNM9ooYXoc9s+R5o\nR05ZL1BsVKadQBgOVH/kj7PQuD+ABEFVgB6rJNi287fRuZeZR+MCoG72H+AYsAhR\nsEaB5SuI7gDEstXuTyjhx5bz0wUujbDK4VMgRfPO6MQo+A0c95OadDEvEQDG3KBQ\nwLXapv+ZfsjG7NgdawIDAQAB\n-----END PUBLIC KEY-----" 8 | 9 | -------------------------------------------------------------------------------- /.env.staging: -------------------------------------------------------------------------------- 1 | NODE_ENV = production 2 | 3 | # just a flag 4 | ENV = 'staging' 5 | 6 | # base api 7 | VUE_APP_BASE_API = '/stage-api' 8 | 9 | -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | build/*.js 2 | src/assets 3 | public 4 | dist 5 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/config.yml: -------------------------------------------------------------------------------- 1 | blank_issues_enabled: false 2 | contact_links: 3 | - name: 📜 官方文档 | GO Ldap Admin Doc 4 | url: http://ldapdoc.eryajf.net 5 | about: 关于项目的功能用法以及设计考量,都会在官网进行呈现,提交问题之前,请先阅读官方文档,如果还不能满足,则再提问题。 6 | - name: 👀 Github论坛 | GitHub Discussions 7 | url: https://github.com/eryajf/go-ldap-admin/discussions 8 | about: 如果您的问题不是功能或者错误,请转到讨论面板并在提交之前检索您的问题是否已经存在。 9 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/issue-template-bug.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: 🐛 错误报告 | Bug Report 3 | about: 请详细描述您使用过程中遇到的问题。| Please describe in detail the problems you encountered in the process of using. 4 | title: "🐛 一些问题。。。 | [Bug] Some problem..." 5 | labels: ["bug"] 6 | --- 7 | 8 | 9 | 10 | #### 您使用的版本? | Your usage version? 11 | 12 | #### 您使用的场景? | Your usage scenarios? 13 | 14 | #### 您做了什么操作? | What did you do? 15 | 16 | #### 您遇到了什么问题? | What are your problems? 17 | 18 | #### 您期望的结果是怎样的? | What is your expected outcome? 19 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/issue-template-feature.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: 🚀 功能请求 | Feature Request 3 | about: 请详细描述您期望的功能。 | Please describe in detail the features you expect. 4 | title: "🚀 一些功能。。。 | [Feature]Some feature..." 5 | labels: ["enhancement"] 6 | --- 7 | 8 | 9 | 10 | #### 您使用的场景? | 1. Your usage scenarios? 11 | 12 | #### 您期望的结果是怎样的? | 2. What is your expected outcome? 13 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/question-report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: 🙋 问题交流 | Question Report 3 | about: 在文档或讨论中没有回答的使用问题 | Usage question that isn't answered in docs or discussion 4 | title: "🙋 问题交流。。。 | [Question] Some question..." 5 | labels: ["question"] 6 | --- 7 | 8 | ## Question Report 9 | 10 | - 搜索打开和关闭的 [GitHub 问题](https://github.com/eryajf/go-ldap-admin/issues) 11 | 12 | 请在提交问题之前回答这些问题,谢谢。 | Please answer these questions before submitting them. Thank you. 13 | 14 | ### 你使用了哪个版本? | Which version did you use? 15 | 16 | ### 预期行为 | Expected behavior 17 | 18 | ### 实际行为 | Actual behavior 19 | 20 | ### 原因分析(如果可以) | Cause analysis (if possible) 21 | 22 | ### 问题重现步骤 | Steps to reproduce the problem -------------------------------------------------------------------------------- /.github/pull-request-template.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | **在提出此拉取请求时,我确认了以下几点(请复选框):** 4 | 5 | - [ ] 我已阅读并理解[贡献者指南]()。 6 | - [ ] 我已检查没有与此请求重复的拉取请求。 7 | - [ ] 我已经考虑过,并确认这份呈件对其他人很有价值。 8 | - [ ] 我接受此提交可能不会被使用,并根据维护人员的意愿关闭拉取请求。 9 | 10 | **填写PR内容:** 11 | 12 | - 13 | - 14 | - -------------------------------------------------------------------------------- /.github/release-drafter.yml: -------------------------------------------------------------------------------- 1 | # Configuration for Release Drafter: https://github.com/toolmantim/release-drafter 2 | name-template: 'v$NEXT_PATCH_VERSION 🌈' 3 | tag-template: 'v$NEXT_PATCH_VERSION' 4 | version-template: $MAJOR.$MINOR.$PATCH 5 | # Emoji reference: https://gitmoji.carloscuesta.me/ 6 | categories: 7 | - title: '🚀 Features' 8 | labels: 9 | - 'feature' 10 | - 'enhancement' 11 | - 'kind/feature' 12 | - title: '🐛 Bug Fixes' 13 | labels: 14 | - 'fix' 15 | - 'bugfix' 16 | - 'bug' 17 | - 'regression' 18 | - 'kind/bug' 19 | - title: 📝 Documentation updates 20 | labels: 21 | - documentation 22 | - 'kind/doc' 23 | - title: 👻 Maintenance 24 | labels: 25 | - chore 26 | - dependencies 27 | - 'kind/chore' 28 | - 'kind/dep' 29 | - title: 🚦 Tests 30 | labels: 31 | - test 32 | - tests 33 | exclude-labels: 34 | - reverted 35 | - no-changelog 36 | - skip-changelog 37 | - invalid 38 | change-template: '* $TITLE (#$NUMBER) @$AUTHOR' 39 | template: | 40 | ## What’s Changed 41 | $CHANGES -------------------------------------------------------------------------------- /.github/workflows/dist-to-release.yml: -------------------------------------------------------------------------------- 1 | name: Build Release 2 | 3 | on: 4 | release: 5 | types: [created,published] # 表示在创建新的 Release 时触发 6 | 7 | env: # 设置环境变量 8 | TZ: Asia/Shanghai # 时区(设置时区可使页面中的`最近更新时间`使用时区时间) 9 | 10 | jobs: 11 | deploy: 12 | runs-on: ubuntu-latest 13 | steps: 14 | - name: Checkout 🛎️ 15 | uses: actions/checkout@v3 16 | - name: Inject slug/short variables 17 | uses: rlespinasse/github-slug-action@v4 18 | 19 | - name: build project ⚗️ 20 | uses: actions/setup-node@v3 21 | with: 22 | node-version: 14 23 | 24 | - run: | 25 | sed -i 's@http://localhost:8888/@/@g' .env.production 26 | git config --global url."https://".insteadOf git:// 27 | npm install 28 | yarn build:prod 29 | 30 | - run: | 31 | zip -q -r dist.zip dist 32 | openssl md5 dist.zip > dist.zip.md5 33 | 34 | - name: Upload release package 35 | uses: softprops/action-gh-release@v1 36 | with: 37 | files: | 38 | dist.zip 39 | dist.zip.md5 40 | -------------------------------------------------------------------------------- /.github/workflows/reademe-contributors.yml: -------------------------------------------------------------------------------- 1 | name: Generate a list of contributors 2 | 3 | on: 4 | push: 5 | branches: 6 | - main 7 | 8 | jobs: 9 | contrib-readme-en-job: 10 | runs-on: ubuntu-latest 11 | name: A job to automate contrib in readme 12 | steps: 13 | - name: Contribute List 14 | uses: akhilmhdh/contributors-readme-action@v2.3.4 15 | env: 16 | GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }} -------------------------------------------------------------------------------- /.github/workflows/release.yml: -------------------------------------------------------------------------------- 1 | name: Release Drafter 2 | 3 | on: 4 | push: 5 | # branches to consider in the event; optional, defaults to all 6 | branches: 7 | - main 8 | # pull_request event is required only for autolabeler 9 | pull_request: 10 | # Only following types are handled by the action, but one can default to all as well 11 | types: [opened, reopened, synchronize] 12 | # pull_request_target event is required for autolabeler to support PRs from forks 13 | # pull_request_target: 14 | # types: [opened, reopened, synchronize] 15 | 16 | permissions: 17 | contents: read 18 | 19 | jobs: 20 | update_release_draft: 21 | permissions: 22 | contents: write # for release-drafter/release-drafter to create a github release 23 | pull-requests: write # for release-drafter/release-drafter to add label to PR 24 | runs-on: ubuntu-latest 25 | steps: 26 | # (Optional) GitHub Enterprise requires GHE_HOST variable set 27 | #- name: Set GHE_HOST 28 | # run: | 29 | # echo "GHE_HOST=${GITHUB_SERVER_URL##https:\/\/}" >> $GITHUB_ENV 30 | 31 | # Drafts your next Release notes as Pull Requests are merged into "master" 32 | - uses: release-drafter/release-drafter@v5 33 | # (Optional) specify config name to use, relative to .github/. Default: release-drafter.yml 34 | # with: 35 | # config-name: my-config.yml 36 | # disable-autolabeler: true 37 | env: 38 | GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }} -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules/ 3 | dist/ 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | **/*.log 8 | 9 | tests/**/coverage/ 10 | tests/e2e/reports 11 | selenium-debug.log 12 | 13 | # Editor directories and files 14 | .idea 15 | .vscode 16 | *.suo 17 | *.ntvs* 18 | *.njsproj 19 | *.sln 20 | *.local 21 | 22 | package-lock.json 23 | yarn.lock 24 | .history -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM node:14.18 AS builder 2 | 3 | RUN mkdir /app 4 | ADD . /app/ 5 | WORKDIR /app 6 | RUN sed -i 's@http://localhost:8888/@/@g' .env.production \ 7 | && git config --global url."https://".insteadOf git:// \ 8 | && npm install --registry=http://registry.npmmirror.com \ 9 | && yarn build:prod 10 | 11 | FROM openresty/openresty:1.21.4.1-0-centos7 12 | RUN mkdir /app 13 | WORKDIR /app 14 | COPY --from=builder /app/default.conf /etc/nginx/conf.d/default.conf 15 | COPY --from=builder /app/dist . 16 | 17 | CMD nginx -g "daemon off;" -------------------------------------------------------------------------------- /babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [ 3 | // https://github.com/vuejs/vue-cli/tree/master/packages/@vue/babel-preset-app 4 | '@vue/cli-plugin-babel/preset' 5 | ], 6 | 'env': { 7 | 'development': { 8 | // babel-plugin-dynamic-import-node plugin only does one thing by converting all import() to require(). 9 | // This plugin can significantly increase the speed of hot updates, when you have a large number of pages. 10 | // https://panjiachen.github.io/vue-element-admin-site/guide/advanced/lazy-loading.html 11 | 'plugins': ['dynamic-import-node'] 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /build/index.js: -------------------------------------------------------------------------------- 1 | const { run } = require('runjs') 2 | const chalk = require('chalk') 3 | const config = require('../vue.config.js') 4 | const rawArgv = process.argv.slice(2) 5 | const args = rawArgv.join(' ') 6 | 7 | if (process.env.npm_config_preview || rawArgv.includes('--preview')) { 8 | const report = rawArgv.includes('--report') 9 | 10 | run(`vue-cli-service build ${args}`) 11 | 12 | const port = 9526 13 | const publicPath = config.publicPath 14 | 15 | var connect = require('connect') 16 | var serveStatic = require('serve-static') 17 | const app = connect() 18 | 19 | app.use( 20 | publicPath, 21 | serveStatic('./dist', { 22 | index: ['index.html', '/'] 23 | }) 24 | ) 25 | 26 | app.listen(port, function () { 27 | console.log(chalk.green(`> Preview at http://localhost:${port}${publicPath}`)) 28 | if (report) { 29 | console.log(chalk.green(`> Report at http://localhost:${port}${publicPath}report.html`)) 30 | } 31 | 32 | }) 33 | } else { 34 | run(`vue-cli-service build ${args}`) 35 | } 36 | -------------------------------------------------------------------------------- /default.conf: -------------------------------------------------------------------------------- 1 | server { 2 | listen 80; 3 | server_name _; 4 | 5 | root /app; 6 | 7 | location / { 8 | try_files $uri $uri/ /index.html; 9 | add_header Cache-Control 'no-store'; 10 | } 11 | 12 | location /api/ { 13 | proxy_set_header Host $http_host; 14 | proxy_set_header X-Real-IP $remote_addr; 15 | proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; 16 | proxy_set_header X-Forwarded-Proto $scheme; 17 | proxy_pass http://go-ldap-admin-server:8888; 18 | } 19 | } -------------------------------------------------------------------------------- /jest.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | moduleFileExtensions: ['js', 'jsx', 'json', 'vue'], 3 | transform: { 4 | '^.+\\.vue$': 'vue-jest', 5 | '.+\\.(css|styl|less|sass|scss|svg|png|jpg|ttf|woff|woff2)$': 6 | 'jest-transform-stub', 7 | '^.+\\.jsx?$': 'babel-jest' 8 | }, 9 | moduleNameMapper: { 10 | '^@/(.*)$': '/src/$1' 11 | }, 12 | snapshotSerializers: ['jest-serializer-vue'], 13 | testMatch: [ 14 | '**/tests/unit/**/*.spec.(js|jsx|ts|tsx)|**/__tests__/*.(js|jsx|ts|tsx)' 15 | ], 16 | collectCoverageFrom: ['src/utils/**/*.{js,vue}', '!src/utils/auth.js', '!src/utils/request.js', 'src/components/**/*.{js,vue}'], 17 | coverageDirectory: '/tests/unit/coverage', 18 | // 'collectCoverage': true, 19 | 'coverageReporters': [ 20 | 'lcov', 21 | 'text-summary' 22 | ], 23 | testURL: 'http://localhost/' 24 | } 25 | -------------------------------------------------------------------------------- /jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": "./", 4 | "paths": { 5 | "@/*": ["src/*"] 6 | } 7 | }, 8 | "exclude": ["node_modules", "dist"] 9 | } -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "go-ldap-admin-ui", 3 | "version": "1.0.0", 4 | "description": "go-ldap-admin前端项目", 5 | "author": "eryajf ", 6 | "scripts": { 7 | "dev": "vue-cli-service serve", 8 | "lint": "eslint --ext .js,.vue src", 9 | "build:prod": "vue-cli-service build", 10 | "build:stage": "vue-cli-service build --mode staging", 11 | "preview": "node build/index.js --preview", 12 | "new": "plop", 13 | "svgo": "svgo -f src/icons/svg --config=src/icons/svgo.yml", 14 | "test:unit": "jest --clearCache && vue-cli-service test:unit", 15 | "test:ci": "npm run lint && npm run test:unit" 16 | }, 17 | "dependencies": { 18 | "@riophae/vue-treeselect": "^0.4.0", 19 | "axios": "0.18.1", 20 | "clipboard": "2.0.4", 21 | "codemirror": "5.45.0", 22 | "core-js": "^3.8.1", 23 | "driver.js": "0.9.5", 24 | "dropzone": "5.5.1", 25 | "echarts": "4.2.1", 26 | "element-ui": "2.13.2", 27 | "file-saver": "2.0.1", 28 | "fuse.js": "3.4.4", 29 | "js-cookie": "2.2.0", 30 | "jsencrypt": "^3.0.1", 31 | "jsonlint": "1.6.3", 32 | "jszip": "3.2.1", 33 | "normalize.css": "7.0.0", 34 | "nprogress": "0.2.0", 35 | "path-to-regexp": "2.4.0", 36 | "screenfull": "4.2.0", 37 | "script-loader": "0.7.2", 38 | "sortablejs": "1.8.4", 39 | "tui-editor": "1.3.3", 40 | "vue": "2.6.10", 41 | "vue-count-to": "1.0.13", 42 | "vue-router": "3.0.2", 43 | "vue-splitpane": "1.0.4", 44 | "vuedraggable": "2.20.0", 45 | "vuex": "3.1.0", 46 | "xlsx": "0.14.1" 47 | }, 48 | "devDependencies": { 49 | "@vue/cli-plugin-babel": "4.4.4", 50 | "@vue/cli-plugin-eslint": "4.4.4", 51 | "@vue/cli-plugin-unit-jest": "4.4.4", 52 | "@vue/cli-service": "4.4.4", 53 | "@vue/test-utils": "1.0.0-beta.29", 54 | "autoprefixer": "9.5.1", 55 | "babel-eslint": "10.1.0", 56 | "babel-jest": "23.6.0", 57 | "babel-plugin-dynamic-import-node": "2.3.3", 58 | "chalk": "2.4.2", 59 | "chokidar": "2.1.5", 60 | "connect": "3.6.6", 61 | "eslint": "6.7.2", 62 | "eslint-plugin-vue": "6.2.2", 63 | "html-webpack-plugin": "3.2.0", 64 | "husky": "1.3.1", 65 | "lint-staged": "8.1.5", 66 | "mockjs": "1.0.1-beta3", 67 | "plop": "2.3.0", 68 | "runjs": "4.3.2", 69 | "sass": "1.26.2", 70 | "sass-loader": "8.0.2", 71 | "script-ext-html-webpack-plugin": "2.1.3", 72 | "serve-static": "1.13.2", 73 | "svg-sprite-loader": "4.1.3", 74 | "svgo": "1.2.0", 75 | "vue-template-compiler": "2.6.10" 76 | }, 77 | "browserslist": [ 78 | "> 1%", 79 | "last 2 versions" 80 | ], 81 | "engines": { 82 | "node": ">=8.9", 83 | "npm": ">= 3.0.0" 84 | }, 85 | "license": "MIT", 86 | "lint-staged": { 87 | "src/**/*.{js,vue}": [ 88 | "eslint --fix", 89 | "git add" 90 | ] 91 | }, 92 | "husky": { 93 | "hooks": { 94 | "pre-commit": "lint-staged" 95 | } 96 | }, 97 | "repository": { 98 | "type": "git", 99 | "url": "git+https://github.com/eryajf-world/go-ldap-admin-ui.git" 100 | } 101 | } 102 | -------------------------------------------------------------------------------- /plop-templates/component/index.hbs: -------------------------------------------------------------------------------- 1 | {{#if template}} 2 | 5 | {{/if}} 6 | 7 | {{#if script}} 8 | 20 | {{/if}} 21 | 22 | {{#if style}} 23 | 26 | {{/if}} 27 | -------------------------------------------------------------------------------- /plop-templates/component/prompt.js: -------------------------------------------------------------------------------- 1 | const { notEmpty } = require('../utils.js') 2 | 3 | module.exports = { 4 | description: 'generate vue component', 5 | prompts: [{ 6 | type: 'input', 7 | name: 'name', 8 | message: 'component name please', 9 | validate: notEmpty('name') 10 | }, 11 | { 12 | type: 'checkbox', 13 | name: 'blocks', 14 | message: 'Blocks:', 15 | choices: [{ 16 | name: '