You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 lines
36 KiB
1 lines
36 KiB
(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-0e89abdc","chunk-756f9686"],{"0b65":function(t,e,r){"use strict";e.a={shortcuts:[{text:"今天",value:function(){var t=new Date,e=new Date;return e.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate())),[e,t]}},{text:"昨天",value:function(){var t=new Date,e=new Date;return e.setTime(e.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate()-1))),t.setTime(t.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate()-1))),[e,t]}},{text:"最近7天",value:function(){var t=new Date,e=new Date;return e.setTime(e.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate()-6))),[e,t]}},{text:"最近30天",value:function(){var t=new Date,e=new Date;return e.setTime(e.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate()-29))),[e,t]}},{text:"上月",value:function(){var t=new Date,e=new Date,r=new Date(e.getFullYear(),e.getMonth(),0).getDate();return e.setTime(e.setTime(new Date((new Date).getFullYear(),(new Date).getMonth()-1,1))),t.setTime(t.setTime(new Date((new Date).getFullYear(),(new Date).getMonth()-1,r))),[e,t]}},{text:"本月",value:function(){var t=new Date,e=new Date;return e.setTime(e.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),1))),[e,t]}},{text:"本年",value:function(){var t=new Date,e=new Date;return e.setTime(e.setTime(new Date((new Date).getFullYear(),0,1))),[e,t]}}]}},"0fc4":function(t,e,r){"use strict";r.d(e,"a",(function(){return a})),r.d(e,"c",(function(){return o})),r.d(e,"b",(function(){return i}));var n=r("b6bd");function a(){return Object(n.a)({url:"erp/config",method:"get"})}function o(t){return Object(n.a)({url:"store/erp/shop",method:"get",params:t})}function i(t){return Object(n.a)({url:"product/import_erp_product",method:"post",data:t})}},"1a0e":function(t,e,r){},6112:function(t,e,r){"use strict";r.r(e);var n=r("f478");function a(t){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function o(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function i(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=a(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=a(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==a(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var s={name:"rightConfig",components:function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?o(Object(r),!0).forEach((function(e){i(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):o(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({},r("2542").a),props:{name:{type:null,default:""},pageId:{type:Number,default:0}},computed:{defultArr:function(){this.$store.dispatch("admin/user/getPageName");var t=this.$store.state.admin.user.pageName;return this.$store.state.admin[t].component}},watch:{name:{handler:function(t,e){this.rCom=[];var r=this.$store.state.admin.user.pageName;if(this.configData=this.$store.state.admin[r].defaultConfig[t],this.rCom=this.$store.state.admin[r].component[t].list,this.configData.selectConfig){var n=this.configData.selectConfig.type?this.configData.selectConfig.type:"";this.configData.selectConfig.list=this.categoryList,n?this.getByCategory():this.getCategory()}},deep:!0},defultArr:{handler:function(t,e){this.rCom=[],this.objToArray(t),this.rCom=t[this.name].list},deep:!0}},data:function(){return{rCom:[],configData:{},isShow:!0,categoryList:[],status:0}},mounted:function(){this.storeStatus()},methods:{storeStatus:function(){var t=this;Object(n.y)().then((function(e){t.status=parseInt(e.data.store_status)}))},getCategory:function(){var t=this;Object(n.h)().then((function(e){var r=[];e.data.map((function(t){r.push({title:t.title,pid:t.pid,activeValue:t.id.toString()})})),t.categoryList=r,t.bus.$emit("upData",r)}))},getByCategory:function(){var t=this;Object(n.g)().then((function(e){var r=[];e.data.map((function(t){r.push({title:t.cate_name,pid:t.pid,activeValue:t.id.toString()})})),t.categoryList=r,t.bus.$emit("upData",r)}))},saveConfig:function(){var t=this,e=this.$store.state.admin.user.pageName,r=this.$store.state.admin[e].defaultConfig,a=this.$store.state.admin[e].periphery;if("z_tabBar"==this.name){if(!a||!this.status)for(var o=r.z_tabBar.tabBarList.list,i=0;i<o.length;i++)if("/pages/storeList/index"==o[i].link||"pages/storeList/index"==o[i].link)return this.$Message.error("请先开启您的周边功能(/pages/storeList/index)");if(r.z_tabBar.tabBarList.list.length<2)return this.$Message.error("您最少应添加2个导航")}Object(n.e)(this.pageId,{value:r}).then((function(e){t.$Message.success("保存成功")}))},objToArray:function(t){var e=[];for(var r in t)e.push(t[r]);return e}}},c=(r("8760"),r("2877")),u={name:"index",components:{rightConfig:Object(c.a)(s,(function(){var t=this,e=t._self._c;return t.rCom.length?e("div",{staticClass:"right-box"},[e("div",{staticClass:"title-bar"},[t._v("模块配置")]),t.rCom.length?e("div",{staticClass:"mobile-config"},[t._l(t.rCom,(function(r,n){return e("div",{key:n},[e(r.components.name,{tag:"component",attrs:{name:r.configNme,configData:t.configData}})],1)})),t.rCom.length?e("div",{staticStyle:{"text-align":"center"}},[e("Button",{staticStyle:{width:"100%",margin:"0 auto",height:"40px"},attrs:{type:"primary"},on:{click:t.saveConfig}},[t._v("保存")])],1):t._e()],2):t._e()]):t._e()}),[],!1,null,"be68bd50",null).exports,links:r("2250").default},data:function(){return{configName:"",iframeUrl:"",setConfig:"",updataConfig:"",pageId:0}},created:function(){var t=this,e=this.$route.query.id,r=this.$route.query.name;this.setConfig="admin/"+r+"/setConfig",this.updataConfig="admin/"+r+"/updataConfig",this.pageId=parseInt(e),this.iframeUrl="".concat(location.origin,"?type=iframeMakkMinkkJuan"),Object(n.c)(parseInt(e)).then((function(e){var r=e.data.info.value;t.upData(r)}))},mounted:function(){window.addEventListener("message",this.handleMessage,!1)},methods:{handleMessage:function(t){t.data.name&&(this.configName=t.data.name,this.add(t.data.name))},add:function(t){this.$store.commit(this.setConfig,t)},upData:function(t){this.$store.commit(this.updataConfig,t)}}},d=(r("959b"),Object(c.a)(u,(function(){var t=this._self._c;return t("div",[t("div",{staticClass:"i-layout-page-header"},[t("PageHeader",{staticClass:"product_tabs",attrs:{"hidden-breadcrumb":""}},[t("div",{attrs:{slot:"title"},slot:"title"},[t("router-link",{attrs:{to:{path:"".concat(this.roterPre,"/setting/pages/devise")}}},[t("Button",{staticClass:"mr20",attrs:{icon:"ios-arrow-back",size:"small"}},[this._v("返回")])],1),t("span",{staticClass:"mr20",domProps:{textContent:this._s("页面设计")}})],1)])],1),t("Card",{staticClass:"ivu-mt",attrs:{bordered:!1,"dis-hover":""}},[t("div",{staticClass:"flex-wrapper"},[t("iframe",{ref:"iframe",staticClass:"iframe-box",attrs:{src:this.iframeUrl,frameborder:"0"}}),t("div",[t("div",{staticClass:"content"},[t("rightConfig",{attrs:{name:this.configName,pageId:this.pageId}})],1)]),t("links")],1)])],1)}),[],!1,null,"43a57755",null));e.default=d.exports},"66e0":function(t,e,r){},"73f5":function(t,e,r){"use strict";r.d(e,"D",(function(){return a})),r.d(e,"u",(function(){return o})),r.d(e,"q",(function(){return i})),r.d(e,"t",(function(){return s})),r.d(e,"v",(function(){return c})),r.d(e,"x",(function(){return u})),r.d(e,"j",(function(){return d})),r.d(e,"i",(function(){return f})),r.d(e,"U",(function(){return l})),r.d(e,"h",(function(){return p})),r.d(e,"z",(function(){return h})),r.d(e,"y",(function(){return m})),r.d(e,"A",(function(){return g})),r.d(e,"w",(function(){return v})),r.d(e,"m",(function(){return y})),r.d(e,"B",(function(){return b})),r.d(e,"s",(function(){return _})),r.d(e,"L",(function(){return w})),r.d(e,"M",(function(){return O})),r.d(e,"J",(function(){return D})),r.d(e,"K",(function(){return j})),r.d(e,"g",(function(){return k})),r.d(e,"G",(function(){return x})),r.d(e,"H",(function(){return C})),r.d(e,"I",(function(){return L})),r.d(e,"T",(function(){return $})),r.d(e,"O",(function(){return I})),r.d(e,"N",(function(){return S})),r.d(e,"e",(function(){return F})),r.d(e,"S",(function(){return M})),r.d(e,"o",(function(){return T})),r.d(e,"P",(function(){return E})),r.d(e,"Q",(function(){return P})),r.d(e,"R",(function(){return N})),r.d(e,"n",(function(){return B})),r.d(e,"r",(function(){return z})),r.d(e,"E",(function(){return G})),r.d(e,"p",(function(){return A})),r.d(e,"C",(function(){return R})),r.d(e,"f",(function(){return W})),r.d(e,"F",(function(){return Y})),r.d(e,"b",(function(){return V})),r.d(e,"d",(function(){return q})),r.d(e,"c",(function(){return U})),r.d(e,"a",(function(){return J})),r.d(e,"k",(function(){return H})),r.d(e,"l",(function(){return K}));var n=r("b6bd");function a(t){return Object(n.a)({url:"merchant/store_list",method:"get",params:t})}function o(t){return Object(n.a)({url:"store/order/list",method:"get",params:t})}function i(t){return Object(n.a)({url:"store/order/chart",method:"get",params:t})}function s(t){return Object(n.a)({url:"store/order/header",method:"get"})}function c(t){return Object(n.a)({url:"store/recharge",method:"get",params:t})}function u(t){return Object(n.a)({url:"store/vip_order",method:"get",params:t})}function d(t){return Object(n.a)({url:"store/order/edit/".concat(t),method:"get"})}function f(t){return Object(n.a)({url:"store/order/distribution/".concat(t),method:"get"})}function l(t){return Object(n.a)({url:"store/order/write_update/".concat(t),method:"put"})}function p(t){return Object(n.a)({url:"store/order/info/".concat(t),method:"get"})}function h(t){return Object(n.a)({url:"order/remark/".concat(t.id),method:"put",data:t.remark})}function m(t){return Object(n.a)({url:"store/recharge/remark/".concat(t.id),method:"put",data:t.remark})}function g(t){return Object(n.a)({url:"store/vip/remark/".concat(t.id),method:"put",data:t.remark})}function v(t){return Object(n.a)({url:"store/refund/list",method:"get",params:t})}function y(t){return Object(n.a)({url:"/order/no_refund/".concat(t),method:"get"})}function b(t){return Object(n.a)({url:"/order/refund_integral/".concat(t),method:"get"})}function _(t,e){return Object(n.a)({url:"store/order/export/".concat(e),method:"post",data:t})}function w(t){return Object(n.a)({url:"store/finance_flow/list",method:"get",params:t})}function O(t,e){return Object(n.a)({url:"store/finance_flow/mark/".concat(t),method:"put",params:e})}function D(t){return Object(n.a)({url:"store/finance_flow/fund_record",method:"get",params:t})}function j(t){return Object(n.a)({url:"store/finance_flow/fund_record_info",method:"get",params:t})}function k(t){return Object(n.a)({url:"/export/storeFinanceRecord",method:"get",params:t})}function x(t){return Object(n.a)({url:"/store/extract/list",method:"get",params:t})}function C(t,e){return Object(n.a)({url:"store/extract/mark/".concat(t),method:"post",data:e})}function L(t,e){return Object(n.a)({url:"store/extract/verify/".concat(t),method:"post",data:e})}function $(t){return Object(n.a)({url:"store/extract/transfer/".concat(t),method:"get"})}function I(t){return Object(n.a)({url:"store/store",method:"get",params:t})}function S(t){return Object(n.a)({url:"store/store/get_info/".concat(t),method:"get"})}function F(t){return Object(n.a)({url:"city",method:"get",params:t})}function M(t,e){return Object(n.a)({url:"store/store/".concat(t),method:"post",data:e})}function T(){return Object(n.a)({url:"store/store/address",method:"get"})}function E(t){return Object(n.a)({url:"store/store/login/".concat(t),method:"get"})}function P(t,e){return Object(n.a)({url:"store/store/set_show/".concat(t,"/").concat(e),method:"put"})}function N(t){return Object(n.a)({url:"store/share/order",method:"post",params:t})}function B(t){return Object(n.a)({url:"store/home/header",method:"get",params:t})}function z(t){return Object(n.a)({url:"store/home/orderChart",method:"get",params:t})}function G(t){return Object(n.a)({url:"store/home/store",method:"get",params:t})}function A(t){return Object(n.a)({url:"store/home/operate",method:"get",params:t})}function R(t){return Object(n.a)({url:"store/store/reset_admin/".concat(t),method:"get"})}function W(t,e,r){return Object(n.a)({url:"export/storeFlowExport?store_id=".concat(t,"&keyword=").concat(e,"&data=").concat(r),method:"get"})}function Y(t){return Object(n.a)({url:"/store/category",params:t,method:"get"})}function V(t){return Object(n.a)({url:"/store/category/create/".concat(t),method:"get"})}function q(t){return Object(n.a)({url:"/store/category/tree/".concat(t),method:"get"})}function U(t){return Object(n.a)({url:"/store/category/set_show/".concat(t.id,"/").concat(t.is_show),method:"PUT"})}function J(t){return Object(n.a)({url:"store/category/cascader_list/".concat(t),method:"get"})}function H(t){return Object(n.a)({url:"/store/refund/detail/".concat(t),method:"get"})}function K(t){return Object(n.a)({url:"/store/refund/refund/".concat(t),method:"get"})}},8760:function(t,e,r){"use strict";r("1a0e")},"959b":function(t,e,r){"use strict";r("e72d")},afd1:function(t,e,r){"use strict";r.r(e);var n=r("2f62"),a=(r("f8b7"),r("73f5")),o=r("0fc4"),i=r("31b4"),s=r("fc48"),c=r("61f8"),u=r("417c"),d=r("0b65");function f(t){return(f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function l(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */l=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,a=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",s=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function d(t,e,r,n){var o=e&&e.prototype instanceof b?e:b,i=Object.create(o.prototype),s=new F(n||[]);return a(i,"_invoke",{value:L(t,r,s)}),i}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=d;var h="suspendedStart",m="suspendedYield",g="executing",v="completed",y={};function b(){}function _(){}function w(){}var O={};u(O,i,(function(){return this}));var D=Object.getPrototypeOf,j=D&&D(D(M([])));j&&j!==r&&n.call(j,i)&&(O=j);var k=w.prototype=b.prototype=Object.create(O);function x(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function C(t,e){function r(a,o,i,s){var c=p(t[a],t,o);if("throw"!==c.type){var u=c.arg,d=u.value;return d&&"object"==f(d)&&n.call(d,"__await")?e.resolve(d.__await).then((function(t){r("next",t,i,s)}),(function(t){r("throw",t,i,s)})):e.resolve(d).then((function(t){u.value=t,i(u)}),(function(t){return r("throw",t,i,s)}))}s(c.arg)}var o;a(this,"_invoke",{value:function(t,n){function a(){return new e((function(e,a){r(t,n,e,a)}))}return o=o?o.then(a,a):a()}})}function L(e,r,n){var a=h;return function(o,i){if(a===g)throw Error("Generator is already running");if(a===v){if("throw"===o)throw i;return{value:t,done:!0}}for(n.method=o,n.arg=i;;){var s=n.delegate;if(s){var c=$(s,n);if(c){if(c===y)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(a===h)throw a=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);a=g;var u=p(e,r,n);if("normal"===u.type){if(a=n.done?v:m,u.arg===y)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(a=v,n.method="throw",n.arg=u.arg)}}}function $(e,r){var n=r.method,a=e.iterator[n];if(a===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,$(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),y;var o=p(a,e.iterator,r.arg);if("throw"===o.type)return r.method="throw",r.arg=o.arg,r.delegate=null,y;var i=o.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,y):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y)}function I(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 S(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function F(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(I,this),this.reset(!0)}function M(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var a=-1,o=function r(){for(;++a<e.length;)if(n.call(e,a))return r.value=e[a],r.done=!1,r;return r.value=t,r.done=!0,r};return o.next=o}}throw new TypeError(f(e)+" is not iterable")}return _.prototype=w,a(k,"constructor",{value:w,configurable:!0}),a(w,"constructor",{value:_,configurable:!0}),_.displayName=u(w,c,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===_||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,w):(t.__proto__=w,u(t,c,"GeneratorFunction")),t.prototype=Object.create(k),t},e.awrap=function(t){return{__await:t}},x(C.prototype),u(C.prototype,s,(function(){return this})),e.AsyncIterator=C,e.async=function(t,r,n,a,o){void 0===o&&(o=Promise);var i=new C(d(t,r,n,a),o);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},x(k),u(k,c,"Generator"),u(k,i,(function(){return this})),u(k,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=M,F.prototype={constructor:F,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(S),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function a(n,a){return s.type="throw",s.arg=e,r.next=n,a&&(r.method="next",r.arg=t),!!a}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],s=i.completion;if("root"===i.tryLoc)return a("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return a(i.catchLoc,!0);if(this.prev<i.finallyLoc)return a(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return a(i.catchLoc,!0)}else{if(!u)throw Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return a(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=e&&e<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=t,i.arg=e,o?(this.method="next",this.next=o.finallyLoc,y):this.complete(i)},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),y},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),S(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var a=n.arg;S(r)}return a}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:M(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y}},e}function p(t,e,r,n,a,o,i){try{var s=t[o](i),c=s.value}catch(t){return void r(t)}s.done?e(c):Promise.resolve(c).then(n,a)}function h(t){return function(){var e=this,r=arguments;return new Promise((function(n,a){var o=t.apply(e,r);function i(t){p(o,n,a,i,s,"next",t)}function s(t){p(o,n,a,i,s,"throw",t)}i(void 0)}))}}function m(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function g(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?m(Object(r),!0).forEach((function(e){v(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):m(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function v(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=f(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=f(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==f(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var y={components:{editFrom:i.a,detailsFrom:s.a,orderRemark:c.a,orderRecord:u.a},data:function(){return{openErp:!1,thead:[{title:"订单号",align:"center",slot:"order_id",minWidth:150},{title:"用户信息",slot:"nickname",minWidth:130},{title:"商品信息",slot:"info",minWidth:300},{title:"实际支付",key:"pay_price",minWidth:70},{title:"发起退款时间",key:"add_time",minWidth:110},{title:"门店名称",key:"store_name",minWidth:80},{title:"退款状态",slot:"refund_type",minWidth:100},{title:"退款信息",slot:"statusName",minWidth:100},{title:"售后备注",key:"remark",minWidth:130},{title:"操作",slot:"action",fixed:"right",minWidth:150,align:"center"}],tbody:[],num:[],orderDatalist:null,loading:!1,FromData:null,total:0,orderId:0,animal:1,pagination:{page:1,limit:15,order_id:"",time:"",refund_type:0,store_id:""},options:d.a,timeVal:[],modal:!1,qrcode:null,name:"",spin:!1,rowActive:{},supplierList:[]}},computed:g(g({},Object(n.e)("order",["orderChartType"])),{},{labelWidth:function(){return this.isMobile?void 0:96},labelPosition:function(){return this.isMobile?"top":"right"}}),created:function(){this.getErpConfig(),this.getOrderList(),this.getStaffList()},methods:{getStaffList:function(){var t=this;Object(a.D)().then(function(){var e=h(l().mark((function e(r){return l().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.supplierList=r.data;case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){t.$Message.error(e.msg)}))},reset:function(){this.pagination={page:1,limit:15,order_id:"",time:"",refund_type:0,store_id:""},this.timeVal=[],this.getOrderList()},getErpConfig:function(){var t=this;Object(o.a)().then((function(e){t.openErp=e.data.open_erp})).catch((function(e){t.$Message.error(e.msg)}))},onchangeCode:function(t){this.animal=t,this.qrcodeShow()},onchangeTime:function(t){this.pagination.page=1,this.timeVal=t,this.pagination.time=this.timeVal[0]?this.timeVal.join("-"):"",this.getOrderList()},getData:function(t,e){var r=this;Object(a.k)(t).then(function(){var t=h(l().mark((function t(n){return l().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e||(r.$refs.detailss.modals=!0),r.$refs.detailss.activeName="detail",r.orderDatalist=n.data;case 3:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){r.$Message.error(t.msg)}))},changeMenu:function(t,e){var r=this;switch(this.orderId=t.id,e){case"1":this.delfromData={title:"修改立即支付",url:"/supplier/order/pay_offline/".concat(t.id),method:"post",ids:""},this.$modalSure(this.delfromData).then((function(t){r.$Message.success(t.msg),r.getOrderList()})).catch((function(t){r.$Message.error(t.msg)}));break;case"2":this.rowActive=t,this.getData(t.id);break;case"3":this.$refs.record.modals=!0,this.$refs.record.getList(t.store_order_id);break;case"4":this.$refs.remarks.modals=!0,this.$refs.remarks.formValidate.remark=t.remark;break;case"5":this.getRefundData(t.id,t.refund_type);break;case"55":this.getRefundGoodsData(t.id,t.refund_type);break;case"6":this.getRefundIntegral(t.id);break;case"7":this.getNoRefundData(t.id);break;case"8":this.delfromData={title:"修改确认收货",url:"/supplier/order/take/".concat(t.id),method:"put",ids:""},this.$modalSure(this.delfromData).then((function(t){r.$Message.success(t.msg),r.getOrderList()})).catch((function(t){r.$Message.error(t.msg)}));break;case"10":this.delfromData={title:"立即打印订单",info:"您确认打印此订单吗?",url:"/supplier/order/print/".concat(t.id),method:"get",ids:""},this.$modalSure(this.delfromData).then((function(t){r.$Message.success(t.msg),r.$emit("changeGetTabs"),r.getOrderList()})).catch((function(t){r.$Message.error(t.msg)}));break;case"11":this.delfromData={title:"立即打印电子面单",info:"您确认打印此电子面单吗?",url:"/supplier/order/order_dump/".concat(t.id),method:"get",ids:""},this.$modalSure(this.delfromData).then((function(t){r.$Message.success(t.msg),r.getOrderList()})).catch((function(t){r.$Message.error(t.msg)}));break;default:this.delfromData={title:"删除订单",url:"/supplier/order/del/".concat(t.id),method:"DELETE",ids:""},this.delOrder(t,this.delfromData)}},getRefundData:function(t,e){var r=this;2==e?(this.delfromData={title:"是否立即退货",url:"/store/refund/agree/".concat(t),method:"get"},this.$modalSure(this.delfromData).then((function(t){r.$Message.success(t.msg),r.getOrderList(),r.getData(r.orderId,1)})).catch((function(t){r.$Message.error(t.msg)}))):this.$modalForm(Object(a.l)(t)).then((function(){r.getOrderList(),r.getData(r.orderId,1),r.$emit("changeGetTabs")}))},getRefundGoodsData:function(t){var e=this;this.delfromData={title:"是否立即退货",url:"/store/refund/agree/".concat(t),method:"get"},this.$modalSure(this.delfromData).then((function(t){e.$Message.success(t.msg),e.getOrderList(),e.getData(e.orderId,1)})).catch((function(t){e.$Message.error(t.msg)}))},getRefundIntegral:function(t){var e=this;Object(a.B)(t).then(function(){var t=h(l().mark((function t(r){return l().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e.FromData=r.data,e.$refs.edits.modals=!0;case 2:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){e.$Message.error(t.msg)}))},delOrder:function(t,e){var r=this;1===t.is_del?this.$modalSure(e).then((function(t){r.$Message.success(t.msg),r.getOrderList()})).catch((function(t){r.$Message.error(t.msg)})):this.$Modal.error({title:"错误!",content:"<p>您选择的的订单存在用户未删除的订单,无法删除用户未删除的订单!</p>"})},submitFail:function(){this.getOrderList(),this.getData(this.orderId,1)},selectChange2:function(t){this.pagination.page=1,this.pagination.refund_type=t,this.getOrderList(t)},getNoRefundData:function(t){var e=this;this.$modalForm(Object(a.m)(t)).then((function(){e.getOrderList(),e.getData(e.orderId),e.$emit("changeGetTabs")}))},getOrderList:function(){var t=this;this.loading=!0,Object(a.w)(this.pagination).then((function(e){t.loading=!1;var r=e.data,n=r.count,a=r.list,o=r.num;t.total=n,t.tbody=a,t.num=o,a.forEach((function(e){e.id==t.orderId&&(t.rowActive=e)}))})).catch((function(e){t.loading=!1,t.$Message.error(e.msg)}))},pageChange:function(t){this.pagination.page=t,this.getOrderList()},nameSearch:function(){this.pagination.page=1,this.getOrderList()},orderSearch:function(){this.pagination.page=1,this.getOrderList()},delivery:function(t){var e=this;getDistribution(t.id).then(function(){var t=h(l().mark((function t(r){return l().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e.FromData=r.data,e.$refs.edits.modals=!0;case 2:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){e.$Message.error(t.msg)}))}}},b=(r("e38b"),r("2877")),_=Object(b.a)(y,(function(){var t=this,e=t._self._c;return e("div",[e("Card",{staticClass:"ivu-mt",attrs:{bordered:!1,"dis-hover":"",padding:0}},[e("div",{staticClass:"new_card_pd"},[e("Form",{ref:"pagination",attrs:{inline:"",model:t.pagination,"label-width":t.labelWidth,"label-position":t.labelPosition},nativeOn:{submit:function(t){t.preventDefault()}}},[e("FormItem",{attrs:{label:"退款时间:"}},[e("DatePicker",{staticClass:"input-add",attrs:{editable:!1,value:t.timeVal,format:"yyyy/MM/dd",type:"daterange",placement:"bottom-start",placeholder:"自定义时间",options:t.options},on:{"on-change":t.onchangeTime}})],1),e("FormItem",{attrs:{label:"门店:",prop:"supplier"}},[e("Select",{staticClass:"input-add",attrs:{clearable:"",filterable:"",placeholder:"请选择门店"},on:{"on-change":t.getOrderList},model:{value:t.pagination.store_id,callback:function(e){t.$set(t.pagination,"store_id",e)},expression:"pagination.store_id"}},t._l(t.supplierList,(function(r,n){return e("Option",{key:n,attrs:{value:r.id}},[t._v(t._s(r.name))])})),1)],1),e("FormItem",{attrs:{label:"订单状态:"}},[e("Select",{staticClass:"input-add",on:{"on-change":t.getOrderList},model:{value:t.pagination.refund_type,callback:function(e){t.$set(t.pagination,"refund_type",e)},expression:"pagination.refund_type"}},t._l(t.num,(function(r,n){return e("Option",{key:n,attrs:{value:n}},[t._v(t._s(r.name))])})),1)],1),e("FormItem",{attrs:{label:"订单搜索:","label-for":"title"}},[e("Input",{staticClass:"input-add mr14",attrs:{placeholder:"请输入订单号"},model:{value:t.pagination.order_id,callback:function(e){t.$set(t.pagination,"order_id",e)},expression:"pagination.order_id"}}),e("Button",{attrs:{type:"primary"},on:{click:function(e){return t.getOrderList()}}},[t._v("查询")]),e("Button",{staticClass:"btn",on:{click:function(e){return t.reset()}}},[t._v("重置")])],1)],1)],1)]),e("Card",{staticClass:"ivu-mt",attrs:{bordered:!1,"dis-hover":""}},[e("Table",{ref:"table",attrs:{columns:t.thead,data:t.tbody,loading:t.loading,"highlight-row":"","no-userFrom-text":"暂无数据","no-filtered-userFrom-text":"暂无筛选结果"},scopedSlots:t._u([{key:"order_id",fn:function(r){var n=r.row;return[e("span",{staticStyle:{display:"block"},domProps:{textContent:t._s(n.order_id)}}),e("span",{directives:[{name:"show",rawName:"v-show",value:1===n.is_del&&null==n.delete_time,expression:"row.is_del === 1 && row.delete_time == null"}],staticClass:"span-del"},[t._v("用户已删除")])]}},{key:"nickname",fn:function(r){var n=r.row;return[e("div",[t._v("\n "+t._s(n.nickname)),null!=n.delete_time?e("span",{staticStyle:{color:"#ed4014"}},[t._v("\n (已注销)")]):t._e()])]}},{key:"user",fn:function(r){var n=r.row;return[e("div",[t._v("用户名:"+t._s(n.nickname))]),e("div",[t._v("用户ID:"+t._s(n.uid))])]}},{key:"refund_type",fn:function(r){var n=r.row;return[0==n.refund_type&&1==n.apply_type?e("Tag",{attrs:{color:"blue",size:"medium"}},[t._v("仅退款")]):t._e(),0==n.refund_type&&2==n.apply_type?e("Tag",{attrs:{color:"blue",size:"medium"}},[t._v("退货退款")]):t._e(),3==n.refund_type?e("Tag",{attrs:{color:"red",size:"medium"}},[t._v("拒绝退款")]):t._e(),4==n.refund_type?e("Tag",{attrs:{color:"blue",size:"medium"}},[t._v("商品待退货")]):t._e(),5==n.refund_type?e("Tag",{attrs:{color:"blue",size:"medium"}},[t._v("退货待收货")]):t._e(),6==n.refund_type?e("Tag",{attrs:{color:"green",size:"medium"}},[t._v("已退款")]):t._e()]}},{key:"info",fn:function(r){var n=r.row;return[e("Tooltip",{attrs:{theme:"dark","max-width":"300",delay:600}},[t._l(n._info,(function(r,n){return e("div",{key:n,staticClass:"tabBox"},[e("div",{directives:[{name:"viewer",rawName:"v-viewer"}],staticClass:"tabBox_img"},[e("img",{directives:[{name:"lazy",rawName:"v-lazy",value:r.cart_info.productInfo.attrInfo?r.cart_info.productInfo.attrInfo.image:r.cart_info.productInfo.image,expression:"\n val.cart_info.productInfo.attrInfo\n ? val.cart_info.productInfo.attrInfo.image\n : val.cart_info.productInfo.image\n "}]})]),e("span",{staticClass:"tabBox_tit line1"},[r.cart_info.is_gift?e("span",{staticClass:"font-color-red"},[t._v("赠品")]):t._e(),t._v("\n "+t._s(r.cart_info.productInfo.store_name+" | ")+t._s(r.cart_info.productInfo.attrInfo?r.cart_info.productInfo.attrInfo.suk:"")+"\n ")])])})),e("div",{attrs:{slot:"content"},slot:"content"},t._l(n._info,(function(r,n){return e("div",{key:n},[r.cart_info.is_gift?e("p",{staticClass:"font-color-red"},[t._v("赠品")]):t._e(),e("p",[t._v(t._s(r.cart_info.productInfo.store_name))]),e("p",[t._v(t._s(r.cart_info.productInfo.attrInfo?r.cart_info.productInfo.attrInfo.suk:""))]),e("p",{staticClass:"tabBox_pice"},[t._v(t._s("¥"+r.cart_info.truePrice+" x "+r.cart_info.cart_num))])])})),0)],2)]}},{key:"statusName",fn:function(r){var n=r.row;return[e("Tooltip",{attrs:{theme:"dark","max-width":"300",delay:600}},[e("div",{staticClass:"pt5",domProps:{innerHTML:t._s(n.refund_reason)}}),e("div",{attrs:{slot:"content"},slot:"content"},[e("div",{staticClass:"pt5"},[t._v("退款原因:"+t._s(n.refund_explain))]),n.refund_goods_explain?e("div",{staticClass:"pt5"},[t._v("\n 退货原因:"+t._s(n.refund_goods_explain)+"\n ")]):t._e()])]),n.refund_img?e("div",{staticClass:"pictrue-box"},t._l(n.refund_img||[],(function(t,r){return e("div",{directives:[{name:"viewer",rawName:"v-viewer"}],key:r},[e("img",{directives:[{name:"lazy",rawName:"v-lazy",value:t,expression:"item"}],staticClass:"pictrue mr10",attrs:{src:t}})])})),0):t._e()]}},{key:"action",fn:function(r){var n=r.row;return[e("a",{directives:[{name:"show",rawName:"v-show",value:(1==n.apply_type||5==n.refund_type||4==n.refund_type&&3==n.apply_type)&&![3,6].includes(n.refund_type)&&(parseFloat(n.pay_price)>parseFloat(n.refunded_price)||0==n.pay_price),expression:"\n (row.apply_type == 1 || row.refund_type == 5 || (row.refund_type == 4 && row.apply_type == 3)) &&\n ![3, 6].includes(row.refund_type) &&\n (parseFloat(row.pay_price) > parseFloat(row.refunded_price) || row.pay_price == 0)\n "}],attrs:{disabled:t.openErp},on:{click:function(e){return t.changeMenu(n,"5")}}},[t._v("立即退款")]),e("Divider",{directives:[{name:"show",rawName:"v-show",value:(1==n.apply_type||5==n.refund_type||4==n.refund_type&&3==n.apply_type)&&![3,6].includes(n.refund_type)&&(parseFloat(n.pay_price)>parseFloat(n.refunded_price)||0==n.pay_price),expression:"\n (row.apply_type == 1 || row.refund_type == 5 || (row.refund_type == 4 && row.apply_type == 3)) &&\n ![3, 6].includes(row.refund_type) &&\n (parseFloat(row.pay_price) > parseFloat(row.refunded_price) || row.pay_price == 0)\n "}],attrs:{type:"vertical"}}),e("a",{directives:[{name:"show",rawName:"v-show",value:[2,3].includes(n.apply_type)&&[0,1,2].includes(n.refund_type),expression:"\n [2, 3].includes(row.apply_type) && [0, 1, 2].includes(row.refund_type)"}],attrs:{disabled:t.openErp},on:{click:function(e){return t.changeMenu(n,"55")}}},[t._v("同意退货")]),e("Divider",{directives:[{name:"show",rawName:"v-show",value:[2,3].includes(n.apply_type)&&[0,1,2].includes(n.refund_type),expression:"[2, 3].includes(row.apply_type) && [0, 1, 2].includes(row.refund_type)"}],attrs:{type:"vertical"}}),e("a",{on:{click:function(e){return t.changeMenu(n,"2")}}},[t._v("订单详情")])]}}])}),e("div",{staticClass:"acea-row row-right page"},[e("Page",{attrs:{total:t.total,current:t.pagination.page,"show-elevator":"","show-total":"","page-size":t.pagination.limit},on:{"on-change":t.pageChange}})],1)],1),e("edit-from",{ref:"edits",attrs:{FromData:t.FromData},on:{submitFail:t.submitFail}}),e("details-from",{ref:"detailss",attrs:{orderDatalist:t.orderDatalist,orderId:t.orderId,rowActive:t.rowActive,openErp:t.openErp}}),e("order-remark",{ref:"remarks",attrs:{remarkType:"refund",orderId:t.orderId},on:{submitFail:t.submitFail}}),e("order-record",{ref:"record"})],1)}),[],!1,null,"6ac08e0f",null);e.default=_.exports},e38b:function(t,e,r){"use strict";r("66e0")},e72d:function(t,e,r){}}]); |