(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-2d212f1e"],{ab29:function(t,e,i){"use strict";i.r(e);var a=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{directives:[{name:"loading",rawName:"v-loading.fullscreen.lock",value:t.loading,expression:"loading",modifiers:{fullscreen:!0,lock:!0}}],staticClass:"app-container",attrs:{"element-loading-text":t.loadingText}},[i("div",{staticClass:"app-form margin-top"},[i("el-form",{ref:"dataForm",attrs:{rules:t.rules,model:t.form,"label-position":"right","label-width":"200px"}},[i("div",{staticClass:"app-form-group"},[i("div",{staticClass:"app-form-ti"},[t._v("清除设置")]),i("div",{staticClass:"padding-top-lg"},[i("el-form-item",{attrs:{label:"类型",prop:"type"}},[i("el-radio-group",{model:{value:t.form.type,callback:function(e){t.$set(t.form,"type",e)},expression:"form.type"}},[i("el-radio",{attrs:{label:1}},[t._v("清除用户数据")]),i("el-radio",{attrs:{label:0}},[t._v("清除所有数据")])],1),i("el-alert",{staticClass:"maring-top-sm",attrs:{title:"清除用户数据：清除用户数据是指清除用户相关数据，如会员信息、订单信息等，一般用于正式上线前清除测试数据；",type:"error"}}),i("el-alert",{staticClass:"maring-top-sm",staticStyle:{"margin-top":"10px"},attrs:{title:"清除所有数据：清除所有数据是指清除商城所有数据类容，例如用户数据、商品、应用设置、分销设置级等级等（类似于手机的恢复原厂设置），一般情况下不建议进行此项操作。",type:"error"}}),i("el-alert",{staticClass:"maring-top-sm",staticStyle:{"margin-top":"10px"},attrs:{title:"以上两种清除都是不可逆行为，清除任何一种数据后都找不回来（专业人员提前备份的除外），请谨慎操作！。",type:"error"}})],1)],1)]),i("div",{staticClass:"padding-lg flex justify-center"},[i("el-button",{attrs:{type:"primary"},on:{click:t.submit}},[t._v("提交")]),i("el-button",{attrs:{type:"success"},on:{click:t.clearQrcode}},[t._v("清除二维码缓存")])],1)])],1),i("copyright")],1)},n=[],o=i("7f70"),s=(i("6994"),i("8327")),l={name:"Clear",components:{},data:function(){return{activeIndex:"1",loading:!1,loadingText:"清除中...",rules:{},form:{type:1}}},computed:Object(o["a"])({},Object(s["b"])(["config"])),watch:{config:function(t){this.init()}},mounted:function(){this.init()},methods:{handleSelect:function(t,e){this.activeIndex=t},submit:function(){var t=this;this.$util.confirm("此操作将永久删除数据, 是否继续?",(function(e){e&&t.$refs["dataForm"].validate((function(e){e&&(t.loading=!0,t.loadingText="清除数据中...",t.api.post("common/clearData",t.form).then((function(e){1==e.code?(t.$util.success(e.message),t.$store.dispatch("settings/getSetting")):t.$util.error(e.message)})).finally((function(){t.loading=!1})))}))}))},init:function(){},clearQrcode:function(){var t=this;this.$util.confirm("此操作将清除二维码缓存, 是否继续?",(function(e){e&&(t.loading=!0,t.loadingText="清除二维码中...",t.api.post("config/clearQrcode").then((function(e){1==e.code?(t.$util.success(e.message),t.$store.dispatch("settings/getSetting")):t.$util.error(e.message)})).finally((function(){t.loading=!1})))}))}}},r=l,c=i("3d7a"),d=Object(c["a"])(r,a,n,!1,null,null,null);e["default"]=d.exports}}]);