(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-49693196"],{"1cfb":function(t,e,s){"use strict";s("a252")},"6be0":function(t,e,s){"use strict";s.d(e,"c",(function(){return n})),s.d(e,"b",(function(){return i})),s.d(e,"d",(function(){return o})),s.d(e,"a",(function(){return r}));var a=s("f175");const n=()=>a.a.get("/settings.shop.Storage/lists"),i=t=>a.a.get("/settings.shop.Storage/index",{params:t}),o=t=>a.a.post("/settings.shop.Storage/setup",t),r=t=>a.a.post("/settings.shop.Storage/change",t)},a252:function(t,e,s){},af4f:function(t,e,s){"use strict";s.r(e);var a=s("9ab4"),n=s("1b40"),i=s("6be0");let o=class extends n.e{constructor(){super(...arguments),this.list=[],this.oldEngine="local"}onStorageEdit(t){this.$router.push({path:"/setting/storage/storage",query:{engine:t.engine}})}getStorageList(){Object(i.c)().then(t=>{this.list=t}).catch(()=>{this.$message.error("获取数据失败，请重试！")})}postStorageChange(t){Object(i.a)({engine:t.engine}).then(t=>{this.getStorageList(),this.$message.success("更新成功")}).catch(()=>{this.$message.error("更新失败")})}created(){this.getStorageList()}};o=Object(a.a)([Object(n.a)({components:{}})],o);var r=o,c=(s("1cfb"),s("2877")),l=Object(c.a)(r,(function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"storage-setting"},[s("div",{staticClass:"ls-card"},[s("el-alert",{attrs:{title:"温馨提示：1.切换存储方式后，需要将资源文件传输至新的存储端；2.请勿随意切换存储方式，可能导致图片无法查看。",type:"info",closable:!1,"show-icon":""}})],1),s("div",{staticClass:"ls-user_tag ls-card m-t-20"},[s("div",{staticClass:"list-table m-t-16"},[s("el-table",{staticStyle:{width:"100%"},attrs:{data:t.list,size:"mini","header-cell-style":{background:"#f5f8ff"}}},[s("el-table-column",{attrs:{prop:"name",label:"存储方式","min-width":"",width:""}}),s("el-table-column",{attrs:{prop:"path",label:"存储位置","min-width":"260",width:""}}),s("el-table-column",{attrs:{prop:"status",label:"状态","min-width":"",width:""},scopedSlots:t._u([{key:"default",fn:function(e){return[s("el-switch",{attrs:{"active-value":1,"inactive-value":0,"active-color":t.styleConfig.primary,"inactive-color":"#f4f4f5"},on:{change:function(s){return t.postStorageChange(e.row)}},model:{value:e.row.status,callback:function(s){t.$set(e.row,"status",s)},expression:"scope.row.status"}})]}}])}),s("el-table-column",{attrs:{label:"操作","min-width":"",fixed:"right"},scopedSlots:t._u([{key:"default",fn:function(e){return[s("el-button",{attrs:{type:"text",size:"small"},on:{click:function(s){return t.onStorageEdit(e.row)}}},[t._v("设置")])]}}])})],1)],1)])])}),[],!1,null,"bbd7239e",null);e.default=l.exports}}]);