王总上门按摩后台代码
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 line
11 KiB

2 months ago
webpackJsonp([98],{"M+bL":function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var i=t("Xxa5"),r=t.n(i),u=t("exGp"),s=t.n(u),a={data:function(){return{options:[{value:0,label:"本地上传"},{value:2,label:"七牛云上传"},{value:1,label:"阿里云OSS上传"},{value:3,label:"腾讯云上传"}],baseForm:{id:""},baseFormRules:{},open_oss:0,qiniuyunForm:{qiniu_accesskey:"",qiniu_secretkey:"",qiniu_bucket:"",qiniu_yuming:""},qiniuyunFormRules:{qiniu_accesskey:{required:!0,type:"string",message:"请输入AccessKey",trigger:"blur"},qiniu_secretkey:{required:!0,type:"string",message:"请输入SecretKey",trigger:"blur"},qiniu_bucket:{required:!0,type:"string",message:"请输入仓库名称",trigger:"blur"},qiniu_yuming:{required:!0,type:"string",message:"请输入自定义域名",trigger:"blur"}},aliyunForm:{aliyun_bucket:"",aliyun_access_key_id:"",aliyun_access_key_secret:"",aliyun_base_dir:"",aliyun_zidinyi_yuming:"",aliyun_endpoint:""},aliyunFormRules:{aliyun_bucket:{required:!0,type:"string",message:"请输入仓库名称",trigger:"blur"},aliyun_access_key_id:{required:!0,type:"string",message:"请输入AccessKeyId",trigger:"blur"},aliyun_access_key_secret:{required:!0,type:"string",message:"请输入AccessKeySecret",trigger:"blur"},aliyun_base_dir:{required:!0,type:"string",message:"请输入上传根目录",trigger:"blur"},aliyun_zidinyi_yuming:{required:!0,type:"string",message:"请输入自定义域名",trigger:"blur"},aliyun_endpoint:{required:!0,type:"string",message:"请输入Endpoint",trigger:"blur"}},tengxunyunForm:{tenxunyun_appid:"",tenxunyun_secretid:"",tenxunyun_secretkey:"",tenxunyun_bucket:"",tenxunyun_region:"",tenxunyun_yuming:""},tengxunyunFormRules:{tenxunyun_appid:{required:!0,type:"string",message:"请输入AppId",trigger:"blur"},tenxunyun_secretid:{required:!0,type:"string",message:"请输入SecretId",trigger:"blur"},tenxunyun_secretkey:{required:!0,type:"string",message:"请输入SecretKey",trigger:"blur"},tenxunyun_bucket:{required:!0,type:"string",message:"请输入仓库名称",trigger:"blur"},tenxunyun_region:{required:!1,type:"string",message:"请输入仓库地域",trigger:"blur"},tenxunyun_yuming:{required:!0,type:"string",message:"请输入仓库域名",trigger:"blur"}}}},created:function(){this.getFormInfo()},methods:{getFormInfo:function(){var e=this;return s()(r.a.mark(function n(){var t,i,u,s,a,l,o;return r.a.wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,e.$api.system.getOssConfig();case 2:if(t=n.sent,i=t.code,u=t.data,200===i){n.next=7;break}return n.abrupt("return");case 7:for(e.open_oss=u.open_oss,a=0,l=(s=["baseForm","qiniuyunForm","aliyunForm","tengxunyunForm"]).length;a<l;a++)for(o in e[s[a]])e[s[a]][o]=u[o];case 10:case"end":return n.stop()}},n,e)}))()},submitForm:function(e){var n=this,t=["baseForm"];"baseForm"!==e&&t.push(e);for(var i=!0,r=0,u=t.length;r<u;r++)this.$refs[t[r]].validate(function(e){if(!e)return i=!1,!1});if(i){var s=this[e];s.open_oss=this.open_oss,this.$api.system.updateOssConfig({oss_config:s}).then(function(e){200===e.code&&n.$message.success(n.$t("tips.successSub"))})}}}},l={render:function(){var e=this,n=e.$createElement,t=e._self._c||n;return t("div",{staticClass:"lb-system-upload"},[t("top-nav"),e._v(" "),t("div",{staticClass:"page-main"},[t("el-form",{ref:"baseForm",attrs:{"label-width":"130px",model:e.baseForm,rules:e.baseFormRules},nativeOn:{submit:function(e){e.preventDefault()}}},[t("el-form-item",{attrs:{required:"",label:"请选择上传类型"}},[t("el-select",{attrs:{placeholder:"请选择"},model:{value:e.open_oss,callback:function(n){e.open_oss=n},expression:"open_oss"}},e._l(e.options,function(e){return t("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})}),1)],1),e._v(" "),0===e.open_oss?t("el-form-item",[t("lb-button",{directives:[{name:"preventReClick",rawName:"v-preventReClick"}],attrs:{type:"primary"},on:{click:function(n){return e.submitForm("baseForm")}}},[e._v(e._s(e.$t("action.submit")))])],1):e._e()],1),e._v(" "),t("el-form",{directives:[{name:"show",rawName:"v-show",value:2=