chunk-509abf9b.24daa6da.js 3.1 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-509abf9b","chunk-2d207803"],{3610:function(e,t,o){},"657d":function(e,t,o){"use strict";o("3610")},a196:function(e,t,o){"use strict";o.r(t),o.d(t,"chooseImgMixin",(function(){return i}));var i={data:function(){return{currentFiled:"",imgVisible:!1}},methods:{handleImg:function(e){this.currentFiled=e,this.imgVisible=!0},imgConfirm:function(e){this.form[this.currentFiled]=e.imageList[e.imageList.length-1].url,this.imgVisible=!1}}}},d23a:function(e,t,o){"use strict";o.r(t);var i=o("7a23"),n=Object(i["withScopeId"])("data-v-1911d4ec");Object(i["pushScopeId"])("data-v-1911d4ec");var a={class:"ele-body"};Object(i["popScopeId"])();var r=n((function(e,t,o,r,l,s){var c=Object(i["resolveComponent"])("a-input"),d=Object(i["resolveComponent"])("a-form-item"),m=Object(i["resolveComponent"])("a-form"),u=Object(i["resolveComponent"])("imageSelector"),b=Object(i["resolveComponent"])("a-modal");return Object(i["openBlock"])(),Object(i["createBlock"])(b,{"wrap-class-name":"ele-modal-movable ele-modal-resizable ele-modal-resizable",visible:l.modalShow,closable:"",keyboard:"",title:l.form.id?"编辑":"新增",width:600,onCancel:t[3]||(t[3]=function(e){return l.modalShow=!1}),onOk:s.submit,confirmLoading:l.loading,bodyStyle:l.modalBodyStyle},{default:n((function(){return[Object(i["createVNode"])("div",a,[Object(i["createVNode"])(m,{ref:"form",model:l.form,rules:l.rules,style:{"max-width":"800px",margin:"0 auto"},"label-col":{md:{span:6},sm:{span:24}},"wrapper-col":{md:{span:18},sm:{span:24}}},{default:n((function(){return[Object(i["createVNode"])(d,{label:"分类名称:",name:"title"},{default:n((function(){return[Object(i["createVNode"])(c,{value:l.form.title,"onUpdate:value":t[1]||(t[1]=function(e){return l.form.title=e}),placeholder:"请填写分类名称","allow-clear":""},null,8,["value"])]})),_:1})]})),_:1},8,["model","rules"])]),Object(i["createVNode"])(u,{onConfirm:e.imgConfirm,visible:e.imgVisible,"onUpdate:visible":t[2]||(t[2]=function(t){return e.imgVisible=t})},null,8,["onConfirm","visible"])]})),_:1},8,["visible","title","onOk","confirmLoading","bodyStyle"])})),l=(o("a9e3"),o("d3b7"),o("9e53")),s=o("a196"),c={mixins:[s["chooseImgMixin"]],components:{imageSelector:l["a"]},name:"addEdit",data:function(){return{modalShow:!1,loading:!1,agentOptions:[],modalBodyStyle:{maxHeight:"68vh",overflowY:"auto"},form:{},rules:{title:[{required:!0,message:"请输入标题",trigger:"blur"}],image:[{required:!0,message:"请选择图片",trigger:"blur"}]}}},methods:{openDetail:function(e){if(e){var t=Object.assign({},e);t.bili=Number(t.bili),this.form=t}else this.form={title:"",pic:""};this.modalShow=!0},submit:function(){var e=this;this.$refs.form.validate().then((function(){e.loading=!0;var t=Object.assign({},e.form),o="";o=t.id?"/manager/shopCate/edit":"/manager/shopCate/add",e.$post(o,t).then((function(){e.$message.success("操作成功!"),e.$emit("reload"),e.modalShow=!1}))})).finally((function(){e.loading=!1}))}}},d=(o("657d"),o("6b0d")),m=o.n(d);const u=m()(c,[["render",r],["__scopeId","data-v-1911d4ec"]]);t["default"]=u}}]);