chunk-c6679818.c9427790.js 3.2 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-c6679818"],{"259b":function(e,t,o){},"694e":function(e,t,o){"use strict";o("259b")},"6d32":function(e,t,o){"use strict";o.r(t);var r=function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",[e.upgradeOpen?o("el-dialog",{attrs:{visible:e.upgradeOpen,title:"升级"},on:{close:e.onClose}},[o("el-row",{attrs:{gutter:15}},[o("el-form",{ref:"elForm",attrs:{model:e.formData,rules:e.rules,size:"medium","label-width":"100px"}},[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"现在版本",prop:"versionInfoOld"}},[o("el-input",{style:{width:"100%"},attrs:{placeholder:"请输入现在版本",readonly:"",disabled:!0,clearable:""},model:{value:e.formData.versionInfoOld,callback:function(t){e.$set(e.formData,"versionInfoOld",t)},expression:"formData.versionInfoOld"}})],1)],1),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"升级版本",prop:"versionInfo"}},[o("el-input",{style:{width:"100%"},attrs:{placeholder:"请输入升级版本",maxlength:64,clearable:""},model:{value:e.formData.versionInfo,callback:function(t){e.$set(e.formData,"versionInfo",t)},expression:"formData.versionInfo"}})],1)],1),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"校验码",prop:"vcode"}},[o("el-input",{style:{width:"100%"},attrs:{placeholder:"请输入校验码",clearable:""},model:{value:e.formData.vcode,callback:function(t){e.$set(e.formData,"vcode",t)},expression:"formData.vcode"}})],1)],1)],1)],1),o("div",{attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:e.close}},[e._v("取消")]),o("el-button",{attrs:{type:"primary"},on:{click:e.handleConfirm}},[e._v("确定")])],1)],1):e._e()],1)},a=[],n=o("c7eb"),l=o("1da1"),s=o("943d"),i={inheritAttrs:!1,components:{},props:{upgradeOpen:{type:Boolean,default:!1}},data:function(){return{formData:{},rules:{versionInfo:[{required:!0,message:"请输入升级版本",trigger:"blur"}],vcode:[{required:!0,message:"请输入校验码",trigger:"blur"}]},field102Action:"https://jsonplaceholder.typicode.com/posts/",field102fileList:[]}},computed:{},watch:{},created:function(){},mounted:function(){},methods:{onClose:function(){this.$emit("closeDialog")},close:function(){this.$emit("closeDialog")},handleConfirm:function(){var e=this;return Object(l["a"])(Object(n["a"])().mark((function t(){return Object(n["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:console.log(e.formData),e.$refs.elForm.validate(function(){var t=Object(l["a"])(Object(n["a"])().mark((function t(o){var r;return Object(n["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(!o){t.next=5;break}return t.next=3,Object(s["cb"])(e.formData);case 3:r=t.sent,200===r.code?(e.$emit("initList"),e.$emit("closeDialog"),e.$message.success("保存成功"),e.formData={}):(e.$message.error(r.msg),e.$emit("closeDialog"));case 5:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}());case 2:case"end":return t.stop()}}),t)})))()},field102BeforeUpload:function(e){var t=e.size/1024/1024<2;return t||this.$message.error("文件大小超过 2MB"),t}}},c=i,u=(o("694e"),o("2877")),f=Object(u["a"])(c,r,a,!1,null,null,null);t["default"]=f.exports}}]);