no message

This commit is contained in:
小陌 2024-01-31 15:17:45 +08:00
parent 7d184bf50c
commit 422e1e976f
26 changed files with 796 additions and 569 deletions

2
dist/index.html vendored
View File

@ -1,4 +1,4 @@
<!doctype html><html lang="en"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible"/><meta content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=0" name="viewport"/><link rel="icon" href="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/favicon.ico"><title>X-PHP</title><script>document.write("<script src='config.js'><\/script>");</script><script defer="defer" src="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/js/echarts.49558cc4.js"></script><script defer="defer" src="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/js/elicons.4bccae06.js"></script><script defer="defer" src="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/js/modules.af2834df.js"></script><script defer="defer" src="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/js/app.3e711122.js"></script><link href="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/css/modules.34563575.css" rel="stylesheet"><link href="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/css/app.4add4dbd.css" rel="stylesheet"></head><body><noscript><strong>We're sorry but X-PHP doesn't work properly without JavaScript enabled.</strong></noscript><div id="app" class="adminui"><div class="app-loading"><div class="app-loading__logo"><img src="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/logo.png"/></div><div class="app-loading-text"><span class="app-loading-preloader">X</span> <span class="app-loading-preloader">-</span> <span class="app-loading-preloader">A</span> <span class="app-loading-preloader">d</span> <span class="app-loading-preloader">m</span> <span class="app-loading-preloader">i</span> <span class="app-loading-preloader">n</span><div class="app-loading-viewtext-container"><span class="app-loading-viewtext">X</span> <span class="app-loading-viewtext">-</span> <span class="app-loading-viewtext">A</span> <span class="app-loading-viewtext">d</span> <span class="app-loading-viewtext">m</span> <span class="app-loading-viewtext">i</span> <span class="app-loading-viewtext">n</span></div></div></div></div></body><div id="versionCheck" class="versionCheck"><h2>当前浏览器内核版本过低</h2><p>当前版本:<span id="versionCheck-type">--</span> <span id="versionCheck-version">--</span></p><p>最低版本要求Chrome 71+、Firefox 65+、Safari 12+、Edge 97+。</p><p>请升级浏览器版本,或更换现代浏览器,如果你使用的是双核浏览器,请切换到极速/高速模式。</p></div><style>html,
<!doctype html><html lang="en"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible"/><meta content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=0" name="viewport"/><link rel="icon" href="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/favicon.ico"><title>X-PHP</title><script>document.write("<script src='config.js'><\/script>");</script><script defer="defer" src="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/js/echarts.49558cc4.js"></script><script defer="defer" src="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/js/elicons.4bccae06.js"></script><script defer="defer" src="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/js/modules.af2834df.js"></script><script defer="defer" src="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/js/app.8e1f9a56.js"></script><link href="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/css/modules.34563575.css" rel="stylesheet"><link href="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/static/css/app.717335f6.css" rel="stylesheet"></head><body><noscript><strong>We're sorry but X-PHP doesn't work properly without JavaScript enabled.</strong></noscript><div id="app" class="adminui"><div class="app-loading"><div class="app-loading__logo"><img src="https://ansnid.oss-cn-shenzhen.aliyuncs.com/x-Admin/logo.png"/></div><div class="app-loading-text"><span class="app-loading-preloader">X</span> <span class="app-loading-preloader">-</span> <span class="app-loading-preloader">A</span> <span class="app-loading-preloader">d</span> <span class="app-loading-preloader">m</span> <span class="app-loading-preloader">i</span> <span class="app-loading-preloader">n</span><div class="app-loading-viewtext-container"><span class="app-loading-viewtext">X</span> <span class="app-loading-viewtext">-</span> <span class="app-loading-viewtext">A</span> <span class="app-loading-viewtext">d</span> <span class="app-loading-viewtext">m</span> <span class="app-loading-viewtext">i</span> <span class="app-loading-viewtext">n</span></div></div></div></div></body><div id="versionCheck" class="versionCheck"><h2>当前浏览器内核版本过低</h2><p>当前版本:<span id="versionCheck-type">--</span> <span id="versionCheck-version">--</span></p><p>最低版本要求Chrome 71+、Firefox 65+、Safari 12+、Edge 97+。</p><p>请升级浏览器版本,或更换现代浏览器,如果你使用的是双核浏览器,请切换到极速/高速模式。</p></div><style>html,
body,
#app {
transition-property: filter;

4
dist/report.html vendored

File diff suppressed because one or more lines are too long

View File

@ -1 +0,0 @@
.x[data-v-26f35ebe]{display:table;position:fixed;left:0;top:0;width:100%;height:100%}.x .y[data-v-26f35ebe]{display:table-cell;vertical-align:middle}.router-err[data-v-26f35ebe]{display:flex;width:900px;margin:50px auto;align-items:center}.router-err__icon[data-v-26f35ebe]{width:400px}.router-err__icon img[data-v-26f35ebe]{width:100%}.router-err__content[data-v-26f35ebe]{flex:1;padding:40px}.router-err__content h2[data-v-26f35ebe]{font-size:26px}.router-err__content p[data-v-26f35ebe]{font-size:14px;color:#999;margin:15px 0 30px 0;line-height:1.5}@media (max-width:992px){.router-err[data-v-26f35ebe]{display:block;width:100%;margin-top:10px;text-align:center}.router-err__icon[data-v-26f35ebe]{width:280px;margin:0 auto}}

1
dist/static/css/404.b2bdf01a.css vendored Normal file
View File

@ -0,0 +1 @@
.x[data-v-1190603b]{display:table;position:fixed;left:0;top:0;width:100%;height:100%}.x .y[data-v-1190603b]{display:table-cell;vertical-align:middle}.router-err[data-v-1190603b]{display:flex;width:900px;margin:50px auto;align-items:center}.router-err__icon[data-v-1190603b]{width:400px}.router-err__icon img[data-v-1190603b]{width:100%}.router-err__content[data-v-1190603b]{flex:1;padding:40px}.router-err__content h2[data-v-1190603b]{font-size:26px}.router-err__content p[data-v-1190603b]{font-size:14px;color:#999;margin:15px 0 30px 0;line-height:1.5}@media (max-width:992px){.router-err[data-v-1190603b]{display:block;width:100%;margin-top:10px;text-align:center}.router-err__icon[data-v-1190603b]{width:280px;margin:0 auto}}

1
dist/static/css/576.34ca934a.css vendored Normal file
View File

@ -0,0 +1 @@
.x-user-select[data-v-2212f4bf]{display:flex}.x-user-select__left[data-v-2212f4bf]{width:400px}.x-user-select__right[data-v-2212f4bf]{flex:1}.x-user-select__search[data-v-2212f4bf]{padding-bottom:10px}.x-user-select__select[data-v-2212f4bf]{display:flex;border:1px solid var(--el-border-color-light);background:var(--el-color-white)}.x-user-select__tree[data-v-2212f4bf]{width:200px;height:300px;border-right:1px solid var(--el-border-color-light)}.x-user-select__user[data-v-2212f4bf]{width:200px;height:300px;display:flex;flex-direction:column}.x-user-select__user__list[data-v-2212f4bf]{flex:1;overflow:auto}.x-user-select__user footer[data-v-2212f4bf]{height:36px;padding-top:5px;border-top:1px solid var(--el-border-color-light)}.x-user-select__toicon[data-v-2212f4bf]{display:flex;justify-content:center;align-items:center;margin:0 10px}.x-user-select__toicon i[data-v-2212f4bf]{display:flex;justify-content:center;align-items:center;background:#ccc;width:20px;height:20px;text-align:center;line-height:20px;border-radius:50%;color:#fff}.x-user-select__selected[data-v-2212f4bf]{height:345px;width:200px;border:1px solid var(--el-border-color-light);background:var(--el-color-white)}.x-user-select__selected header[data-v-2212f4bf]{height:43px;line-height:43px;border-bottom:1px solid var(--el-border-color-light);padding:0 15px;font-size:12px}.x-user-select__selected ul[data-v-2212f4bf]{height:300px;overflow:auto}.x-user-select__selected li[data-v-2212f4bf]{display:flex;align-items:center;justify-content:space-between;padding:5px 5px 5px 15px;height:38px}.x-user-select__selected li .name[data-v-2212f4bf]{display:flex;align-items:center}.x-user-select__selected li .name .el-avatar[data-v-2212f4bf]{background:#409eff;margin-right:6px}.x-user-select__selected li .delete[data-v-2212f4bf]{display:none}.x-user-select__selected li[data-v-2212f4bf]:hover{background:var(--el-color-primary-light-9)}.x-user-select__selected li:hover .delete[data-v-2212f4bf]{display:inline-block}.x-user-select-role .x-user-select__left[data-v-2212f4bf]{width:200px}.x-user-select-role .x-user-select__tree[data-v-2212f4bf]{border:none;height:345px}[data-theme=dark] .x-user-select__selected li[data-v-2212f4bf]:hover{background:rgba(0,0,0,.2)}[data-theme=dark] .x-user-select__toicon i[data-v-2212f4bf]{background:#383838}

View File

@ -1 +1 @@
.mobile-nav-button[data-v-80b8c2f0]{position:fixed;bottom:10px;left:10px;z-index:10;width:50px;height:50px;background:#409eff;box-shadow:0 2px 12px 0 #409eff;border-radius:50%;display:flex;align-items:center;justify-content:center;cursor:pointer}.mobile-nav-button i[data-v-80b8c2f0]{color:#fff;font-size:20px}.mobile-nav[data-v-80b8c2f0]{background:#212d3d}.mobile-nav .el-header[data-v-80b8c2f0]{background:transparent;border:0}.mobile-nav .el-main[data-v-80b8c2f0]{padding:0}.mobile-nav .logo-bar[data-v-80b8c2f0]{display:flex;align-items:center;font-weight:700;font-size:20px;color:#fff}.mobile-nav .logo-bar img[data-v-80b8c2f0]{width:30px;margin-right:10px}.mobile-nav .el-submenu__title[data-v-80b8c2f0]:hover{background:#fff!important}.el-breadcrumb[data-v-29cbd22a]{margin-left:15px}.el-breadcrumb .el-breadcrumb__inner .icon[data-v-29cbd22a]{font-size:14px;margin-right:5px;float:left}.breadcrumb-enter-active[data-v-29cbd22a],.breadcrumb-leave-active[data-v-29cbd22a]{transition:all .3s}.breadcrumb-enter-from[data-v-29cbd22a],.breadcrumb-leave-active[data-v-29cbd22a]{opacity:0;transform:translateX(20px)}.breadcrumb-leave-active[data-v-29cbd22a]{position:absolute}@media (max-width:860px){.el-breadcrumb span[data-v-29cbd22a]:not(:last-child){display:none}}.contextmenu{position:fixed;width:200px;margin:0;border-radius:0;background:var(--el-bg-color-overlay);border:1px solid var(--el-border-color-light);box-shadow:0 2px 12px 0 rgba(0,0,0,.1);z-index:3000;list-style-type:none;padding:10px 0}.contextmenu hr{margin:5px 0;border:none;height:1px;font-size:0;background-color:var(--el-border-color-light)}.contextmenu li{display:flex;align-items:center;margin:0;cursor:pointer;line-height:30px;padding:0 17px;color:#606266}.contextmenu li i{font-size:14px;margin-right:10px}.contextmenu li:hover{background-color:#ecf5ff;color:#66b1ff}.contextmenu li.disabled{cursor:not-allowed;color:#bbb;background:transparent}.tags-tip{padding:5px}.tags-tip p{margin-bottom:10px}.dark .contextmenu li{color:var(--el-text-color-primary)}.el-tag.is-closable[data-v-70e69558]{padding-right:5px;margin-right:5px}.x-search-no-result[data-v-70e69558]{text-align:center;margin:40px 0;color:#999}.x-search-history[data-v-70e69558]{margin-top:10px}.x-search-history .el-tag[data-v-70e69558]{cursor:pointer}.x-search-result[data-v-70e69558]{margin-top:15px}.x-search-result li[data-v-70e69558]{height:56px;padding:0 15px;background:var(--el-bg-color-overlay);border:1px solid var(--el-border-color-light);list-style:none;border-radius:4px;margin-bottom:5px;font-size:14px;display:flex;align-items:center;cursor:pointer}.x-search-result li i[data-v-70e69558]{font-size:20px;margin-right:15px}.x-search-result li[data-v-70e69558]:hover{background:var(--el-color-primary);color:#fff;border-color:var(--el-color-primary)}.user-bar-tasks-item[data-v-3102f840]{margin-bottom:10px}.user-bar-tasks-item[data-v-3102f840]:hover{border-color:var(--el-color-primary)}.user-bar-tasks-item-body[data-v-3102f840]{display:flex}.user-bar-tasks-item-body .taskIcon[data-v-3102f840]{width:45px;height:45px;background:var(--el-color-primary-light-9);margin-right:20px;display:flex;justify-content:center;align-items:center;color:var(--el-color-primary);border-radius:20px}.user-bar-tasks-item-body .taskMain[data-v-3102f840]{flex:1}.user-bar-tasks-item-body .title h2[data-v-3102f840]{font-size:15px}.user-bar-tasks-item-body .title p[data-v-3102f840]{font-size:12px;color:#999;margin-top:5px}.user-bar-tasks-item-body .bottom[data-v-3102f840]{display:flex;justify-content:space-between;align-items:center;padding-top:20px}.user-bar .panel-item[data-v-6eaf3eed],.user-bar[data-v-6eaf3eed]{display:flex;align-items:center;height:100%}.user-bar .panel-item[data-v-6eaf3eed]{padding:0 10px;cursor:pointer}.user-bar .panel-item i[data-v-6eaf3eed]{font-size:16px}.user-bar .panel-item[data-v-6eaf3eed]:hover{background:rgba(0,0,0,.1)}.user-bar .user-avatar[data-v-6eaf3eed]{height:49px;display:flex;align-items:center}.user-bar .user-avatar label[data-v-6eaf3eed]{display:inline-block;margin-left:5px;font-size:12px;cursor:pointer}.msg-list li[data-v-6eaf3eed]{border-top:1px solid #eee}.msg-list li a[data-v-6eaf3eed]{display:flex;padding:20px}.msg-list li a[data-v-6eaf3eed]:hover{background:#ecf5ff}.msg-list__icon[data-v-6eaf3eed]{width:40px;margin-right:15px}.msg-list__main[data-v-6eaf3eed]{flex:1}.msg-list__main h2[data-v-6eaf3eed]{font-size:15px;font-weight:400;color:#333}.msg-list__main p[data-v-6eaf3eed]{font-size:12px;color:#999;line-height:1.8;margin-top:5px}.msg-list__time[data-v-6eaf3eed]{width:100px;text-align:right;color:#999}.dark .msg-list__main h2[data-v-6eaf3eed]{color:#d0d0d0}.dark .msg-list li[data-v-6eaf3eed]{border-top:1px solid #363636}.dark .msg-list li a[data-v-6eaf3eed]:hover{background:#383838}.iframe-pages[data-v-3a9537e6]{width:100%;height:100%;background:#fff}iframe[data-v-3a9537e6]{border:0;width:100%;height:100%;display:block}
.mobile-nav-button[data-v-b0ded7f0]{position:fixed;bottom:10px;left:10px;z-index:10;width:50px;height:50px;background:#409eff;box-shadow:0 2px 12px 0 #409eff;border-radius:50%;display:flex;align-items:center;justify-content:center;cursor:pointer}.mobile-nav-button i[data-v-b0ded7f0]{color:#fff;font-size:20px}.mobile-nav[data-v-b0ded7f0]{background:#212d3d}.mobile-nav .el-header[data-v-b0ded7f0]{background:transparent;border:0}.mobile-nav .el-main[data-v-b0ded7f0]{padding:0}.mobile-nav .logo-bar[data-v-b0ded7f0]{display:flex;align-items:center;font-weight:700;font-size:20px;color:#fff}.mobile-nav .logo-bar img[data-v-b0ded7f0]{width:30px;margin-right:10px}.mobile-nav .el-submenu__title[data-v-b0ded7f0]:hover{background:#fff!important}.el-breadcrumb[data-v-29cbd22a]{margin-left:15px}.el-breadcrumb .el-breadcrumb__inner .icon[data-v-29cbd22a]{font-size:14px;margin-right:5px;float:left}.breadcrumb-enter-active[data-v-29cbd22a],.breadcrumb-leave-active[data-v-29cbd22a]{transition:all .3s}.breadcrumb-enter-from[data-v-29cbd22a],.breadcrumb-leave-active[data-v-29cbd22a]{opacity:0;transform:translateX(20px)}.breadcrumb-leave-active[data-v-29cbd22a]{position:absolute}@media (max-width:860px){.el-breadcrumb span[data-v-29cbd22a]:not(:last-child){display:none}}.contextmenu{position:fixed;width:200px;margin:0;border-radius:0;background:var(--el-bg-color-overlay);border:1px solid var(--el-border-color-light);box-shadow:0 2px 12px 0 rgba(0,0,0,.1);z-index:3000;list-style-type:none;padding:10px 0}.contextmenu hr{margin:5px 0;border:none;height:1px;font-size:0;background-color:var(--el-border-color-light)}.contextmenu li{display:flex;align-items:center;margin:0;cursor:pointer;line-height:30px;padding:0 17px;color:#606266}.contextmenu li i{font-size:14px;margin-right:10px}.contextmenu li:hover{background-color:#ecf5ff;color:#66b1ff}.contextmenu li.disabled{cursor:not-allowed;color:#bbb;background:transparent}.tags-tip{padding:5px}.tags-tip p{margin-bottom:10px}.dark .contextmenu li{color:var(--el-text-color-primary)}.el-tag.is-closable[data-v-70e69558]{padding-right:5px;margin-right:5px}.x-search-no-result[data-v-70e69558]{text-align:center;margin:40px 0;color:#999}.x-search-history[data-v-70e69558]{margin-top:10px}.x-search-history .el-tag[data-v-70e69558]{cursor:pointer}.x-search-result[data-v-70e69558]{margin-top:15px}.x-search-result li[data-v-70e69558]{height:56px;padding:0 15px;background:var(--el-bg-color-overlay);border:1px solid var(--el-border-color-light);list-style:none;border-radius:4px;margin-bottom:5px;font-size:14px;display:flex;align-items:center;cursor:pointer}.x-search-result li i[data-v-70e69558]{font-size:20px;margin-right:15px}.x-search-result li[data-v-70e69558]:hover{background:var(--el-color-primary);color:#fff;border-color:var(--el-color-primary)}.user-bar-tasks-item[data-v-7e8aac0c]{margin-bottom:10px}.user-bar-tasks-item[data-v-7e8aac0c]:hover{border-color:var(--el-color-primary)}.user-bar-tasks-item-body[data-v-7e8aac0c]{display:flex}.user-bar-tasks-item-body .taskIcon[data-v-7e8aac0c]{width:45px;height:45px;background:var(--el-color-primary-light-9);margin-right:20px;display:flex;justify-content:center;align-items:center;color:var(--el-color-primary);border-radius:20px}.user-bar-tasks-item-body .taskMain[data-v-7e8aac0c]{flex:1}.user-bar-tasks-item-body .title h2[data-v-7e8aac0c]{font-size:15px}.user-bar-tasks-item-body .title p[data-v-7e8aac0c]{font-size:12px;color:#999;margin-top:5px}.user-bar-tasks-item-body .bottom[data-v-7e8aac0c]{display:flex;justify-content:space-between;align-items:center;padding-top:20px}.user-bar .panel-item[data-v-c522a238],.user-bar[data-v-c522a238]{display:flex;align-items:center;height:100%}.user-bar .panel-item[data-v-c522a238]{padding:0 10px;cursor:pointer}.user-bar .panel-item i[data-v-c522a238]{font-size:16px}.user-bar .panel-item[data-v-c522a238]:hover{background:rgba(0,0,0,.1)}.user-bar .user-avatar[data-v-c522a238]{height:49px;display:flex;align-items:center}.user-bar .user-avatar label[data-v-c522a238]{display:inline-block;margin-left:5px;font-size:12px;cursor:pointer}.msg-list li[data-v-c522a238]{border-top:1px solid #eee}.msg-list li a[data-v-c522a238]{display:flex;padding:20px}.msg-list li a[data-v-c522a238]:hover{background:#ecf5ff}.msg-list__icon[data-v-c522a238]{width:40px;margin-right:15px}.msg-list__main[data-v-c522a238]{flex:1}.msg-list__main h2[data-v-c522a238]{font-size:15px;font-weight:400;color:#333}.msg-list__main p[data-v-c522a238]{font-size:12px;color:#999;line-height:1.8;margin-top:5px}.msg-list__time[data-v-c522a238]{width:100px;text-align:right;color:#999}.dark .msg-list__main h2[data-v-c522a238]{color:#d0d0d0}.dark .msg-list li[data-v-c522a238]{border-top:1px solid #363636}.dark .msg-list li a[data-v-c522a238]:hover{background:#383838}.iframe-pages[data-v-7ce74040]{width:100%;height:100%;background:#fff}iframe[data-v-7ce74040]{border:0;width:100%;height:100%;display:block}

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
"use strict";(self["webpackChunkx_php_admin"]=self["webpackChunkx_php_admin"]||[]).push([[251],{251:function(e,t,a){a.r(t),a.d(t,{default:function(){return m}});var r=a(6808),l=a(9511);const n={class:"left-panel"},i={class:"right-panel"},s={class:"right-panel-search"};function c(e,t,a,c,o,u){const h=(0,r.up)("el-date-picker"),p=(0,r.up)("el-input"),d=(0,r.up)("el-button"),m=(0,r.up)("el-header"),g=(0,r.up)("el-table-column"),f=(0,r.up)("xTable"),w=(0,r.up)("el-main"),b=(0,r.up)("el-container");return(0,r.wg)(),(0,r.j4)(b,{class:"container"},{default:(0,r.w5)((()=>[(0,r.Wm)(m,null,{default:(0,r.w5)((()=>[(0,r._)("div",n,[(0,r.Wm)(h,{modelValue:o.date,"onUpdate:modelValue":t[0]||(t[0]=e=>o.date=e),type:"datetimerange","range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期"},null,8,["modelValue"])]),(0,r._)("div",i,[(0,r._)("div",s,[(0,r.Wm)(p,{modelValue:o.search.keyword,"onUpdate:modelValue":t[1]||(t[1]=e=>o.search.keyword=e),placeholder:"输入关键词",clearable:""},null,8,["modelValue"]),(0,r.Wm)(d,{type:"primary",icon:"el-icon-search",onClick:u.upsearch},null,8,["onClick"])])])])),_:1}),(0,r.Wm)(w,{class:"nopadding"},{default:(0,r.w5)((()=>[(0,r.Wm)(f,{ref:"table",api:o.api,params:o.search,tableColumn:o.tableColumn,stripe:"",highlightCurrentRow:"",onRowClick:u.rowClick},{default:(0,r.w5)((()=>[(0,r.Wm)(g,{type:"index",width:"60",align:"center"},{default:(0,r.w5)((e=>[(0,r._)("span",null,(0,l.zw)(e.$index+(o.currentPage-1)*o.limit+1),1)])),_:1})])),_:1},8,["api","params","tableColumn","onRowClick"])])),_:1})])),_:1})}var o=a(8764),u=a(1843),h={name:"log",components:{columnItem:o.Z,xMenuItem:u.Z},data(){return{infoDrawer:!1,chartoption:{},typeList:[],date:[],data:[],search:{},api:"",current:"",config:{},tableColumn:{},column:"default",currentPage:1,limit:20}},mounted(){this.getType()},watch:{current(){this.search.type=this.current,this.getCurrent()}},methods:{sideClick(e){this.info=e,this.search.type=e.value,this.current=e.value,this.column=e.column||"column"},changeURLArg(e,t,a){var r=t+"=([^&]*)";if(""===a)return e=e.replace(new RegExp("&?"+r,"gi"),""),e=e.replace(new RegExp("\\??"+r+"&?","gi"),"?"),e;var l=t+"="+a;if(e.match(r)){var n="("+t+"=)([^&]*)";return n=e.replace(new RegExp(n,"gi"),l),n}return e.match("[?]")?e+"&"+l:e+"?"+l},nodeClick(e){if(e.disabled)return!1;this.current=e.label,this.column=e.column||"column"},getType(){this.$http.get("log/admin/types",{type:this.$route.query.type},{cacheparameters:!0}).then((e=>{if(200==e.code){Object.assign(this.$data,e.data);for(const e in this.search)Object.prototype.hasOwnProperty.call(this.$route.query,e)&&(this.search[e]=this.$route.query[e])}}))},getCurrent(){this.tableColumn=this.config[this.column]||this.config.default,this.api||(this.api="log/admin/lists"),this.$refs.table.reload(this.search);let e=window.location.href;for(const[t,a]of Object.entries(this.search))e=this.changeURLArg(e,t,a);history.replaceState(Object.assign({},window.history.state,{url:e}),"null",e)},upsearch(){this.getCurrent()},rowClick(e){this.infoDrawer=!0,this.$nextTick((()=>{this.$refs.info.setData(e)}))}}},p=a(8700);const d=(0,p.Z)(h,[["render",c],["__scopeId","data-v-eba8b6d4"]]);var m=d}}]);
"use strict";(self["webpackChunkx_php_admin"]=self["webpackChunkx_php_admin"]||[]).push([[251],{251:function(e,t,a){a.r(t),a.d(t,{default:function(){return m}});var r=a(6808),l=a(9511);const n={class:"left-panel"},i={class:"right-panel"},s={class:"right-panel-search"};function c(e,t,a,c,o,u){const h=(0,r.up)("el-date-picker"),p=(0,r.up)("el-input"),d=(0,r.up)("el-button"),m=(0,r.up)("el-header"),g=(0,r.up)("el-table-column"),f=(0,r.up)("xTable"),w=(0,r.up)("el-main"),b=(0,r.up)("el-container");return(0,r.wg)(),(0,r.j4)(b,{class:"container"},{default:(0,r.w5)((()=>[(0,r.Wm)(m,null,{default:(0,r.w5)((()=>[(0,r._)("div",n,[(0,r.Wm)(h,{modelValue:o.date,"onUpdate:modelValue":t[0]||(t[0]=e=>o.date=e),type:"datetimerange","range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期"},null,8,["modelValue"])]),(0,r._)("div",i,[(0,r._)("div",s,[(0,r.Wm)(p,{modelValue:o.search.keyword,"onUpdate:modelValue":t[1]||(t[1]=e=>o.search.keyword=e),placeholder:"输入关键词",clearable:""},null,8,["modelValue"]),(0,r.Wm)(d,{type:"primary",icon:"el-icon-search",onClick:u.upsearch},null,8,["onClick"])])])])),_:1}),(0,r.Wm)(w,{class:"nopadding"},{default:(0,r.w5)((()=>[(0,r.Wm)(f,{ref:"table",api:o.api,params:o.search,tableColumn:o.tableColumn,stripe:"",highlightCurrentRow:"",onRowClick:u.rowClick},{default:(0,r.w5)((()=>[(0,r.Wm)(g,{type:"index",width:"60",align:"center"},{default:(0,r.w5)((e=>[(0,r._)("span",null,(0,l.zw)(e.$index+(o.currentPage-1)*o.limit+1),1)])),_:1})])),_:1},8,["api","params","tableColumn","onRowClick"])])),_:1})])),_:1})}var o=a(3077),u=a(1843),h={name:"log",components:{columnItem:o.Z,xMenuItem:u.Z},data(){return{infoDrawer:!1,chartoption:{},typeList:[],date:[],data:[],search:{},api:"",current:"",config:{},tableColumn:{},column:"default",currentPage:1,limit:20}},mounted(){this.getType()},watch:{current(){this.search.type=this.current,this.getCurrent()}},methods:{sideClick(e){this.info=e,this.search.type=e.value,this.current=e.value,this.column=e.column||"column"},changeURLArg(e,t,a){var r=t+"=([^&]*)";if(""===a)return e=e.replace(new RegExp("&?"+r,"gi"),""),e=e.replace(new RegExp("\\??"+r+"&?","gi"),"?"),e;var l=t+"="+a;if(e.match(r)){var n="("+t+"=)([^&]*)";return n=e.replace(new RegExp(n,"gi"),l),n}return e.match("[?]")?e+"&"+l:e+"?"+l},nodeClick(e){if(e.disabled)return!1;this.current=e.label,this.column=e.column||"column"},getType(){this.$http.get("log/admin/types",{type:this.$route.query.type},{cacheparameters:!0}).then((e=>{if(200==e.code){Object.assign(this.$data,e.data);for(const e in this.search)Object.prototype.hasOwnProperty.call(this.$route.query,e)&&(this.search[e]=this.$route.query[e])}}))},getCurrent(){this.tableColumn=this.config[this.column]||this.config.default,this.api||(this.api="log/admin/lists"),this.$refs.table.reload(this.search);let e=window.location.href;for(const[t,a]of Object.entries(this.search))e=this.changeURLArg(e,t,a);history.replaceState(Object.assign({},window.history.state,{url:e}),"null",e)},upsearch(){this.getCurrent()},rowClick(e){this.infoDrawer=!0,this.$nextTick((()=>{this.$refs.info.setData(e)}))}}},p=a(8700);const d=(0,p.Z)(h,[["render",c],["__scopeId","data-v-eba8b6d4"]]);var m=d}}]);

View File

@ -1 +0,0 @@
"use strict";(self["webpackChunkx_php_admin"]=self["webpackChunkx_php_admin"]||[]).push([[596],{4399:function(r,o,e){e.r(o),e.d(o,{default:function(){return g}});var n=e(6808),t=e(5747);const i=r=>((0,n.dD)("data-v-26f35ebe"),r=r(),(0,n.Cn)(),r),a={class:"x"},c={class:"y"},s={class:"router-err"},u=i((()=>(0,n._)("div",{class:"router-err__icon"},[(0,n._)("img",{src:t})],-1))),l={class:"router-err__content"},d=i((()=>(0,n._)("h2",null,"无权限或找不到页面",-1))),_=i((()=>(0,n._)("p",null,"当前页面无权限访问或者打开了一个不存在的链接,请检查当前账户权限和链接的可访问性。",-1)));function p(r,o,e,t,i,p){const h=(0,n.up)("el-button");return(0,n.wg)(),(0,n.iD)("div",a,[(0,n._)("div",c,[(0,n._)("div",s,[u,(0,n._)("div",l,[d,_,(0,n.Wm)(h,{type:"primary",plain:"",round:"",onClick:p.gohome},{default:(0,n.w5)((()=>[(0,n.Uk)("返回首页")])),_:1},8,["onClick"]),(0,n.Wm)(h,{type:"primary",round:"",onClick:p.goback},{default:(0,n.w5)((()=>[(0,n.Uk)("返回上一页")])),_:1},8,["onClick"])])])])])}e(8311);var h={methods:{gohome(){location.href="#/"},goback(){this.$router.go(-1)},gologin(){this.$router.push("/login")}}},k=e(8700);const f=(0,k.Z)(h,[["render",p],["__scopeId","data-v-26f35ebe"]]);var g=f}}]);

1
dist/static/js/404.4ccf6fc9.js vendored Normal file
View File

@ -0,0 +1 @@
"use strict";(self["webpackChunkx_php_admin"]=self["webpackChunkx_php_admin"]||[]).push([[596],{6599:function(r,o,n){n.r(o),n.d(o,{default:function(){return m}});var t=n(6808),e=n(5747);const i=r=>((0,t.dD)("data-v-1190603b"),r=r(),(0,t.Cn)(),r),a={class:"x"},c={class:"y"},s={class:"router-err"},u=i((()=>(0,t._)("div",{class:"router-err__icon"},[(0,t._)("img",{src:e})],-1))),l={class:"router-err__content"},d=i((()=>(0,t._)("h2",null,"无权限或找不到页面",-1))),_=i((()=>(0,t._)("p",null,"当前页面无权限访问或者打开了一个不存在的链接,请检查当前账户权限和链接的可访问性。",-1)));function p(r,o,n,e,i,p){const h=(0,t.up)("el-button");return(0,t.wg)(),(0,t.iD)("div",a,[(0,t._)("div",c,[(0,t._)("div",s,[u,(0,t._)("div",l,[d,_,(0,t.Wm)(h,{type:"primary",plain:"",round:"",onClick:p.gohome},{default:(0,t.w5)((()=>[(0,t.Uk)("返回首页")])),_:1},8,["onClick"]),(0,t.Wm)(h,{type:"primary",round:"",onClick:p.goback},{default:(0,t.w5)((()=>[(0,t.Uk)("返回上一页")])),_:1},8,["onClick"])])])])])}n(8311);var h={methods:{gohome(){location.href="#/"},goback(){this.$router.go(-1)},gologin(){this.$router.push("/login")}}},k=n(8700);const g=(0,k.Z)(h,[["render",p],["__scopeId","data-v-1190603b"]]);var m=g}}]);

1
dist/static/js/576.a28f8752.js vendored Normal file

File diff suppressed because one or more lines are too long

1
dist/static/js/645.ec99eacf.js vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

1
dist/static/js/app.8e1f9a56.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -105,12 +105,16 @@
<template v-else-if="item.component == 'avatar'">
<x-avatar :data="data" :options="bind" size="small"></x-avatar>
</template>
<!-- xUserSelect -->
<template v-else-if="item.component == 'xuserselect'">
<x-user-select v-model="data[item.name]" :type="item.type"></x-user-select>
</template>
<template v-else-if="item.component == 'formtable'">
<x-form-table ref="xformtable" v-model="data[item.name]" v-bind="bind"> </x-form-table>
</template>
<template v-else-if="item.component == 'tabs'">
<el-tabs v-model="tabsValue" v-bind="bind" class="formtabs">
<el-tab-pane v-for="(t, index) in options" :key="index" v-bind="t">
<el-tabs v-model="tabsValue" type="border-card" v-bind="bind" class="formtabs">
<el-tab-pane v-for="(t, index) in options" :key="index" :name="t.value" v-bind="t">
<template #label>
<el-badge is-dot v-if="data[item.name][t.value]"> </el-badge>
<span>{{ t.label }}</span>
@ -151,6 +155,7 @@
import { defineAsyncComponent } from 'vue'
const tableselectRender = defineAsyncComponent(() => import('./items/tableselect'))
const xEditor = defineAsyncComponent(() => import('@/components/xEditor'))
const xUserSelect = defineAsyncComponent(() => import('@/components/xUser/select'))
export default {
props: {
@ -164,6 +169,7 @@ export default {
},
components: {
tableselectRender,
xUserSelect,
xEditor
},
computed: {
@ -183,7 +189,7 @@ export default {
computedValue: {
get() {
// 使
const key = this.item && this.item.options && this.item.options.props && this.item.options.props.key;
const key = this.bind && this.bind && this.bind.props && this.bind.props.key;
if (key === null) {
return this.data;
}
@ -191,8 +197,8 @@ export default {
},
set(value) {
// 使
if (this.item && this.item.options && this.item.options.props && this.item.options.props.key) {
this.$emit('update:data', { [this.item.options.props.key]: value });
if (this.bind && this.bind && this.bind.props && this.bind.props.key) {
this.$emit('update:data', { [this.bind.props.key]: value });
} else {
this.$emit('update:data', value);
}

View File

@ -1,9 +1,9 @@
<template>
<div style="display: flex;">
<el-badge v-if="item.status && item.status.key && row[item.status.key]" is-dot class="item" :type="item.status.type || 'primary'" style="width: 10px;cursor: pointer;margin-top: 10px;"></el-badge>
<x-avatar v-if="item.columntype == 'avatar' || item.component == 'avatar'" :name="item.name" :options="item.options" :data="row"></x-avatar>
<el-badge v-else-if="item.columntype == 'badge' || item.columntype == 'imagegroup'" :value="getType(row[item.name])" @click="handleClick(row, item)" v-bind="item.options" style="cursor: pointer; "></el-badge>
<el-link v-else-if="item.columntype == 'link'" v-bind="item.bind || item.options" @click="handleClick(row, item)"> {{ row[item.name] }} </el-link>
<x-avatar v-if="item.columntype == 'avatar' || item.component == 'avatar'" :name="item.name" :options="bind" :data="row"></x-avatar>
<el-badge v-else-if="item.columntype == 'badge' || item.columntype == 'imagegroup'" :value="getType(row[item.name])" @click="handleClick(row, item)" v-bind="bind" style="cursor: pointer; "></el-badge>
<el-link v-else-if="item.columntype == 'link'" v-bind="bind" @click="handleClick(row, item)"> {{ row[item.name] }} </el-link>
<el-image v-else-if="item.columntype == 'image'" :preview-src-list="[getImg(row[item.name])]" :preview-teleported="true" hide-on-click-modal="true" lazy="true" style="max-width: 60px; height: 26px; border-radius: 2px;" fit="cover" :src="getImg(row[item.name])">
<template #error>
<div class="image-slot">
@ -12,28 +12,28 @@
</template>
</el-image>
<input v-else-if="item.columntype == 'input'" @click="handleClick(row, item)" style="cursor: pointer; " class="el-input__inner" type="text" readonly :value="row[item.name]">
<p v-else-if="item.columntype == 'status'">
<p v-else-if="item.columntype == 'status'" :style="item.style">
<template v-for="{ value, type = 'success', label, options={} } in options">
<x-status-indicator :style="item.style" :key="value" pulse :type="type" :label="label" @click="handleClick(row, options || item)" v-if="value == row[item.name]"></x-status-indicator>
<x-status-indicator :key="value" pulse :type="type" :label="label" @click="handleClick(row, options || item)" v-if="value == row[item.name]"></x-status-indicator>
</template>
</p>
<p v-else-if="item.columntype == 'button'">
<span v-if="options && options.length > 0">
<template v-for="(op, index) in options">
<el-button @click="handleClick(row, op.options || item)" :key="index" :type="op.type || 'warning'" :size="op.size || 'small'" v-bind="op" v-if="op.value == row[item.name]">
<el-button @click="handleClick(row, op.options || item)" :key="index" type="warning" size="small" v-bind="op" v-if="op.value == row[item.name]">
{{ op.label }}
</el-button>
</template>
</span>
<el-button v-else @click="handleClick(row, item)" :type="item.type || 'warning'" v-bind="item.bind || item.options"> {{ row[item.name] }} </el-button>
<el-button v-else @click="handleClick(row, item)" type="warning" v-bind="bind"> {{ row[item.name] }} </el-button>
</p>
<p v-else-if="item.columntype == 'text'">
<el-text v-bind="item.bind || item.options" v-if="item.copy" v-copy="row[item.copy]" style="cursor: pointer;display: inline;"> {{ row[item.name] }} </el-text>
<el-text v-bind="item.bind || item.options" v-else @click="handleClick(row, item)" style="cursor: pointer;display: inline;"> {{ row[item.name] }} </el-text>
<el-text v-bind="bind" v-if="item.copy" v-copy="row[item.copy]" style="cursor: pointer;display: inline;"> {{ row[item.name] }} </el-text>
<el-text v-bind="bind" v-else @click="handleClick(row, item)" style="cursor: pointer;display: inline;"> {{ row[item.name] }} </el-text>
</p>
<p v-else-if="item.columntype == 'tag' || item.columntype == 'time'" @click="handleClick(row, item)" v-time.tip="row[item.name]"></p>
<slot v-else :name="item.name">
{{ item.columntype == 'select' && options && options ? getNameByValue(row[item.name], options) : row[item.name] }}
{{ item.columntype == 'select' && options ? getNameByValue(row[item.name], options) : row[item.name] }}
</slot>
</div>
</template>
@ -48,7 +48,7 @@ export default {
props: {
item: {
type: Object, default: () => ({
options: {},
options: [],
bind: {},
})
},
@ -58,8 +58,15 @@ export default {
options() {
return this.item.options.items || (Array.isArray(this.item.options) ? this.item.options : []); //
},
bind() {
const { bind, options } = this.item;
return bind || (this.isPlainObject(options) ? options : {});
},
},
methods: {
isPlainObject(obj) {
return typeof obj === 'object' && obj !== null && !Array.isArray(obj);
},
handleClick(row, item) {
//

View File

@ -3,264 +3,363 @@
-->
<template>
<el-dialog v-model="dialogVisible" :title="titleMap[type-1]" :width="type==1?680:460" destroy-on-close append-to-body @closed="$emit('closed')">
<template v-if="type==1">
<div class="x-user-select">
<div class="x-user-select__left">
<div class="x-user-select__search">
<el-input v-model="keyword" prefix-icon="el-icon-search" placeholder="搜索成员">
<template #append>
<el-button icon="el-icon-search" @click="search"></el-button>
</template>
</el-input>
<template v-if="type == 1">
<div class="x-user-select">
<div class="x-user-select__left">
<div class="x-user-select__search">
<el-input v-model="keyword" prefix-icon="el-icon-search" placeholder="搜索成员">
<template #append>
<el-button icon="el-icon-search" @click="search"></el-button>
</template>
</el-input>
</div>
<div class="x-user-select__select">
<div class="x-user-select__tree" v-loading="showGrouploading">
<el-scrollbar>
<el-tree class="menu" ref="groupTree" :data="group" :node-key="groupProps.key" :props="groupProps" highlight-current :expand-on-click-node="false" :current-node-key="groupid" @node-click="groupClick" />
</el-scrollbar>
</div>
<div class="x-user-select__select">
<div class="x-user-select__tree" v-loading="showGrouploading">
<el-scrollbar>
<el-tree class="menu" ref="groupTree" :data="group" :node-key="groupProps.key" :props="groupProps" highlight-current :expand-on-click-node="false" :current-node-key="groupid" @node-click="groupClick"/>
<div class="x-user-select__user" v-loading="showUserloading">
<div class="x-user-select__user__list">
<el-scrollbar ref="userScrollbar">
<el-tree class="menu" ref="userTree" :data="user" :node-key="userProps.key" :props="userProps" :default-checked-keys="selectedIds" show-checkbox check-on-click-node @check-change="userClick"></el-tree>
</el-scrollbar>
</div>
<div class="x-user-select__user" v-loading="showUserloading">
<div class="x-user-select__user__list">
<el-scrollbar ref="userScrollbar">
<el-tree class="menu" ref="userTree" :data="user" :node-key="userProps.key" :props="userProps" :default-checked-keys="selectedIds" show-checkbox check-on-click-node @check-change="userClick"></el-tree>
</el-scrollbar>
</div>
<footer>
<el-pagination background layout="prev,next" small :total="total" :page-size="limit" v-model:currentPage="currentPage" @current-change="paginationChange"></el-pagination>
</footer>
</div>
<footer>
<el-pagination background layout="prev,next" small :total="total" :page-size="limit" v-model:currentPage="currentPage" @current-change="paginationChange"></el-pagination>
</footer>
</div>
</div>
<div class="x-user-select__toicon"><el-icon><el-icon-arrow-right /></el-icon></div>
<div class="x-user-select__selected">
<header>已选 ({{selected.length}})</header>
<ul>
<el-scrollbar>
<li v-for="(item, index) in selected" :key="item.id">
<span class="name">
<el-avatar size="small">{{item.name.substring(0,1)}}</el-avatar>
<label>{{item.name}}</label>
</span>
<span class="delete">
<el-button type="danger" icon="el-icon-delete" circle size="small" @click="deleteSelected(index)"></el-button>
</span>
</li>
</el-scrollbar>
</ul>
</div>
</div>
</template>
<div class="x-user-select__toicon"><el-icon><el-icon-arrow-right /></el-icon></div>
<div class="x-user-select__selected">
<header>已选 ({{ selected.length }})</header>
<ul>
<el-scrollbar>
<li v-for="(item, index) in selected" :key="item.id">
<span class="name">
<el-avatar size="small">{{ item.name.substring(0, 1) }}</el-avatar>
<label>{{ item.name }}</label>
</span>
<span class="delete">
<el-button type="danger" icon="el-icon-delete" circle size="small" @click="deleteSelected(index)"></el-button>
</span>
</li>
</el-scrollbar>
</ul>
</div>
</div>
</template>
<template v-if="type==2">
<div class="x-user-select x-user-select-role">
<div class="x-user-select__left">
<div class="x-user-select__select">
<div class="x-user-select__tree" v-loading="showGrouploading">
<el-scrollbar>
<el-tree class="menu" ref="groupTree" :data="role" :node-key="roleProps.key" :props="roleProps" show-checkbox check-strictly check-on-click-node :expand-on-click-node="false" :default-checked-keys="selectedIds" @check-change="roleClick"/>
</el-scrollbar>
</div>
<template v-if="type == 2">
<div class="x-user-select x-user-select-role">
<div class="x-user-select__left">
<div class="x-user-select__select">
<div class="x-user-select__tree" v-loading="showGrouploading">
<el-scrollbar>
<el-tree class="menu" ref="groupTree" :data="role" :node-key="roleProps.key" :props="roleProps" show-checkbox check-strictly check-on-click-node :expand-on-click-node="false" :default-checked-keys="selectedIds" @check-change="roleClick" />
</el-scrollbar>
</div>
</div>
<div class="x-user-select__toicon"><el-icon><el-icon-arrow-right /></el-icon></div>
<div class="x-user-select__selected">
<header>已选 ({{selected.length}})</header>
<ul>
<el-scrollbar>
<li v-for="(item, index) in selected" :key="item.id">
<span class="name">
<label>{{item.name}}</label>
</span>
<span class="delete">
<el-button type="danger" icon="el-icon-delete" circle size="small" @click="deleteSelected(index)"></el-button>
</span>
</li>
</el-scrollbar>
</ul>
</div>
</div>
</template>
<template #footer>
<el-button @click="dialogVisible = false"> </el-button>
<el-button type="primary" @click="save"> </el-button>
</template>
</el-dialog>
<div class="x-user-select__toicon"><el-icon><el-icon-arrow-right /></el-icon></div>
<div class="x-user-select__selected">
<header>已选 ({{ selected.length }})</header>
<ul>
<el-scrollbar>
<li v-for="(item, index) in selected" :key="item.id">
<span class="name">
<label>{{ item.name }}</label>
</span>
<span class="delete">
<el-button type="danger" icon="el-icon-delete" circle size="small" @click="deleteSelected(index)"></el-button>
</span>
</li>
</el-scrollbar>
</ul>
</div>
</div>
</template>
</template>
<script>
import config from "@/config/workflow";
export default {
props: {
modelValue: { type: Boolean, default: false }
import config from "@/config/workflow";
export default {
name: 'xUserSelect',
data() {
return {
groupProps: config.group.props,
userProps: config.user.props,
roleProps: config.role.props,
showGrouploading: false,
showUserloading: false,
keyword: '',
groupid: '',
limit: config.user.limit,
total: 0,
currentPage: 1,
group: [],
user: [],
role: [],
selected: [],
}
},
props: {
modelValue: { type: Array, default: () => [] },
type: { type: [String, Number], default: 1 },
},
watch: {
// selected
selectedIds(newVal) {
this.$emit('update:modelValue', newVal);
},
data() {
return {
groupProps: config.group.props,
userProps: config.user.props,
roleProps: config.role.props,
titleMap: ['人员选择', '角色选择'],
dialogVisible: false,
showGrouploading: false,
showUserloading: false,
keyword: '',
groupid: '',
limit: config.user.limit,
total: 0,
currentPage: 1,
group: [],
user: [],
role: [],
type: 1,
selected: [],
value: []
},
computed: {
selectedIds() {
return this.selected.map(t => t.id)
}
},
mounted() {
this.value = this.modelValue;
this.open()
},
methods: {
//
open() {
if (this.type == 1) {
this.getGroup()
this.getUser()
} else if (this.type == 2) {
this.getRole()
}
},
computed: {
selectedIds(){
return this.selected.map(t => t.id)
}
//
async getGroup() {
this.showGrouploading = true;
var res = await this.$http.get('user/group/roleList');
this.showGrouploading = false;
var allNode = { [config.group.props.key]: '', [config.group.props.label]: '所有' }
res.data.unshift(allNode);
this.group = config.group.parseData(res).rows
},
mounted() {
//
async getUser() {
this.showUserloading = true;
var params = {
[config.user.request.keyword]: this.keyword || null,
[config.user.request.groupid]: this.groupid || null,
[config.user.request.page]: this.currentPage,
[config.user.request.limit]: this.limit
}
var res = await this.$http.get('user/index/lists', params);
this.showUserloading = false;
this.user = config.user.parseData(res).rows;
this.total = config.user.parseData(res).total || 0;
this.$refs.userScrollbar.setScrollTop(0)
},
//
async getRole() {
this.showGrouploading = true;
var res = await this.$http.get('user/group/roleList', { type: 'system' });
this.showGrouploading = false;
this.role = res.data
// 使filterID
this.selected = this.role.filter(item => this.modelValue.includes(item.id)).map(item => ({
id: item[config.role.props.key],
name: item[config.role.props.label]
}));
},
methods: {
//
open(type, data){
this.type = type
this.value = data||[]
this.selected = JSON.parse(JSON.stringify(data||[]))
this.dialogVisible = true
if(this.type==1){
this.getGroup()
this.getUser()
}else if(this.type==2){
this.getRole()
}
},
//
async getGroup(){
this.showGrouploading = true;
var res = await this.$http.get('user/group/lists');
this.showGrouploading = false;
var allNode = {[config.group.props.key]: '', [config.group.props.label]: '所有'}
res.data.unshift(allNode);
this.group = config.group.parseData(res).rows
},
//
async getUser(){
this.showUserloading = true;
var params = {
[config.user.request.keyword]: this.keyword || null,
[config.user.request.groupid]: this.groupid || null,
[config.user.request.page]: this.currentPage,
[config.user.request.limit]: this.limit
}
var res = await this.$http.get('user/index/lists', params);
this.showUserloading = false;
this.user = config.user.parseData(res).rows;
this.total = config.user.parseData(res).total || 0;
this.$refs.userScrollbar.setScrollTop(0)
},
//
async getRole(){
this.showGrouploading = true;
var res = await this.$http.get('user/group/lists');
this.showGrouploading = false;
this.role = config.role.parseData(res).rows
},
//
groupClick(data){
this.keyword = ''
this.currentPage = 1
this.groupid = data[config.group.props.key]
this.getUser()
},
//
userClick(data, checked){
if(checked){
this.selected.push({
id: data[config.user.props.key],
name: data[config.user.props.label]
})
}else{
this.selected = this.selected.filter(item => item.id != data[config.user.props.key])
}
},
//
paginationChange(){
this.getUser()
},
//
search(){
this.groupid = ''
this.$refs.groupTree.setCurrentKey(this.groupid)
this.currentPage = 1
this.getUser()
},
//
deleteSelected(index){
this.selected.splice(index,1);
if(this.type==1){
this.$refs.userTree.setCheckedKeys(this.selectedIds)
}else if(this.type==2){
this.$refs.groupTree.setCheckedKeys(this.selectedIds)
}
},
//
roleClick(data, checked){
if(checked){
this.selected.push({
id: data[config.role.props.key],
name: data[config.role.props.label]
})
}else{
this.selected = this.selected.filter(item => item.id != data[config.role.props.key])
}
},
//
save(){
this.value.splice(0,this.value.length);
this.selected.map(item => {
this.value.push(item)
//
groupClick(data) {
this.keyword = ''
this.currentPage = 1
this.groupid = data[config.group.props.key]
this.getUser()
},
//
userClick(data, checked) {
if (checked) {
this.selected.push({
id: data[config.user.props.key],
name: data[config.user.props.label]
})
this.dialogVisible = false
} else {
this.selected = this.selected.filter(item => item.id != data[config.user.props.key])
}
}
},
//
paginationChange() {
this.getUser()
},
//
search() {
this.groupid = ''
this.$refs.groupTree.setCurrentKey(this.groupid)
this.currentPage = 1
this.getUser()
},
//
deleteSelected(index) {
this.selected.splice(index, 1);
if (this.type == 1) {
this.$refs.userTree.setCheckedKeys(this.selectedIds)
} else if (this.type == 2) {
this.$refs.groupTree.setCheckedKeys(this.selectedIds)
}
},
//
roleClick(data, checked) {
if (checked) {
this.selected.push({
id: data[config.role.props.key],
name: data[config.role.props.label]
})
} else {
this.selected = this.selected.filter(item => item.id != data[config.role.props.key])
}
},
}
}
</script>
<style scoped>
.x-user-select {display: flex;}
.x-user-select__left {width: 400px;}
.x-user-select__right {flex: 1;}
.x-user-select {
display: flex;
}
.x-user-select__search {padding-bottom:10px;}
.x-user-select__left {
width: 400px;
}
.x-user-select__select {display: flex;border: 1px solid var(--el-border-color-light);background: var(--el-color-white);}
.x-user-select__tree {width: 200px;height:300px;border-right: 1px solid var(--el-border-color-light);}
.x-user-select__user {width: 200px;height:300px;display: flex;flex-direction: column;}
.x-user-select__user__list {flex: 1;overflow: auto;}
.x-user-select__user footer {height:36px;padding-top:5px;border-top: 1px solid var(--el-border-color-light);}
.x-user-select__right {
flex: 1;
}
.x-user-select__toicon {display: flex;justify-content: center;align-items: center;margin:0 10px;}
.x-user-select__toicon i {display: flex;justify-content: center;align-items: center;background: #ccc;width: 20px;height: 20px;text-align: center;line-height: 20px;border-radius:50%;color: #fff;}
.x-user-select__search {
padding-bottom: 10px;
}
.x-user-select__selected {height:345px;width: 200px;border: 1px solid var(--el-border-color-light);background: var(--el-color-white);}
.x-user-select__selected header {height:43px;line-height: 43px;border-bottom: 1px solid var(--el-border-color-light);padding:0 15px;font-size: 12px;}
.x-user-select__selected ul {height:300px;overflow: auto;}
.x-user-select__selected li {display: flex;align-items: center;justify-content: space-between;padding:5px 5px 5px 15px;height:38px;}
.x-user-select__selected li .name {display: flex;align-items: center;}
.x-user-select__selected li .name .el-avatar {background: #409eff;margin-right: 10px;}
.x-user-select__selected li .name label {}
.x-user-select__selected li .delete {display: none;}
.x-user-select__selected li:hover {background: var(--el-color-primary-light-9);}
.x-user-select__selected li:hover .delete {display: inline-block;}
.x-user-select__select {
display: flex;
border: 1px solid var(--el-border-color-light);
background: var(--el-color-white);
}
.x-user-select-role .x-user-select__left {width: 200px;}
.x-user-select-role .x-user-select__tree {border: none;height: 343px;}
.x-user-select-role .x-user-select__selected {}
.x-user-select__tree {
width: 200px;
height: 300px;
border-right: 1px solid var(--el-border-color-light);
}
[data-theme='dark'] .x-user-select__selected li:hover {background: rgba(0, 0, 0, 0.2);}
[data-theme='dark'] .x-user-select__toicon i {background: #383838;}
.x-user-select__user {
width: 200px;
height: 300px;
display: flex;
flex-direction: column;
}
.x-user-select__user__list {
flex: 1;
overflow: auto;
}
.x-user-select__user footer {
height: 36px;
padding-top: 5px;
border-top: 1px solid var(--el-border-color-light);
}
.x-user-select__toicon {
display: flex;
justify-content: center;
align-items: center;
margin: 0 10px;
}
.x-user-select__toicon i {
display: flex;
justify-content: center;
align-items: center;
background: #ccc;
width: 20px;
height: 20px;
text-align: center;
line-height: 20px;
border-radius: 50%;
color: #fff;
}
.x-user-select__selected {
height: 345px;
width: 200px;
border: 1px solid var(--el-border-color-light);
background: var(--el-color-white);
}
.x-user-select__selected header {
height: 43px;
line-height: 43px;
border-bottom: 1px solid var(--el-border-color-light);
padding: 0 15px;
font-size: 12px;
}
.x-user-select__selected ul {
height: 300px;
overflow: auto;
}
.x-user-select__selected li {
display: flex;
align-items: center;
justify-content: space-between;
padding: 5px 5px 5px 15px;
height: 38px;
}
.x-user-select__selected li .name {
display: flex;
align-items: center;
}
.x-user-select__selected li .name .el-avatar {
background: #409eff;
margin-right: 6px;
}
.x-user-select__selected li .name label {}
.x-user-select__selected li .delete {
display: none;
}
.x-user-select__selected li:hover {
background: var(--el-color-primary-light-9);
}
.x-user-select__selected li:hover .delete {
display: inline-block;
}
.x-user-select-role .x-user-select__left {
width: 200px;
}
.x-user-select-role .x-user-select__tree {
border: none;
height: 345px;
}
.x-user-select-role .x-user-select__selected {}
[data-theme='dark'] .x-user-select__selected li:hover {
background: rgba(0, 0, 0, 0.2);
}
[data-theme='dark'] .x-user-select__toicon i {
background: #383838;
}
</style>

View File

@ -20,7 +20,7 @@ export default {
//显示数据字段映射
props: {
key: 'id',
label: 'name',
label: 'title',
children: 'children'
}
},

View File

@ -1,21 +1,25 @@
<template>
<div v-if="navMenus.length<=0" style="padding:20px;">
<div v-if="navMenus.length <= 0" style="padding:20px;">
<el-alert title="无子集菜单" center type="info" :closable="false"></el-alert>
</div>
<template v-for="navMenu in navMenus" v-bind:key="navMenu">
<el-menu-item v-if="!hasChildren(navMenu)" :index="navMenu.path">
<a v-if="navMenu.meta&&navMenu.meta.type=='link'" :href="navMenu.path" target="_blank" @click.stop='()=>{}'></a>
<el-icon v-if="navMenu.meta&&navMenu.meta.icon"><component :is="navMenu.meta.icon || 'el-icon-menu'"/></el-icon>
<a v-if="navMenu.meta && navMenu.meta.type == 'link'" :href="navMenu.path" target="_blank" @click.stop='() => { }'></a>
<el-icon v-if="navMenu.meta && navMenu.meta.icon">
<component :is="navMenu.meta.icon || 'el-icon-menu'" />
</el-icon>
<template #title>
<span>{{navMenu.meta.title}}</span>
<span v-if="navMenu.meta.tag" class="menu-tag">{{navMenu.meta.tag}}</span>
<span>{{ navMenu.meta.title }}</span>
<span v-if="navMenu.meta.tag" class="menu-tag">{{ navMenu.meta.tag }}</span>
</template>
</el-menu-item>
<el-sub-menu v-else :index="navMenu.path">
<template #title>
<el-icon v-if="navMenu.meta&&navMenu.meta.icon"><component :is="navMenu.meta.icon || 'el-icon-menu'"/></el-icon>
<span>{{navMenu.meta.title}}</span>
<span v-if="navMenu.meta.tag" class="menu-tag">{{navMenu.meta.tag}}</span>
<el-icon v-if="navMenu.meta && navMenu.meta.icon">
<component :is="navMenu.meta.icon || 'el-icon-menu'" />
</el-icon>
<span>{{ navMenu.meta.title }}</span>
<span v-if="navMenu.meta.tag" class="menu-tag">{{ navMenu.meta.tag }}</span>
</template>
<NavMenu :navMenus="navMenu.children"></NavMenu>
</el-sub-menu>
@ -23,16 +27,16 @@
</template>
<script>
export default {
name: 'NavMenu',
props: ['navMenus'],
data() {
return {}
},
methods: {
hasChildren(item) {
return item.children && !item.children.every(item => item.meta.hidden)
}
export default {
name: 'NavMenu',
props: ['navMenus'],
data() {
return {}
},
methods: {
hasChildren(item) {
return item.children && !item.children.every(item => item.meta.hidden)
}
}
}
</script>

View File

@ -1,79 +1,85 @@
<!--
* @Descripttion: 处理iframe持久化涉及store(VUEX)
-->
<template>
<div v-show="$route.meta.type=='iframe'" class="iframe-pages">
<iframe v-for="item in iframeList" :key="item.meta.url" v-show="$route.meta.url==item.meta.url" :src="url(item.meta.url)" frameborder='0'>
</iframe>
<div v-show="$route.meta.type == 'iframe'" class="iframe-pages">
<iframe v-for="(item, i) in iframeList" :key="i" v-show="$route.meta.url == item.meta.url" :src="url(item.meta.url)" frameborder='0' />
</div>
</template>
<script>
export default {
data() {
return {
export default {
data() {
return {
}
}
},
watch: {
$route(e) {
this.push(e)
},
watch: {
$route(e) {
this.push(e)
},
},
created() {
this.push(this.$route);
},
computed: {
iframeList() {
return this.$store.state.iframe.iframeList
},
created() {
this.push(this.$route);
ismobile() {
return this.$store.state.global.ismobile
},
computed:{
iframeList(){
return this.$store.state.iframe.iframeList
},
ismobile(){
return this.$store.state.global.ismobile
},
layoutTags(){
return this.$store.state.global.layoutTags
}
},
mounted() {
layoutTags() {
return this.$store.state.global.layoutTags
}
},
mounted() {
},
methods: {
url(currentUrl) {
let token = this.$tool.cookie.get(this.$config.SESSIONNAME);
//
if (currentUrl.indexOf('?') === -1) {
// 使?
currentUrl += '?' + this.$config.TOKEN_NAME + '=' + token;
} else {
// 使&
currentUrl += '&' + this.$config.TOKEN_NAME + '=' + token;
}
return currentUrl;
},
methods: {
url(currentUrl){
let token = this.$tool.cookie.get(this.$config.SESSIONNAME);
//
if (currentUrl.indexOf('?') === -1) {
// 使?
currentUrl += '?' + this.$config.TOKEN_NAME + '=' + token;
} else {
// 使&
currentUrl += '&' + this.$config.TOKEN_NAME + '=' + token;
push(route) {
if (route.meta.type == 'iframe') {
//
if (route.meta.maximize) {
document.getElementById('app').classList.add('main-maximize')
}
return currentUrl;
},
push(route){
if(route.meta.type == 'iframe'){
//
if (route.meta.maximize) {
document.getElementById('app').classList.add('main-maximize')
}
if(this.ismobile || !this.layoutTags){
this.$store.commit("setIframeList", route)
}else{
this.$store.commit("pushIframeList", route)
}
}else{
if(this.ismobile || !this.layoutTags){
this.$store.commit("clearIframeList")
}
if (this.ismobile || !this.layoutTags) {
this.$store.commit("setIframeList", route)
} else {
this.$store.commit("pushIframeList", route)
}
} else {
if (this.ismobile || !this.layoutTags) {
this.$store.commit("clearIframeList")
}
}
}
}
}
</script>
<style scoped>
.iframe-pages {width:100%;height:100%;background: #fff;}
iframe {border:0;width:100%;height:100%;display: block;}
.iframe-pages {
width: 100%;
height: 100%;
background: #fff;
}
iframe {
border: 0;
width: 100%;
height: 100%;
display: block;
}
</style>

View File

@ -1,6 +1,5 @@
<template>
<div ref="" class="mobile-nav-button" @click="showMobileNav($event)" v-drag draggable="false"><el-icon><el-icon-menu /></el-icon></div>
<el-drawer ref="mobileNavBox" title="移动端菜单" :size="240" v-model="nav" direction="ltr" :with-header="false" destroy-on-close>
<el-container class="mobile-nav">
<el-header>
@ -15,122 +14,161 @@
</el-main>
</el-container>
</el-drawer>
</template>
<script>
import NavMenu from './NavMenu.vue';
import NavMenu from './NavMenu.vue';
export default {
components: {
NavMenu
},
data() {
return {
nav: false,
menu: []
export default {
components: {
NavMenu
},
data() {
return {
nav: false,
menu: []
}
},
computed: {
},
created() {
var menu = this.$router.x_getMenu()
this.menu = this.filterUrl(menu)
},
watch: {
},
methods: {
showMobileNav(e) {
var isdrag = e.currentTarget.getAttribute('drag-flag')
if (isdrag == 'true') {
return false;
} else {
this.nav = true;
}
},
computed:{
},
created() {
var menu = this.$router.x_getMenu()
this.menu = this.filterUrl(menu)
select() {
this.$refs.mobileNavBox.handleClose()
},
watch: {
},
methods: {
showMobileNav(e){
var isdrag = e.currentTarget.getAttribute('drag-flag')
if (isdrag == 'true') {
return false;
}else{
this.nav = true;
//
filterUrl(map) {
var newMap = []
map && map.forEach(item => {
item.meta = item.meta ? item.meta : {};
//
if (item.meta.hidden || item.meta.type == "button") {
return false
}
//http
if (item.meta.type == 'iframe') {
item.path = `/i/${item.name}`;
}
//
if (item.children && item.children.length > 0) {
item.children = this.filterUrl(item.children);
}
newMap.push(item)
})
return newMap;
}
},
directives: {
drag(el) {
let oDiv = el; //
let firstTime = '', lastTime = '';
//
// document.onselectstart = function() {
// return false;
// };
oDiv.onmousedown = function (e) {
//
let disX = e.clientX - oDiv.offsetLeft;
let disY = e.clientY - oDiv.offsetTop;
document.onmousemove = function (e) {
oDiv.setAttribute('drag-flag', true);
firstTime = new Date().getTime();
//
let l = e.clientX - disX;
let t = e.clientY - disY;
},
select(){
this.$refs.mobileNavBox.handleClose()
},
//
filterUrl(map){
var newMap = []
map && map.forEach(item => {
item.meta = item.meta?item.meta:{};
//
if(item.meta.hidden || item.meta.type=="button"){
return false
//
if (t > 0 && t < document.body.clientHeight - 50) {
oDiv.style.top = t + "px";
}
//http
if(item.meta.type=='iframe'){
item.path = `/i/${item.name}`;
if (l > 0 && l < document.body.clientWidth - 50) {
oDiv.style.left = l + "px";
}
//
if(item.children&&item.children.length > 0){
item.children = this.filterUrl(item.children);
}
document.onmouseup = function () {
lastTime = new Date().getTime();
if ((lastTime - firstTime) > 200) {
oDiv.setAttribute('drag-flag', false);
}
newMap.push(item)
})
return newMap;
}
},
directives: {
drag(el){
let oDiv = el; //
let firstTime='',lastTime='';
//
// document.onselectstart = function() {
// return false;
// };
oDiv.onmousedown = function(e){
//
let disX = e.clientX - oDiv.offsetLeft;
let disY = e.clientY - oDiv.offsetTop;
document.onmousemove = function(e){
oDiv.setAttribute('drag-flag', true);
firstTime = new Date().getTime();
//
let l = e.clientX - disX;
let t = e.clientY - disY;
//
if(t > 0 && t < document.body.clientHeight - 50){
oDiv.style.top = t + "px";
}
if(l > 0 && l < document.body.clientWidth - 50){
oDiv.style.left = l + "px";
}
}
document.onmouseup = function(){
lastTime = new Date().getTime();
if( (lastTime - firstTime)>200 ){
oDiv.setAttribute('drag-flag', false);
}
document.onmousemove = null;
document.onmouseup = null;
};
//return falsedivonmouseup
return false;
document.onmousemove = null;
document.onmouseup = null;
};
}
//return falsedivonmouseup
return false;
};
}
}
}
</script>
<style scoped>
.mobile-nav-button {position: fixed;bottom:10px;left:10px;z-index: 10;width: 50px;height: 50px;background: #409EFF;box-shadow: 0 2px 12px 0 rgba(64, 158, 255, 1);border-radius: 50%;display: flex;align-items: center;justify-content: center;cursor: pointer;}
.mobile-nav-button i {color: #fff;font-size: 20px;}
.mobile-nav-button {
position: fixed;
bottom: 10px;
left: 10px;
z-index: 10;
width: 50px;
height: 50px;
background: #409EFF;
box-shadow: 0 2px 12px 0 rgba(64, 158, 255, 1);
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
}
.mobile-nav {background: #212d3d;}
.mobile-nav .el-header {background: transparent;border: 0;}
.mobile-nav .el-main {padding:0;}
.mobile-nav .logo-bar {display: flex;align-items: center;font-weight: bold;font-size: 20px;color: #fff;}
.mobile-nav .logo-bar img {width: 30px;margin-right: 10px;}
.mobile-nav .el-submenu__title:hover {background: #fff!important;}
</style>
.mobile-nav-button i {
color: #fff;
font-size: 20px;
}
.mobile-nav {
background: #212d3d;
}
.mobile-nav .el-header {
background: transparent;
border: 0;
}
.mobile-nav .el-main {
padding: 0;
}
.mobile-nav .logo-bar {
display: flex;
align-items: center;
font-weight: bold;
font-size: 20px;
color: #fff;
}
.mobile-nav .logo-bar img {
width: 30px;
margin-right: 10px;
}
.mobile-nav .el-submenu__title:hover {
background: #fff !important;
}</style>

View File

@ -51,8 +51,8 @@
methods: {
async getData(){
this.loading = true
var res = await this.$http.get('tasks')
this.tasks = res.data
// var res = await this.$http.get('tasks')
// this.tasks = res.data
this.loading = false
},
refresh(){

View File

@ -1,7 +1,7 @@
<template>
<div class="user-bar">
<div v-if="$store.state.global.layout!='menu'" class="panel-item hidden-sm-and-down" @click='$store.commit("TOGGLE_layoutTags")'>
<div v-if="$store.state.global.layout != 'menu'" class="panel-item hidden-sm-and-down" @click='$store.commit("TOGGLE_layoutTags")'>
<el-icon v-if="$store.state.global.layoutTags"><el-icon-open /></el-icon>
<el-icon v-else><el-icon-TurnOff /></el-icon>
</div>
@ -66,154 +66,220 @@
</el-dropdown>
</div>
<el-dialog v-model="searchVisible" :width="700" title="搜索" center destroy-on-close>
<search @success="searchVisible=false"></search>
<el-dialog v-model="searchVisible" :width="700" title="搜索" center destroy-on-close>
<search @success="searchVisible = false"></search>
</el-dialog>
<el-drawer v-model="tasksVisible" :size="450" title="任务中心" destroy-on-close>
<el-drawer v-model="tasksVisible" :size="450" title="任务中心" destroy-on-close>
<tasks></tasks>
</el-drawer>
</template>
<script>
import search from './search.vue'
import tasks from './tasks.vue'
import search from './search.vue'
import tasks from './tasks.vue'
export default {
components: {
search,
tasks
},
data(){
return {
username: "",
avatar: "",
searchVisible: false,
tasksVisible: false,
msg: false,
msgList: [
{
id: 1,
type: 'user',
avatar: "img/avatar.jpg",
title: "Skuya",
describe: "如果喜欢就点个星星支持一下哦",
link: "",
time: "5分钟前"
},
{
id: 2,
type: 'user',
avatar: "img/avatar2.gif",
title: "Lolowan",
describe: "点进去Gitee获取最新开源版本",
link: "",
time: "14分钟前"
},
{
id: 3,
type: 'system',
avatar: "img/logo.png",
title: "感谢登录Admin",
describe: "Vue 3.0 + Vue-Router 4.0 + ElementPlus + Axios 后台管理系统。",
link: "",
time: "2020年7月24日"
}
]
export default {
components: {
search,
tasks
},
data() {
return {
username: "",
avatar: "",
searchVisible: false,
tasksVisible: false,
msg: false,
msgList: [
{
id: 1,
type: 'user',
avatar: "img/avatar.jpg",
title: "Skuya",
describe: "如果喜欢就点个星星支持一下哦",
link: "",
time: "5分钟前"
},
{
id: 2,
type: 'user',
avatar: "img/avatar2.gif",
title: "Lolowan",
describe: "点进去Gitee获取最新开源版本",
link: "",
time: "14分钟前"
},
{
id: 3,
type: 'system',
avatar: "img/logo.png",
title: "感谢登录Admin",
describe: "Vue 3.0 + Vue-Router 4.0 + ElementPlus + Axios 后台管理系统。",
link: "",
time: "2020年7月24日"
}
]
}
},
created() {
var userInfo = this.$tool.data.get("user");
this.username = userInfo.username;
this.avatar = userInfo.avatar;
},
methods: {
//
handleUser(command) {
if (command == "userinfo") {
this.$router.push({ path: '/user/info' });
}
if (command == "cmd") {
this.$router.push({ path: '/cmd' });
}
if (command == "clearCache") {
this.$confirm('清除缓存会将系统初始化,包括登录状态、主题、语言设置等,是否继续?', '提示', {
type: 'info',
}).then(() => {
const loading = this.$loading()
this.$tool.data.clear()
this.$router.replace({
path: '/login',
query: { redirect: this.$route.fullPath }
})
setTimeout(() => {
loading.close()
location.reload()
}, 1000)
}).catch(() => {
//
})
}
if (command == "outLogin") {
this.$confirm('确认是否退出当前用户?', '提示', {
type: 'warning',
confirmButtonText: '退出',
confirmButtonClass: 'el-button--danger'
}).then(() => {
this.$router.replace({
path: '/login',
query: { redirect: this.$route.fullPath }
});
}).catch(() => {
//退
})
}
},
created() {
var userInfo = this.$tool.data.get("user");
this.username = userInfo.username;
this.avatar = userInfo.avatar;
//
screen() {
var element = document.documentElement;
this.$tool.screen(element)
},
methods: {
//
handleUser(command) {
if(command == "userinfo"){
this.$router.push({path: '/user/info'});
}
if(command == "cmd"){
this.$router.push({path: '/cmd'});
}
if(command == "clearCache"){
this.$confirm('清除缓存会将系统初始化,包括登录状态、主题、语言设置等,是否继续?','提示', {
type: 'info',
}).then(() => {
const loading = this.$loading()
this.$tool.data.clear()
this.$router.replace({
path: '/login',
query: { redirect: this.$route.fullPath }
})
setTimeout(()=>{
loading.close()
location.reload()
},1000)
}).catch(() => {
//
})
}
if(command == "outLogin"){
this.$confirm('确认是否退出当前用户?','提示', {
type: 'warning',
confirmButtonText: '退出',
confirmButtonClass: 'el-button--danger'
}).then(() => {
this.$router.replace({
path: '/login',
query: { redirect: this.$route.fullPath }
});
}).catch(() => {
//退
})
}
},
//
screen(){
var element = document.documentElement;
this.$tool.screen(element)
},
//
showMsg(){
this.msg = true
},
//
markRead(){
this.msgList = []
},
//
search(){
this.searchVisible = true
},
//
tasks(){
this.tasksVisible = true
}
//
showMsg() {
this.msg = true
},
//
markRead() {
this.msgList = []
},
//
search() {
this.searchVisible = true
},
//
tasks() {
this.tasksVisible = true
}
}
}
</script>
<style scoped>
.user-bar {display: flex;align-items: center;height: 100%;}
.user-bar .panel-item {padding: 0 10px;cursor: pointer;height: 100%;display: flex;align-items: center;}
.user-bar .panel-item i {font-size: 16px;}
.user-bar .panel-item:hover {background: rgba(0, 0, 0, 0.1);}
.user-bar .user-avatar {height:49px;display: flex;align-items: center;}
.user-bar .user-avatar label {display: inline-block;margin-left:5px;font-size: 12px;cursor:pointer;}
.user-bar {
display: flex;
align-items: center;
height: 100%;
}
.msg-list li {border-top:1px solid #eee;}
.msg-list li a {display: flex;padding:20px;}
.msg-list li a:hover {background: #ecf5ff;}
.msg-list__icon {width: 40px;margin-right: 15px;}
.msg-list__main {flex: 1;}
.msg-list__main h2 {font-size: 15px;font-weight: normal;color: #333;}
.msg-list__main p {font-size: 12px;color: #999;line-height: 1.8;margin-top: 5px;}
.msg-list__time {width: 100px;text-align: right;color: #999;}
.user-bar .panel-item {
padding: 0 10px;
cursor: pointer;
height: 100%;
display: flex;
align-items: center;
}
.dark .msg-list__main h2 {color: #d0d0d0;}
.dark .msg-list li {border-top:1px solid #363636;}
.dark .msg-list li a:hover {background: #383838;}
</style>
.user-bar .panel-item i {
font-size: 16px;
}
.user-bar .panel-item:hover {
background: rgba(0, 0, 0, 0.1);
}
.user-bar .user-avatar {
height: 49px;
display: flex;
align-items: center;
}
.user-bar .user-avatar label {
display: inline-block;
margin-left: 5px;
font-size: 12px;
cursor: pointer;
}
.msg-list li {
border-top: 1px solid #eee;
}
.msg-list li a {
display: flex;
padding: 20px;
}
.msg-list li a:hover {
background: #ecf5ff;
}
.msg-list__icon {
width: 40px;
margin-right: 15px;
}
.msg-list__main {
flex: 1;
}
.msg-list__main h2 {
font-size: 15px;
font-weight: normal;
color: #333;
}
.msg-list__main p {
font-size: 12px;
color: #999;
line-height: 1.8;
margin-top: 5px;
}
.msg-list__time {
width: 100px;
text-align: right;
color: #999;
}
.dark .msg-list__main h2 {
color: #d0d0d0;
}
.dark .msg-list li {
border-top: 1px solid #363636;
}
.dark .msg-list li a:hover {
background: #383838;
}</style>

View File

@ -185,7 +185,7 @@
<div class="main-maximize-exit" @click="exitMaximize"><el-icon><el-icon-close /></el-icon></div>
<div class="layout-setting" v-if="$config.THEMESETTING" @click="openSetting"><el-icon><el-icon-brush-filled /></el-icon></div>
<el-drawer title="布局实时演示" v-model="settingDialog" :size="400" append-to-body destroy-on-close>
<el-drawer title="布局实时演示" v-if="settingDialog" v-model="settingDialog" :size="400" append-to-body destroy-on-close>
<setting></setting>
</el-drawer>
<auto-exit></auto-exit>

View File

@ -9,7 +9,6 @@
<h2>无权限或找不到页面</h2>
<p>当前页面无权限访问或者打开了一个不存在的链接请检查当前账户权限和链接的可访问性</p>
<el-button type="primary" plain round @click="gohome">返回首页</el-button>
<!-- <el-button type="primary" plain round @click="gologin">重新登录</el-button> -->
<el-button type="primary" round @click="goback">返回上一页</el-button>
</div>
</div>