You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 lines
2.2 KiB
1 lines
2.2 KiB
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-607df780"],{8916:function(t,e,a){"use strict";var n=a("365c");function i(t){var e="/adminLoginLog/index";return n["a"].get(e,t)}function s(t){var e="/adminOptLog/index";return n["a"].get(e,t)}function o(t){var e="/database/backup";return n["a"].post(e,t)}function r(t){var e="/database/restore";return n["a"].post(e,t)}function c(t){var e="/database/delete";return n["a"].post(e,t)}function u(t){var e="/database/index";return n["a"].get(e,t)}e["a"]={loginLog:i,optLog:s,dataBackup:o,dataRestore:r,dataDelete:c,dataList:u}},cef3:function(t,e,a){"use strict";a.r(e);var n=function(){var t=this,e=t._self._c;return e("div",{staticClass:"main-box"},[e("el-button",{staticStyle:{"margin-bottom":"16px"},attrs:{icon:"el-icon-plus",type:"primary"},on:{click:t.backup}},[t._v(" "+t._s(t.$t("备份数据库"))+" ")]),e("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],attrs:{data:t.dataBase}},[e("el-table-column",{attrs:{label:t.$t("文件名"),prop:"title"}}),e("el-table-column",{attrs:{label:t.$t("文件大小"),prop:"size"}}),e("el-table-column",{attrs:{label:t.$t("操作"),fixed:"right",width:"100",align:"right"},scopedSlots:t._u([{key:"default",fn:function(a){return[e("RestoreBtn",{attrs:{"tips-content":t.$t("恢复")},on:{click:function(e){return t.restore(a.row)}}}),e("DelBtn",{attrs:{"confirm-content":t.$t("删除该备份文件")},on:{click:function(e){return t.getDele(a.row)}}})]}}])})],1)],1)},i=[],s=a("8916"),o={data:function(){return{dataBase:[],loading:!1}},created:function(){this.getList()},methods:{backup:function(){var t=this;this.loading=!0,s["a"].dataBackup().then((function(e){t.loading=!1,0==e.code&&(t.$message.success(e.msg),t.getList())}))},getList:function(){var t=this;s["a"].dataList().then((function(e){t.dataBase=e.data}))},restore:function(t){var e=this;s["a"].dataRestore({filename:t.title}).then((function(t){0==t.code&&(e.$message.success(t.msg),e.getList())}))},getDele:function(t){var e=this;s["a"].dataDelete({filename:t.title}).then((function(t){0==t.code&&(e.getList(),e.$message.success(t.msg))}))}}},r=o,c=a("2877"),u=Object(c["a"])(r,n,i,!1,null,"f55a62ca",null);e["default"]=u.exports}}]);
|