pyxis-page/dist/js/chunk-37ee6f14.73e6328b.js
2021-06-11 15:56:39 +08:00

2 lines
39 KiB
JavaScript

(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-37ee6f14"],{"31a8":function(e,t,a){"use strict";var r=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"upload-corp-container"},[a("div",{staticClass:"source"},[a("div",[a("div",{staticClass:"avatar-uploader"},[a("div",{staticClass:"el-upload el-upload--text",attrs:{tabindex:"0"}},[e.hasImg?e._e():a("i",{staticClass:"el-icon-plus avatar-uploader-icon",on:{click:e.handleClick}}),e.hasImg?a("img",{staticClass:"upload-preview-img",attrs:{alt:"",src:e.initialImgUrl},on:{click:e.showInitImg}}):e._e(),a("input",{ref:"fileinput",staticClass:"el-upload__input",attrs:{type:"file",name:"file",accept:"image/*"},on:{change:e.handleChange}}),e.hasImg?a("div",{staticClass:"action-bar"},[a("el-button",{attrs:{type:"success",size:"small",icon:"el-icon-edit"},on:{click:e.handleClick}},[e._v(" 替换 ")]),a("el-button",{attrs:{type:"danger",size:"small",icon:"el-icon-delete"},on:{click:e.removeImg}},[e._v(" 移除 ")])],1):e._e()])])])]),a("div",{directives:[{name:"show",rawName:"v-show",value:e.show,expression:"show"}],staticClass:"vue-image-crop-upload"},[a("div",{staticClass:"vicp-wrap"},[a("div",{staticClass:"vicp-close",on:{click:e.off}},[a("i",{staticClass:"vicp-icon4"})]),2===e.step?a("div",{staticClass:"vicp-step2"},[a("div",{staticClass:"vicp-crop"},[a("div",{directives:[{name:"show",rawName:"v-show",value:!0,expression:"true"}],staticClass:"vicp-crop-left"},[a("div",{staticClass:"vicp-img-container",on:{wheel:function(t){return t.preventDefault(),e.handleMouseWheel(t)}}},[a("img",{ref:"img",staticClass:"vicp-img",style:e.sourceImgStyle,attrs:{src:e.sourceImgUrl,draggable:"false",alt:""},on:{drag:e.preventDefault,dragstart:e.preventDefault,dragend:e.preventDefault,dragleave:e.preventDefault,dragover:e.preventDefault,dragenter:e.preventDefault,drop:e.preventDefault,touchstart:e.imgStartMove,touchmove:e.imgMove,touchend:e.createImg,touchcancel:e.createImg,mousedown:e.imgStartMove,mousemove:e.imgMove,mouseup:e.createImg,mouseout:e.createImg}}),a("div",{staticClass:"vicp-img-shade vicp-img-shade-1",style:e.sourceImgShadeStyle}),a("div",{staticClass:"vicp-img-shade vicp-img-shade-2",style:e.sourceImgShadeStyle})]),a("div",{staticClass:"vicp-range"},[a("input",{directives:[{name:"model",rawName:"v-model",value:e.scale.range,expression:"scale.range"}],attrs:{type:"range",step:"1",min:"0",max:"100"},domProps:{value:e.scale.range},on:{mousemove:e.zoomChange,__r:function(t){return e.$set(e.scale,"range",t.target.value)}}}),a("i",{staticClass:"vicp-icon5",on:{mousedown:e.startZoomSub,mouseout:e.endZoomSub,mouseup:e.endZoomSub}}),a("i",{staticClass:"vicp-icon6",on:{mousedown:e.startZoomAdd,mouseout:e.endZoomAdd,mouseup:e.endZoomAdd}})]),e.noRotate?e._e():a("div",{staticClass:"vicp-rotate"},[a("i",{on:{click:e.rotateImg}},[e._v("↻")])])]),a("div",{directives:[{name:"show",rawName:"v-show",value:!0,expression:"true"}],staticClass:"vicp-crop-right"},[a("div",{staticClass:"vicp-preview"},[e.noSquare?e._e():a("div",{staticClass:"vicp-preview-item"},[a("img",{style:e.previewStyle,attrs:{src:e.createImgUrl}}),a("span",[e._v("预览")])]),e.noCircle?e._e():a("div",{staticClass:"vicp-preview-item vicp-preview-item-circle"},[a("img",{style:e.previewStyle,attrs:{src:e.createImgUrl}}),a("span",[e._v("预览")])])])])]),a("div",{staticClass:"vicp-operate"},[a("el-button",{attrs:{type:"warning",size:"small",icon:"el-icon-edit"},on:{click:e.off}},[e._v(" 取消 ")]),a("el-button",{attrs:{type:"primary",size:"small",icon:"el-icon-success"},on:{click:e.prepareUpload}},[e._v(" 保存 ")])],1)]):e._e(),3===e.step?a("div",{staticClass:"vicp-step3"},[a("div",{staticClass:"vicp-upload"},[a("span",{directives:[{name:"show",rawName:"v-show",value:1===e.loading,expression:"loading === 1"}],staticClass:"vicp-loading"},[e._v("正在上传……")]),a("div",{staticClass:"vicp-progress-wrap"},[a("span",{directives:[{name:"show",rawName:"v-show",value:1===e.loading,expression:"loading === 1"}],staticClass:"vicp-progress",style:e.progressStyle})]),a("div",{directives:[{name:"show",rawName:"v-show",value:2===e.loading,expression:"loading === 2"}],staticClass:"vicp-success"},[a("i",{staticClass:"vicp-icon3"}),e._v(" 上传成功 ")])]),a("div",{staticClass:"vicp-operate"},[a("a",{on:{click:function(t){return e.setStep(2)},mousedown:e.ripple}},[e._v("返回")]),a("a",{on:{click:e.off,mousedown:e.ripple}},[e._v("关闭")])])]):e._e(),a("canvas",{directives:[{name:"show",rawName:"v-show",value:!1,expression:"false"}],ref:"canvas",attrs:{width:e.width,height:e.height}})])])])},i=[],s=a("1da1"),o=a("53ca"),n=a("d4ec"),c=a("bee2"),l=a("262e"),u=a("2caf"),p=(a("96cf"),a("c975"),a("4795"),a("b0c0"),a("4160"),a("159b"),a("b64b"),a("d3b7"),a("9ab4")),h=a("1b40"),d=(a("4ec9"),a("3ca3"),a("ddb0"),new Map([["jpg","image/jpeg"],["png","image/png"],["gif","image/gif"],["svg","image/svg+xml"],["psd","image/photoshop"]]));a("ac1f"),a("1276"),a("ace4"),a("5cc6"),a("9a8c"),a("a975"),a("735e"),a("c1ac"),a("d139"),a("3a7b"),a("d5d6"),a("82f8"),a("e91f"),a("60bd"),a("5f96"),a("3280"),a("3fcc"),a("ca91"),a("25a1"),a("cd26"),a("3c5d"),a("2954"),a("649e"),a("219c"),a("170b"),a("b39a"),a("72f7");function m(e,t){e=e.split(",")[1],e=window.atob(e);for(var a=new Uint8Array(e.length),r=0;r<e.length;r++)a[r]=e.charCodeAt(r);return new Blob([a],{type:t})}function g(e,t){var a=Object.assign({ele:e.target,type:"hit",bgc:"rgba(0, 0, 0, 0.15)"},t),r=a.ele;if(r){var i=r.getBoundingClientRect(),s=r.querySelector(".e-ripple");switch(s?s.className="e-ripple":(s=document.createElement("span"),s.className="e-ripple",s.style.height=s.style.width=Math.max(i.width,i.height)+"px",r.appendChild(s)),a.type){case"center":s.style.top=i.height/2-s.offsetHeight/2+"px",s.style.left=i.width/2-s.offsetWidth/2+"px";break;default:s.style.top=e.pageY-i.top-s.offsetHeight/2-document.body.scrollTop+"px",s.style.left=e.pageX-i.left-s.offsetWidth/2-document.body.scrollLeft+"px"}return s.style.backgroundColor=a.bgc,s.className="e-ripple z-active",!1}}var f=function(e){Object(l["a"])(a,e);var t=Object(u["a"])(a);function a(){var e;return Object(n["a"])(this,a),e=t.apply(this,arguments),e.allowImgFormat=["gif","jpg","png"],e.mime="image/png",e.show=!1,e.isSupported=!0,e.isSupportTouch=document.hasOwnProperty("ontouchstart"),e.step=1,e.loading=0,e.progress=0,e.hasError=!1,e.errorMsg="",e.ratio=1,e.sourceImg=null,e.sourceImgUrl=e.initialImgUrl,e.createImgUrl=e.initialImgUrl,e.sourceImgMouseDown={on:!1,mX:0,mY:0,x:0,y:0},e.previewContainer={width:100,height:100},e.sourceImgContainer={width:240,height:184},e.scale={zoomAddOn:!1,zoomSubOn:!1,range:1,x:0,y:0,width:0,height:0,maxWidth:0,maxHeight:0,minWidth:0,minHeight:0,naturalWidth:0,naturalHeight:0},e}return Object(c["a"])(a,[{key:"created",value:function(){var e=this.imgFormat,t=this.allowImgFormat,a=!0,r=-1===t.indexOf(e)?"jpg":e,i=d.get(r);"function"!==typeof FormData&&(a=!1),this.ratio=this.width/this.height,this.mime=i,this.isSupported=a,document.addEventListener("keyup",this.handleEscClose)}},{key:"hasImg",get:function(){return!!this.initialImgUrl}},{key:"progressStyle",get:function(){return{width:this.progress+"%"}}},{key:"sourceImgStyle",get:function(){var e=this.scale.y+this.sourceImgMasking.y+"px",t=this.scale.x+this.sourceImgMasking.x+"px";return{top:e,left:t,width:this.scale.width+"px",height:this.scale.height+"px"}}},{key:"sourceImgMasking",get:function(){var e=this.width,t=this.height,a=this.ratio,r=this.sourceImgContainer,i=r,s=i.width/i.height,o=0,n=0,c=i.width,l=i.height,u=1;return a<s&&(u=i.height/t,c=i.height*a,o=(i.width-c)/2),a>s&&(u=i.width/e,l=i.width/a,n=(i.height-l)/2),{scale:u,x:o,y:n,width:c,height:l}}},{key:"sourceImgShadeStyle",get:function(){var e=this.sourceImgMasking,t=this.sourceImgContainer,a=t,r=e,i=r.width===a.width?r.width:(a.width-r.width)/2,s=r.height===a.height?r.height:(a.height-r.height)/2;return{width:i+"px",height:s+"px"}}},{key:"previewStyle",get:function(){var e=this.ratio,t=this.previewContainer,a=t,r=a.width,i=a.height,s=r/i;return e<s&&(r=a.height*e),e>s&&(i=a.width/e),{width:r+"px",height:i+"px"}}},{key:"beforeUnmount",value:function(){document.removeEventListener("keyup",this.handleEscClose)}},{key:"mounted",value:function(){this.sourceImgUrl&&this.startCrop()}},{key:"showInitImg",value:function(){this.initialImgUrl&&(this.sourceImgUrl=this.initialImgUrl,this.startCrop())}},{key:"handleEscClose",value:function(e){!this.show||"Escape"!==e.key&&27!==e.keyCode||this.off()}},{key:"ripple",value:function(e){g(e)}},{key:"stepChange",value:function(){this.show=1!==this.step}},{key:"checkShowError",value:function(){this.hasError&&this.errorMsg&&(this.$message.error(this.errorMsg),this.hasError=!1,this.errorMsg="")}},{key:"off",value:function(){var e=this;setTimeout((function(){e.show=!1,3===e.step&&2===e.loading&&e.setStep(1)}),200)}},{key:"setStep",value:function(e){var t=this;setTimeout((function(){t.step=e}),200)}},{key:"preventDefault",value:function(e){return e.preventDefault(),!1}},{key:"handleClick",value:function(e){1!==this.loading&&e.target!==this.$refs.fileinput&&(e.preventDefault(),this.$refs.fileinput.click())}},{key:"handleChange",value:function(e){if(e.preventDefault(),1!==this.loading){var t=e.target.files||e.dataTransfer.files;this.reset(),this.checkFile(t[0])?this.setSourceImg(t[0]):this.off()}}},{key:"checkFile",value:function(e){var t=this.maxSize;return-1===e.type.indexOf("image")?(this.hasError=!0,this.errorMsg="仅限图片格式",!1):!(e.size/1024>t)||(this.hasError=!0,this.errorMsg="单文件大小不能超过 "+t+"kb",!1)}},{key:"reset",value:function(){this.loading=0,this.hasError=!1,this.errorMsg="",this.progress=0}},{key:"setSourceImg",value:function(e){this.$emit("src-file-set",e.name,e.type,e.size);var t=new FileReader,a=this;t.onload=function(e){a.sourceImgUrl=t.result+"",a.startCrop()},t.readAsDataURL(e)}},{key:"startCrop",value:function(){var e=this.width,t=this.height,a=this.ratio,r=this.scale,i=this.sourceImgUrl,s=this.sourceImgMasking,o=s,n=new Image;n.src=i,n.setAttribute("crossOrigin","Anonymous");var c=this;n.onload=function(){var i=n.naturalWidth,s=n.naturalHeight,l=i/s,u=o.width,p=o.height,h=0,d=0;if(i<e||s<t)return c.hasError=!0,c.errorMsg="图片最低像素为(宽*高):"+e+"*"+t,!1;c.show=!0,a>l&&(p=u/l,d=(o.height-p)/2),a<l&&(u=p*l,h=(o.width-u)/2),r.range=0,r.x=h,r.y=d,r.width=u,r.height=p,r.minWidth=u,r.minHeight=p,r.maxWidth=i*o.scale,r.maxHeight=s*o.scale,r.naturalWidth=i,r.naturalHeight=s,c.sourceImg=n,c.createImg(),c.setStep(2)}}},{key:"imgStartMove",value:function(e){if(e.preventDefault(),this.isSupportTouch&&!e.targetTouches)return!1;var t=e.targetTouches?e.targetTouches[0]:e,a=this.sourceImgMouseDown,r=this.scale,i=a;i.mX=t.screenX,i.mY=t.screenY,i.x=r.x,i.y=r.y,i.on=!0}},{key:"imgMove",value:function(e){if(e.preventDefault(),this.isSupportTouch&&!e.targetTouches)return!1;var t=e.targetTouches?e.targetTouches[0]:e,a=this.sourceImgMouseDown,r=a.on,i=a.mX,s=a.mY,o=a.x,n=a.y,c=this.scale,l=this.sourceImgMasking,u=l,p=t.screenX,h=t.screenY,d=p-i,m=h-s,g=o+d,f=n+m;r&&(g>0&&(g=0),f>0&&(f=0),g<u.width-c.width&&(g=u.width-c.width),f<u.height-c.height&&(f=u.height-c.height),c.x=g,c.y=f)}},{key:"rotateImg",value:function(e){var t=this.sourceImg,a=this.scale,r=a.naturalWidth,i=a.naturalHeight,s=i,o=r,n=this.$refs.canvas,c=n.getContext("2d");n.width=s,n.height=o,c.clearRect(0,0,s,o),c.fillStyle="rgba(0,0,0,0)",c.fillRect(0,0,s,o),c.translate(s,0),c.rotate(90*Math.PI/180),c.drawImage(t,0,0,r,i);var l=n.toDataURL(d.get("png"));this.sourceImgUrl=l,this.startCrop()}},{key:"handleMouseWheel",value:function(e){e=e||window.event;var t=this.scale;e.wheelDelta?(e.wheelDelta>0&&this.zoomImg(t.range>=100?100:++t.range),e.wheelDelta<0&&this.zoomImg(t.range<=0?0:--t.range)):e.detail&&(e.detail>0&&this.zoomImg(t.range>=100?100:++t.range),e.detail<0&&this.zoomImg(t.range<=0?0:--t.range))}},{key:"startZoomAdd",value:function(e){var t=this.scale,a=this;function r(){if(t.zoomAddOn){var e=t.range>=100?100:++t.range;a.zoomImg(e),setTimeout((function(){r()}),60)}}t.zoomAddOn=!0,r()}},{key:"endZoomAdd",value:function(e){this.scale.zoomAddOn=!1}},{key:"startZoomSub",value:function(e){var t=this.scale,a=this;function r(){if(t.zoomSubOn){var e=t.range<=0?0:--t.range;a.zoomImg(e),setTimeout((function(){r()}),60)}}t.zoomSubOn=!0,r()}},{key:"endZoomSub",value:function(e){var t=this.scale;t.zoomSubOn=!1}},{key:"zoomChange",value:function(e){this.zoomImg(e.target.value)}},{key:"zoomImg",value:function(e){var t=this.sourceImgMasking,a=this.scale,r=a.maxWidth,i=a.maxHeight,s=a.minWidth,o=a.minHeight,n=a.width,c=a.height,l=a.x,u=a.y,p=t,h=p.width,d=p.height,m=s+(r-s)*e/100,g=o+(i-o)*e/100,f=h/2-m/n*(h/2-l),v=d/2-g/c*(d/2-u);f>0&&(f=0),v>0&&(v=0),f<h-m&&(f=h-m),v<d-g&&(v=d-g),a.x=f,a.y=v,a.width=m,a.height=g,a.range=e;var b=this;setTimeout((function(){a.range===e&&b.createImg()}),300)}},{key:"createImg",value:function(e){var t=this.imgFormat,a=this.imgBgc,r=this.mime,i=this.sourceImg,s=this.scale,o=s.x,n=s.y,c=s.width,l=s.height,u=this.sourceImgMasking.scale,p=this.$refs.canvas,h=p.getContext("2d");e&&(this.sourceImgMouseDown.on=!1),p.width=this.width,p.height=this.height,h.clearRect(0,0,this.width,this.height),h.fillStyle="png"===t?"rgba(0,0,0,0)":a,h.fillRect(0,0,this.width,this.height),h.drawImage(i,o/u,n/u,c/u,l/u),this.createImgUrl=p.toDataURL(r)}},{key:"prepareUpload",value:function(){var e=this.url,t=this.createImgUrl,a=this.field,r=this.ki;this.$emit("crop-success",t,a,r),e?this.upload():this.off()}},{key:"requestUpload",value:function(){var e=this.imgFormat,t=this.mime,a=this.url,r=this.params,i=this.headers,s=this.field,n=this.createImgUrl,c=this.withCredentials,l=this.method,u=this,p=new FormData;return"object"===Object(o["a"])(r)&&r&&Object.keys(r).forEach((function(e){p.append(e,r[e]+"")})),p.append(s,m(n,t),s+"."+e),this.reset(),this.loading=1,this.setStep(3),new Promise((function(e,t){var r=new XMLHttpRequest;r.open(l,a,!0),r.withCredentials=c,r.onreadystatechange=function(){4===this.readyState&&(200===this.status||201===this.status||202===this.status?e(JSON.parse(this.responseText)):t&&t(this.status))},r.upload.addEventListener("progress",(function(e){e.lengthComputable&&(u.progress=100*Math.round(e.loaded)/e.total)}),!1),"object"===Object(o["a"])(i)&&i&&Object.keys(i).forEach((function(e){r.setRequestHeader(e,i[e]+"")})),r.send(p)}))}},{key:"removeImg",value:function(){var e=Object(s["a"])(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this.$confirm("确认移除该图片?","Warning",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"});case 3:this.$emit("crop-upload-success","",this.field,this.ki),e.next=8;break;case 6:e.prev=6,e.t0=e["catch"](0);case 8:case"end":return e.stop()}}),e,this,[[0,6]])})));function t(){return e.apply(this,arguments)}return t}()},{key:"upload",value:function(){var e=Object(s["a"])(regeneratorRuntime.mark((function e(){var t;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this.requestUpload();case 3:t=e.sent,this.show&&(t.errorCode?(this.loading=3,this.hasError=!0,this.errorMsg=t.errmsg,this.$emit("crop-upload-fail",this.field,this.ki)):(this.loading=2,this.$emit("crop-upload-success",t.url_cdn,this.field,this.ki))),e.next=10;break;case 7:e.prev=7,e.t0=e["catch"](0),this.show&&(this.loading=3,this.hasError=!0,this.errorMsg="图片上传失败",this.$emit("crop-upload-fail",this.field,this.ki));case 10:case"end":return e.stop()}}),e,this,[[0,7]])})));function t(){return e.apply(this,arguments)}return t}()}]),a}(h["c"]);Object(p["a"])([Object(h["b"])({default:"avatar"})],f.prototype,"field",void 0),Object(p["a"])([Object(h["b"])({default:"0"})],f.prototype,"ki",void 0),Object(p["a"])([Object(h["b"])({default:"https://opm.kingsome.cn/api/upload"})],f.prototype,"url",void 0),Object(p["a"])([Object(h["b"])({default:function(){return{sub_path:"game",type:"image"}}})],f.prototype,"params",void 0),Object(p["a"])([Object(h["b"])({default:null})],f.prototype,"headers",void 0),Object(p["a"])([Object(h["b"])({default:200})],f.prototype,"width",void 0),Object(p["a"])([Object(h["b"])({default:200})],f.prototype,"height",void 0),Object(p["a"])([Object(h["b"])({default:!0})],f.prototype,"noRotate",void 0),Object(p["a"])([Object(h["b"])({default:!0})],f.prototype,"noCircle",void 0),Object(p["a"])([Object(h["b"])({default:!1})],f.prototype,"noSquare",void 0),Object(p["a"])([Object(h["b"])({default:10240})],f.prototype,"maxSize",void 0),Object(p["a"])([Object(h["b"])({default:"png"})],f.prototype,"imgFormat",void 0),Object(p["a"])([Object(h["b"])({default:"#fff"})],f.prototype,"imgBgc",void 0),Object(p["a"])([Object(h["b"])({default:!1})],f.prototype,"withCredentials",void 0),Object(p["a"])([Object(h["b"])({default:"POST"})],f.prototype,"method",void 0),Object(p["a"])([Object(h["b"])({default:""})],f.prototype,"initialImgUrl",void 0),Object(p["a"])([Object(h["d"])("step")],f.prototype,"stepChange",null),Object(p["a"])([Object(h["d"])("hasError")],f.prototype,"checkShowError",null),f=Object(p["a"])([Object(h["a"])({name:"UploadCorpImage",model:{prop:"initialImgUrl",event:"update"}})],f);var v=f,b=v,y=(a("dd45"),a("0c7c")),w=Object(y["a"])(b,r,i,!1,null,null,null);t["a"]=w.exports},8960:function(e,t,a){"use strict";a.d(t,"a",(function(){return i})),a.d(t,"d",(function(){return s})),a.d(t,"c",(function(){return o})),a.d(t,"e",(function(){return n})),a.d(t,"b",(function(){return c}));var r=a("b32d"),i={shop:"",name:"",content:"",total:0,count:0,limitOne:1},s=function(e){return Object(r["a"])({url:"/api/coupons",method:"post",params:e})},o=function(e,t){return Object(r["a"])({url:"/api/coupon/".concat(e),method:"get",params:t})},n=function(e){return Object(r["a"])({url:"/api/coupon/save",method:"post",data:e})},c=function(e){return Object(r["a"])({url:"/api/coupon/".concat(e,"/delete"),method:"post"})}},a139:function(e,t,a){"use strict";a.r(t);var r=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"app-container"},[a("el-form",{ref:"postForm",staticClass:"form-container",attrs:{model:e.postForm,rules:e.rules,"label-width":"121px"}},[a("el-tabs",{model:{value:e.activeName,callback:function(t){e.activeName=t},expression:"activeName"}},[a("el-tab-pane",{attrs:{label:"基本信息",name:"first"}},[1===e.userLevel?a("el-form-item",{attrs:{label:e.$t("main.shop"),prop:"key"}},[a("el-select",{staticClass:"w100",attrs:{placeholder:"选择"+e.$t("main.shop"),name:"shop",required:""},model:{value:e.postForm.shop,callback:function(t){e.$set(e.postForm,"shop",t)},expression:"postForm.shop"}},e._l(e.allDepts,(function(e){return a("el-option",{key:e._id,attrs:{label:e.name,value:e._id}})})),1)],1):e._e(),a("el-form-item",{staticStyle:{"margin-bottom":"40px"},attrs:{label:"活动名称:",prop:"name"}},[a("el-input",{attrs:{placeholder:"输入活动名称",name:"name",required:""},model:{value:e.postForm.name,callback:function(t){e.$set(e.postForm,"name",t)},expression:"postForm.name"}})],1),a("el-form-item",{attrs:{label:"激活:",prop:"active"}},[a("el-switch",{attrs:{name:"active","active-color":"#13ce66","inactive-color":"#ff4949",required:""},model:{value:e.postForm.active,callback:function(t){e.$set(e.postForm,"active",t)},expression:"postForm.active"}})],1),a("el-form-item",{staticStyle:{"margin-bottom":"30px"},attrs:{prop:"desc",label:"活动简介:"}},[a("el-input",{attrs:{type:"textarea"},model:{value:e.postForm.desc,callback:function(t){e.$set(e.postForm,"desc",t)},expression:"postForm.desc"}})],1),a("el-form-item",{attrs:{prop:"icon",label:"活动icon"}},[a("upload-corp-image",{attrs:{field:"image-file",width:400,height:120,"img-format":"png"},on:{"crop-upload-success":e.iconUploadSuccess},model:{value:e.postForm.icon,callback:function(t){e.$set(e.postForm,"icon",t)},expression:"postForm.icon"}})],1),a("el-form-item",{attrs:{prop:"banner",label:"活动配图"}},[a("upload-corp-image",{attrs:{field:"image-file",width:400,height:260,"img-format":"png"},on:{"crop-upload-success":e.bannerUploadSuccess},model:{value:e.postForm.banner,callback:function(t){e.$set(e.postForm,"banner",t)},expression:"postForm.banner"}})],1),a("el-form-item",{attrs:{label:"重复类型",prop:"repeatType"}},[a("el-select",{staticClass:"w100",attrs:{placeholder:"选择",name:"repeatType",required:""},model:{value:e.postForm.repeatType,callback:function(t){e.$set(e.postForm,"repeatType",t)},expression:"postForm.repeatType"}},e._l(e.repeatTypes,(function(e){return a("el-option",{key:e.id,attrs:{label:e.label,value:e.id}})})),1)],1),9!==e.postForm.repeatType?a("el-form-item",{attrs:{label:"活动时间",prop:"beginTime"}},[a("el-select",{staticStyle:{width:"60%"},attrs:{placeholder:"选择或输入时间, 格式 09:15",name:"beginTime",required:"",multiple:"",clearable:"",filterable:"","allow-create":"","default-first-option":""},on:{change:e.timeChange},model:{value:e.selectTime,callback:function(t){e.selectTime=t},expression:"selectTime"}},e._l(e.times,(function(e){return a("el-option",{key:e,attrs:{label:e,value:e}})})),1)],1):e._e(),2===e.postForm.repeatType?a("el-form-item",{attrs:{label:"周几",prop:"weekDays"}},[a("el-select",{staticStyle:{width:"60%"},attrs:{placeholder:"选择周几",name:"weekDays",required:"",multiple:"",clearable:"","default-first-option":""},model:{value:e.postForm.weekDays,callback:function(t){e.$set(e.postForm,"weekDays",t)},expression:"postForm.weekDays"}},e._l(e.weekDays,(function(e){return a("el-option",{key:e.id,attrs:{label:e.label,value:e.id}})})),1)],1):e._e(),3===e.postForm.repeatType?a("el-form-item",{attrs:{label:"选择天",prop:"monthDays"}},[a("el-select",{staticStyle:{width:"60%"},attrs:{placeholder:"选择每月中需要运行的日子",name:"monthDays",required:"",multiple:"",clearable:"","default-first-option":""},on:{change:e.monthDaysChange},model:{value:e.postForm.monthDays,callback:function(t){e.$set(e.postForm,"monthDays",t)},expression:"postForm.monthDays"}},e._l(e.monthDays,(function(e){return a("el-option",{key:e.id,attrs:{label:e.label,value:e.id}})})),1)],1):e._e(),0===e.postForm.repeatType?a("el-form-item",{attrs:{label:"指定日期",prop:"selectDate"}},[a("el-date-picker",{staticStyle:{width:"60%"},attrs:{type:"dates",align:"right",placeholder:"选择一个或多个日期"},on:{change:e.dataChange},model:{value:e.selectDate,callback:function(t){e.selectDate=t},expression:"selectDate"}})],1):e._e(),0!==e.postForm.repeatType&&9!==e.postForm.repeatType?a("el-form-item",{attrs:{label:"开始/结束日期",prop:"dataRange"}},[a("el-date-picker",{staticStyle:{width:"40%"},attrs:{type:"daterange",align:"right","unlink-panels":"","range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期"},model:{value:e.dataRange,callback:function(t){e.dataRange=t},expression:"dataRange"}})],1):e._e(),9!==e.postForm.repeatType?a("el-form-item",{attrs:{label:"准备时间(分):",prop:"prepareTime"}},[a("el-input",{attrs:{placeholder:"提前多少时间可进游戏房间(分钟)",name:"prepareTime",required:""},model:{value:e.postForm.prepareTime,callback:function(t){e.$set(e.postForm,"prepareTime",t)},expression:"postForm.prepareTime"}})],1):e._e()],1),a("el-tab-pane",{attrs:{label:"题库设置",name:"second"}},[a("el-form-item",{attrs:{label:"题目数量:",prop:"qcount"}},[a("el-input",{attrs:{placeholder:"本次活动题目数量",name:"qcount",type:"number",required:""},model:{value:e.postForm.qcount,callback:function(t){e.$set(e.postForm,"qcount",t)},expression:"postForm.qcount"}})],1),a("el-form-item",{attrs:{label:"题库分类"}},[a("el-tree",{ref:"typeTree",attrs:{data:e.typeOptions,"show-checkbox":"",accordion:"","node-key":"id","highlight-current":"","default-checked-keys":e.typeSelected,props:e.defaultProps}})],1)],1),a("el-tab-pane",{attrs:{label:"奖励设置",name:"third"}},[a("el-button",{attrs:{type:"primary",icon:"el-icon-edit"},on:{click:e.handleCreateReward}},[e._v(" 添加 ")]),a("el-table",{attrs:{data:e.postForm.rewardInfo,border:"",fit:"","highlight-current-row":""}},[a("el-table-column",{attrs:{label:"排名",prop:"rank",formatter:e.formatRank}}),a("el-table-column",{attrs:{label:"奖励",prop:"coupon",formatter:e.formatCoupon}}),a("el-table-column",{attrs:{align:"center",width:"180",label:"操作",fixed:"right"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-button",{attrs:{type:"primary",size:"small",icon:"el-icon-edit"},on:{click:function(a){return e.handleEdit(t)}}},[e._v(" 编辑 ")]),a("el-button",{staticStyle:{"margin-left":"10px"},attrs:{type:"danger",size:"small"},on:{click:function(a){return e.deleteRank(t)}}},[e._v(" "+e._s(e.$t("permission.delete"))+" ")])]}}])})],1)],1)],1),a("el-form-item",[a("el-button",{attrs:{type:"primary"},on:{click:e.submitForm}},[e._v(" 保存 ")]),a("el-button",{on:{click:e.onCancel}},[e._v(" 取消 ")])],1)],1),a("el-dialog",{attrs:{visible:e.dialogVisible,title:"编辑奖励"},on:{"update:visible":function(t){e.dialogVisible=t}}},[a("el-form",{ref:"modalForm",attrs:{model:e.record,rules:e.modalRules,"label-width":"80px","label-position":"left"}},[a("el-form-item",{attrs:{label:"排名",prop:"rank"}},[e._v(" 第 "),a("el-input",{staticStyle:{width:"30%"},attrs:{placeholder:"排名",type:"number"},model:{value:e.record.rank,callback:function(t){e.$set(e.record,"rank",t)},expression:"record.rank"}}),e._v(" 名至 "),a("el-input",{staticStyle:{width:"30%"},attrs:{placeholder:"可不填",type:"number"},model:{value:e.record.rankEnd,callback:function(t){e.$set(e.record,"rankEnd",t)},expression:"record.rankEnd"}}),e._v(" 名 ")],1),a("el-form-item",{attrs:{label:"奖励",prop:"coupon"}},[a("el-select",{staticClass:"w100",attrs:{placeholder:"选择奖励",name:"coupon",required:""},model:{value:e.record.coupon,callback:function(t){e.$set(e.record,"coupon",t)},expression:"record.coupon"}},e._l(e.coupons,(function(e){return a("el-option",{key:e._id,attrs:{label:e.name,value:e._id}})})),1)],1),a("el-form-item",{attrs:{label:"数量",prop:"count"}},[a("el-input",{attrs:{placeholder:"数量",type:"number"},model:{value:e.record.count,callback:function(t){e.$set(e.record,"count",t)},expression:"record.count"}})],1),a("el-form-item",[a("el-button",{directives:[{name:"permission",rawName:"v-permission",value:["activity:edit"],expression:"['activity:edit']"}],attrs:{type:"primary"},on:{click:e.saveReward}},[e._v(" 保存 ")]),a("el-button",{on:{click:e.closeModal}},[e._v(" 取消 ")])],1)],1)],1)],1)},i=[],s=a("b85c"),o=a("1da1"),n=a("d4ec"),c=a("bee2"),l=a("262e"),u=a("2caf"),p=(a("0d03"),a("99af"),a("a434"),a("c975"),a("b0c0"),a("96cf"),a("9ab4")),h=a("1b40"),d=a("ac1a"),m=a("e741"),g=a("da80"),f=a("b804"),v=a("6b45"),b=a("6a04"),y=a("db85"),w=a("ef85"),k=a("d257"),x=a("63a2"),O=a("2ef0"),j=a("8960"),C=a("9dba"),F=a("31a8"),I=a("4c9b"),T=function(e){Object(l["a"])(a,e);var t=Object(u["a"])(a);function a(){var e;return Object(n["a"])(this,a),e=t.apply(this,arguments),e.validateRequire=function(t,a,r){""===a?("imageURL"===t.field?e.$message({message:"Upload cover image is required",type:"error"}):e.$message({message:t.field+" 是必填的",type:"error"}),r(new Error(t.field+" 是必填的"))):r()},e.activeName="first",e.monthDays=[],e.repeatTypes=[{id:0,label:"指定日期"},{id:1,label:"每日"},{id:2,label:"每周"},{id:3,label:"每月"},{id:9,label:"随时(一般测试用)"}],e.weekDays=[{id:0,label:"周日"},{id:1,label:"周一"},{id:2,label:"周二"},{id:3,label:"周三"},{id:4,label:"周四"},{id:5,label:"周五"},{id:6,label:"周六"}],e.dataRange=[],e.selectDate=[],e.times=[],e.selectTime=[],e.postForm=Object.assign({},w["a"]),e.loading=!1,e.allDepts=[],e.typeOptions=[],e.typeSelected=[],e.defaultProps={children:"children",label:"label"},e.rules={name:[{validator:e.validateRequire}]},e.dialogType="new",e.record={type:0},e.dialogVisible=!1,e.modalRules={rank:[{required:!0,message:"请输入排名",trigger:"blur"}]},e.coupons=[],e}return Object(c["a"])(a,[{key:"userLevel",get:function(){return C["a"].level}},{key:"lang",get:function(){return d["a"].language}},{key:"created",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(){var t,a,r=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.initTimes(),a=null===(t=this.$route.params)||void 0===t?void 0:t.id,e.next=4,this.getRemoteCategory();case 4:if(!a){e.next=7;break}return e.next=7,this.fetchData(a);case 7:if(1!==C["a"].level){e.next=13;break}return e.next=10,this.getRemoteDeptList();case 10:I["k"].$on(I["j"],(function(){r.getRemoteDeptList()})),e.next=16;break;case 13:return this.postForm.shop=C["a"].department,e.next=16,this.fetchMyShop();case 16:this.tempTagView=Object.assign({},this.$route),I["k"].$on(I["c"],(function(){r.postForm.shop&&r.getCouponList(r.postForm.shop)}));case 18:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"beforeDestory",value:function(){I["k"].$off(I["c"]),1===C["a"].level&&I["k"].$off(I["j"])}},{key:"fetchData",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(t){var a,r,i,o,n,c,l,u,p;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Object(w["d"])(t,{});case 3:if(a=e.sent,r=a.data,console.log(r),this.postForm=r,this.selectTime=[],r.beginTime){i=Object(s["a"])(r.beginTime);try{for(i.s();!(o=i.n()).done;)n=o.value,this.selectTime.push(Object(k["f"])(n,!1))}catch(h){i.e(h)}finally{i.f()}}if(this.selectDate=[],r.beginDays){c=Object(s["a"])(r.beginDays);try{for(c.s();!(l=c.n()).done;)u=l.value,this.selectDate.push(new Date(u))}catch(h){c.e(h)}finally{c.f()}}r.beginDay&&r.endDay&&(this.dataRange.push(new Date(r.beginDay)),this.dataRange.push(new Date(r.endDay))),p="zh"===this.lang?"编辑活动":"Edit Activity",this.setTagsViewTitle(p),this.setPageTitle(p),e.next=20;break;case 17:e.prev=17,e.t0=e["catch"](0),console.error(e.t0);case 20:case"end":return e.stop()}}),e,this,[[0,17]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"setTagsViewTitle",value:function(e){var t=this.tempTagView;t&&(t.title="".concat(e,"-").concat(this.postForm._id),m["a"].updateVisitedView(t))}},{key:"setPageTitle",value:function(e){document.title="".concat(e," - ").concat(this.postForm._id)}},{key:"submitForm",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(){var t,a,r,i,o,n,c,l,u;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this.$refs.postForm.validate();case 3:t=[],a=Object(s["a"])(this.selectTime);try{for(a.s();!(r=a.n()).done;)i=r.value,t.push(Object(k["g"])(i))}catch(p){a.e(p)}finally{a.f()}this.postForm.beginTime=t,this.postForm.beginDays.length=0,o=Object(s["a"])(this.selectDate);try{for(o.s();!(n=o.n()).done;)c=n.value,this.postForm.beginDays.push(c.getTime())}catch(p){o.e(p)}finally{o.f()}return this.dataRange.length>1&&(this.postForm.beginDay=this.dataRange[0].getTime(),this.postForm.endDay=this.dataRange[1].getTime()),this.postForm.qtypes=this.$refs.typeTree.getCheckedKeys(),this.loading=!0,e.next=15,Object(w["g"])(this.postForm);case 15:l=e.sent,u=l.data,this.postForm=u,this.loading=!1,this.$notify({title:"Success",message:"The post save successfully",type:"success",duration:2e3}),I["k"].$emit(I["a"],{}),e.next=27;break;case 23:return e.prev=23,e.t0=e["catch"](0),console.error("Submit Error!"),e.abrupt("return",!1);case 27:case"end":return e.stop()}}),e,this,[[0,23]])})));function t(){return e.apply(this,arguments)}return t}()},{key:"onCancel",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this.$confirm("确认不保存当前活动信息?","Warning",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"});case 3:this.$store.dispatch("delView",this.$route),this.$router.go(-1),e.next=9;break;case 7:e.prev=7,e.t0=e["catch"](0);case 9:case"end":return e.stop()}}),e,this,[[0,7]])})));function t(){return e.apply(this,arguments)}return t}()},{key:"getRemoteDeptList",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(){var t,a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,Object(y["k"])({});case 2:if(t=e.sent,a=t.data,a.records){e.next=6;break}return e.abrupt("return");case 6:this.allDepts=a.records;case 7:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"fetchMyShop",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(){var t,a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,Object(y["d"])();case 2:t=e.sent,a=t.data,this.typeSelected=a.qtypes,console.log(this.typeSelected),this.$refs.typeTree.setCheckedKeys(this.typeSelected);case 7:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"dataChange",value:function(e){console.log(this.selectDate)}},{key:"initTimes",value:function(){for(var e=0;e<24;e++)for(var t=0;t<4;t++){var a=3600*e+15*t*60,r=Object(k["f"])(a,!1);this.times.push(r)}this.monthDays.push({id:0,label:"全选"});for(var i=1;i<32;i++)this.monthDays.push({id:i,label:i+""})}},{key:"timeChange",value:function(e){if(e.length>0){var t=this.selectTime[this.selectTime.length-1];/^\d{1,2}:\d{1,2}$/.test(t)||this.selectTime.pop(),t=Object(k["f"])(Object(k["g"])(t),!1),this.selectTime.splice(this.selectTime.length-1,1,t),console.log(this.selectTime)}}},{key:"monthDaysChange",value:function(e){if(e.indexOf(0)>=0){this.postForm.monthDays.length=0;for(var t=1;t<32;t++)this.postForm.monthDays.push(t)}}},{key:"onShopChange",value:function(){var e;if(this.postForm.shop&&this.getCouponList(this.postForm.shop),(null===(e=this.postForm.qtypes)||void 0===e?void 0:e.length)>0)this.typeSelected=this.postForm.qtypes;else if(this.postForm.shop){var t,a,r=Object(s["a"])(this.allDepts);try{for(r.s();!(a=r.n()).done;){var i=a.value;if(i._id===this.postForm.shop){t=i;break}}}catch(o){r.e(o)}finally{r.f()}this.typeSelected=t?t.qtypes:[]}this.$refs.typeTree.setCheckedKeys(this.typeSelected)}},{key:"getRemoteCategory",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(){var t,a,r,i,o,n,c,l,u;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,Object(x["d"])();case 2:t=e.sent,a=t.data,r=Object(s["a"])(a);try{for(r.s();!(i=r.n()).done;){o=i.value,n=[],c=Object(s["a"])(o.children);try{for(c.s();!(l=c.n()).done;)u=l.value,n.push({id:u._id,label:u.name})}catch(p){c.e(p)}finally{c.f()}this.typeOptions.push({id:o._id,label:o.name,children:n})}}catch(p){r.e(p)}finally{r.f()}case 6:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"getCouponList",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(t){var a,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,Object(j["d"])({shop:t});case 2:a=e.sent,r=a.data,this.coupons=r.records;case 5:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"formatCoupon",value:function(e,t,a,r){var i,o="未知(".concat(a,")"),n=this.postForm.rewardInfo[r],c=Object(s["a"])(this.coupons);try{for(c.s();!(i=c.n()).done;){var l=i.value;if(l._id===a){o=l.name;break}}}catch(u){c.e(u)}finally{c.f()}return"".concat(o," x ").concat(n.count)}},{key:"formatRank",value:function(e,t,a,r){var i=this.postForm.rewardInfo[r],s="第 ".concat(i.rank," 名");return i.rankEnd&&(s="第 ".concat(i.rank," 至 ").concat(i.rankEnd," 名")),s}},{key:"deleteRank",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(t){var a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return a=t.$index,e.prev=1,e.next=4,this.$confirm("Confirm to remove the record?","Warning",{confirmButtonText:"Confirm",cancelButtonText:"Cancel",type:"warning"});case 4:this.postForm.rewardInfo.splice(a,1),this.$message({type:"success",message:"删除成功, 请点击保存"}),e.next=10;break;case 8:e.prev=8,e.t0=e["catch"](1);case 10:case"end":return e.stop()}}),e,this,[[1,8]])})));function t(t){return e.apply(this,arguments)}return t}()},{key:"handleCreateReward",value:function(){this.record=Object.assign({},w["b"]),this.record.id=this.postForm.rewardInfo.length,this.dialogType="new",this.dialogVisible=!0}},{key:"handleEdit",value:function(e){this.dialogType="edit",this.dialogVisible=!0,this.record=Object(O["cloneDeep"])(e.row)}},{key:"closeModal",value:function(){this.dialogVisible=!1,this.$refs.modalForm.clearValidate()}},{key:"saveReward",value:function(){var e=this,t="edit"===this.dialogType;this.$refs.modalForm.validate(function(){var a=Object(o["a"])(regeneratorRuntime.mark((function a(r){var i;return regeneratorRuntime.wrap((function(a){while(1)switch(a.prev=a.next){case 0:if(r){a.next=3;break}return e.$message.error("请按要求填写表单"),a.abrupt("return",!1);case 3:if(!t){a.next=14;break}i=0;case 5:if(!(i<e.postForm.rewardInfo.length)){a.next=12;break}if(e.postForm.rewardInfo[i].id!==e.record.id){a.next=9;break}return e.postForm.rewardInfo.splice(i,1,Object.assign({},e.record)),a.abrupt("break",12);case 9:i++,a.next=5;break;case 12:a.next=15;break;case 14:e.postForm.rewardInfo.push(e.record);case 15:e.dialogVisible=!1,e.$notify({title:"Success",dangerouslyUseHTMLString:!0,message:"\n 奖励成功保存, 请点击保存\n ",type:"success"});case 17:case"end":return a.stop()}}),a)})));return function(e){return a.apply(this,arguments)}}())}},{key:"iconUploadSuccess",value:function(e){console.log("upload icon success: "+e),this.postForm.icon=e,this.$forceUpdate()}},{key:"bannerUploadSuccess",value:function(e){console.log("upload banner success: "+e),this.postForm.banner=e,this.$forceUpdate()}}]),a}(h["c"]);Object(p["a"])([Object(h["d"])("postForm.shop")],T.prototype,"onShopChange",null),T=Object(p["a"])([Object(h["a"])({name:"ActivityEditor",components:{MaterialInput:g["a"],Sticky:f["a"],UploadImage:v["a"],RegionPicker:b["a"],UploadCorpImage:F["a"]}})],T);var D=T,S=D,R=a("0c7c"),_=Object(R["a"])(S,r,i,!1,null,"9340e522",null);t["default"]=_.exports},a575:function(e,t,a){},dd45:function(e,t,a){"use strict";a("a575")},ef85:function(e,t,a){"use strict";a.d(t,"b",(function(){return i})),a.d(t,"a",(function(){return s})),a.d(t,"e",(function(){return o})),a.d(t,"d",(function(){return n})),a.d(t,"g",(function(){return c})),a.d(t,"c",(function(){return l})),a.d(t,"f",(function(){return u}));var r=a("b32d"),i={count:1,type:0,rewardType:0},s={beginDays:[],active:!1,beginTime:[],monthDays:[],weekDays:[],name:"",prepareTime:0,qcount:0,qtypes:[],repeatType:0,shop:"",rewardInfo:[]},o=function(e){return Object(r["a"])({url:"/api/activitys",method:"post",params:e})},n=function(e,t){return Object(r["a"])({url:"/api/activity/".concat(e),method:"get",params:t})},c=function(e){return Object(r["a"])({url:"/api/activity/save",method:"post",data:e})},l=function(e){return Object(r["a"])({url:"/api/activity/".concat(e,"/delete"),method:"post"})},u=function(e){return Object(r["a"])({url:"/api/activity/publish",method:"post",data:e})}}}]);
//# sourceMappingURL=chunk-37ee6f14.73e6328b.js.map