This commit is contained in:
小陌 2024-01-10 16:07:50 +08:00
parent f96b2755dc
commit b3d67bf5f1
13 changed files with 71 additions and 60 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.6d24c4be.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.5ced905c.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="aminui"><div class="app-loading"><div class="app-loading__logo"></div><div class="app-loading__loader"></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>.app-loading {
<!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.e96184fd.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.5ced905c.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="aminui"><div class="app-loading"><div class="app-loading__logo"></div><div class="app-loading__loader"></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>.app-loading {
position: absolute;
top:0px;
left:0px;

4
dist/report.html vendored

File diff suppressed because one or more lines are too long

1
dist/static/css/268.a4ecbc5f.css vendored Normal file
View File

@ -0,0 +1 @@
.container[data-v-a07f0f7c]{border:1px solid var(--el-border-color-light);border-radius:4px;background-color:var(--el-fill-color-blank);overflow:hidden}.el-header[data-v-a07f0f7c]{height:50px}.el-aside[data-v-a07f0f7c]{background-color:#fff}.x-page-header[data-v-a07f0f7c]{border-bottom:0 solid #ebebebc2;padding:5px;.x-page-header__icon[data-v-a07f0f7c]{width:40px}}

View File

@ -1 +0,0 @@
.container[data-v-28462f8d]{border:1px solid var(--el-border-color-light);border-radius:4px;background-color:var(--el-fill-color-blank);overflow:hidden}.el-header[data-v-28462f8d]{height:50px}.el-aside[data-v-28462f8d]{background-color:#fff}.x-page-header[data-v-28462f8d]{border-bottom:0 solid #ebebebc2;padding:5px;.x-page-header__icon[data-v-28462f8d]{width:40px}}

1
dist/static/css/862.f78d2a26.css vendored Normal file
View File

@ -0,0 +1 @@
.el-header[data-v-b547498a]{height:50px}.x-page-header[data-v-b547498a]{border-bottom:0 solid hsla(0,0%,92%,.761);padding:5px}.x-page-header .x-page-header__icon[data-v-b547498a]{width:40px}.message-header[data-v-b547498a]{margin-left:28px;height:60px}.message-header .title-icon[data-v-b547498a]{width:30px;height:30px;margin-right:10px;border-radius:4px}.message-header .title[data-v-b547498a]{font-size:16px;font-weight:600}.message-body[data-v-b547498a],.message-content[data-v-b547498a]{position:relative;height:100%}.message-body-side[data-v-b547498a]{padding:0 0;font-size:14px;background-color:#fff;position:absolute;top:0;left:0;bottom:0;z-index:100;border-right:1px solid #e6e6e6;overflow-y:auto}.message-body-side .side-item[data-v-b547498a]{position:relative;height:50px;line-height:50px;padding:0 20px;font-size:13px;cursor:pointer}.message-body-side .side-item i[data-v-b547498a]{color:#999}.message-body-content[data-v-b547498a]{height:100%;overflow:hidden}@media(max-width:767px){.message-body-side[data-v-b547498a]{width:0!important;transition:all .1s;overflow-y:hidden}.message-body-content[data-v-b547498a]{margin-left:0!important;transition:all .1s}}

View File

@ -1 +0,0 @@
.el-header[data-v-acc1c5dc]{height:50px}.x-page-header[data-v-acc1c5dc]{border-bottom:0 solid hsla(0,0%,92%,.761);padding:5px}.x-page-header .x-page-header__icon[data-v-acc1c5dc]{width:40px}.message-header[data-v-acc1c5dc]{margin-left:28px;height:60px}.message-header .title-icon[data-v-acc1c5dc]{width:30px;height:30px;margin-right:10px;border-radius:4px}.message-header .title[data-v-acc1c5dc]{font-size:16px;font-weight:600}.message-body[data-v-acc1c5dc],.message-content[data-v-acc1c5dc]{position:relative;height:100%}.message-body-side[data-v-acc1c5dc]{padding:0 0;font-size:14px;background-color:#fff;position:absolute;top:0;left:0;bottom:0;z-index:100;border-right:1px solid #e6e6e6;overflow-y:auto}.message-body-side .side-item[data-v-acc1c5dc]{position:relative;height:50px;line-height:50px;padding:0 20px;font-size:13px;cursor:pointer}.message-body-side .side-item i[data-v-acc1c5dc]{color:#999}.message-body-content[data-v-acc1c5dc]{height:100%;overflow:hidden}@media(max-width:767px){.message-body-side[data-v-acc1c5dc]{width:0!important;transition:all .1s;overflow-y:hidden}.message-body-content[data-v-acc1c5dc]{margin-left:0!important;transition:all .1s}}

1
dist/static/js/268.2987c984.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -1 +0,0 @@
"use strict";(self["webpackChunkx_php_admin"]=self["webpackChunkx_php_admin"]||[]).push([[484],{2484:function(e,t,a){a.r(t),a.d(t,{default:function(){return g}});var l=a(6808),n=a(9511);const i={class:"left-panel"},r={class:"right-panel"},o={class:"right-panel-search"};function c(e,t,a,c,u,s){const h=(0,l.up)("x-page-header"),p=(0,l.up)("el-header"),d=(0,l.up)("x-menu-item"),m=(0,l.up)("el-main"),f=(0,l.up)("el-container"),g=(0,l.up)("el-aside"),w=(0,l.up)("el-date-picker"),y=(0,l.up)("el-input"),b=(0,l.up)("el-button"),_=(0,l.up)("xEcharts"),k=(0,l.up)("el-table-column"),C=(0,l.up)("xTable"),x=(0,l.up)("info"),W=(0,l.up)("el-drawer");return(0,l.wg)(),(0,l.iD)(l.HY,null,[(0,l.Wm)(f,null,{default:(0,l.w5)((()=>[(0,l.Wm)(g,{width:"210px"},{default:(0,l.w5)((()=>[(0,l.Wm)(f,null,{default:(0,l.w5)((()=>[(0,l.Wm)(p,null,{default:(0,l.w5)((()=>[(0,l.Wm)(h,{title:"日志",icon:"el-icon-Calendar"})])),_:1}),(0,l.Wm)(m,{style:{padding:"0"}},{default:(0,l.w5)((()=>[((0,l.wg)(!0),(0,l.iD)(l.HY,null,(0,l.Ko)(u.typeList,((e,t)=>((0,l.wg)(),(0,l.j4)(d,{key:t,label:e.label,num:e.num,icon:e.icon,"icon-color":e.color,select:u.search.type==e.value,onClick:t=>s.sideClick(e)},null,8,["label","num","icon","icon-color","select","onClick"])))),128))])),_:1})])),_:1})])),_:1}),(0,l.Wm)(f,{style:{padding:"10px 10px 6px 10px"}},{default:(0,l.w5)((()=>[(0,l.Wm)(m,{class:"nopadding"},{default:(0,l.w5)((()=>[(0,l.Wm)(f,{class:"container"},{default:(0,l.w5)((()=>[(0,l.Wm)(p,null,{default:(0,l.w5)((()=>[(0,l._)("div",i,[(0,l.Wm)(w,{modelValue:u.date,"onUpdate:modelValue":t[0]||(t[0]=e=>u.date=e),type:"datetimerange","range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期"},null,8,["modelValue"])]),(0,l._)("div",r,[(0,l._)("div",o,[(0,l.Wm)(y,{modelValue:u.search.keyword,"onUpdate:modelValue":t[1]||(t[1]=e=>u.search.keyword=e),placeholder:"输入关键词",clearable:""},null,8,["modelValue"]),(0,l.Wm)(b,{type:"primary",icon:"el-icon-search",onClick:s.upsearch},null,8,["onClick"])])])])),_:1}),"object"===typeof u.chartoption&&Object.keys(u.chartoption).length>0?((0,l.wg)(),(0,l.j4)(p,{key:0,style:{height:"120px"}},{default:(0,l.w5)((()=>[(0,l.Wm)(_,{height:"100%",option:u.chartoption},null,8,["option"])])),_:1})):(0,l.kq)("",!0),(0,l.Wm)(m,{class:"nopadding"},{default:(0,l.w5)((()=>[(0,l.Wm)(C,{ref:"table",api:u.api,params:u.search,tableColumn:u.tableColumn,stripe:"",highlightCurrentRow:"",onRowClick:s.rowClick},{default:(0,l.w5)((()=>[(0,l.Wm)(k,{type:"index",width:"60",align:"center"},{default:(0,l.w5)((e=>[(0,l._)("span",null,(0,n.zw)(e.$index+(u.currentPage-1)*u.limit+1),1)])),_:1})])),_:1},8,["api","params","tableColumn","onRowClick"])])),_:1})])),_:1})])),_:1})])),_:1})])),_:1}),(0,l.Wm)(W,{modelValue:u.infoDrawer,"onUpdate:modelValue":t[2]||(t[2]=e=>u.infoDrawer=e),title:"日志详情",size:700,"destroy-on-close":""},{default:(0,l.w5)((()=>[(0,l.Wm)(x,{ref:"info"},null,512)])),_:1},8,["modelValue"])],64)}var u=a(328),s=a(7844),h=a(4001),p=a(1843),d={name:"log",components:{info:u["default"],columnItem:h.Z,xMenuItem:p.Z,xEcharts:s.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 l=t+"=([^&]*)";if(""===a)return e=e.replace(new RegExp("&?"+l,"gi"),""),e=e.replace(new RegExp("\\??"+l+"&?","gi"),"?"),e;var n=t+"="+a;if(e.match(l)){var i="("+t+"=)([^&]*)";return i=e.replace(new RegExp(i,"gi"),n),i}return e.match("[?]")?e+"&"+n:e+"?"+n},nodeClick(e){if(e.disabled)return!1;this.current=e.label,this.column=e.column||"column"},getType(){var e={cache:this.$route.meta.cache||!0,cacheparameters:this.$route.meta.cacheparameters||!1};this.$http.get("log/admin/types",{type:this.$route.query.type},e).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)}))}}},m=a(8700);const f=(0,m.Z)(d,[["render",c],["__scopeId","data-v-28462f8d"]]);var g=f}}]);

1
dist/static/js/862.102bf2ea.js vendored Normal file
View File

@ -0,0 +1 @@
"use strict";(self["webpackChunkx_php_admin"]=self["webpackChunkx_php_admin"]||[]).push([[862],{862:function(e,l,n){n.r(l),n.d(l,{default:function(){return b}});var i=n(6808),t=n(9511);const a=e=>((0,i.dD)("data-v-b547498a"),e=e(),(0,i.Cn)(),e),o={class:"message-body"},c={class:"message-content"},s={class:"message-body-item"},u=a((()=>(0,i._)("span",null,"系统管理组",-1))),d=a((()=>(0,i._)("span",null,"自定义用户组",-1))),m=a((()=>(0,i._)("span",null,"用户等级组",-1)));function r(e,l,n,a,r,k){const p=(0,i.up)("x-page-header"),w=(0,i.up)("el-header"),g=(0,i.up)("x-menu-item"),h=(0,i.up)("el-icon-Setting"),b=(0,i.up)("el-icon"),y=(0,i.up)("el-sub-menu"),f=(0,i.up)("el-icon-Stamp"),_=(0,i.up)("el-icon-Flag"),C=(0,i.up)("el-menu"),v=(0,i.up)("el-main"),j=(0,i.up)("el-container"),W=(0,i.up)("table2"),x=(0,i.Q2)("loading");return(0,i.wg)(),(0,i.iD)("div",o,[(0,i.wy)(((0,i.wg)(),(0,i.iD)("div",c,[(0,i._)("div",{class:"message-body-side",style:(0,t.j5)({width:r.width+"px"})},[(0,i.Wm)(j,null,{default:(0,i.w5)((()=>[r.title?((0,i.wg)(),(0,i.j4)(w,{key:0},{default:(0,i.w5)((()=>[(0,i.Wm)(p,{title:r.title,icon:r.icon},null,8,["title","icon"])])),_:1})):(0,i.kq)("",!0),(0,i.Wm)(v,{style:{padding:"0"}},{default:(0,i.w5)((()=>[(0,i._)("div",s,[((0,i.wg)(!0),(0,i.iD)(i.HY,null,(0,i.Ko)(r.items.all,((e,l)=>((0,i.wg)(),(0,i.j4)(g,{key:l,label:e.label,num:e.num,icon:e.icon,"icon-color":e.color,select:r.search[r.key]==e.value,onClick:l=>k.sideClick(e)},null,8,["label","num","icon","icon-color","select","onClick"])))),128)),(0,i.Wm)(C,{"unique-opened":!0,defaultOpeneds:["system"]},{default:(0,i.w5)((()=>[r.items.system?((0,i.wg)(),(0,i.j4)(y,{key:0,index:"system"},{title:(0,i.w5)((()=>[(0,i.Wm)(b,null,{default:(0,i.w5)((()=>[(0,i.Wm)(h)])),_:1}),u])),default:(0,i.w5)((()=>[((0,i.wg)(!0),(0,i.iD)(i.HY,null,(0,i.Ko)(r.items.system,((e,l)=>((0,i.wg)(),(0,i.j4)(g,{key:l,label:e.label,num:e.num,icon:e.icon,"icon-color":e.color,select:r.search[r.key]==e.value,onClick:l=>k.sideClick(e)},null,8,["label","num","icon","icon-color","select","onClick"])))),128))])),_:1})):(0,i.kq)("",!0),r.items.default?((0,i.wg)(),(0,i.j4)(y,{key:1,index:"default"},{title:(0,i.w5)((()=>[(0,i.Wm)(b,null,{default:(0,i.w5)((()=>[(0,i.Wm)(f)])),_:1}),d])),default:(0,i.w5)((()=>[((0,i.wg)(!0),(0,i.iD)(i.HY,null,(0,i.Ko)(r.items.default,((e,l)=>((0,i.wg)(),(0,i.j4)(g,{key:l,label:e.label,num:e.num,icon:e.icon,"icon-color":e.color,select:r.search[r.key]==e.value,onClick:l=>k.sideClick(e)},null,8,["label","num","icon","icon-color","select","onClick"])))),128))])),_:1})):(0,i.kq)("",!0),r.items.member?((0,i.wg)(),(0,i.j4)(y,{key:2,index:"member"},{title:(0,i.w5)((()=>[(0,i.Wm)(b,null,{default:(0,i.w5)((()=>[(0,i.Wm)(_)])),_:1}),m])),default:(0,i.w5)((()=>[((0,i.wg)(!0),(0,i.iD)(i.HY,null,(0,i.Ko)(r.items.member,((e,l)=>((0,i.wg)(),(0,i.j4)(g,{key:l,label:e.label,num:e.num,icon:e.icon,"icon-color":e.color,select:r.search[r.key]==e.value,onClick:l=>k.sideClick(e)},null,8,["label","num","icon","icon-color","select","onClick"])))),128))])),_:1})):(0,i.kq)("",!0)])),_:1})])])),_:1})])),_:1})],4),(0,i._)("div",{class:"message-body-content",style:(0,t.j5)({"margin-left":r.width+"px"})},[(0,i.Wm)(W,{ref:"table",onChildLoaded:k.getChildData},null,8,["onChildLoaded"])],4)])),[[x,r.loading]])])}var k=n(1843),p=n(223),w={name:"table_3",components:{table2:p["default"],xMenuItem:k.Z},props:{name:{type:String,default:""}},data(){return{loading:!0,icon:"",width:180,title:"",items:[],key:"",search:{}}},methods:{sideClick(e){this.info=e,this.search[this.key||"type"]=e.value,this.$refs.table.filterChange(this.search)},getChildData(e){Object.assign(this.$data,e),this.loading=!1}}},g=n(8700);const h=(0,g.Z)(w,[["render",r],["__scopeId","data-v-b547498a"]]);var b=h}}]);

View File

@ -1 +0,0 @@
"use strict";(self["webpackChunkx_php_admin"]=self["webpackChunkx_php_admin"]||[]).push([[970],{2970:function(e,l,n){n.r(l),n.d(l,{default:function(){return b}});var i=n(6808),t=n(9511);const a=e=>((0,i.dD)("data-v-acc1c5dc"),e=e(),(0,i.Cn)(),e),c={class:"message-body"},o={class:"message-content"},s={class:"message-body-item"},u=a((()=>(0,i._)("span",null,"系统管理组",-1))),d=a((()=>(0,i._)("span",null,"自定义用户组",-1))),m=a((()=>(0,i._)("span",null,"用户等级组",-1)));function r(e,l,n,a,r,p){const h=(0,i.up)("x-page-header"),w=(0,i.up)("el-header"),g=(0,i.up)("x-menu-item"),k=(0,i.up)("el-icon-Setting"),b=(0,i.up)("el-icon"),f=(0,i.up)("el-sub-menu"),y=(0,i.up)("el-icon-Stamp"),_=(0,i.up)("el-icon-Flag"),C=(0,i.up)("el-menu"),v=(0,i.up)("el-main"),W=(0,i.up)("el-container"),x=(0,i.up)("table2"),D=(0,i.Q2)("loading");return(0,i.wg)(),(0,i.iD)("div",c,[(0,i.wy)(((0,i.wg)(),(0,i.iD)("div",o,[(0,i._)("div",{class:"message-body-side",style:(0,t.j5)({width:r.width+"px"})},[(0,i.Wm)(W,null,{default:(0,i.w5)((()=>[r.title?((0,i.wg)(),(0,i.j4)(w,{key:0},{default:(0,i.w5)((()=>[(0,i.Wm)(h,{title:r.title,icon:r.icon},null,8,["title","icon"])])),_:1})):(0,i.kq)("",!0),(0,i.Wm)(v,{style:{padding:"0"}},{default:(0,i.w5)((()=>[(0,i._)("div",s,[((0,i.wg)(!0),(0,i.iD)(i.HY,null,(0,i.Ko)(r.items.all,((e,l)=>((0,i.wg)(),(0,i.j4)(g,{key:l,label:e.label,num:e.num,icon:e.icon,"icon-color":e.color,select:r.search[r.key]==e.value,onClick:l=>p.sideClick(e)},null,8,["label","num","icon","icon-color","select","onClick"])))),128)),(0,i.Wm)(C,{"unique-opened":!0,defaultOpeneds:["system"]},{default:(0,i.w5)((()=>[(0,i.Wm)(f,{index:"system"},{title:(0,i.w5)((()=>[(0,i.Wm)(b,null,{default:(0,i.w5)((()=>[(0,i.Wm)(k)])),_:1}),u])),default:(0,i.w5)((()=>[((0,i.wg)(!0),(0,i.iD)(i.HY,null,(0,i.Ko)(r.items.system,((e,l)=>((0,i.wg)(),(0,i.j4)(g,{key:l,label:e.label,num:e.num,icon:e.icon,"icon-color":e.color,select:r.search[r.key]==e.value,onClick:l=>p.sideClick(e)},null,8,["label","num","icon","icon-color","select","onClick"])))),128))])),_:1}),(0,i.Wm)(f,{index:"default"},{title:(0,i.w5)((()=>[(0,i.Wm)(b,null,{default:(0,i.w5)((()=>[(0,i.Wm)(y)])),_:1}),d])),default:(0,i.w5)((()=>[((0,i.wg)(!0),(0,i.iD)(i.HY,null,(0,i.Ko)(r.items.default,((e,l)=>((0,i.wg)(),(0,i.j4)(g,{key:l,label:e.label,num:e.num,icon:e.icon,"icon-color":e.color,select:r.search[r.key]==e.value,onClick:l=>p.sideClick(e)},null,8,["label","num","icon","icon-color","select","onClick"])))),128))])),_:1}),(0,i.Wm)(f,{index:"member"},{title:(0,i.w5)((()=>[(0,i.Wm)(b,null,{default:(0,i.w5)((()=>[(0,i.Wm)(_)])),_:1}),m])),default:(0,i.w5)((()=>[((0,i.wg)(!0),(0,i.iD)(i.HY,null,(0,i.Ko)(r.items.member,((e,l)=>((0,i.wg)(),(0,i.j4)(g,{key:l,label:e.label,num:e.num,icon:e.icon,"icon-color":e.color,select:r.search[r.key]==e.value,onClick:l=>p.sideClick(e)},null,8,["label","num","icon","icon-color","select","onClick"])))),128))])),_:1})])),_:1})])])),_:1})])),_:1})],4),(0,i._)("div",{class:"message-body-content",style:(0,t.j5)({"margin-left":r.width+"px"})},[(0,i.Wm)(x,{ref:"table",onChildLoaded:p.getChildData},null,8,["onChildLoaded"])],4)])),[[D,r.loading]])])}var p=n(1843),h=n(223),w={name:"table_3",components:{table2:h["default"],xMenuItem:p.Z},props:{name:{type:String,default:""}},data(){return{loading:!0,icon:"",width:180,title:"",items:[],key:"",search:{}}},methods:{sideClick(e){this.info=e,this.search[this.key||"type"]=e.value,this.$refs.table.filterChange(this.search)},getChildData(e){Object.assign(this.$data,e),this.loading=!1}}},g=n(8700);const k=(0,g.Z)(w,[["render",r],["__scopeId","data-v-acc1c5dc"]]);var b=k}}]);

File diff suppressed because one or more lines are too long

View File

@ -1,12 +1,12 @@
<template>
<el-container>
<el-aside width="210px">
<el-container v-loading="loading">
<el-aside v-if="aside && aside.items.length > 0" :width="aside.width || '200px'">
<el-container>
<el-header>
<x-page-header title="日志" icon="el-icon-Calendar"></x-page-header>
<x-page-header :title="aside.title || '日志'" :icon="aside.icon || 'el-icon-Calendar'"></x-page-header>
</el-header>
<el-main style="padding: 0;">
<x-menu-item v-for="(item, index) in typeList" :key="index" :label="item.label" :num="item.num" :icon="item.icon" :icon-color="item.color" :select="search.type == item.value" @click="sideClick(item)" />
<x-menu-item v-for="(item, index) in aside.items" :key="index" :label="item.label" :num="item.num" :icon="item.icon" :icon-color="item.color" :select="search.type == item.value" @click="sideClick(item)" />
</el-main>
</el-container>
</el-aside>
@ -15,7 +15,7 @@
<el-container class="container">
<el-header>
<div class="left-panel">
<el-date-picker v-model="date" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
<el-date-picker v-model="search.date" clearable type="daterange" format="YYYY-MM-DD" value-format="YYYY-MM-DD" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</div>
<div class="right-panel">
<div class="right-panel-search">
@ -25,16 +25,10 @@
</div>
</el-header>
<el-header style="height:120px;" v-if="typeof chartoption === 'object' && Object.keys(chartoption).length > 0">
<xEcharts height="100%" :option="chartoption"></xEcharts>
<xEcharts height="100%" :option="chartoption" />
</el-header>
<el-main class="nopadding">
<xTable ref="table" :api="api" :params="search" :tableColumn="tableColumn" stripe highlightCurrentRow @row-click="rowClick">
<el-table-column type="index" width="60" align="center">
<template #default="scope">
<span>{{ scope.$index + (currentPage - 1) * limit + 1 }}</span>
</template>
</el-table-column>
</xTable>
<xTable ref="table" :api="xapi" :params="search" :tableColumn="tableColumn" stripe highlightCurrentRow @row-click="rowClick" />
</el-main>
</el-container>
</el-main>
@ -48,43 +42,57 @@
<script>
import info from './info'
import xEcharts from '@/components/xEcharts'
import columnItem from '@/components/xTable/columnItem'
import xMenuItem from '@/components/xMenu/item'
export default {
name: 'log',
components: {
info,
columnItem,
xMenuItem,
xEcharts
},
data() {
return {
loading: false,
infoDrawer: false,
chartoption: {},
typeList: [],
aside: {
items: []
},
search: {
date: [],
data: [],
search: {},
keyword: ''
},
api: '',
current: '',
configtype: '',
config: {},
tableColumn: {},
column: 'default',
currentPage: 1,
limit: 20,
column: {},
tablename: this.$route.meta.tablename,
tableurl: this.$route.meta.tableurl,
}
},
mounted() {
this.getType();
},
computed: {
tableColumn() {
if (this.config && this.config[this.configtype] && this.config[this.configtype].column) {
return this.config[this.configtype].column;
}
return this.column;
},
xapi() {
if (this.config && this.config[this.configtype] && this.config[this.configtype].api) {
return this.config[this.configtype].api;
}
return this.api;
}
},
watch: {
//props
current() {
this.search.type = this.current;
this.getCurrent();
},
},
methods: {
@ -92,7 +100,8 @@ export default {
this.info = item
this.search.type = item.value;
this.current = item.value;
this.column = item.column || 'column';
this.configtype = item.configtype || 'default';
this.upsearch();
},
changeURLArg(url, arg, arg_val) {
var pattern = arg + '=([^&]*)';
@ -112,36 +121,38 @@ export default {
}
return url + '?' + replaceText;
},
//
nodeClick(data) {
if (data.disabled) {
return false;
}
this.current = data.label;
this.column = data.column || 'column';
},
getType() {
var options = {
cache: this.$route.meta.cache || true,
cacheparameters: this.$route.meta.cacheparameters || false
cacheparameters: this.$route.meta.cacheparameters || false,
};
this.$http.get('log/admin/types', { type: this.$route.query.type }, options).then((res) => {
this.loading = true;
//
if (this.tablename || this.tableurl) {
var params = {
type: this.$route.query.type || '',
name: this.tablename
}
var awaitvar = this.$http.get(this.tableurl || '/table/get', params, options)
awaitvar.then((res) => {
this.loading = false;
if (res.code == 200) {
Object.assign(this.$data, res.data);
// search
for (const key in this.search) {
if (Object.prototype.hasOwnProperty.call(this.$route.query, key)) {
if (key=='date') {
this.search[key] = this.$route.query[key].split(",");
}else{
this.search[key] = this.$route.query[key];
}
}
}
Object.assign(this.$data, res.data);
}
});
}
},
getCurrent() {
this.tableColumn = this.config[this.column] || this.config.default;
if (!this.api) {
this.api = 'log/admin/lists'
}
this.$refs.table.reload(this.search)
let url = window.location.href;
for (const [key, value] of Object.entries(this.search)) {

View File

@ -10,7 +10,7 @@
<div class="message-body-item">
<x-menu-item v-for="(item, index) in items.all" :key="index" :label="item.label" :num="item.num" :icon="item.icon" :icon-color="item.color" :select="search[key] == item.value" @click="sideClick(item)" />
<el-menu :unique-opened="true" :defaultOpeneds="['system']">
<el-sub-menu index="system">
<el-sub-menu index="system" v-if="items.system">
<template #title>
<el-icon>
<el-icon-Setting />
@ -19,7 +19,7 @@
</template>
<x-menu-item v-for="(item, index) in items.system" :key="index" :label="item.label" :num="item.num" :icon="item.icon" :icon-color="item.color" :select="search[key] == item.value" @click="sideClick(item)" />
</el-sub-menu>
<el-sub-menu index="default">
<el-sub-menu index="default" v-if="items.default">
<template #title>
<el-icon>
<el-icon-Stamp />
@ -28,7 +28,7 @@
</template>
<x-menu-item v-for="(item, index) in items.default" :key="index" :label="item.label" :num="item.num" :icon="item.icon" :icon-color="item.color" :select="search[key] == item.value" @click="sideClick(item)" />
</el-sub-menu>
<el-sub-menu index="member">
<el-sub-menu index="member" v-if="items.member">
<template #title>
<el-icon>
<el-icon-Flag />