chunk-3e4bbcfe.cb92543f.js 11 KB

1
  1. (window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-3e4bbcfe"],{"4de7":function(t,e,r){},a53e:function(t,e,r){"use strict";r.r(e),r("a4d3"),r("e01a"),r("d28b"),r("3ca3"),r("ddb0"),r("b636"),r("944a"),r("0c47"),r("23dc"),r("3410"),r("d9e2"),r("131a"),r("fb6a");var n=r("0122"),i=r("c964"),o=(r("d3b7"),r("159b"),r("25f0"),r("a9e3"),r("b0c0"),r("9860")),a=(o=r.n(o),r("90e7")),c=r("6b6c");function s(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */s=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,i=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},a=o.iterator||"@@iterator",c=o.asyncIterator||"@@asyncIterator",u=o.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(e){l=function(t,e,r){return t[e]=r}}function h(t,e,r,n){var o,a,c,s;e=e&&e.prototype instanceof p?e:p,e=Object.create(e.prototype),n=new x(n||[]);return i(e,"_invoke",{value:(o=t,a=r,c=n,s="suspendedStart",function(t,e){if("executing"===s)throw new Error("Generator is already running");if("completed"===s){if("throw"===t)throw e;return S()}for(c.method=t,c.arg=e;;){var r=c.delegate;if(r&&(r=function t(e,r){var n=r.method,i=e.iterator[n];return void 0===i?(r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=void 0,t(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),d):(n=f(i,e.iterator,r.arg),"throw"===n.type?(r.method="throw",r.arg=n.arg,r.delegate=null,d):(i=n.arg,i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=void 0),r.delegate=null,d):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,d)))}(r,c),r)){if(r===d)continue;return r}if("next"===c.method)c.sent=c._sent=c.arg;else if("throw"===c.method){if("suspendedStart"===s)throw s="completed",c.arg;c.dispatchException(c.arg)}else"return"===c.method&&c.abrupt("return",c.arg);if(s="executing",r=f(o,a,c),"normal"===r.type){if(s=c.done?"completed":"suspendedYield",r.arg===d)continue;return{value:r.arg,done:c.done}}"throw"===r.type&&(s="completed",c.method="throw",c.arg=r.arg)}})}),e}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=h;var d={};function p(){}function g(){}function m(){}o={};var v=(l(o,a,(function(){return this})),Object.getPrototypeOf),y=(v=v&&v(v(k([]))),v&&v!==e&&r.call(v,a)&&(o=v),m.prototype=p.prototype=Object.create(o));function b(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function w(t,e){var o;i(this,"_invoke",{value:function(i,a){function c(){return new e((function(o,c){!function i(o,a,c,s){var u;o=f(t[o],t,a);if("throw"!==o.type)return(a=(u=o.arg).value)&&"object"==Object(n.a)(a)&&r.call(a,"__await")?e.resolve(a.__await).then((function(t){i("next",t,c,s)}),(function(t){i("throw",t,c,s)})):e.resolve(a).then((function(t){u.value=t,c(u)}),(function(t){return i("throw",t,c,s)}));s(o.arg)}(i,a,o,c)}))}return o=o?o.then(c,c):c()}})}function _(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 L(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function x(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(_,this),this.reset(!0)}function k(t){if(t){var e,n=t[a];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length))return e=-1,(n=function n(){for(;++e<t.length;)if(r.call(t,e))return n.value=t[e],n.done=!1,n;return n.value=void 0,n.done=!0,n}).next=n}return{next:S}}function S(){return{value:void 0,done:!0}}return i(y,"constructor",{value:g.prototype=m,configurable:!0}),i(m,"constructor",{value:g,configurable:!0}),g.displayName=l(m,u,"GeneratorFunction"),t.isGeneratorFunction=function(t){return t="function"==typeof t&&t.constructor,!!t&&(t===g||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,l(t,u,"GeneratorFunction")),t.prototype=Object.create(y),t},t.awrap=function(t){return{__await:t}},b(w.prototype),l(w.prototype,c,(function(){return this})),t.AsyncIterator=w,t.async=function(e,r,n,i,o){void 0===o&&(o=Promise);var a=new w(h(e,r,n,i),o);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},b(y),l(y,u,"Generator"),l(y,a,(function(){return this})),l(y,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e,r=Object(t),n=[];for(e in r)n.push(e);return n.reverse(),function t(){for(;n.length;){var e=n.pop();if(e in r)return t.value=e,t.done=!1,t}return t.done=!0,t}},t.values=k,x.prototype={constructor:x,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(L),!t)for(var e in this)"t"===e.charAt(0)&&r.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 n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var i=this.tryEntries.length-1;0<=i;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return n("end");if(o.tryLoc<=this.prev){var c=r.call(o,"catchLoc"),s=r.call(o,"finallyLoc");if(c&&s){if(this.prev<o.catchLoc)return n(o.catchLoc,!0);if(this.prev<o.finallyLoc)return n(o.finallyLoc)}else if(c){if(this.prev<o.catchLoc)return n(o.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return n(o.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;0<=n;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}var a=(o=o&&("break"===t||"continue"===t)&&o.tryLoc<=e&&e<=o.finallyLoc?null:o)?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,d):this.complete(a)},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),d},finish:function(t){for(var e=this.tryEntries.length-1;0<=e;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),L(r),d}},catch:function(t){for(var e=this.tryEntries.length-1;0<=e;--e){var r,n,i=this.tryEntries[e];if(i.tryLoc===t)return"throw"===(r=i.completion).type&&(n=r.arg,L(i)),n}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:k(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),d}},t}r("2934"),o={name:"setting_setSystem",components:{formCreate:o.a.$form()},data:function(){return{rules:[],option:{form:{labelWidth:185},submitBtn:{col:{span:3,push:3}},global:{upload:{props:{onSuccess:function(t,e){200===t.status?e.url=t.data.src:this.$Message.error(t.msg)}}},frame:{props:{closeBtn:!1,okBtn:!1}}}},spinShow:!1,FromData:null,currentTab:"",headerList:[],headerChildrenList:[],childrenId:"",title:""}},created:function(){this.getAllData()},watch:{$route:function(t,e){this.headerChildrenList=[],this.getAllData()},childrenId:function(){this.getFrom()}},methods:{childrenList:function(t){var e=this;e.headerList.forEach((function(r){r.value.toString()===e.currentTab&&(void 0===r.children?(e.childrenId=r.id,e.headerChildrenList=[]):(e.headerChildrenList=r.children,e.childrenId=r.children.length?r.children[t||0].id.toString():""))}))},getHeader:function(t){var e=this;return this.spinShow=!0,new Promise((function(r,n){var o=e.$route.params.tab_id;o={type:e.$route.params.type||0,pid:o||0};Object(a.v)(o).then(function(){var n=Object(i.a)(s().mark((function n(i){var o;return s().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:o=i.data.config_tab,e.headerList=o,e.currentTab=o[t||0].value.toString(),e.childrenList(t?1:0),r(e.currentTab),e.spinShow=!1;case 6:case"end":return n.stop()}}),n)})));return function(t){return n.apply(this,arguments)}}()).catch((function(t){e.spinShow=!1,e.$Message.error(t)}))}))},getFrom:function(){var t=this;return this.spinShow=!0,new Promise((function(e,r){var n="",o=(n="3"===t.$route.params.type?t.$route.params.tab_id:t.childrenId||t.currentTab,n={tab_id:Number(n)},"setting_logistics"===t.$route.name?"freight/config/edit_basics":"setting_distributionSet"===t.$route.name?"agent/config/edit_basics":"setting_message"===t.$route.name?"serve/sms_config/edit_basics":"setting_setSystem"===t.$route.name?"setting/config/edit_basics":"marketing/integral_config/edit_basics");Object(a.k)(n,o).then(function(){var e=Object(i.a)(s().mark((function e(r){return s().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if((t.spinShow=!1)===r.data.status)return e.abrupt("return",t.$authLapse(r.data));e.next=3;break;case 3:t.FromData=r.data,t.rules=r.data.rules,t.title=r.data.title;case 6:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){t.spinShow=!1,t.$Message.error(e.msg)}))}))},getAllData:function(){var t=this;return Object(i.a)(s().mark((function e(){return s().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if("download"===t.$route.query.from)return e.next=3,t.getHeader(2);e.next=5;break;case 3:e.next=13;break;case 5:if("3"!==t.$route.params.type)return t.childrenId="",e.next=9,t.getHeader();e.next=11;break;case 9:e.next=13;break;case 11:t.headerList=[],t.getFrom();case 13:case"end":return e.stop()}}),e)})))()},changeTab:function(){this.childrenList()},changeChildrenTab:function(t){this.childrenId=t},onSubmit:function(t){var e=this;Object(c.a)({url:this.FromData.action,method:this.FromData.method,data:t}).then((function(r){e.$Message.success(r.msg),t.site_name&&(localStorage.setItem("ADMIN_TITLE",t.site_name),e.$store.commit("setAdminTitle",t.site_name),window.document.title="".concat(t.site_name," - 系统设置"))})).catch((function(t){e.$Message.error(t.msg)}))}}},r("a54d"),r=r("2877"),r=Object(r.a)(o,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",[t.headerList.length?t._e():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:"article-manager"},[r("Card",{staticClass:"ivu-mt fromBox",attrs:{bordered:!1,"dis-hover":""}},[t.headerList.length?r("Tabs",{on:{"on-click":t.changeTab},model:{value:t.currentTab,callback:function(e){t.currentTab=e},expression:"currentTab"}},t._l(t.headerList,(function(t,e){return r("TabPane",{key:e,attrs:{icon:t.icon,label:t.label,name:t.value.toString()}})})),1):t._e(),t.headerChildrenList.length?r("Tabs",{attrs:{type:"card"},on:{"on-click":t.changeChildrenTab},model:{value:t.childrenId,callback:function(e){t.childrenId=e},expression:"childrenId"}},t._l(t.headerChildrenList,(function(t,e){return r("TabPane",{key:e,attrs:{label:t.label,name:t.id.toString()}})})),1):t._e(),0!==t.rules.length?r("form-create",{attrs:{option:t.option,rule:t.rules},on:{submit:t.onSubmit}}):t._e(),t.spinShow?r("Spin",{attrs:{size:"large",fix:""}}):t._e()],1)],1)])}),[],!1,null,"3f1fa0a4",null),e.default=r.exports},a54d:function(t,e,r){"use strict";var n=r("4de7");r.n(n).a}}]);