diff --git a/web/src/api/data.js b/web/src/api/data.js new file mode 100644 index 0000000..d975d75 --- /dev/null +++ b/web/src/api/data.js @@ -0,0 +1,17 @@ +import request from '@/utils/request' +import qs from 'qs' + +export function initData(url, params) { + return request({ + url: url + '?' + qs.stringify(params, { indices: false }), + method: 'get' + }) +} + +export function download(url, params) { + return request({ + url: url + '?' + qs.stringify(params, { indices: false }), + method: 'get', + responseType: 'blob' + }) +} diff --git a/web/src/api/login.js b/web/src/api/login.js new file mode 100644 index 0000000..07cabb5 --- /dev/null +++ b/web/src/api/login.js @@ -0,0 +1,35 @@ +import request from '@/utils/request' + +export function login(username, password, code, uuid) { + return request({ + url: 'admin/auth/login', + method: 'post', + data: { + username, + password, + code, + uuid + } + }) +} + +export function getInfo() { + return request({ + url: 'admin/auth/info', + method: 'get' + }) +} + +export function getCodeImg() { + return request({ + url: 'admin/auth/captcha', + method: 'get' + }) +} + +export function logout() { + return request({ + url: 'admin/auth/logout', + method: 'delete' + }) +} diff --git a/web/src/api/system/dept.js b/web/src/api/system/dept.js new file mode 100644 index 0000000..3a5e9b2 --- /dev/null +++ b/web/src/api/system/dept.js @@ -0,0 +1,43 @@ +import request from '@/utils/request' + +export function getDepts(params) { + return request({ + url: 'admin/dept', + method: 'get', + params + }) +} + +export function add(data) { + return request({ + url: 'admin/dept', + method: 'post', + data + }) +} + +export function del(ids) { + return request({ + url: 'admin/dept', + method: 'delete', + data: ids + }) +} + +export function edit(data) { + return request({ + url: 'admin/dept', + method: 'put', + data + }) +} + +export function getDeptSuperior(data) { + return request({ + url: 'admin/dept', + method: 'get', + data + }) +} + +export default { add, edit, del, getDepts, getDeptSuperior } diff --git a/web/src/api/system/dict.js b/web/src/api/system/dict.js new file mode 100644 index 0000000..82c7fb1 --- /dev/null +++ b/web/src/api/system/dict.js @@ -0,0 +1,33 @@ +import request from '@/utils/request' + +export function getDicts() { + return request({ + url: 'admin/dict/all', + method: 'get' + }) +} + +export function add(data) { + return request({ + url: 'admin/dict', + method: 'post', + data + }) +} + +export function del(id) { + return request({ + url: 'admin/dict/' + id, + method: 'delete' + }) +} + +export function edit(data) { + return request({ + url: 'admin/dict', + method: 'put', + data + }) +} + +export default { add, edit, del } diff --git a/web/src/api/system/dictDetail.js b/web/src/api/system/dictDetail.js new file mode 100644 index 0000000..af17481 --- /dev/null +++ b/web/src/api/system/dictDetail.js @@ -0,0 +1,52 @@ +import request from '@/utils/request' + +export function get(dictName) { + const params = { + dictName, + page: 0, + size: 9999 + } + return request({ + url: 'admin/dictDetail', + method: 'get', + params + }) +} + +export function getDictMap(dictName) { + const params = { + dictName, + page: 0, + size: 9999 + } + return request({ + url: 'admin/dictDetail/map', + method: 'get', + params + }) +} + +export function add(data) { + return request({ + url: 'admin/dictDetail', + method: 'post', + data + }) +} + +export function del(id) { + return request({ + url: 'admin/dictDetail/' + id, + method: 'delete' + }) +} + +export function edit(data) { + return request({ + url: 'admin/dictDetail', + method: 'put', + data + }) +} + +export default { add, edit, del } diff --git a/web/src/api/system/job.js b/web/src/api/system/job.js new file mode 100644 index 0000000..4ca4f5f --- /dev/null +++ b/web/src/api/system/job.js @@ -0,0 +1,40 @@ +import request from '@/utils/request' + +export function getAllJob(deptId) { + const params = { + deptId, + page: 0, + size: 9999 + } + return request({ + url: 'admin/job', + method: 'get', + params + }) +} + +export function add(data) { + return request({ + url: 'admin/job', + method: 'post', + data + }) +} + +export function del(ids) { + return request({ + url: 'admin/job', + method: 'delete', + data: ids + }) +} + +export function edit(data) { + return request({ + url: 'admin/job', + method: 'put', + data + }) +} + +export default { add, edit, del } diff --git a/web/src/api/system/menu.js b/web/src/api/system/menu.js new file mode 100644 index 0000000..4eca220 --- /dev/null +++ b/web/src/api/system/menu.js @@ -0,0 +1,41 @@ +import request from '@/utils/request' + +export function getMenusTree() { + return request({ + url: 'admin/menu/tree', + method: 'get' + }) +} + +export function buildMenus() { + return request({ + url: 'admin/menu/build', + method: 'get' + }) +} + +export function add(data) { + return request({ + url: 'admin/menu', + method: 'post', + data + }) +} + +export function del(ids) { + return request({ + url: 'admin/menu', + method: 'delete', + data: ids + }) +} + +export function edit(data) { + return request({ + url: 'admin/menu', + method: 'put', + data + }) +} + +export default { add, edit, del, getMenusTree } diff --git a/web/src/api/system/role.js b/web/src/api/system/role.js new file mode 100644 index 0000000..eef71fb --- /dev/null +++ b/web/src/api/system/role.js @@ -0,0 +1,50 @@ +import request from '@/utils/request' + +// 获取所有的Role +export function getAll() { + return request({ + url: 'admin/roles', + method: 'get' + }) +} + +export function add(data) { + return request({ + url: 'admin/roles', + method: 'post', + data + }) +} + +export function get(id) { + return request({ + url: 'admin/roles/' + id, + method: 'get' + }) +} + +export function del(ids) { + return request({ + url: 'admin/roles', + method: 'delete', + data: ids + }) +} + +export function edit(data) { + return request({ + url: 'admin/roles', + method: 'put', + data + }) +} + +export function editMenu(data) { + return request({ + url: 'admin/roles/menu', + method: 'put', + data + }) +} + +export default { add, edit, del, get, editMenu } diff --git a/web/src/api/system/user.js b/web/src/api/system/user.js new file mode 100644 index 0000000..d90a2f4 --- /dev/null +++ b/web/src/api/system/user.js @@ -0,0 +1,58 @@ +import request from '@/utils/request' +import { encrypt } from '@/utils/rsaEncrypt' + +export function add(data) { + return request({ + url: 'admin/user', + method: 'post', + data + }) +} + +export function del(ids) { + return request({ + url: 'admin/user', + method: 'delete', + data: ids + }) +} + +export function edit(data) { + return request({ + url: 'admin/user', + method: 'put', + data + }) +} + +export function editUser(data) { + return request({ + url: 'admin/user/center', + method: 'put', + data + }) +} + +export function updatePass(user) { + const data = { + oldPass: user.oldPass, + newPass: user.newPass + } + return request({ + url: 'admin/user/updatePass/', + method: 'post', + data + }) +} + +// 用户头像上传 +export function uploadAvatar(data) { + return request({ + url: '/admin/user/updateAvatar', + method: 'post', + data: data + }) +} + +export default { add, edit, del, uploadAvatar } + diff --git a/web/src/assets/401_images/401.gif b/web/src/assets/401_images/401.gif new file mode 100644 index 0000000..cd6e0d9 Binary files /dev/null and b/web/src/assets/401_images/401.gif differ diff --git a/web/src/assets/404_images/404.png b/web/src/assets/404_images/404.png new file mode 100644 index 0000000..3d8e230 Binary files /dev/null and b/web/src/assets/404_images/404.png differ diff --git a/web/src/assets/404_images/404_cloud.png b/web/src/assets/404_images/404_cloud.png new file mode 100644 index 0000000..c6281d0 Binary files /dev/null and b/web/src/assets/404_images/404_cloud.png differ diff --git a/web/src/assets/icons/index.js b/web/src/assets/icons/index.js new file mode 100644 index 0000000..2c6b309 --- /dev/null +++ b/web/src/assets/icons/index.js @@ -0,0 +1,9 @@ +import Vue from 'vue' +import SvgIcon from '@/components/SvgIcon'// svg component + +// register globally +Vue.component('svg-icon', SvgIcon) + +const req = require.context('./svg', false, /\.svg$/) +const requireAll = requireContext => requireContext.keys().map(requireContext) +requireAll(req) diff --git a/web/src/assets/icons/svg/Sign.svg b/web/src/assets/icons/svg/Sign.svg new file mode 100644 index 0000000..59c9e6f --- /dev/null +++ b/web/src/assets/icons/svg/Sign.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/Steve-Jobs.svg b/web/src/assets/icons/svg/Steve-Jobs.svg new file mode 100644 index 0000000..12ad97a --- /dev/null +++ b/web/src/assets/icons/svg/Steve-Jobs.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/add.svg b/web/src/assets/icons/svg/add.svg new file mode 100644 index 0000000..2ddbd0b --- /dev/null +++ b/web/src/assets/icons/svg/add.svg @@ -0,0 +1,2 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/alipay.svg b/web/src/assets/icons/svg/alipay.svg new file mode 100644 index 0000000..c976aa1 --- /dev/null +++ b/web/src/assets/icons/svg/alipay.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/anq.svg b/web/src/assets/icons/svg/anq.svg new file mode 100644 index 0000000..d47a3b1 --- /dev/null +++ b/web/src/assets/icons/svg/anq.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/app.svg b/web/src/assets/icons/svg/app.svg new file mode 100644 index 0000000..0796da3 --- /dev/null +++ b/web/src/assets/icons/svg/app.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/article.svg b/web/src/assets/icons/svg/article.svg new file mode 100644 index 0000000..2df901d --- /dev/null +++ b/web/src/assets/icons/svg/article.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/backup.svg b/web/src/assets/icons/svg/backup.svg new file mode 100644 index 0000000..a3272a4 --- /dev/null +++ b/web/src/assets/icons/svg/backup.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/banner.svg b/web/src/assets/icons/svg/banner.svg new file mode 100644 index 0000000..dc9b7c0 --- /dev/null +++ b/web/src/assets/icons/svg/banner.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/bargain.svg b/web/src/assets/icons/svg/bargain.svg new file mode 100644 index 0000000..c12661b --- /dev/null +++ b/web/src/assets/icons/svg/bargain.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/button.svg b/web/src/assets/icons/svg/button.svg new file mode 100644 index 0000000..972e263 --- /dev/null +++ b/web/src/assets/icons/svg/button.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/chain.svg b/web/src/assets/icons/svg/chain.svg new file mode 100644 index 0000000..7f027c2 --- /dev/null +++ b/web/src/assets/icons/svg/chain.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/chart.svg b/web/src/assets/icons/svg/chart.svg new file mode 100644 index 0000000..27728fb --- /dev/null +++ b/web/src/assets/icons/svg/chart.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/codeConsole.svg b/web/src/assets/icons/svg/codeConsole.svg new file mode 100644 index 0000000..ca37b00 --- /dev/null +++ b/web/src/assets/icons/svg/codeConsole.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/comment.svg b/web/src/assets/icons/svg/comment.svg new file mode 100644 index 0000000..fad4b67 --- /dev/null +++ b/web/src/assets/icons/svg/comment.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/configure.svg b/web/src/assets/icons/svg/configure.svg new file mode 100644 index 0000000..0b0591d --- /dev/null +++ b/web/src/assets/icons/svg/configure.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/coupon.svg b/web/src/assets/icons/svg/coupon.svg new file mode 100644 index 0000000..5a02565 --- /dev/null +++ b/web/src/assets/icons/svg/coupon.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/coupon2.svg b/web/src/assets/icons/svg/coupon2.svg new file mode 100644 index 0000000..b3a003e --- /dev/null +++ b/web/src/assets/icons/svg/coupon2.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/dashboard.svg b/web/src/assets/icons/svg/dashboard.svg new file mode 100644 index 0000000..5317d37 --- /dev/null +++ b/web/src/assets/icons/svg/dashboard.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/database.svg b/web/src/assets/icons/svg/database.svg new file mode 100644 index 0000000..7fbad9b --- /dev/null +++ b/web/src/assets/icons/svg/database.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/date.svg b/web/src/assets/icons/svg/date.svg new file mode 100644 index 0000000..50eb947 --- /dev/null +++ b/web/src/assets/icons/svg/date.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/dengji.svg b/web/src/assets/icons/svg/dengji.svg new file mode 100644 index 0000000..e2cd8cf --- /dev/null +++ b/web/src/assets/icons/svg/dengji.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/deploy.svg b/web/src/assets/icons/svg/deploy.svg new file mode 100644 index 0000000..f4a1c56 --- /dev/null +++ b/web/src/assets/icons/svg/deploy.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/dept.svg b/web/src/assets/icons/svg/dept.svg new file mode 100644 index 0000000..05d0fb2 --- /dev/null +++ b/web/src/assets/icons/svg/dept.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/dev.svg b/web/src/assets/icons/svg/dev.svg new file mode 100644 index 0000000..ed4d23c --- /dev/null +++ b/web/src/assets/icons/svg/dev.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/develop.svg b/web/src/assets/icons/svg/develop.svg new file mode 100644 index 0000000..e49764e --- /dev/null +++ b/web/src/assets/icons/svg/develop.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/dictionary.svg b/web/src/assets/icons/svg/dictionary.svg new file mode 100644 index 0000000..2a9d6f0 --- /dev/null +++ b/web/src/assets/icons/svg/dictionary.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/edit.svg b/web/src/assets/icons/svg/edit.svg new file mode 100644 index 0000000..d26101f --- /dev/null +++ b/web/src/assets/icons/svg/edit.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/education.svg b/web/src/assets/icons/svg/education.svg new file mode 100644 index 0000000..7bfb01d --- /dev/null +++ b/web/src/assets/icons/svg/education.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/email.svg b/web/src/assets/icons/svg/email.svg new file mode 100644 index 0000000..d00884b --- /dev/null +++ b/web/src/assets/icons/svg/email.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/error.svg b/web/src/assets/icons/svg/error.svg new file mode 100644 index 0000000..1a07929 --- /dev/null +++ b/web/src/assets/icons/svg/error.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/exit-fullscreen.svg b/web/src/assets/icons/svg/exit-fullscreen.svg new file mode 100644 index 0000000..485c128 --- /dev/null +++ b/web/src/assets/icons/svg/exit-fullscreen.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/express.svg b/web/src/assets/icons/svg/express.svg new file mode 100644 index 0000000..667528e --- /dev/null +++ b/web/src/assets/icons/svg/express.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/fenxiao.svg b/web/src/assets/icons/svg/fenxiao.svg new file mode 100644 index 0000000..943263d --- /dev/null +++ b/web/src/assets/icons/svg/fenxiao.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/fullscreen.svg b/web/src/assets/icons/svg/fullscreen.svg new file mode 100644 index 0000000..0e86b6f --- /dev/null +++ b/web/src/assets/icons/svg/fullscreen.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/fwb.svg b/web/src/assets/icons/svg/fwb.svg new file mode 100644 index 0000000..7f0bea9 --- /dev/null +++ b/web/src/assets/icons/svg/fwb.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/github.svg b/web/src/assets/icons/svg/github.svg new file mode 100644 index 0000000..03c81e0 --- /dev/null +++ b/web/src/assets/icons/svg/github.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/gonggao.svg b/web/src/assets/icons/svg/gonggao.svg new file mode 100644 index 0000000..740ea69 --- /dev/null +++ b/web/src/assets/icons/svg/gonggao.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/goods.svg b/web/src/assets/icons/svg/goods.svg new file mode 100644 index 0000000..21b74f7 --- /dev/null +++ b/web/src/assets/icons/svg/goods.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/ic-yesterday.svg b/web/src/assets/icons/svg/ic-yesterday.svg new file mode 100644 index 0000000..fae35c2 --- /dev/null +++ b/web/src/assets/icons/svg/ic-yesterday.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/icon.svg b/web/src/assets/icons/svg/icon.svg new file mode 100644 index 0000000..0faf313 --- /dev/null +++ b/web/src/assets/icons/svg/icon.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/image.svg b/web/src/assets/icons/svg/image.svg new file mode 100644 index 0000000..9b3376a --- /dev/null +++ b/web/src/assets/icons/svg/image.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/index.svg b/web/src/assets/icons/svg/index.svg new file mode 100644 index 0000000..5317d37 --- /dev/null +++ b/web/src/assets/icons/svg/index.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/international.svg b/web/src/assets/icons/svg/international.svg new file mode 100644 index 0000000..e9b56ee --- /dev/null +++ b/web/src/assets/icons/svg/international.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/ipvisits.svg b/web/src/assets/icons/svg/ipvisits.svg new file mode 100644 index 0000000..59eebc6 --- /dev/null +++ b/web/src/assets/icons/svg/ipvisits.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/java.svg b/web/src/assets/icons/svg/java.svg new file mode 100644 index 0000000..117dc66 --- /dev/null +++ b/web/src/assets/icons/svg/java.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/link.svg b/web/src/assets/icons/svg/link.svg new file mode 100644 index 0000000..48197ba --- /dev/null +++ b/web/src/assets/icons/svg/link.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/list.svg b/web/src/assets/icons/svg/list.svg new file mode 100644 index 0000000..9853581 --- /dev/null +++ b/web/src/assets/icons/svg/list.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/live.svg b/web/src/assets/icons/svg/live.svg new file mode 100644 index 0000000..9ca8853 --- /dev/null +++ b/web/src/assets/icons/svg/live.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/lock.svg b/web/src/assets/icons/svg/lock.svg new file mode 100644 index 0000000..bee8924 --- /dev/null +++ b/web/src/assets/icons/svg/lock.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/log.svg b/web/src/assets/icons/svg/log.svg new file mode 100644 index 0000000..a740783 --- /dev/null +++ b/web/src/assets/icons/svg/log.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/login.svg b/web/src/assets/icons/svg/login.svg new file mode 100644 index 0000000..cc5a854 --- /dev/null +++ b/web/src/assets/icons/svg/login.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/markdown.svg b/web/src/assets/icons/svg/markdown.svg new file mode 100644 index 0000000..26edd96 --- /dev/null +++ b/web/src/assets/icons/svg/markdown.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/menu.svg b/web/src/assets/icons/svg/menu.svg new file mode 100644 index 0000000..5c8e20d --- /dev/null +++ b/web/src/assets/icons/svg/menu.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/message.svg b/web/src/assets/icons/svg/message.svg new file mode 100644 index 0000000..14ca817 --- /dev/null +++ b/web/src/assets/icons/svg/message.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/mnt.svg b/web/src/assets/icons/svg/mnt.svg new file mode 100644 index 0000000..502a7c0 --- /dev/null +++ b/web/src/assets/icons/svg/mnt.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/money.svg b/web/src/assets/icons/svg/money.svg new file mode 100644 index 0000000..3e70b0b --- /dev/null +++ b/web/src/assets/icons/svg/money.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/monitor.svg b/web/src/assets/icons/svg/monitor.svg new file mode 100644 index 0000000..bc308cb --- /dev/null +++ b/web/src/assets/icons/svg/monitor.svg @@ -0,0 +1,2 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/monthlyview.svg b/web/src/assets/icons/svg/monthlyview.svg new file mode 100644 index 0000000..8657dd5 --- /dev/null +++ b/web/src/assets/icons/svg/monthlyview.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/nested.svg b/web/src/assets/icons/svg/nested.svg new file mode 100644 index 0000000..06713a8 --- /dev/null +++ b/web/src/assets/icons/svg/nested.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/news.svg b/web/src/assets/icons/svg/news.svg new file mode 100644 index 0000000..b26e1e3 --- /dev/null +++ b/web/src/assets/icons/svg/news.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/order.svg b/web/src/assets/icons/svg/order.svg new file mode 100644 index 0000000..df06451 --- /dev/null +++ b/web/src/assets/icons/svg/order.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/orderinfo.svg b/web/src/assets/icons/svg/orderinfo.svg new file mode 100644 index 0000000..86e919f --- /dev/null +++ b/web/src/assets/icons/svg/orderinfo.svg @@ -0,0 +1 @@ + diff --git a/web/src/assets/icons/svg/password.svg b/web/src/assets/icons/svg/password.svg new file mode 100644 index 0000000..ce16269 --- /dev/null +++ b/web/src/assets/icons/svg/password.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/people.svg b/web/src/assets/icons/svg/people.svg new file mode 100644 index 0000000..2bd54ae --- /dev/null +++ b/web/src/assets/icons/svg/people.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/peoples.svg b/web/src/assets/icons/svg/peoples.svg new file mode 100644 index 0000000..2c91161 --- /dev/null +++ b/web/src/assets/icons/svg/peoples.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/permission.svg b/web/src/assets/icons/svg/permission.svg new file mode 100644 index 0000000..b389846 --- /dev/null +++ b/web/src/assets/icons/svg/permission.svg @@ -0,0 +1,2 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/phone.svg b/web/src/assets/icons/svg/phone.svg new file mode 100644 index 0000000..e5e04ab --- /dev/null +++ b/web/src/assets/icons/svg/phone.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/points.svg b/web/src/assets/icons/svg/points.svg new file mode 100644 index 0000000..7c450d5 --- /dev/null +++ b/web/src/assets/icons/svg/points.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/price.svg b/web/src/assets/icons/svg/price.svg new file mode 100644 index 0000000..952f8ac --- /dev/null +++ b/web/src/assets/icons/svg/price.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/pt.svg b/web/src/assets/icons/svg/pt.svg new file mode 100644 index 0000000..d357865 --- /dev/null +++ b/web/src/assets/icons/svg/pt.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/qiniu.svg b/web/src/assets/icons/svg/qiniu.svg new file mode 100644 index 0000000..dc30724 --- /dev/null +++ b/web/src/assets/icons/svg/qiniu.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/rec.svg b/web/src/assets/icons/svg/rec.svg new file mode 100644 index 0000000..18339da --- /dev/null +++ b/web/src/assets/icons/svg/rec.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/redis.svg b/web/src/assets/icons/svg/redis.svg new file mode 100644 index 0000000..bef111b --- /dev/null +++ b/web/src/assets/icons/svg/redis.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/reply.svg b/web/src/assets/icons/svg/reply.svg new file mode 100644 index 0000000..3be88d4 --- /dev/null +++ b/web/src/assets/icons/svg/reply.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/role.svg b/web/src/assets/icons/svg/role.svg new file mode 100644 index 0000000..a474450 --- /dev/null +++ b/web/src/assets/icons/svg/role.svg @@ -0,0 +1,2 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/run.svg b/web/src/assets/icons/svg/run.svg new file mode 100644 index 0000000..c90ff44 --- /dev/null +++ b/web/src/assets/icons/svg/run.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/running.svg b/web/src/assets/icons/svg/running.svg new file mode 100644 index 0000000..b95cb88 --- /dev/null +++ b/web/src/assets/icons/svg/running.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/search.svg b/web/src/assets/icons/svg/search.svg new file mode 100644 index 0000000..f615eec --- /dev/null +++ b/web/src/assets/icons/svg/search.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/seckill.svg b/web/src/assets/icons/svg/seckill.svg new file mode 100644 index 0000000..dcd59e9 --- /dev/null +++ b/web/src/assets/icons/svg/seckill.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/server.svg b/web/src/assets/icons/svg/server.svg new file mode 100644 index 0000000..db6dcdf --- /dev/null +++ b/web/src/assets/icons/svg/server.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/seven.svg b/web/src/assets/icons/svg/seven.svg new file mode 100644 index 0000000..d2df729 --- /dev/null +++ b/web/src/assets/icons/svg/seven.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/shop.svg b/web/src/assets/icons/svg/shop.svg new file mode 100644 index 0000000..7e644c6 --- /dev/null +++ b/web/src/assets/icons/svg/shop.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/shopping.svg b/web/src/assets/icons/svg/shopping.svg new file mode 100644 index 0000000..87513e7 --- /dev/null +++ b/web/src/assets/icons/svg/shopping.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/sign2.svg b/web/src/assets/icons/svg/sign2.svg new file mode 100644 index 0000000..73e6106 --- /dev/null +++ b/web/src/assets/icons/svg/sign2.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/size.svg b/web/src/assets/icons/svg/size.svg new file mode 100644 index 0000000..ddb25b8 --- /dev/null +++ b/web/src/assets/icons/svg/size.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/skill.svg b/web/src/assets/icons/svg/skill.svg new file mode 100644 index 0000000..a3b7312 --- /dev/null +++ b/web/src/assets/icons/svg/skill.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/source.svg b/web/src/assets/icons/svg/source.svg new file mode 100644 index 0000000..1c3a038 --- /dev/null +++ b/web/src/assets/icons/svg/source.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/sqlMonitor.svg b/web/src/assets/icons/svg/sqlMonitor.svg new file mode 100644 index 0000000..f530a06 --- /dev/null +++ b/web/src/assets/icons/svg/sqlMonitor.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/store.svg b/web/src/assets/icons/svg/store.svg new file mode 100644 index 0000000..65d1f13 --- /dev/null +++ b/web/src/assets/icons/svg/store.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/swagger.svg b/web/src/assets/icons/svg/swagger.svg new file mode 100644 index 0000000..10547a6 --- /dev/null +++ b/web/src/assets/icons/svg/swagger.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/sys-tools.svg b/web/src/assets/icons/svg/sys-tools.svg new file mode 100644 index 0000000..c813067 --- /dev/null +++ b/web/src/assets/icons/svg/sys-tools.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/system.svg b/web/src/assets/icons/svg/system.svg new file mode 100644 index 0000000..dba28cf --- /dev/null +++ b/web/src/assets/icons/svg/system.svg @@ -0,0 +1,2 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/tab.svg b/web/src/assets/icons/svg/tab.svg new file mode 100644 index 0000000..b4b48e4 --- /dev/null +++ b/web/src/assets/icons/svg/tab.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/task manege.svg b/web/src/assets/icons/svg/task manege.svg new file mode 100644 index 0000000..91c986a --- /dev/null +++ b/web/src/assets/icons/svg/task manege.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/temp.svg b/web/src/assets/icons/svg/temp.svg new file mode 100644 index 0000000..c18d6d9 --- /dev/null +++ b/web/src/assets/icons/svg/temp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/theme.svg b/web/src/assets/icons/svg/theme.svg new file mode 100644 index 0000000..5982a2f --- /dev/null +++ b/web/src/assets/icons/svg/theme.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/timing.svg b/web/src/assets/icons/svg/timing.svg new file mode 100644 index 0000000..50ce065 --- /dev/null +++ b/web/src/assets/icons/svg/timing.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/tixian.svg b/web/src/assets/icons/svg/tixian.svg new file mode 100644 index 0000000..9363bd9 --- /dev/null +++ b/web/src/assets/icons/svg/tixian.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/today.svg b/web/src/assets/icons/svg/today.svg new file mode 100644 index 0000000..3ab4d15 --- /dev/null +++ b/web/src/assets/icons/svg/today.svg @@ -0,0 +1 @@ + diff --git a/web/src/assets/icons/svg/tools.svg b/web/src/assets/icons/svg/tools.svg new file mode 100644 index 0000000..19eeedf --- /dev/null +++ b/web/src/assets/icons/svg/tools.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/tree-table.svg b/web/src/assets/icons/svg/tree-table.svg new file mode 100644 index 0000000..8aafdb8 --- /dev/null +++ b/web/src/assets/icons/svg/tree-table.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/tree.svg b/web/src/assets/icons/svg/tree.svg new file mode 100644 index 0000000..dd4b7dd --- /dev/null +++ b/web/src/assets/icons/svg/tree.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/unlock.svg b/web/src/assets/icons/svg/unlock.svg new file mode 100644 index 0000000..d412720 --- /dev/null +++ b/web/src/assets/icons/svg/unlock.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/user.svg b/web/src/assets/icons/svg/user.svg new file mode 100644 index 0000000..30a6503 --- /dev/null +++ b/web/src/assets/icons/svg/user.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/user1.svg b/web/src/assets/icons/svg/user1.svg new file mode 100644 index 0000000..a3a0c66 --- /dev/null +++ b/web/src/assets/icons/svg/user1.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/validCode.svg b/web/src/assets/icons/svg/validCode.svg new file mode 100644 index 0000000..029244c --- /dev/null +++ b/web/src/assets/icons/svg/validCode.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/visits.svg b/web/src/assets/icons/svg/visits.svg new file mode 100644 index 0000000..88c8150 --- /dev/null +++ b/web/src/assets/icons/svg/visits.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/web.svg b/web/src/assets/icons/svg/web.svg new file mode 100644 index 0000000..9c57415 --- /dev/null +++ b/web/src/assets/icons/svg/web.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/wechat.svg b/web/src/assets/icons/svg/wechat.svg new file mode 100644 index 0000000..ef48940 --- /dev/null +++ b/web/src/assets/icons/svg/wechat.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/weixin.svg b/web/src/assets/icons/svg/weixin.svg new file mode 100644 index 0000000..5d57a61 --- /dev/null +++ b/web/src/assets/icons/svg/weixin.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/wxapp.svg b/web/src/assets/icons/svg/wxapp.svg new file mode 100644 index 0000000..8d3af3a --- /dev/null +++ b/web/src/assets/icons/svg/wxapp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/wxpay.svg b/web/src/assets/icons/svg/wxpay.svg new file mode 100644 index 0000000..d3e4d16 --- /dev/null +++ b/web/src/assets/icons/svg/wxpay.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/yingxiao.svg b/web/src/assets/icons/svg/yingxiao.svg new file mode 100644 index 0000000..8b7d1f1 --- /dev/null +++ b/web/src/assets/icons/svg/yingxiao.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svg/zujian.svg b/web/src/assets/icons/svg/zujian.svg new file mode 100644 index 0000000..8e0cc0a --- /dev/null +++ b/web/src/assets/icons/svg/zujian.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/web/src/assets/icons/svgo.yml b/web/src/assets/icons/svgo.yml new file mode 100644 index 0000000..d11906a --- /dev/null +++ b/web/src/assets/icons/svgo.yml @@ -0,0 +1,22 @@ +# replace default config + +# multipass: true +# full: true + +plugins: + + # - name + # + # or: + # - name: false + # - name: true + # + # or: + # - name: + # param1: 1 + # param2: 2 + +- removeAttrs: + attrs: + - 'fill' + - 'fill-rule' diff --git a/web/src/assets/images/avatar.png b/web/src/assets/images/avatar.png new file mode 100644 index 0000000..997732a Binary files /dev/null and b/web/src/assets/images/avatar.png differ diff --git a/web/src/assets/images/bg.jpg b/web/src/assets/images/bg.jpg new file mode 100644 index 0000000..ddc30c8 Binary files /dev/null and b/web/src/assets/images/bg.jpg differ diff --git a/web/src/assets/images/icons.png b/web/src/assets/images/icons.png new file mode 100644 index 0000000..c015e3a Binary files /dev/null and b/web/src/assets/images/icons.png differ diff --git a/web/src/assets/images/logo.png b/web/src/assets/images/logo.png new file mode 100644 index 0000000..626dac1 Binary files /dev/null and b/web/src/assets/images/logo.png differ diff --git a/web/src/assets/images/yshop.png b/web/src/assets/images/yshop.png new file mode 100644 index 0000000..573fb9e Binary files /dev/null and b/web/src/assets/images/yshop.png differ diff --git a/web/src/assets/styles/btn.scss b/web/src/assets/styles/btn.scss new file mode 100644 index 0000000..8f47f2c --- /dev/null +++ b/web/src/assets/styles/btn.scss @@ -0,0 +1,99 @@ +@import 'variables'; + +@mixin colorBtn($color) { + background: $color; + + &:hover { + color: $color; + + &:before, + &:after { + background: $color; + } + } +} + +.blue-btn { + @include colorBtn($blue) +} + +.light-blue-btn { + @include colorBtn($light-blue) +} + +.red-btn { + @include colorBtn($red) +} + +.pink-btn { + @include colorBtn($pink) +} + +.green-btn { + @include colorBtn($green) +} + +.tiffany-btn { + @include colorBtn($tiffany) +} + +.yellow-btn { + @include colorBtn($yellow) +} + +.pan-btn { + font-size: 14px; + color: #fff; + padding: 14px 36px; + border-radius: 8px; + border: none; + outline: none; + transition: 600ms ease all; + position: relative; + display: inline-block; + + &:hover { + background: #fff; + + &:before, + &:after { + width: 100%; + transition: 600ms ease all; + } + } + + &:before, + &:after { + content: ''; + position: absolute; + top: 0; + right: 0; + height: 2px; + width: 0; + transition: 400ms ease all; + } + + &::after { + right: inherit; + top: inherit; + left: 0; + bottom: 0; + } +} + +.custom-button { + display: inline-block; + line-height: 1; + white-space: nowrap; + cursor: pointer; + background: #fff; + color: #fff; + -webkit-appearance: none; + text-align: center; + box-sizing: border-box; + outline: 0; + margin: 0; + padding: 10px 15px; + font-size: 14px; + border-radius: 4px; +} diff --git a/web/src/assets/styles/description.scss b/web/src/assets/styles/description.scss new file mode 100644 index 0000000..76b0992 --- /dev/null +++ b/web/src/assets/styles/description.scss @@ -0,0 +1,17 @@ +.my-blockquote{ + margin: 0px 0px 10px; + padding: 15px; + line-height: 22px; + border-left: 5px solid #00437B; + border-radius: 0 2px 2px 0; + background-color: #f2f2f2; +} +.my-code{ + position: relative; + padding: 15px; + line-height: 20px; + border-left: 5px solid #ddd; + color: #333; + font-family: Courier New; + font-size: 12px +} diff --git a/web/src/assets/styles/eladmin.scss b/web/src/assets/styles/eladmin.scss new file mode 100644 index 0000000..338cbba --- /dev/null +++ b/web/src/assets/styles/eladmin.scss @@ -0,0 +1,100 @@ +.head-container { + padding-bottom: 10px; + .filter-item { + display: inline-block; + vertical-align: middle; + margin: 0 2px 10px 0; + input { + height: 30.5px; + line-height: 30.5px; + } + } + .el-select__caret.el-input__icon.el-icon-arrow-up{ + line-height: 30.5px; + } + .date-item { + display: inline-block; + vertical-align: middle; + margin-bottom: 10px; + height: 30.5px; + width: 223px; + } +} +.el-avatar { + display: inline-block; + text-align: center; + background: #ccc; + color: #fff; + white-space: nowrap; + position: relative; + overflow: hidden; + vertical-align: middle; + width: 32px; + height: 32px; + line-height: 32px; + border-radius: 16px; +} + +.logo-con{ + height: 60px; + padding: 13px 0 0; + img{ + height: 32px; + width: 135px; + display: block; + //margin: 0 auto; + } +} + +#el-login-footer { + height: 40px; + line-height: 40px; + position: fixed; + bottom: 0; + width: 100%; + text-align: center; + color: #fff; + font-family: Arial, serif; + font-size: 12px; + letter-spacing: 1px; +} + +#el-main-footer { + background: none repeat scroll 0 0 white; + border-top: 1px solid #e7eaec; + overflow: hidden; + padding: 10px 6px 0 6px; + height: 33px; + font-size: 0.7rem !important; + color: #7a8b9a; + letter-spacing: 0.8px; + font-family: Arial, sans-serif !important; + position: fixed; + bottom: 0; + z-index: 99; + width: 100%; +} +.eladmin-upload { + border: 1px dashed #c0ccda; + border-radius: 5px; + height: 45px; + line-height: 45px; + width: 368px; +} +.my-blockquote{ + margin: 0 0 10px; + padding: 15px; + line-height: 22px; + border-left: 5px solid #00437B; + border-radius: 0 2px 2px 0; + background-color: #f2f2f2; +} +.my-code{ + position: relative; + padding: 15px; + line-height: 20px; + border-left: 5px solid #ddd; + color: #333; + font-family: Courier New, serif; + font-size: 12px +} diff --git a/web/src/assets/styles/element-ui.scss b/web/src/assets/styles/element-ui.scss new file mode 100644 index 0000000..8f7881c --- /dev/null +++ b/web/src/assets/styles/element-ui.scss @@ -0,0 +1,79 @@ +// cover some element-ui styles + +.el-breadcrumb__inner, +.el-breadcrumb__inner a { + font-weight: 400 !important; +} + +.el-upload { + input[type="file"] { + display: none !important; + } +} + +.el-upload__input { + display: none; +} + +.cell { + .el-tag { + margin-right: 0; + } +} + +.small-padding { + .cell { + padding-left: 5px; + padding-right: 5px; + } +} + +.fixed-width { + .el-button--mini { + padding: 7px 10px; + width: 60px; + } +} + +.status-col { + .cell { + padding: 0 10px; + text-align: center; + + .el-tag { + margin-right: 0; + } + } +} + +// to fixed https://github.com/ElemeFE/element/issues/2461 +.el-dialog { + transform: none; + left: 0; + position: relative; + margin: 0 auto; +} + +// refine element ui upload +.upload-container { + .el-upload { + width: 100%; + + .el-upload-dragger { + width: 100%; + height: 200px; + } + } +} + +// dropdown +.el-dropdown-menu { + a { + display: block + } +} + +// fix date-picker ui bug in filter-item +.el-range-editor.el-input__inner { + display: inline-flex !important; +} diff --git a/web/src/assets/styles/element-variables.scss b/web/src/assets/styles/element-variables.scss new file mode 100644 index 0000000..a4f8c4a --- /dev/null +++ b/web/src/assets/styles/element-variables.scss @@ -0,0 +1,31 @@ +/** +* I think element-ui's default theme color is too light for long-term use. +* So I modified the default color and you can modify it to your liking. +**/ + +/* theme color */ +$--color-primary: #1890ff; +$--color-success: #13ce66; +$--color-warning: #FFBA00; +$--color-danger: #ff4949; +// $--color-info: #1E1E1E; + +$--button-font-weight: 400; + +// $--color-text-regular: #1f2d3d; + +$--border-color-light: #dfe4ed; +$--border-color-lighter: #e6ebf5; + +$--table-border:1px solid#dfe6ec; + +/* icon font path, required */ +$--font-path: '~element-ui/lib/theme-chalk/fonts'; + +@import "../../../node_modules/element-ui/packages/theme-chalk/src/index"; + +// the :export directive is the magic sauce for webpack +// https://www.bluematador.com/blog/how-to-share-variables-between-js-and-sass +:export { + theme: $--color-primary; +} diff --git a/web/src/assets/styles/index.scss b/web/src/assets/styles/index.scss new file mode 100644 index 0000000..85b22a0 --- /dev/null +++ b/web/src/assets/styles/index.scss @@ -0,0 +1,183 @@ +@import 'variables'; +@import 'mixin'; +@import 'transition'; +@import 'element-ui'; +@import 'sidebar'; +@import 'btn'; +@import 'eladmin'; +@import "yshop"; + +body { + height: 100%; + -moz-osx-font-smoothing: grayscale; + -webkit-font-smoothing: antialiased; + text-rendering: optimizeLegibility; + font-family: Helvetica Neue, Helvetica, PingFang SC, Hiragino Sans GB, Microsoft YaHei, Arial, sans-serif; +} + +label { + font-weight: 700; +} + +html { + height: 100%; + box-sizing: border-box; +} + +#app { + height: 100%; +} + +*, +*:before, +*:after { + box-sizing: inherit; +} + +.no-padding { + padding: 0 !important; +} + +.padding-content { + padding: 4px 0; +} + +a:focus, +a:active { + outline: none; +} + +a, +a:focus, +a:hover { + cursor: pointer; + color: inherit; + text-decoration: none; +} + +div:focus { + outline: none; +} + +.fr { + float: right; +} + +.fl { + float: left; +} + +.pr-5 { + padding-right: 5px; +} + +.pl-5 { + padding-left: 5px; +} + +.block { + display: block; +} + +.pointer { + cursor: pointer; +} + +.inlineBlock { + display: block; +} + +.clearfix { + &:after { + visibility: hidden; + display: block; + font-size: 0; + content: " "; + clear: both; + height: 0; + } +} + +aside { + background: #eef1f6; + padding: 8px 24px; + margin-bottom: 20px; + border-radius: 2px; + display: block; + line-height: 32px; + font-size: 16px; + font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif; + color: #2c3e50; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + + a { + color: #337ab7; + cursor: pointer; + + &:hover { + color: rgb(32, 160, 255); + } + } +} + +//main-container全局样式 +.app-container { + padding: 20px 20px 45px 20px; +} + +.components-container { + margin: 30px 50px; + position: relative; +} + +.pagination-container { + margin-top: 30px; +} + +.text-center { + text-align: center +} + +.sub-navbar { + height: 50px; + line-height: 50px; + position: relative; + width: 100%; + text-align: right; + padding-right: 20px; + transition: 600ms ease position; + background: linear-gradient(90deg, rgba(32, 182, 249, 1) 0%, rgba(32, 182, 249, 1) 0%, rgba(33, 120, 241, 1) 100%, rgba(33, 120, 241, 1) 100%); + + .subtitle { + font-size: 20px; + color: #fff; + } + + &.draft { + background: #d0d0d0; + } + + &.deleted { + background: #d0d0d0; + } +} + +.link-type, +.link-type:focus { + color: #337ab7; + cursor: pointer; + + &:hover { + color: rgb(32, 160, 255); + } +} + +//refine vue-multiselect plugin +.multiselect { + line-height: 16px; +} + +.multiselect--active { + z-index: 1000 !important; +} diff --git a/web/src/assets/styles/mixin.scss b/web/src/assets/styles/mixin.scss new file mode 100644 index 0000000..06fa061 --- /dev/null +++ b/web/src/assets/styles/mixin.scss @@ -0,0 +1,66 @@ +@mixin clearfix { + &:after { + content: ""; + display: table; + clear: both; + } +} + +@mixin scrollBar { + &::-webkit-scrollbar-track-piece { + background: #d3dce6; + } + + &::-webkit-scrollbar { + width: 6px; + } + + &::-webkit-scrollbar-thumb { + background: #99a9bf; + border-radius: 20px; + } +} + +@mixin relative { + position: relative; + width: 100%; + height: 100%; +} + +@mixin pct($pct) { + width: #{$pct}; + position: relative; + margin: 0 auto; +} + +@mixin triangle($width, $height, $color, $direction) { + $width: $width/2; + $color-border-style: $height solid $color; + $transparent-border-style: $width solid transparent; + height: 0; + width: 0; + + @if $direction==up { + border-bottom: $color-border-style; + border-left: $transparent-border-style; + border-right: $transparent-border-style; + } + + @else if $direction==right { + border-left: $color-border-style; + border-top: $transparent-border-style; + border-bottom: $transparent-border-style; + } + + @else if $direction==down { + border-top: $color-border-style; + border-left: $transparent-border-style; + border-right: $transparent-border-style; + } + + @else if $direction==left { + border-right: $color-border-style; + border-top: $transparent-border-style; + border-bottom: $transparent-border-style; + } +} diff --git a/web/src/assets/styles/sidebar.scss b/web/src/assets/styles/sidebar.scss new file mode 100644 index 0000000..17381fc --- /dev/null +++ b/web/src/assets/styles/sidebar.scss @@ -0,0 +1,209 @@ +#app { + + .main-container { + min-height: 100%; + transition: margin-left .28s; + margin-left: $sideBarWidth; + position: relative; + } + + .sidebar-container { + transition: width 0.28s; + width: $sideBarWidth !important; + background-color: $menuBg; + height: 100%; + position: fixed; + font-size: 0; + top: 0; + bottom: 0; + left: 0; + z-index: 1001; + overflow: hidden; + + // reset element-ui css + .horizontal-collapse-transition { + transition: 0s width ease-in-out, 0s padding-left ease-in-out, 0s padding-right ease-in-out; + } + + .scrollbar-wrapper { + overflow-x: hidden !important; + } + + .el-scrollbar__bar.is-vertical { + right: 0; + } + + .el-scrollbar { + height: 100%; + } + + &.has-logo { + .el-scrollbar { + height: calc(100% - 50px); + } + } + + .is-horizontal { + display: none; + } + + a { + display: inline-block; + width: 100%; + overflow: hidden; + } + + .svg-icon { + margin-right: 16px; + } + + .el-menu { + border: none; + height: 100%; + width: 100% !important; + } + + // menu hover + .submenu-title-noDropdown, + .el-submenu__title { + &:hover { + background-color: $menuHover !important; + } + } + + .is-active>.el-submenu__title { + color: $subMenuActiveText !important; + } + + & .nest-menu .el-submenu>.el-submenu__title, + & .el-submenu .el-menu-item { + min-width: $sideBarWidth !important; + background-color: $subMenuBg !important; + + &:hover { + background-color: $subMenuHover !important; + } + } + } + + .hideSidebar { + .sidebar-container { + width: 54px !important; + } + + .main-container { + margin-left: 54px; + } + + .submenu-title-noDropdown { + padding: 0 !important; + position: relative; + + .el-tooltip { + padding: 0 !important; + + .svg-icon { + margin-left: 20px; + } + } + } + + .el-submenu { + overflow: hidden; + + &>.el-submenu__title { + padding: 0 !important; + + .svg-icon { + margin-left: 20px; + } + + .el-submenu__icon-arrow { + display: none; + } + } + } + + .el-menu--collapse { + .el-submenu { + &>.el-submenu__title { + &>span { + height: 0; + width: 0; + overflow: hidden; + visibility: hidden; + display: inline-block; + } + } + } + } + } + + .el-menu--collapse .el-menu .el-submenu { + min-width: $sideBarWidth !important; + } + + // mobile responsive + .mobile { + .main-container { + margin-left: 0; + } + + .sidebar-container { + transition: transform .28s; + width: $sideBarWidth !important; + } + + &.hideSidebar { + .sidebar-container { + pointer-events: none; + transition-duration: 0.3s; + transform: translate3d(-$sideBarWidth, 0, 0); + } + } + } + + .withoutAnimation { + + .main-container, + .sidebar-container { + transition: none; + } + } +} + +// when menu collapsed +.el-menu--vertical { + &>.el-menu { + .svg-icon { + margin-right: 16px; + } + } + + .nest-menu .el-submenu>.el-submenu__title, + .el-menu-item { + &:hover { + // you can use $subMenuHover + background-color: $menuHover !important; + } + } + + // the scroll bar appears when the subMenu is too long + >.el-menu--popup { + max-height: 100vh; + overflow-y: auto; + + &::-webkit-scrollbar-track-piece { + background: #d3dce6; + } + + &::-webkit-scrollbar { + width: 6px; + } + + &::-webkit-scrollbar-thumb { + background: #99a9bf; + border-radius: 20px; + } + } +} diff --git a/web/src/assets/styles/transition.scss b/web/src/assets/styles/transition.scss new file mode 100644 index 0000000..4cb27cc --- /dev/null +++ b/web/src/assets/styles/transition.scss @@ -0,0 +1,48 @@ +// global transition css + +/* fade */ +.fade-enter-active, +.fade-leave-active { + transition: opacity 0.28s; +} + +.fade-enter, +.fade-leave-active { + opacity: 0; +} + +/* fade-transform */ +.fade-transform-leave-active, +.fade-transform-enter-active { + transition: all .5s; +} + +.fade-transform-enter { + opacity: 0; + transform: translateX(-30px); +} + +.fade-transform-leave-to { + opacity: 0; + transform: translateX(30px); +} + +/* breadcrumb transition */ +.breadcrumb-enter-active, +.breadcrumb-leave-active { + transition: all .5s; +} + +.breadcrumb-enter, +.breadcrumb-leave-active { + opacity: 0; + transform: translateX(20px); +} + +.breadcrumb-move { + transition: all .5s; +} + +.breadcrumb-leave-active { + position: absolute; +} diff --git a/web/src/assets/styles/variables.scss b/web/src/assets/styles/variables.scss new file mode 100644 index 0000000..41de79c --- /dev/null +++ b/web/src/assets/styles/variables.scss @@ -0,0 +1,35 @@ +// base color +$blue:#324157; +$light-blue:#3A71A8; +$red:#C03639; +$pink: #E65D6E; +$green: #30B08F; +$tiffany: #4AB7BD; +$yellow:#FEC171; +$panGreen: #30B08F; + +// sidebar +$menuText:#bfcbd9; +$menuActiveText:#409EFF; +$subMenuActiveText:#f4f4f5; // https://github.com/ElemeFE/element/issues/12951 + +$menuBg:#304156; +$menuHover:#263445; + +$subMenuBg:#1f2d3d; +$subMenuHover:#001528; + +$sideBarWidth: 205px; + +// the :export directive is the magic sauce for webpack +// https://www.bluematador.com/blog/how-to-share-variables-between-js-and-sass +:export { + menuText: $menuText; + menuActiveText: $menuActiveText; + subMenuActiveText: $subMenuActiveText; + menuBg: $menuBg; + menuHover: $menuHover; + subMenuBg: $subMenuBg; + subMenuHover: $subMenuHover; + sideBarWidth: $sideBarWidth; +} diff --git a/web/src/assets/styles/yshop.css b/web/src/assets/styles/yshop.css new file mode 100644 index 0000000..c14c4c2 --- /dev/null +++ b/web/src/assets/styles/yshop.css @@ -0,0 +1,268 @@ +@charset "UTF-8"; +.acea-row { + display: -webkit-box; + display: -moz-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-box-lines: multiple; + -moz-box-lines: multiple; + -o-box-lines: multiple; + -webkit-flex-wrap: wrap; + -ms-flex-wrap: wrap; + flex-wrap: wrap; + /* 辅助类 */ +} + +.acea-row.row-middle { + -webkit-box-align: center; + -moz-box-align: center; + -o-box-align: center; + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; +} + +.acea-row.row-top { + -webkit-box-align: start; + -moz-box-align: start; + -o-box-align: start; + -ms-flex-align: start; + -webkit-align-items: flex-start; + align-items: flex-start; +} + +.acea-row.row-bottom { + -webkit-box-align: end; + -moz-box-align: end; + -o-box-align: end; + -ms-flex-align: end; + -webkit-align-items: flex-end; + align-items: flex-end; +} + +.acea-row.row-center { + -webkit-box-pack: center; + -moz-box-pack: center; + -o-box-pack: center; + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; +} + +.acea-row.row-right { + -webkit-box-pack: end; + -moz-box-pack: end; + -o-box-pack: end; + -ms-flex-pack: end; + -webkit-justify-content: flex-end; + justify-content: flex-end; +} + +.acea-row.row-left { + -webkit-box-pack: start; + -moz-box-pack: start; + -o-box-pack: start; + -ms-flex-pack: start; + -webkit-justify-content: flex-start; + justify-content: flex-start; +} + +.acea-row.row-between { + -webkit-box-pack: justify; + -moz-box-pack: justify; + -o-box-pack: justify; + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; +} + +.acea-row.row-around { + justify-content: space-around; + -webkit-justify-content: space-around; +} + +.acea-row.row-column-around { + -webkit-flex-direction: column; + -ms-flex-direction: column; + flex-direction: column; + justify-content: space-around; + -webkit-justify-content: space-around; +} + +.acea-row.row-column { + -webkit-box-orient: vertical; + -moz-box-orient: vertical; + -o-box-orient: vertical; + -webkit-flex-direction: column; + -ms-flex-direction: column; + flex-direction: column; +} + +.acea-row.row-column-between { + -webkit-box-orient: vertical; + -moz-box-orient: vertical; + -o-box-orient: vertical; + -webkit-flex-direction: column; + -ms-flex-direction: column; + flex-direction: column; + -webkit-box-pack: justify; + -moz-box-pack: justify; + -o-box-pack: justify; + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; +} + +/* 上下左右垂直居中 */ +.acea-row.row-center-wrapper { + -webkit-box-align: center; + -moz-box-align: center; + -o-box-align: center; + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + -webkit-box-pack: center; + -moz-box-pack: center; + -o-box-pack: center; + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; +} + +/* 上下两边居中对齐 */ +.acea-row.row-between-wrapper { + -webkit-box-align: center; + -moz-box-align: center; + -o-box-align: center; + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + -webkit-box-pack: justify; + -moz-box-pack: justify; + -o-box-pack: justify; + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; +} + +/*表单公共样式*/ +html, body { + font-size: 12px !important; +} + +.ivu-table-wrapper { + overflow: unset !important; +} + +.page { + margin-top: 22px; +} + +.vxe-table--loading { + background-color: rgba(255, 255, 255, 0.9) !important; +} + +.vxe-table--loading .vxe-table--spinner:after, .vxe-table--loading .vxe-table--spinner:before { + width: 50% !important; + height: 50% !important; +} + + +/*距离样式*/ +.mr { + margin-right: 15px; +} + +.mr10 { + margin-right: 10px; +} + +.ml20 { + margin-left: 20px; +} + +.ml10 { + margin-left: 10px; +} + +.ml40 { + margin-left: 40px !important; +} +.ml95 { + margin-left: 95px !important; +} + +.pt5 { + padding: 5px 0 !important; + box-sizing: border-box; +} + +.mr50 { + margin-right: 50px; +} + +.mr20 { + margin-right: 20px !important; +} + +.mr15 { + margin-right: 15px !important; +} +.mr5 { + margin-right: 5px !important; +} + +.mb20 { + margin-bottom: 20px !important; +} +.mb5 { + margin-bottom: 5px !important; +} +.mb15 { + margin-bottom: 15px !important; +} + +.mb30 { + margin-bottom: 30px !important; +} + +.mt30 { + margin-top: 30px; +} + +.mt25 { + margin-top: 25px; +} + +.mt20 { + margin-top: 20px; +} + +.mt50 { + margin-top: 50px; +} + +.mt10{ + margin-top: 10px; +} +.mb10 { + margin-bottom: 10px !important; +} +.mb5 { + margin-bottom: 5px !important; +} +.index_bg { + width: 100%; + /*height: 100vh;*/ + background: rgba(0, 0, 0, .6) !important; + z-index: 0 !important; +} + + +/*字体上移变蓝色*/ +.font-blue:hover { + color:#2D8cF0; + cursor:pointer; +} + diff --git a/web/src/assets/styles/yshop.scss b/web/src/assets/styles/yshop.scss new file mode 100644 index 0000000..992faf3 --- /dev/null +++ b/web/src/assets/styles/yshop.scss @@ -0,0 +1,268 @@ +@charset "UTF-8"; +.acea-row { + display: -webkit-box; + display: -moz-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-box-lines: multiple; + -moz-box-lines: multiple; + -o-box-lines: multiple; + -webkit-flex-wrap: wrap; + -ms-flex-wrap: wrap; + flex-wrap: wrap; + /* 辅助类 */ +} + +.acea-row.row-middle { + -webkit-box-align: center; + -moz-box-align: center; + -o-box-align: center; + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; +} + +.acea-row.row-top { + -webkit-box-align: start; + -moz-box-align: start; + -o-box-align: start; + -ms-flex-align: start; + -webkit-align-items: flex-start; + align-items: flex-start; +} + +.acea-row.row-bottom { + -webkit-box-align: end; + -moz-box-align: end; + -o-box-align: end; + -ms-flex-align: end; + -webkit-align-items: flex-end; + align-items: flex-end; +} + +.acea-row.row-center { + -webkit-box-pack: center; + -moz-box-pack: center; + -o-box-pack: center; + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; +} + +.acea-row.row-right { + -webkit-box-pack: end; + -moz-box-pack: end; + -o-box-pack: end; + -ms-flex-pack: end; + -webkit-justify-content: flex-end; + justify-content: flex-end; +} + +.acea-row.row-left { + -webkit-box-pack: start; + -moz-box-pack: start; + -o-box-pack: start; + -ms-flex-pack: start; + -webkit-justify-content: flex-start; + justify-content: flex-start; +} + +.acea-row.row-between { + -webkit-box-pack: justify; + -moz-box-pack: justify; + -o-box-pack: justify; + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; +} + +.acea-row.row-around { + justify-content: space-around; + -webkit-justify-content: space-around; +} + +.acea-row.row-column-around { + -webkit-flex-direction: column; + -ms-flex-direction: column; + flex-direction: column; + justify-content: space-around; + -webkit-justify-content: space-around; +} + +.acea-row.row-column { + -webkit-box-orient: vertical; + -moz-box-orient: vertical; + -o-box-orient: vertical; + -webkit-flex-direction: column; + -ms-flex-direction: column; + flex-direction: column; +} + +.acea-row.row-column-between { + -webkit-box-orient: vertical; + -moz-box-orient: vertical; + -o-box-orient: vertical; + -webkit-flex-direction: column; + -ms-flex-direction: column; + flex-direction: column; + -webkit-box-pack: justify; + -moz-box-pack: justify; + -o-box-pack: justify; + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; +} + +/* 上下左右垂直居中 */ +.acea-row.row-center-wrapper { + -webkit-box-align: center; + -moz-box-align: center; + -o-box-align: center; + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + -webkit-box-pack: center; + -moz-box-pack: center; + -o-box-pack: center; + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; +} + +/* 上下两边居中对齐 */ +.acea-row.row-between-wrapper { + -webkit-box-align: center; + -moz-box-align: center; + -o-box-align: center; + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + -webkit-box-pack: justify; + -moz-box-pack: justify; + -o-box-pack: justify; + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; +} + +/*表单公共样式*/ +html, body { + font-size: 12px !important; +} + + +.page { + margin-top: 22px; +} + +.vxe-table--loading { + background-color: rgba(255, 255, 255, 0.9) !important; +} + +.vxe-table--loading .vxe-table--spinner:after, .vxe-table--loading .vxe-table--spinner:before { + width: 50% !important; + height: 50% !important; +} + + +/*距离样式*/ +.mr { + margin-right: 15px; +} + +.mr10 { + margin-right: 10px; +} + +.ml20 { + margin-left: 20px; +} + +.ml10 { + margin-left: 10px; +} + +.ml40 { + margin-left: 40px !important; +} +.ml95 { + margin-left: 95px !important; +} + +.pt5 { + padding: 5px 0 !important; + box-sizing: border-box; +} + +.mr50 { + margin-right: 50px; +} + +.mr20 { + margin-right: 20px !important; +} + +.mr15 { + margin-right: 15px !important; +} +.mr5 { + margin-right: 5px !important; +} + +.mb20 { + margin-bottom: 20px !important; +} +.mb5 { + margin-bottom: 5px !important; +} +.mb15 { + margin-bottom: 15px !important; +} + +.mb30 { + margin-bottom: 30px !important; +} + +.mt30 { + margin-top: 30px; +} + +.mt25 { + margin-top: 25px; +} + +.mt20 { + margin-top: 20px; +} + +.mt50 { + margin-top: 50px; +} + +.mt10{ + margin-top: 10px; +} +.mb10 { + margin-bottom: 10px !important; +} +.mb5 { + margin-bottom: 5px !important; +} +.index_bg { + width: 100%; + /*height: 100vh;*/ + background: rgba(0, 0, 0, .6) !important; + z-index: 0 !important; +} + + +/*字体上移变蓝色*/ +.font-blue:hover { + color:#2D8cF0; + cursor:pointer; +} + + + + diff --git a/web/src/components/Breadcrumb/index.vue b/web/src/components/Breadcrumb/index.vue new file mode 100644 index 0000000..204ea59 --- /dev/null +++ b/web/src/components/Breadcrumb/index.vue @@ -0,0 +1,81 @@ + + + + + diff --git a/web/src/components/Crud/CRUD.operation.vue b/web/src/components/Crud/CRUD.operation.vue new file mode 100644 index 0000000..de052b7 --- /dev/null +++ b/web/src/components/Crud/CRUD.operation.vue @@ -0,0 +1,179 @@ + + + + diff --git a/web/src/components/Crud/Pagination.vue b/web/src/components/Crud/Pagination.vue new file mode 100644 index 0000000..d4482fb --- /dev/null +++ b/web/src/components/Crud/Pagination.vue @@ -0,0 +1,18 @@ + + + diff --git a/web/src/components/Crud/RR.operation.vue b/web/src/components/Crud/RR.operation.vue new file mode 100644 index 0000000..71453d5 --- /dev/null +++ b/web/src/components/Crud/RR.operation.vue @@ -0,0 +1,22 @@ + + + diff --git a/web/src/components/Crud/UD.operation.vue b/web/src/components/Crud/UD.operation.vue new file mode 100644 index 0000000..38f3339 --- /dev/null +++ b/web/src/components/Crud/UD.operation.vue @@ -0,0 +1,71 @@ + + diff --git a/web/src/components/Crud/crud.js b/web/src/components/Crud/crud.js new file mode 100644 index 0000000..6d40d19 --- /dev/null +++ b/web/src/components/Crud/crud.js @@ -0,0 +1,774 @@ +import { initData, download } from '@/api/data' +import { parseTime, downloadFile } from '@/utils/index' +import Vue from 'vue' + +/** + * CRUD配置 + * @author moxun + * @param {*} options
+ * @return crud instance. + * @example + */ +function CRUD(options) { + const defaultOptions = { + // 标题 + title: '', + // 请求数据的url + url: '', + // 表格数据 + data: [], + // 选择项 + selections: [], + // 待查询的对象 + query: {}, + // 查询数据的参数 + params: {}, + // Form 表单 + form: {}, + // 重置表单 + defaultForm: () => {}, + // 排序规则,默认 id 降序, 支持多字段排序 ['id,desc', 'createTime,asc'] + sort: ['id,desc'], + // 等待时间 + time: 50, + // CRUD Method + crudMethod: { + add: (form) => {}, + delete: (id) => {}, + edit: (form) => {}, + get: (id) => {} + }, + // 主页操作栏显示哪些按钮 + optShow: { + add: true, + edit: true, + del: true, + download: true + }, + // 自定义一些扩展属性 + props: {}, + // 在主页准备 + queryOnPresenterCreated: true, + // 调试开关 + debug: false + } + options = mergeOptions(defaultOptions, options) + const data = { + ...options, + // 记录数据状态 + dataStatus: {}, + status: { + add: CRUD.STATUS.NORMAL, + edit: CRUD.STATUS.NORMAL, + // 添加或编辑状态 + get cu() { + if (this.add === CRUD.STATUS.NORMAL && this.edit === CRUD.STATUS.NORMAL) { + return CRUD.STATUS.NORMAL + } else if (this.add === CRUD.STATUS.PREPARED || this.edit === CRUD.STATUS.PREPARED) { + return CRUD.STATUS.PREPARED + } else if (this.add === CRUD.STATUS.PROCESSING || this.edit === CRUD.STATUS.PROCESSING) { + return CRUD.STATUS.PROCESSING + } + throw new Error('wrong crud\'s cu status') + }, + // 标题 + get title() { + return this.add > CRUD.STATUS.NORMAL ? `新增${crud.title}` : this.edit > CRUD.STATUS.NORMAL ? `编辑${crud.title}` : crud.title + } + }, + msg: { + submit: '提交成功', + add: '新增成功', + edit: '编辑成功', + del: '删除成功' + }, + page: { + // 页码 + page: 0, + // 每页数据条数 + size: 10, + // 总数据条数 + total: 0 + }, + // 整体loading + loading: true, + // 导出的 Loading + downloadLoading: false, + // 删除的 Loading + delAllLoading: false + } + const methods = { + /** + * 通用的提示 + */ + submitSuccessNotify() { + crud.notify(crud.msg.submit, CRUD.NOTIFICATION_TYPE.SUCCESS) + }, + addSuccessNotify() { + crud.notify(crud.msg.add, CRUD.NOTIFICATION_TYPE.SUCCESS) + }, + editSuccessNotify() { + crud.notify(crud.msg.edit, CRUD.NOTIFICATION_TYPE.SUCCESS) + }, + delSuccessNotify() { + crud.notify(crud.msg.del, CRUD.NOTIFICATION_TYPE.SUCCESS) + }, + // 搜索 + toQuery() { + crud.page.page = 1 + crud.refresh() + }, + // 刷新 + refresh() { + if (!callVmHook(crud, CRUD.HOOK.beforeRefresh)) { + return + } + return new Promise((resolve, reject) => { + crud.loading = true + // 请求数据 + initData(crud.url, crud.getQueryParams()).then(data => { + console.log('a:' + data.data.totalElements) + crud.page.total = data.data.totalElements + crud.data = data.data.content + crud.resetDataStatus() + // time 毫秒后显示表格 + setTimeout(() => { + crud.loading = false + callVmHook(crud, CRUD.HOOK.afterRefresh) + }, crud.time) + resolve(data) + }).catch(err => { + crud.loading = false + reject(err) + }) + }) + }, + /** + * 启动添加 + */ + toAdd() { + if (!(callVmHook(crud, CRUD.HOOK.beforeToAdd, crud.form) && callVmHook(crud, CRUD.HOOK.beforeToCU, crud.form))) { + return + } + crud.status.add = CRUD.STATUS.PREPARED + callVmHook(crud, CRUD.HOOK.afterToAdd, crud.form) + callVmHook(crud, CRUD.HOOK.afterToCU, crud.form) + }, + /** + * 启动编辑 + * @param {*} data 数据项 + */ + toEdit(data) { + crud.resetForm(JSON.parse(JSON.stringify(data))) + if (!(callVmHook(crud, CRUD.HOOK.beforeToEdit, crud.form) && callVmHook(crud, CRUD.HOOK.beforeToCU, crud.form))) { + return + } + crud.status.edit = CRUD.STATUS.PREPARED + crud.getDataStatus(data.id).edit = CRUD.STATUS.PREPARED + callVmHook(crud, CRUD.HOOK.afterToEdit, crud.form) + callVmHook(crud, CRUD.HOOK.afterToCU, crud.form) + }, + /** + * 启动删除 + * @param {*} data 数据项 + */ + toDelete(data) { + crud.getDataStatus(data.id).delete = CRUD.STATUS.PREPARED + }, + /** + * 取消删除 + * @param {*} data 数据项 + */ + cancelDelete(data) { + if (!callVmHook(crud, CRUD.HOOK.beforeDeleteCancel, data)) { + return + } + crud.getDataStatus(data.id).delete = CRUD.STATUS.NORMAL + callVmHook(crud, CRUD.HOOK.afterDeleteCancel, data) + }, + /** + * 取消新增/编辑 + */ + cancelCU() { + const addStatus = crud.status.add + const editStatus = crud.status.edit + if (addStatus === CRUD.STATUS.PREPARED) { + if (!callVmHook(crud, CRUD.HOOK.beforeAddCancel, crud.form)) { + return + } + crud.status.add = CRUD.STATUS.NORMAL + } + if (editStatus === CRUD.STATUS.PREPARED) { + if (!callVmHook(crud, CRUD.HOOK.beforeEditCancel, crud.form)) { + return + } + crud.status.edit = CRUD.STATUS.NORMAL + crud.getDataStatus(crud.form.id).edit = CRUD.STATUS.NORMAL + } + crud.resetForm() + if (addStatus === CRUD.STATUS.PREPARED) { + callVmHook(crud, CRUD.HOOK.afterAddCancel, crud.form) + } + if (editStatus === CRUD.STATUS.PREPARED) { + callVmHook(crud, CRUD.HOOK.afterEditCancel, crud.form) + } + // 清除表单验证 + if (crud.findVM('form').$refs['form']) { + crud.findVM('form').$refs['form'].clearValidate() + } + }, + /** + * 提交新增/编辑 + */ + submitCU() { + if (!callVmHook(crud, CRUD.HOOK.beforeValidateCU)) { + return + } + crud.findVM('form').$refs['form'].validate(valid => { + if (!valid) { + return + } + if (!callVmHook(crud, CRUD.HOOK.afterValidateCU)) { + return + } + if (crud.status.add === CRUD.STATUS.PREPARED) { + crud.doAdd() + } else if (crud.status.edit === CRUD.STATUS.PREPARED) { + crud.doEdit() + } + }) + }, + /** + * 执行添加 + */ + doAdd() { + if (!callVmHook(crud, CRUD.HOOK.beforeSubmit)) { + return + } + crud.crudMethod.add(crud.form).then(() => { + crud.status.add = CRUD.STATUS.NORMAL + crud.resetForm() + crud.addSuccessNotify() + callVmHook(crud, CRUD.HOOK.afterSubmit) + crud.toQuery() + }).catch(() => { + callVmHook(crud, CRUD.HOOK.afterAddError) + }) + }, + /** + * 执行编辑 + */ + doEdit() { + if (!callVmHook(crud, CRUD.HOOK.beforeSubmit)) { + return + } + crud.crudMethod.edit(crud.form).then(() => { + crud.status.edit = CRUD.STATUS.NORMAL + crud.getDataStatus(crud.form.id).edit = CRUD.STATUS.NORMAL + crud.editSuccessNotify() + crud.resetForm() + callVmHook(crud, CRUD.HOOK.afterSubmit) + crud.refresh() + }).catch(() => { + callVmHook(crud, CRUD.HOOK.afterEditError) + }) + }, + /** + * 执行删除 + * @param {*} data 数据项 + */ + doDelete(data) { + let delAll = false + let dataStatus + const ids = [] + if (data instanceof Array) { + delAll = true + data.forEach(val => { + ids.push(val.id) + }) + } else { + ids.push(data.id) + dataStatus = crud.getDataStatus(data.id) + } + if (!callVmHook(crud, CRUD.HOOK.beforeDelete, data)) { + return + } + if (!delAll) { + dataStatus.delete = CRUD.STATUS.PROCESSING + } + return crud.crudMethod.del(ids).then(() => { + if (delAll) { + crud.delAllLoading = false + } else dataStatus.delete = CRUD.STATUS.PREPARED + crud.dleChangePage(1) + crud.delSuccessNotify() + callVmHook(crud, CRUD.HOOK.afterDelete, data) + crud.refresh() + }).catch(() => { + if (delAll) { + crud.delAllLoading = false + } else dataStatus.delete = CRUD.STATUS.PREPARED + }) + }, + /** + * 通用导出 + */ + doExport() { + crud.downloadLoading = true + download(crud.url + '/download', crud.getQueryParams()).then(result => { + downloadFile(result, crud.title + '数据', 'xlsx') + crud.downloadLoading = false + }).catch(() => { + crud.downloadLoading = false + }) + }, + /** + * 获取查询参数 + */ + getQueryParams: function() { + return { + page: crud.page.page - 1, + size: crud.page.size, + sort: crud.sort, + ...crud.query, + ...crud.params + } + }, + // 当前页改变 + pageChangeHandler(e) { + crud.page.page = e + crud.refresh() + }, + // 每页条数改变 + sizeChangeHandler(e) { + crud.page.size = e + crud.page.page = 1 + crud.refresh() + }, + // 预防删除第二页最后一条数据时,或者多选删除第二页的数据时,页码错误导致请求无数据 + dleChangePage(size) { + if (crud.data.length === size && crud.page.page !== 1) { + crud.page.page -= 1 + } + }, + // 选择改变 + selectionChangeHandler(val) { + crud.selections = val + }, + /** + * 重置查询参数 + * @param {Boolean} toQuery 重置后进行查询操作 + */ + resetQuery(toQuery = true) { + const defaultQuery = JSON.parse(JSON.stringify(crud.defaultQuery)) + const query = crud.query + Object.keys(query).forEach(key => { + query[key] = defaultQuery[key] + }) + if (toQuery) { + crud.toQuery() + } + }, + /** + * 重置表单 + * @param {Array} data 数据 + */ + resetForm(data) { + const form = data || (typeof crud.defaultForm === 'object' ? JSON.parse(JSON.stringify(crud.defaultForm)) : crud.defaultForm()) + const crudFrom = crud.form + for (const key in form) { + if (crudFrom.hasOwnProperty(key)) { + crudFrom[key] = form[key] + } else { + Vue.set(crudFrom, key, form[key]) + } + } + }, + /** + * 重置数据状态 + */ + resetDataStatus() { + const dataStatus = {} + function resetStatus(datas) { + datas.forEach(e => { + dataStatus[e.id] = { + delete: 0, + edit: 0 + } + if (e.children) { + resetStatus(e.children) + } + }) + } + resetStatus(crud.data) + crud.dataStatus = dataStatus + }, + /** + * 获取数据状态 + * @param {Number | String} id 数据项id + */ + getDataStatus(id) { + return crud.dataStatus[id] + }, + /** + * 用于树形表格多选, 选中所有 + * @param selection + */ + selectAllChange(selection) { + // 如果选中的数目与请求到的数目相同就选中子节点,否则就清空选中 + if (selection && selection.length === crud.data.length) { + selection.forEach(val => { + crud.selectChange(selection, val) + }) + } else { + crud.findVM('presenter').$refs['table'].clearSelection() + } + }, + /** + * 用于树形表格多选,单选的封装 + * @param selection + * @param row + */ + selectChange(selection, row) { + // 如果selection中存在row代表是选中,否则是取消选中 + if (selection.find(val => { return val.id === row.id })) { + if (row.children) { + row.children.forEach(val => { + crud.findVM('presenter').$refs['table'].toggleRowSelection(val, true) + selection.push(val) + if (val.children) { + crud.selectChange(selection, val) + } + }) + } + } else { + crud.toggleRowSelection(selection, row) + } + }, + /** + * 切换选中状态 + * @param selection + * @param data + */ + toggleRowSelection(selection, data) { + if (data.children) { + data.children.forEach(val => { + crud.findVM('presenter').$refs['table'].toggleRowSelection(val, false) + if (val.children) { + crud.toggleRowSelection(selection, val) + } + }) + } + }, + findVM(type) { + return crud.vms.find(vm => vm && vm.type === type).vm + }, + notify(title, type = CRUD.NOTIFICATION_TYPE.INFO) { + crud.vms[0].vm.$notify({ + title, + type, + duration: 2500 + }) + }, + updateProp(name, value) { + Vue.set(crud.props, name, value) + } + } + const crud = Object.assign({}, data) + // 可观测化 + Vue.observable(crud) + // 附加方法 + Object.assign(crud, methods) + // 记录初始默认的查询参数,后续重置查询时使用 + Object.assign(crud, { + defaultQuery: JSON.parse(JSON.stringify(data.query)), + // 预留4位存储:组件 主页、头部、分页、表单,调试查看也方便找 + vms: Array(4), + /** + * 注册组件实例 + * @param {String} type 类型 + * @param {*} vm 组件实例 + * @param {Number} index 该参数内部使用 + */ + registerVM(type, vm, index = -1) { + const vmObj = { + type, + vm: vm + } + if (index < 0) { + this.vms.push(vmObj) + return + } + this.vms.length = Math.max(this.vms.length, index) + this.vms.splice(index, 1, vmObj) + }, + /** + * 取消注册组件实例 + * @param {*} vm 组件实例 + */ + unregisterVM(vm) { + this.vms.splice(this.vms.findIndex(e => e && e.vm === vm), 1) + } + }) + // 冻结处理,需要扩展数据的话,使用crud.updateProp(name, value),以crud.props.name形式访问,这个是响应式的,可以做数据绑定 + Object.freeze(crud) + return crud +} + +// hook VM +function callVmHook(crud, hook) { + if (crud.debug) { + console.log('callVmHook: ' + hook) + } + let ret = true + const nargs = [crud] + for (let i = 2; i < arguments.length; ++i) { + nargs.push(arguments[i]) + } + // 有些组件扮演了多个角色,调用钩子时,需要去重 + const vmSet = new Set() + crud.vms.forEach(vm => vm && vmSet.add(vm.vm)) + vmSet.forEach(vm => { + if (vm[hook]) { + ret = vm[hook].apply(vm, nargs) !== false && ret + } + }) + return ret +} + +function mergeOptions(src, opts) { + const optsRet = { + ...src + } + for (const key in src) { + if (opts.hasOwnProperty(key)) { + optsRet[key] = opts[key] + } + } + return optsRet +} + +/** + * crud主页 + */ +function presenter(crud) { + function obColumns(columns) { + return { + visible(col) { + return !columns || !columns[col] ? true : columns[col].visible + } + } + } + return { + inject: ['crud'], + beforeCreate() { + // 由于initInjections在initProvide之前执行,如果该组件自己就需要crud,需要在initInjections前准备好crud + this._provided = { + crud, + 'crud.query': crud.query, + 'crud.page': crud.page, + 'crud.form': crud.form + } + }, + data() { + return { + searchToggle: true, + columns: obColumns() + } + }, + methods: { + parseTime + }, + created() { + this.crud.registerVM('presenter', this, 0) + if (crud.queryOnPresenterCreated) { + crud.toQuery() + } + }, + beforeDestroy() { + this.crud.unregisterVM(this) + }, + mounted() { + const columns = {} + this.$refs.table.columns.forEach(e => { + if (!e.property || e.type !== 'default') { + return + } + columns[e.property] = { + label: e.label, + visible: true + } + }) + this.columns = obColumns(columns) + this.crud.updateProp('tableColumns', columns) + } + } +} + +/** + * 头部 + */ +function header() { + return { + inject: { + crud: { + from: 'crud' + }, + query: { + from: 'crud.query' + } + }, + created() { + this.crud.registerVM('header', this, 1) + }, + beforeDestroy() { + this.crud.unregisterVM(this) + } + } +} + +/** + * 分页 + */ +function pagination() { + return { + inject: { + crud: { + from: 'crud' + }, + page: { + from: 'crud.page' + } + }, + created() { + this.crud.registerVM('pagination', this, 2) + }, + beforeDestroy() { + this.crud.unregisterVM(this) + } + } +} + +/** + * 表单 + */ +function form(defaultForm) { + return { + inject: { + crud: { + from: 'crud' + }, + form: { + from: 'crud.form' + } + }, + created() { + this.crud.registerVM('form', this, 3) + this.crud.defaultForm = defaultForm + this.crud.resetForm() + }, + beforeDestroy() { + this.crud.unregisterVM(this) + } + } +} + +/** + * crud + */ +function crud(options = {}) { + const defaultOptions = { + type: undefined + } + options = mergeOptions(defaultOptions, options) + return { + inject: { + crud: { + from: 'crud' + } + }, + created() { + this.crud.registerVM(options.type, this) + }, + beforeDestroy() { + this.crud.unregisterVM(this) + } + } +} + +/** + * CRUD钩子 + */ +CRUD.HOOK = { + /** 刷新 - 之前 */ + beforeRefresh: 'beforeCrudRefresh', + /** 刷新 - 之后 */ + afterRefresh: 'afterCrudRefresh', + /** 删除 - 之前 */ + beforeDelete: 'beforeCrudDelete', + /** 删除 - 之后 */ + afterDelete: 'afterCrudDelete', + /** 删除取消 - 之前 */ + beforeDeleteCancel: 'beforeCrudDeleteCancel', + /** 删除取消 - 之后 */ + afterDeleteCancel: 'afterCrudDeleteCancel', + /** 新建 - 之前 */ + beforeToAdd: 'beforeCrudToAdd', + /** 新建 - 之后 */ + afterToAdd: 'afterCrudToAdd', + /** 编辑 - 之前 */ + beforeToEdit: 'beforeCrudToEdit', + /** 编辑 - 之后 */ + afterToEdit: 'afterCrudToEdit', + /** 开始 "新建/编辑" - 之前 */ + beforeToCU: 'beforeCrudToCU', + /** 开始 "新建/编辑" - 之后 */ + afterToCU: 'afterCrudToCU', + /** "新建/编辑" 验证 - 之前 */ + beforeValidateCU: 'beforeCrudValidateCU', + /** "新建/编辑" 验证 - 之后 */ + afterValidateCU: 'afterCrudValidateCU', + /** 添加取消 - 之前 */ + beforeAddCancel: 'beforeCrudAddCancel', + /** 添加取消 - 之后 */ + afterAddCancel: 'afterCrudAddCancel', + /** 编辑取消 - 之前 */ + beforeEditCancel: 'beforeCrudEditCancel', + /** 编辑取消 - 之后 */ + afterEditCancel: 'afterCrudEditCancel', + /** 提交 - 之前 */ + beforeSubmit: 'beforeCrudSubmitCU', + /** 提交 - 之后 */ + afterSubmit: 'afterCrudSubmitCU', + afterAddError: 'afterCrudAddError', + afterEditError: 'afterCrudEditError' +} + +/** + * CRUD状态 + */ +CRUD.STATUS = { + NORMAL: 0, + PREPARED: 1, + PROCESSING: 2 +} + +/** + * CRUD通知类型 + */ +CRUD.NOTIFICATION_TYPE = { + SUCCESS: 'success', + WARNING: 'warning', + INFO: 'info', + ERROR: 'error' +} + +export default CRUD + +export { + presenter, + header, + form, + pagination, + crud +} diff --git a/web/src/components/Dict/Dict.js b/web/src/components/Dict/Dict.js new file mode 100644 index 0000000..8190b31 --- /dev/null +++ b/web/src/components/Dict/Dict.js @@ -0,0 +1,32 @@ +import Vue from 'vue' +import { get as getDictDetail } from '@/api/system/dictDetail' + +export default class Dict { + constructor(dict) { + this.dict = dict + } + + async init(names, completeCallback) { + if (names === undefined || name === null) { + throw new Error('need Dict names') + } + const ps = [] + names.forEach(n => { + Vue.set(this.dict.dict, n, {}) + Vue.set(this.dict.label, n, {}) + Vue.set(this.dict, n, []) + ps.push(getDictDetail(n).then(data => { + this.dict[n].splice(0, 0, ...data.data.content) + data.data.content.forEach(d => { + if (parseInt(d.value).toString() != 'NaN') { + d.value = parseInt(d.value) + } + Vue.set(this.dict.dict[n], d.value, d) + Vue.set(this.dict.label[n], d.value, d.label) + }) + })) + }) + await Promise.all(ps) + completeCallback() + } +} diff --git a/web/src/components/Dict/index.js b/web/src/components/Dict/index.js new file mode 100644 index 0000000..0952f43 --- /dev/null +++ b/web/src/components/Dict/index.js @@ -0,0 +1,29 @@ +import Dict from './Dict' + +const install = function(Vue) { + Vue.mixin({ + data() { + if (this.$options.dicts instanceof Array) { + const dict = { + dict: {}, + label: {} + } + return { + dict + } + } + return {} + }, + created() { + if (this.$options.dicts instanceof Array) { + new Dict(this.dict).init(this.$options.dicts, () => { + this.$nextTick(() => { + this.$emit('dictReady') + }) + }) + } + } + }) +} + +export default { install } diff --git a/web/src/components/Echarts/BarChart.vue b/web/src/components/Echarts/BarChart.vue new file mode 100644 index 0000000..fa265ef --- /dev/null +++ b/web/src/components/Echarts/BarChart.vue @@ -0,0 +1,106 @@ + + + diff --git a/web/src/components/Echarts/Category.vue b/web/src/components/Echarts/Category.vue new file mode 100644 index 0000000..5859114 --- /dev/null +++ b/web/src/components/Echarts/Category.vue @@ -0,0 +1,438 @@ + + + diff --git a/web/src/components/Echarts/Funnel.vue b/web/src/components/Echarts/Funnel.vue new file mode 100644 index 0000000..380b373 --- /dev/null +++ b/web/src/components/Echarts/Funnel.vue @@ -0,0 +1,120 @@ + + + diff --git a/web/src/components/Echarts/Gauge.vue b/web/src/components/Echarts/Gauge.vue new file mode 100644 index 0000000..40ce775 --- /dev/null +++ b/web/src/components/Echarts/Gauge.vue @@ -0,0 +1,74 @@ + + + diff --git a/web/src/components/Echarts/Graph.vue b/web/src/components/Echarts/Graph.vue new file mode 100644 index 0000000..a5a88b3 --- /dev/null +++ b/web/src/components/Echarts/Graph.vue @@ -0,0 +1,101 @@ + + + diff --git a/web/src/components/Echarts/HeatMap.vue b/web/src/components/Echarts/HeatMap.vue new file mode 100644 index 0000000..6606278 --- /dev/null +++ b/web/src/components/Echarts/HeatMap.vue @@ -0,0 +1,105 @@ + + + diff --git a/web/src/components/Echarts/Line3D.vue b/web/src/components/Echarts/Line3D.vue new file mode 100644 index 0000000..c3f16f6 --- /dev/null +++ b/web/src/components/Echarts/Line3D.vue @@ -0,0 +1,96 @@ + + + diff --git a/web/src/components/Echarts/PieChart.vue b/web/src/components/Echarts/PieChart.vue new file mode 100644 index 0000000..ff1bc52 --- /dev/null +++ b/web/src/components/Echarts/PieChart.vue @@ -0,0 +1,84 @@ + + + diff --git a/web/src/components/Echarts/Point.vue b/web/src/components/Echarts/Point.vue new file mode 100644 index 0000000..5a6c777 --- /dev/null +++ b/web/src/components/Echarts/Point.vue @@ -0,0 +1,149 @@ + + + diff --git a/web/src/components/Echarts/RadarChart.vue b/web/src/components/Echarts/RadarChart.vue new file mode 100644 index 0000000..de70e52 --- /dev/null +++ b/web/src/components/Echarts/RadarChart.vue @@ -0,0 +1,120 @@ + + + diff --git a/web/src/components/Echarts/Rich.vue b/web/src/components/Echarts/Rich.vue new file mode 100644 index 0000000..1cf6bf2 --- /dev/null +++ b/web/src/components/Echarts/Rich.vue @@ -0,0 +1,149 @@ + + + diff --git a/web/src/components/Echarts/Sankey.vue b/web/src/components/Echarts/Sankey.vue new file mode 100644 index 0000000..49968c4 --- /dev/null +++ b/web/src/components/Echarts/Sankey.vue @@ -0,0 +1,100 @@ + + + diff --git a/web/src/components/Echarts/Scatter.vue b/web/src/components/Echarts/Scatter.vue new file mode 100644 index 0000000..b776efb --- /dev/null +++ b/web/src/components/Echarts/Scatter.vue @@ -0,0 +1,143 @@ + + + diff --git a/web/src/components/Echarts/Sunburst.vue b/web/src/components/Echarts/Sunburst.vue new file mode 100644 index 0000000..fafc1a8 --- /dev/null +++ b/web/src/components/Echarts/Sunburst.vue @@ -0,0 +1,107 @@ + + + diff --git a/web/src/components/Echarts/ThemeRiver.vue b/web/src/components/Echarts/ThemeRiver.vue new file mode 100644 index 0000000..967fc05 --- /dev/null +++ b/web/src/components/Echarts/ThemeRiver.vue @@ -0,0 +1,148 @@ + + + diff --git a/web/src/components/Echarts/WordCloud.vue b/web/src/components/Echarts/WordCloud.vue new file mode 100644 index 0000000..415f2a8 --- /dev/null +++ b/web/src/components/Echarts/WordCloud.vue @@ -0,0 +1,192 @@ + + + diff --git a/web/src/components/Github/index.vue b/web/src/components/Github/index.vue new file mode 100644 index 0000000..2e1ad59 --- /dev/null +++ b/web/src/components/Github/index.vue @@ -0,0 +1,16 @@ + + + diff --git a/web/src/components/Hamburger/index.vue b/web/src/components/Hamburger/index.vue new file mode 100644 index 0000000..368b002 --- /dev/null +++ b/web/src/components/Hamburger/index.vue @@ -0,0 +1,44 @@ + + + + + diff --git a/web/src/components/HeaderSearch/index.vue b/web/src/components/HeaderSearch/index.vue new file mode 100644 index 0000000..be9b177 --- /dev/null +++ b/web/src/components/HeaderSearch/index.vue @@ -0,0 +1,180 @@ + + + + + diff --git a/web/src/components/IconSelect/index.vue b/web/src/components/IconSelect/index.vue new file mode 100644 index 0000000..0611dc5 --- /dev/null +++ b/web/src/components/IconSelect/index.vue @@ -0,0 +1,69 @@ + + + + + + diff --git a/web/src/components/IconSelect/requireIcons.js b/web/src/components/IconSelect/requireIcons.js new file mode 100644 index 0000000..99e5c54 --- /dev/null +++ b/web/src/components/IconSelect/requireIcons.js @@ -0,0 +1,11 @@ + +const req = require.context('../../assets/icons/svg', false, /\.svg$/) +const requireAll = requireContext => requireContext.keys() + +const re = /\.\/(.*)\.svg/ + +const icons = requireAll(req).map(i => { + return i.match(re)[1] +}) + +export default icons diff --git a/web/src/components/Iframe/index.vue b/web/src/components/Iframe/index.vue new file mode 100644 index 0000000..9f395a3 --- /dev/null +++ b/web/src/components/Iframe/index.vue @@ -0,0 +1,30 @@ +