(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-292e4adf"],{"5f9b":function(e,t,n){"use strict";n.r(t);var c=function(){var e=this,t=e._self._c;return t("div",[t("a-row",{attrs:{type:"flex",gutter:10}},[t("a-col",{attrs:{span:8}},[t("a-card",{staticStyle:{height:"calc(100vh - 125px)"},attrs:{bordered:!1}},[t("advance-table",{attrs:{columns:e.columns,"data-source":e.list,title:"缓存列表",loading:e.loading,scroll:{y:"calc(100vh - 125px)"},rowKey:"cacheId",size:"middle",isTableConfig:!1,isShowSetBtn:!1,tableKey:"monitor-cache-cache-name-list-table",customRow:e.onClickRow,"format-conditions":!0},on:{refresh:e.getList},scopedSlots:e._u([{key:"indexRender",fn:function(n){n.text,n.record;var c=n.index;return t("span",{},[e._v(" "+e._s(c+1)+" ")])}},{key:"operation",fn:function(n){n.text;var c=n.record;return t("span",{},[t("a",{directives:[{name:"hasPermi",rawName:"v-hasPermi",value:["monitor:cache:list"],expression:"['monitor:cache:list']"}],on:{click:function(t){return e.handleClear(c)}}},[e._v(" 删除 ")])])}}])})],1)],1),t("a-col",{attrs:{span:8}},[t("a-card",{staticStyle:{height:"calc(100vh - 125px)"},attrs:{bordered:!1}},[t("advance-table",{attrs:{columns:e.cacheKeysColumns,"data-source":e.subList,title:"键名列表",scroll:{y:"calc(100vh - 125px)"},loading:e.subLoading,rowKey:"cacheKey",size:"middle",customRow:e.onClickSubRow,isTableConfig:!1,isShowSetBtn:!1,tableKey:"monitor-cache-cache-key-list-table","format-conditions":!0},on:{refresh:e.getCacheKeyList},scopedSlots:e._u([{key:"indexSubRender",fn:function(n){n.text,n.record;var c=n.index;return t("span",{},[e._v(" "+e._s(c+1)+" ")])}},{key:"operation",fn:function(n){n.text;var c=n.record;return t("span",{},[t("a",{directives:[{name:"hasPermi",rawName:"v-hasPermi",value:["monitor:cache:list"],expression:"['monitor:cache:list']"}],on:{click:function(t){return t.stopPropagation(),e.handleClearByKey(c)}}},[e._v(" 删除 ")])])}}])})],1)],1),t("a-col",{attrs:{span:8}},[t("a-card",{staticStyle:{height:"calc(100vh - 125px)","overflow-y":"auto","overflow-x":"hidden"},attrs:{bordered:!1}},[t("a-form-model",{ref:"form",attrs:{model:e.form,layout:"vertical"}},[t("a-row",{attrs:{gutter:32}},[t("a-col",{attrs:{offset:1,span:22}},[t("a-form-model-item",{attrs:{label:"缓存名称:",prop:"cacheName"}},[t("a-input",{attrs:{readOnly:!0},model:{value:e.form.cacheName,callback:function(t){e.$set(e.form,"cacheName",t)},expression:"form.cacheName"}})],1)],1),t("a-col",{attrs:{offset:1,span:22}},[t("a-form-model-item",{attrs:{label:"缓存键名:",prop:"cacheKey"}},[t("a-input",{attrs:{readOnly:!0},model:{value:e.form.cacheKey,callback:function(t){e.$set(e.form,"cacheKey",t)},expression:"form.cacheKey"}})],1)],1),t("a-col",{attrs:{offset:1,span:22}},[t("a-form-model-item",{attrs:{label:"缓存内容:",prop:"cacheValue"}},[t("a-textarea",{attrs:{rows:16,readOnly:!0},model:{value:e.form.cacheValue,callback:function(t){e.$set(e.form,"cacheValue",t)},expression:"form.cacheValue"}})],1)],1)],1)],1)],1)],1)],1)],1)},a=[],o=n("2909"),i=(n("7db0"),n("d3b7"),n("ceee")),s=n("5d9e"),r={name:"CacheName",components:{AdvanceTable:s["a"]},data:function(){return{list:[],cacheData:[],subList:[],selectedRowKeys:[],selectedSubRowKeys:[],selectedRows:[],selectedSubRows:[],advanced:!1,single:!0,multiple:!0,subMultiple:!0,currentSelectCacheId:"",selectItem:{},selectSubItem:{},subLoading:!1,form:{},total:0,subTotal:0,labelCol:{span:6},wrapperCol:{span:18},columns:[{title:"序号",width:"20%",align:"center",scopedSlots:{customRender:"indexRender"}},{title:"缓存名称",dataIndex:"cacheName",ellipsis:!0},{title:"备注",dataIndex:"remarks",ellipsis:!0},{title:"操作",dataIndex:"operation",width:"80px",scopedSlots:{customRender:"operation"}}],cacheKeysColumns:[{title:"序号",width:"20%",align:"center",scopedSlots:{customRender:"indexSubRender"}},{title:"缓存键名",dataIndex:"cacheKey",ellipsis:!0},{title:"操作",dataIndex:"operation",width:"100px",scopedSlots:{customRender:"operation"}}]}},filters:{},created:function(){this.form={cacheName:void 0,cacheId:void 0,cacheKey:void 0,cacheValue:void 0,fileType:void 0,fileUrl:void 0,fileCreateTime:void 0,methodName:void 0,dtoValue:void 0,dto:void 0,serviceBean:void 0,status:void 0},this.getList()},computed:{},watch:{selectItem:function(e){this.renderStyle(e,"main"),this.getCacheKeyList(e.cacheId)},selectSubItem:function(e){this.renderStyle(e,"sub")}},methods:{getList:function(){var e=this;this.loading=!0,Object(i["f"])().then((function(t){e.list=t.data,e.loading=!1,e.list.length>0&&e.$nextTick((function(){return e.selectItem=e.list[0]}))}))},handleClear:function(e){var t=this;this.$confirm({title:"确认清除所选中数据的缓存吗?",onOk:function(){return Object(i["a"])(e.cacheId).then((function(){t.onSelectChange([],[]),t.getList(),t.$message.success("缓存清除成功",3)}))},onCancel:function(){}})},handleClearByKey:function(e){var t=this;this.$confirm({title:"确认清除所选中数据的缓存吗?",onOk:function(){return Object(i["b"])(e.cacheId,e.cacheKey).then((function(){t.$message.success("缓存清除成功",3),Object(i["e"])(e.cacheId).then((function(e){t.subList=e.data,t.subLoading=!1}))}))},onCancel:function(){}})},getCacheKeyList:function(e){var t=this;"string"===typeof e?null===e||""===e||void 0===e?e=this.currentSelectCacheId:this.currentSelectCacheId=e:e=this.currentSelectCacheId,this.subLoading=!0,Object(i["e"])(e).then((function(e){t.subList=e.data,t.subLoading=!1}))},onClickRow:function(e,t){var n=this;return{on:{click:function(t){n.selectItem=e}}}},onClickSubRow:function(e,t){var n=this;return{on:{click:function(t){n.selectSubItem=e,Object(i["d"])(e.cacheId,e.cacheKey).then((function(e){n.form=e.data}))}}}},handleQuery:function(){this.getList()},selectFirstRecord:function(){this.list.length>0?this.selectItem=this.list[0]:(this.subList=[],this.subTotal=0)},onSelectChange:function(e,t){this.selectedRowKeys=e,this.selectedRows=t,this.single=1!==e.length,this.multiple=!e.length},onSelectSubChange:function(e,t){this.selectedSubRowKeys=e,this.selectedSubRows=t,this.subMultiple=!e.length},renderStyle:function(e,t){var n,c=document.getElementsByClassName("ant-table-row"),a=document.getElementsByClassName(t+"-row-selection");a.length&&a[0].classList.remove(t+"-row-selection"),c.length&&(n=Object(o["a"])(c),"main"===t?n.find((function(t){return t.dataset.rowKey===e.cacheId})).classList.add(t+"-row-selection"):"sub"===t&&n.find((function(t){return t.dataset.rowKey===e.cacheKey})).classList.add(t+"-row-selection"))}}},l=r,u=(n("f9fe"),n("2877")),d=Object(u["a"])(l,c,a,!1,null,"fa5cca0e",null);t["default"]=d.exports},a2a3:function(e,t,n){},ceee:function(e,t,n){"use strict";n.d(t,"c",(function(){return a})),n.d(t,"f",(function(){return o})),n.d(t,"a",(function(){return i})),n.d(t,"e",(function(){return s})),n.d(t,"b",(function(){return r})),n.d(t,"d",(function(){return l}));var c=n("b775");function a(){return Object(c["b"])({url:"/monitor/cache",method:"get"})}function o(){return Object(c["b"])({url:"/monitor/cache/listCacheName",method:"get"})}function i(e){return Object(c["b"])({url:"/monitor/cache/clearCache/"+e,method:"post"})}function s(e){return Object(c["b"])({url:"/monitor/cache/listCacheKey/"+e,method:"get"})}function r(e,t){return Object(c["b"])({url:"/monitor/cache/clearCacheByKey/"+e+"/"+t,method:"post"})}function l(e,t){return Object(c["b"])({url:"/monitor/cache/getCacheValue/"+e+"/"+t,method:"get"})}},f9fe:function(e,t,n){"use strict";n("a2a3")}}]);