| 1 |
- (window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-374f12d2"],{"2ec3":function(t,e,n){},"31b4":function(t,e,n){"use strict";var r=n("f3f3"),i=n("9860"),a=(i=n.n(i),n("6b6c")),o=n("2f62");i={name:"edit",components:{formCreate:i.a.$form()},computed:Object(r.a)({},Object(o.d)("userLevel",["taskId","levelId"])),props:{FromData:{type:Object,default:null},update:{type:Boolean,default:!0}},data:function(){return{modals:!1,type:0,loading:!1,config:{global:{upload:{props:{onSuccess:function(t,e){200===t.status?e.url=t.data.src:this.Message.error(t.msg)}}}}}}},methods:{couponsType:function(){this.$parent.addType(this.type)},onSubmit:function(t){var e=this;this.loading||(this.loading=!0,Object(a.a)({url:this.FromData.action,method:this.FromData.method,data:t}).then((function(t){e.update&&e.$parent.getList(),e.$Message.success(t.msg),e.modals=!1,setTimeout((function(){e.$emit("submitFail"),e.loading=!1}),1e3)})).catch((function(t){e.loading=!1,e.$Message.error(t.msg)})))},cancel:function(){this.type=0}}},n("9646"),r=n("2877"),o=Object(r.a)(i,(function(){var t=this,e=t.$createElement;e=t._self._c||e;return t.FromData?e("div",[e("Modal",{attrs:{scrollable:"","footer-hide":"",closable:"",title:t.FromData.title,"z-index":1,width:"700"},on:{"on-cancel":t.cancel},model:{value:t.modals,callback:function(e){t.modals=e},expression:"modals"}},[["/marketing/coupon/save.html"===t.FromData.action?e("div",{staticClass:"radio acea-row row-middle"},[e("div",{staticClass:"name ivu-form-item-content"},[t._v("优惠券类型")]),e("Radio-group",{on:{"on-change":t.couponsType},model:{value:t.type,callback:function(e){t.type=e},expression:"type"}},[e("Radio",{attrs:{label:0}},[t._v("通用券")]),e("Radio",{attrs:{label:1}},[t._v("品类券")]),e("Radio",{attrs:{label:2}},[t._v("商品券")])],1)],1):t._e()],e("form-create",{ref:"fc",staticClass:"formBox",attrs:{option:t.config,rule:Array.from(t.FromData.rules),handleIcon:"false"},on:{submit:t.onSubmit}})],2)],1):t._e()}),[],!1,null,"5cc97a38",null);e.a=o.exports},"713f":function(t,e,n){t.exports=n.p+"system_static/img/bluesgin.032bae4b.png"},"89c2":function(t,e,n){t.exports=n.p+"system_static/img/oragesgin.00077d3a.png"},"90be":function(t,e,n){t.exports=n.p+"system_static/img/redsgin.d8b0c12e.png"},9162:function(t,e,n){},"943f":function(t,e,n){t.exports=n.p+"system_static/img/pinksgin.0e1c51b4.png"},9646:function(t,e,n){"use strict";var r=n("2ec3");n.n(r).a},bceb:function(t,e,n){t.exports=n.p+"system_static/img/greesgin.43ae54b5.png"},d152:function(t,e,n){"use strict";n.r(e),n("a4d3"),n("e01a"),n("d3b7"),n("d28b"),n("3ca3"),n("ddb0"),n("b636"),n("944a"),n("0c47"),n("23dc"),n("3410"),n("d9e2"),n("159b"),n("131a"),n("fb6a");var r=n("0122"),i=n("c964"),a=n("f3f3"),o=(n("ac1f"),n("5319"),n("b0c0"),n("e9c4"),n("a069")),s=n("d708"),c=n("f478"),u=n("2f62"),l=n("31b4"),d=(n("c4c8"),n("8593")),f=n("7af3");function h(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */h=function(){return t};var t={},e=Object.prototype,n=e.hasOwnProperty,i=Object.defineProperty||function(t,e,n){t[e]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",s=a.asyncIterator||"@@asyncIterator",c=a.toStringTag||"@@toStringTag";function u(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(e){u=function(t,e,n){return t[e]=n}}function l(t,e,n,r){var a,o,s,c;e=e&&e.prototype instanceof g?e:g,e=Object.create(e.prototype),r=new L(r||[]);return i(e,"_invoke",{value:(a=t,o=n,s=r,c="suspendedStart",function(t,e){if("executing"===c)throw new Error("Generator is already running");if("completed"===c){if("throw"===t)throw e;return E()}for(s.method=t,s.arg=e;;){var n=s.delegate;if(n&&(n=function t(e,n){var r=n.method,i=e.iterator[r];return void 0===i?(n.delegate=null,"throw"===r&&e.iterator.return&&(n.method="return",n.arg=void 0,t(e,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),f):(r=d(i,e.iterator,n.arg),"throw"===r.type?(n.method="throw",n.arg=r.arg,n.delegate=null,f):(i=r.arg,i?i.done?(n[e.resultName]=i.value,n.next=e.nextLoc,"return"!==n.method&&(n.method="next",n.arg=void 0),n.delegate=null,f):i:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,f)))}(n,s),n)){if(n===f)continue;return n}if("next"===s.method)s.sent=s._sent=s.arg;else if("throw"===s.method){if("suspendedStart"===c)throw c="completed",s.arg;s.dispatchException(s.arg)}else"return"===s.method&&s.abrupt("return",s.arg);if(c="executing",n=d(a,o,s),"normal"===n.type){if(c=s.done?"completed":"suspendedYield",n.arg===f)continue;return{value:n.arg,done:s.done}}"throw"===n.type&&(c="completed",s.method="throw",s.arg=n.arg)}})}),e}function d(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}t.wrap=l;var f={};function g(){}function p(){}function m(){}a={};var v=(u(a,o,(function(){return this})),Object.getPrototypeOf),b=(v=v&&v(v(O([]))),v&&v!==e&&n.call(v,o)&&(a=v),m.prototype=g.prototype=Object.create(a));function y(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function _(t,e){var a;i(this,"_invoke",{value:function(i,o){function s(){return new e((function(a,s){!function i(a,o,s,c){var u;a=d(t[a],t,o);if("throw"!==a.type)return(o=(u=a.arg).value)&&"object"==Object(r.a)(o)&&n.call(o,"__await")?e.resolve(o.__await).then((function(t){i("next",t,s,c)}),(function(t){i("throw",t,s,c)})):e.resolve(o).then((function(t){u.value=t,s(u)}),(function(t){return i("throw",t,s,c)}));c(a.arg)}(i,o,a,s)}))}return a=a?a.then(s,s):s()}})}function w(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function x(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function L(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(w,this),this.reset(!0)}function O(t){if(t){var e,r=t[o];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length))return e=-1,(r=function r(){for(;++e<t.length;)if(n.call(t,e))return r.value=t[e],r.done=!1,r;return r.value=void 0,r.done=!0,r}).next=r}return{next:E}}function E(){return{value:void 0,done:!0}}return i(b,"constructor",{value:p.prototype=m,configurable:!0}),i(m,"constructor",{value:p,configurable:!0}),p.displayName=u(m,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){return t="function"==typeof t&&t.constructor,!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,u(t,c,"GeneratorFunction")),t.prototype=Object.create(b),t},t.awrap=function(t){return{__await:t}},y(_.prototype),u(_.prototype,s,(function(){return this})),t.AsyncIterator=_,t.async=function(e,n,r,i,a){void 0===a&&(a=Promise);var o=new _(l(e,n,r,i),a);return t.isGeneratorFunction(n)?o:o.next().then((function(t){return t.done?t.value:o.next()}))},y(b),u(b,c,"Generator"),u(b,o,(function(){return this})),u(b,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e,n=Object(t),r=[];for(e in n)r.push(e);return r.reverse(),function t(){for(;r.length;){var e=r.pop();if(e in n)return t.value=e,t.done=!1,t}return t.done=!0,t}},t.values=O,L.prototype={constructor:L,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(x),!t)for(var e in this)"t"===e.charAt(0)&&n.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(n,r){return o.type="throw",o.arg=t,e.next=n,r&&(e.method="next",e.arg=void 0),!!r}for(var i=this.tryEntries.length-1;0<=i;--i){var a=this.tryEntries[i],o=a.completion;if("root"===a.tryLoc)return r("end");if(a.tryLoc<=this.prev){var s=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(s&&c){if(this.prev<a.catchLoc)return r(a.catchLoc,!0);if(this.prev<a.finallyLoc)return r(a.finallyLoc)}else if(s){if(this.prev<a.catchLoc)return r(a.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return r(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;0<=r;--r){var i=this.tryEntries[r];if(i.tryLoc<=this.prev&&n.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var a=i;break}}var o=(a=a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc?null:a)?a.completion:{};return o.type=t,o.arg=e,a?(this.method="next",this.next=a.finallyLoc,f):this.complete(o)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;0<=e;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),x(n),f}},catch:function(t){for(var e=this.tryEntries.length-1;0<=e;--e){var n,r,i=this.tryEntries[e];if(i.tryLoc===t)return"throw"===(n=i.completion).type&&(r=n.arg,x(i)),r}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:O(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},t}n("c276"),l={name:"list",components:{editFrom:l.a,linkaddress:f.a,WangEditor:o.a},computed:Object(a.a)({bgcolors:function(){return{"--color-theme":this.bgCol}},labelWidth:function(){return this.isMobile?void 0:120},labelPosition:function(){return this.isMobile?"top":"right"}},Object(u.d)("admin/layout",["menuCollapse"])),data:function(){return{formValidate:{content:""},ruleValidate:{},myConfig:{autoHeightEnabled:!1,initialFrameHeight:500,initialFrameWidth:"100%",UEDITOR_HOME_URL:"/UEditor/",serverUrl:""},a:0,guide:0,bgimg:0,columns1:[],bgCol:"",name:"sign_day_num",grid:{xl:7,lg:7,md:12,sm:24,xs:24},loading:!1,sginList:[],progress:0,swiperOption:{pagination:{el:".swiper-pagination"},navigation:{nextEl:".swiper-button-next",prevEl:".swiper-button-prev"},autoplay:{delay:2e3,disableOnInteraction:!1},loop:!1},url:"",BaseURL:s.a.apiBaseURL.replace(/adminapi/,""),pageId:55,theme3:"light",tabList:[],upload_type:"",uploadData:{},lastObj:{add_time:"",comment:"",gid:"",id:"",img:"",link:"",sort:"",status:1},isChoice:"单选",modalPic:!1,gridPic:{xl:6,lg:8,md:12,sm:12,xs:12},gridBtn:{xl:4,lg:8,md:8,sm:8,xs:8},groupAll:[],activeIndex:0,sortName:null,activeIndexs:0,cmsList:[],loadingExist:!1,formItem:{time:"",type:"pic",status:1,value:[],video_link:""},fileUrl:s.a.apiBaseURL+"/file/upload",cardUrl:s.a.apiBaseURL+"/file/upload/1",header:{},type:0,upload:{videoIng:!1}}},created:function(){this.color(),this.info(),this.guide=0,this.a=0,this.url="",this.getListHeader()},mounted:function(){},methods:{color:function(){var t=this;Object(c.h)("color_change").then((function(e){switch(e.data.status){case 1:t.bgCol="#3875EA",t.bgimg=1;break;case 2:t.bgCol="#00C050",t.bgimg=2;break;case 3:t.bgCol="#E93323",t.bgimg=3;break;case 4:t.bgCol="#FF448F",t.bgimg=4;break;case 5:t.bgCol="#FE5C2D",t.bgimg=5}}))},groupAdd:function(){var t=this;this.$modalForm(Object(d.F)({gid:this.pageId,config_name:this.name},"setting/group_data/create")).then((function(){t.url=t.BaseURL+"pages/users/user_sgin/index",t.info()}))},info:function(){var t=this;Object(d.I)({config_name:this.name},"setting/group_data").then(function(){var e=Object(i.a)(h().mark((function e(n){return h().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.tabList=n.data,t.cmsList=n.data.list;case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){t.loading=!1,t.$Message.error(e.msg)}))},addBox:function(){var t;0==this.tabList.list.length?(this.tabList.list.push(this.lastObj),this.lastObj={add_time:"",comment:"",gid:"",id:"",img:"",link:"",sort:"",status:1}):5==this.tabList.list.length?this.$Message.warning("最多添加五张呦"):(t=JSON.parse(JSON.stringify(this.lastObj)),this.tabList.list.push(t))},save:function(){var t=this;1==this.a?this.onsubmit("formValidate"):2==this.guide?(this.formItem.value=this.tabList.list,Object(d.N)(this.formItem).then((function(e){t.$Message.success(e.msg)}))):(this.loadingExist=!0,Object(d.M)({gid:this.pageId,config_name:this.name,data:this.tabList.list}).then((function(e){t.loadingExist=!1,t.$Message.success(e.msg)})).catch((function(e){t.loadingExist=!1,t.$Message.error(e.msg)})))},getListHeader:function(){var t=this;this.loading=!0,Object(d.H)({config_name:this.name},"setting/sign_data/header").then((function(e){e=e.data.header,t.columns1=e,t.loading=!1})).catch((function(e){t.loading=!1,t.$Message.error(e.msg)}))},edit:function(t){var e=this;this.$modalForm(Object(d.G)({gid:this.pageId,config_name:this.name},"setting/group_data/"+t.id+"/edit")).then((function(){e.info(),e.url=e.BaseURL+"pages/users/user_sgin/index"}))},del:function(t,e,n){var r=this;e={title:e,num:n,url:"setting/group_data/"+t.id,method:"DELETE",ids:""};this.$modalSure(e).then((function(t){r.info(),r.$Message.success(t.msg)})).catch((function(t){r.$Message.error(t.msg)}))},onchangeIsShow:function(t){var e=this;Object(d.J)("setting/group_data/set_status/"+t.id+"/"+t.status).then(function(){var t=Object(i.a)(h().mark((function t(n){return h().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e.url=e.BaseURL+"/pages/users/user_sgin/index",e.$Message.success(n.msg),e.info();case 3:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){e.url=e.BaseURL+"/pages/users/user_sgin/index",e.$Message.error(t.msg)}))},getGroupAll:function(){var t=this;Object(d.E)().then(function(){var e=Object(i.a)(h().mark((function e(n){return h().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.groupAll=n.data,t.sortName=n.data[0].config_name,t.pageId=n.data[0].id;case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){t.$Message.error(e.msg)}))},onsubmit:function(t){var e=this;this.$refs[t].validate((function(t){if(!t)return!1;Object(d.Z)(e.formValidate).then(function(){var t=Object(i.a)(h().mark((function t(n){return h().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e.$Message.success(n.msg);case 1:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){e.$Message.error(t.msg)}))}))}}},n("df31"),f=n("2877"),o=Object(f.a)(l,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{style:t.bgcolors},[r("div",{staticClass:"i-layout-page-header header-title"},[r("span",{staticClass:"ivu-page-header-title"},[t._v(t._s(t.$route.meta.title))])]),r("div",{staticClass:"box-wrapper"},["sign_day_num"==t.name?r("div",{staticClass:"iframe",attrs:{bordered:!1}},[r("div",{staticClass:"iframe-box"},[1==t.bgimg?r("img",{attrs:{src:n("713f")}}):t._e(),2==t.bgimg?r("img",{attrs:{src:n("bceb")}}):t._e(),3==t.bgimg?r("img",{attrs:{src:n("90be")}}):t._e(),4==t.bgimg?r("img",{attrs:{src:n("943f")}}):t._e(),5==t.bgimg?r("img",{attrs:{src:n("89c2")}}):t._e()])]):t._e(),"sign_day_num"==t.name?r("div",{staticStyle:{"margin-left":"20px"}},[r("div",{staticClass:"table_box"},[r("div",{attrs:{type:"flex"}},[r("div",t._b({},"div",t.grid,!1),[r("div",{staticClass:"title"},[t._v("签到天数设置")]),r("Button",{staticStyle:{"margin-left":"14px","margin-top":"30px"},attrs:{type:"primary",icon:"md-add"},on:{click:function(e){return t.groupAdd("添加数据")}}},[t._v("添加数据")])],1)]),r("div",{staticClass:"table"},[r("Table",{ref:"table",staticClass:"mt25",attrs:{columns:t.columns1,data:t.cmsList,loading:t.loading,"highlight-row":"","no-userFrom-text":"暂无数据","no-filtered-userFrom-text":"暂无筛选结果"},scopedSlots:t._u([{key:"status",fn:function(e){var n=e.row;return e.index,[r("i-switch",{attrs:{value:n.status,"true-value":1,"false-value":0,size:"large"},on:{"on-change":function(e){return t.onchangeIsShow(n)}},model:{value:n.status,callback:function(e){t.$set(n,"status",e)},expression:"row.status"}},[r("span",{attrs:{slot:"open"},slot:"open"},[t._v("显示")]),r("span",{attrs:{slot:"close"},slot:"close"},[t._v("隐藏")])])]}},{key:"action",fn:function(e){var n=e.row,i=e.index;return[r("a",{on:{click:function(e){return t.edit(n,"编辑")}}},[t._v("编辑")]),r("Divider",{attrs:{type:"vertical"}}),r("a",{on:{click:function(e){return t.del(n,"删除这条信息",i)}}},[t._v("删除")])]}}],null,!1,1621473426)})],1)])]):t._e()]),r("linkaddress",{ref:"linkaddres",on:{linkUrl:t.linkUrl}})],1)}),[],!1,null,"343dbbe4",null),e.default=o.exports},df31:function(t,e,n){"use strict";var r=n("9162");n.n(r).a}}]);
|