(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-56aca0e9"],{"1f57":function(e,t,n){},"31d4":function(e,t,n){"use strict";var r=n("1f57"),s=n.n(r);s.a},b380:function(e,t,n){"use strict";n.r(t);var r=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("cl-crud",{on:{load:e.onLoad},scopedSlots:e._u([{key:"slot-clear-btn",fn:function(){return[n("el-button",{directives:[{name:"permission",rawName:"v-permission",value:e.$service.system.log.clear,expression:"$service.system.log.clear"}],attrs:{size:"mini",type:"danger"},on:{click:e.clear}},[e._v("清空")])]},proxy:!0},{key:"slot-set",fn:function(){return[n("div",{staticClass:"slot-set"},[n("span",[e._v("日志保存天数")]),n("el-input-number",{attrs:{"controls-position":"right",size:"mini",max:1e4,min:1},on:{blur:e.saveDay},model:{value:e.day,callback:function(t){e.day=t},expression:"day"}})],1)]},proxy:!0}])})},s=[],i=(n("3546"),n("0e8d"),n("fdc1"),n("a94a"),n("639b"),n("4f5b"),n("b287"),n("9d37")),o=n("5880");function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){Object(i["a"])(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var l={data:function(){return{crud:null,day:1}},computed:c({},Object(o["mapGetters"])(["permission"])),created:function(){var e=this;this.$service.system.log.getKeep().then((function(t){e.day=t}))},methods:{onLoad:function(e){var t=e.ctx,n=e.app;this.crud=n,t.service(this.$service.system.log).set("table",{columns:[{type:"index",align:"center",width:60},{prop:"userId",label:"用户ID",align:"center"},{prop:"name",label:"昵称",align:"center"},{prop:"action",label:"请求地址",align:"center",minWidth:"200","show-overflow-tooltip":!0},{prop:"params",label:"参数",align:"center",minWidth:"200","show-overflow-tooltip":!0},{prop:"ip",label:"ip",minWidth:"180",align:"center"},{prop:"ipAddr",label:"ip地址",minWidth:"150",align:"center"},{prop:"createTime",label:"创建时间",minWidth:"150",align:"center",sortable:!0}],op:{visible:!1},props:{"default-sort":{prop:"createTime",order:"descending"}}}).set("search",{key:{placeholder:"请输入请求地址, 参数，ip地址"}}).set("layout",[["refresh-btn","add-btn","slot-clear-btn","slot-set","flex1","search-key"],["data-table"],["flex1","pagination"]]).done(),n.refresh()},saveDay:function(){var e=this;this.$service.system.log.setKeep(this.day).then((function(){e.$message.success("保存成功")}))},clear:function(){var e=this;this.$confirm("是否要清空日志","提示",{type:"warning"}).then((function(){e.$service.system.log.clear().then((function(){e.$message.success("清空成功"),e.crud.refresh({page:1})})).catch((function(t){e.$message.error(t)}))})).catch((function(){}))}}},p=l,u=(n("31d4"),n("5511")),d=Object(u["a"])(p,r,s,!1,null,"08f49789",null);t["default"]=d.exports}}]);