app.ec544b86.js 18 KB

1
  1. (window.webpackJsonp=window.webpackJsonp||[]).push([["app"],{0:function(e,n,t){t("db4d"),e.exports=t("56d7")},"091a":function(e,n,t){},"0f9a":function(e,n,t){"use strict";t.r(n),t("386d"),t("96cf");var i=t("1da1"),r=t("5daa"),a=t("5f87"),u={};window.ajaxTimeout=2e4;var c=Object(i.a)(regeneratorRuntime.mark((function e(){var n,t,c,o,s,d,f=arguments;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return c=3<f.length&&void 0!==f[3]?f[3]:{},o=4<f.length&&void 0!==f[4]?f[4]:u,s=5<f.length?f[5]:void 0,t=(n=0<f.length&&void 0!==f[0]?f[0]:"").method.toLowerCase(),d={method:t,baseURL:"",url:r.a.baseURL+n.url,data:n.data,params:c,processData:!0,timeout:window.ajaxTimeout,headers:o,onUploadProgress:s},s&&"function"==typeof s&&(d.onUploadProgress=s),axios.interceptors.request.use((function(e){return e.data.token||(e.data.token=Object(a.e)()),e}),(function(e){return Promise.reject(new Error("服务器异常,请联系管理员!"))})),axios.interceptors.response.use(function(){var e=Object(i.a)(regeneratorRuntime.mark((function e(n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",n);case 1:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}(),(function(e){return Promise.reject(e.response.data)})),e.abrupt("return",new Promise((function(e,n){axios(d).then((function(n){e(n.data)})).catch((function(e){n(e)}))})));case 12:case"end":return e.stop()}}),e)})));t={token:Object(a.e)(),name:"",introduction:"",roles:["admin"],admin:Object(a.b)()||"0",ad:Object(a.a)()?JSON.parse(Object(a.a)()):{},goodsNum:isNaN(Object(a.c)())?0:parseInt(Object(a.c)()),goodsUnit:isNaN(Object(a.d)())?0:parseInt(Object(a.d)())},n.default={namespaced:!0,state:t,mutations:{SET_ADMIN:function(e,n){e.admin=n},SET_TOKEN:function(e,n){e.token=n},SET_HAS:function(e,n){e.has=n},SET_INTRODUCTION:function(e,n){e.introduction=n},SET_NAME:function(e,n){e.name=n},SET_AVATAR:function(e,n){e.avatar=n},SET_ROLES:function(e,n){e.roles=n},SET_AD:function(e,n){e.ad=n},SET_GOODSNUM:function(e,n){e.goodsNum=n},SET_GOODSUNIT:function(e,n){e.getGoodsUnit=n}},actions:{login:function(e,n){var t=e.commit,i=n.mobile,r=n.code;return new Promise((function(e,n){var u;u={username:i.trim(),password:r.trim()},c({url:"home/login",method:"post",data:u}).then((function(n){var r;0===n.code&&(r=n.data,t("SET_TOKEN",r.token),Object(a.o)(r.token),Object(a.f)(),t("SET_AD",{}),Object(a.h)(),t("SET_GOODSNUM",""),Object(a.i)(),t("SET_GOODSUNIT",""),r=-1!=(r=i.trim()).search("TKS")?"2":-1!=r.search("TKR")?"1":"0",t("SET_ADMIN",r),Object(a.l)(r)),e(n)})).catch((function(e){n(e)}))}))},logout:function(e){var n=e.commit,t=(e.state,e.dispatch);return new Promise((function(e,i){n("SET_TOKEN",""),n("SET_ROLES",[]),Object(a.j)(),n("SET_HAS",""),Object(a.f)(),n("SET_AD",{}),Object(a.h)(),n("SET_GOODSNUM",""),Object(a.i)(),n("SET_GOODSUNIT",""),t("tagsView/delAllViews",null,{root:!0}),n("SET_ADMIN","0"),Object(a.g)(),e()}))},resetToken:function(e){var n=e.commit;return new Promise((function(e){n("SET_TOKEN",""),n("SET_ROLES",[]),n("SET_ADMIN","0"),Object(a.g)(),Object(a.j)(),e()}))},set_ad:function(e,n){var t=e.commit;return new Promise((function(e,i){var r=JSON.parse(JSON.stringify(n));Object(a.k)(r),t("SET_AD",r),e({code:0,data:{},message:"ok"})}))},set_goodsNum:function(e,n){var t=e.commit;return new Promise((function(e,i){var r=n;Object(a.m)(r),t("SET_GOODSNUM",r),e({code:0,data:{},message:"ok"})}))},set_goodsUnit:function(e,n){var t=e.commit;return new Promise((function(e,i){var r=n;Object(a.n)(r),t("SET_GOODSUNIT",r),e({code:0,data:{},message:"ok"})}))}}}},1:function(e,n){},2:function(e,n){},"56d7":function(e,n,t){"use strict";t.r(n);var i={};t.r(i),t.d(i,"toThousandFilter",(function(){return X})),t("a481"),t("456d"),t("ac6a"),t("433b");var r=t("d399"),a=(t("5a5c"),t("772a")),u=(t("9eda"),t("565f")),c=(t("c625"),t("b650")),o=(t("b342"),t("ad06")),s=(t("4391"),t("58e6")),d=(t("93b0"),t("2bdd")),f=(t("87d0"),t("e41f")),m=(t("d554"),t("ab2c")),h=(t("558f"),t("0b33")),l=(t("8990"),t("5e46")),b=(t("3ec1"),t("7744")),p=(t("2a53"),t("34e9")),w=(t("bf24"),t("44bf")),v=(t("01bb"),t("e27c")),V=(t("608d"),t("9f14")),E=(t("8e11"),t("f253")),O=(t("ef44"),t("473d")),S=(t("ec8c"),t("1125")),_=(t("d707"),t("8f80")),g=(t("47d1"),t("9ffb")),T=(t("4bc8"),t("d1e1")),j=(t("da02"),t("6b41")),D=(t("6e75"),t("343b")),I=(t("b204"),t("7d5e")),k=(t("578d"),t("ee83")),A=(t("47e2"),t("2241")),N=(t("8244"),t("dc0f")),C=(t("76aa"),t("510b")),y=(t("4071"),t("a3e2")),x=(t("9753"),t("417e")),L=(t("6370"),t("3acc")),U=(t("2591"),t("3104")),R=(t("81a6"),t("7bd9")),P=(t("a789"),t("c41f")),W=(t("1fe9"),t("d961")),G=(t("3cc4"),t("5596")),H=(t("8d12"),t("2bb1")),z=(t("7f9f"),t("efa0")),$=(t("fa08"),t("67bb")),M=(t("cadf"),t("551c"),t("f751"),t("097d"),{}),B=(t("5c0b"),t("2877")),K=Object(B.a)(M,(function(){var e=this.$createElement;e=this._self._c||e;return e("div",{attrs:{id:"app"}},[e("router-view")],1)}),[],!1,null,null,null).exports,J=VueRouter,F=new J({mode:"hash",base:"/",scrollBehavior:function(){return{y:0}},routes:[{path:"/",redirect:"/login"},{path:"/login",component:function(){return t.e("chunk-3acd4560").then(t.bind(null,"9ed6"))},hidden:!0},{path:"/reset",component:function(){return t.e("chunk-203f9367").then(t.bind(null,"44b4"))},hidden:!0},{path:"/home",component:function(){return t.e("chunk-021d6c9c").then(t.bind(null,"c1f7"))},redirect:"/paddy",children:[{path:"paddy",component:function(){return t.e("chunk-7335840d").then(t.bind(null,"f01a"))},name:"paddy",meta:{title:"稻田",noCache:!0,breadcrumb:!0}},{path:"product",component:function(){return t.e("chunk-8d7787fa").then(t.bind(null,"e6e2"))},name:"product",meta:{title:"产品",noCache:!0,breadcrumb:!0}},{path:"my",component:function(){return t.e("chunk-8df27d04").then(t.bind(null,"9639"))},name:"my",meta:{title:"我的",noCache:!0,breadcrumb:!0}}]},{path:"/orderRes",component:function(){return t.e("chunk-a2b5907a").then(t.bind(null,"0957"))},hidden:!0},{path:"/liveD",component:function(){return t.e("chunk-73ab7664").then(t.bind(null,"c288"))},hidden:!0},{path:"/address",component:function(){return t.e("chunk-5c81dcae").then(t.bind(null,"13b6"))},hidden:!0},{path:"/addressView",component:function(){return Promise.all([t.e("chunk-2d0e48cb"),t.e("chunk-419f8c6e")]).then(t.bind(null,"45b9"))},hidden:!0},{path:"/live",component:function(){return t.e("chunk-48fae926").then(t.bind(null,"1502"))},hidden:!0},{path:"/order",component:function(){return t.e("chunk-50322253").then(t.bind(null,"634a"))},hidden:!0},{path:"/oDetail",component:function(){return t.e("chunk-22789b0e").then(t.bind(null,"9dd3"))},hidden:!0},{path:"/aboutUs",component:function(){return t.e("chunk-c03c33c6").then(t.bind(null,"ffc5"))},hidden:!0},{path:"/referMenu",component:function(){return t.e("chunk-2b6dd8e1").then(t.bind(null,"8481"))},hidden:!0},{path:"/introduce",component:function(){return t.e("chunk-76cf1122").then(t.bind(null,"67df"))},hidden:!0},{path:"/goods",component:function(){return t.e("chunk-62172bbd").then(t.bind(null,"7732"))},hidden:!0}]}),Z=J.prototype.push;J.prototype.push=function(e){return Z.call(this,e).catch((function(e){return e}))},Vue.use(J);var q=F;n=t("2f62"),t("7f7f"),M={sidebar:function(e){return e.app.sidebar},size:function(e){return e.app.size},searchSize:function(e){return e.app.searchSize},tablebtnSize:function(e){return e.app.tablebtnSize},device:function(e){return e.app.device},visitedViews:function(e){return e.tagsView.visitedViews},cachedViews:function(e){return e.tagsView.cachedViews},token:function(e){return e.user.token},avatar:function(e){return e.user.avatar},name:function(e){return e.user.name},introduction:function(e){return e.user.introduction},roles:function(e){return e.user.roles},ad:function(e){return e.user.ad},goodsNum:function(e){return e.user.goodsNum},goodsUnit:function(e){return e.user.goodsUnit},admin:function(e){return e.user.admin}};Vue.use(n.a);var Q=t("c653");J=Q.keys().reduce((function(e,n){var t=n.replace(/^\.\/(.*)\.\w+$/,"$1");n=Q(n);return e[t]=n.default,e}),{}),F=new n.a.Store({modules:J,getters:M}),n=t("5f87"),J=t("d6d3"),M=t.n(J);function X(e){return"-"===e?e:(+e||0).toString().replace(/^-?\d+/g,(function(e){return e.replace(/(?=(?!\b)(\d{3})+$)/g,",")}))}t("8e1f"),t("6b54"),t("96cf");J=t("1da1"),J={name:"inputNumber",props:["numb","max"],data:function(){return{num:this.numb?parseInt(this.numb):0,loading:!1,maxHeight:"0",tableData:[]}},created:(Y=Object(J.a)(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}}),e)}))),function(){return Y.apply(this,arguments)}),mounted:function(){},watch:{numb:function(e){this.num=e?parseInt(e):0}},methods:{isnumber:function(e){return/^[0-9]*$/.test(e)},numInput:function(){this.leix();for(var e="",n=this.num+"",t=0;t<n.length;t++)this.isnumber(n[t])&&(e+=n[t]);this.num=""===e?0:parseInt(e),this.num>this.max&&(this.num=this.max),this.num<0&&(this.num=0),this.$emit("backNum",this.num)},jian:function(){this.leix(),0<this.num&&(--this.num,this.$emit("backNum",this.num))},jia:function(){this.leix(),this.num=parseInt(this.num),this.num<this.max&&(this.num+=1,this.$emit("backNum",this.num))},leix:function(){isNaN(this.num)&&(this.num=0)}}};var Y,ee=(t("f40c"),Object(B.a)(J,(function(){var e=this,n=e.$createElement;n=e._self._c||n;return n("div",{staticClass:"inputNumber"},[n("div",{staticClass:"jian",on:{click:e.jian}},[e._v("-")]),n("input",{directives:[{name:"model",rawName:"v-model",value:e.num,expression:"num"}],attrs:{type:"text",min:0,max:e.max},domProps:{value:e.num},on:{blur:e.numInput,input:function(n){n.target.composing||(e.num=n.target.value)}}}),n("div",{staticClass:"jia",on:{click:e.jia}},[e._v("+")])])}),[],!1,null,"7bfe8594",null).exports);B={install:function(e){e.component(ee.name,ee)}};t("451f"),t("fda2"),J=t("a151"),Vue.use(B),Vue.use(r.a).use(a.a).use(u.a).use(c.a).use(o.a).use(s.a).use(d.a).use(f.a).use(m.a).use(h.a).use(l.a).use(b.a).use(p.a).use(w.a).use(v.a).use(V.a).use(E.a).use(O.a).use(S.a).use(_.a).use(g.a).use(T.a).use(j.a).use(D.a).use(I.a).use(k.a).use(A.a).use(N.a).use(C.a).use(y.a).use(x.a).use(L.a).use(U.a).use(R.a).use(P.a).use(W.a).use(G.a).use(H.a).use(z.a).use($.a).use(M.a).use(J),Object.keys(i).forEach((function(e){Vue.filter(e,i[e])})),Vue.config.productionTip=!1,window.vm=new Vue({router:q,store:F,render:function(e){return e(K)}}).$mount("#app"),null!==Object(n.e)()&&void 0!==Object(n.e)()&&""!==Object(n.e)()||(Object(n.j)(),"/login"!==window.vm.$route.path&&"/"!==window.vm.$route.path&&q.replace({name:"/login"}))},"5c0b":function(e,n,t){"use strict";t("e332")},"5daa":function(e,n,t){"use strict";var i=t("f121");n.a={baseURL:i.baseApi}},"5f87":function(e,n,t){"use strict";t.d(n,"e",(function(){return s})),t.d(n,"o",(function(){return d})),t.d(n,"j",(function(){return f})),t.d(n,"a",(function(){return m})),t.d(n,"k",(function(){return h})),t.d(n,"f",(function(){return l})),t.d(n,"c",(function(){return b})),t.d(n,"m",(function(){return p})),t.d(n,"h",(function(){return w})),t.d(n,"d",(function(){return v})),t.d(n,"n",(function(){return V})),t.d(n,"i",(function(){return E})),t.d(n,"b",(function(){return O})),t.d(n,"l",(function(){return S})),t.d(n,"g",(function(){return _}));n=t("a78e");var i=t.n(n),r="wuchang-tk-h5-Token",a="wuchang-tk-h5-Ad",u="wuchang-tk-h5-goodsNum",c="wuchang-tk-h5-goodsUnit",o="wuchang-tk-h5-admin";function s(){return i.a.get(r)}function d(e){return i.a.set(r,e)}function f(){return i.a.remove(r)}function m(){return i.a.get(a)}function h(e){return i.a.set(a,e)}function l(){return i.a.remove(a)}function b(){return i.a.get(u)}function p(e){return i.a.set(u,e)}function w(){return i.a.remove(u)}function v(){return i.a.get(c)}function V(e){return i.a.set(c,e)}function E(){return i.a.remove(c)}function O(){return i.a.get(o)}function S(e){return i.a.set(o,e)}function _(){return i.a.remove(o)}},7509:function(e,n,t){"use strict";t.r(n),t("ac4d"),t("8a81"),t("5df3"),t("1c4c"),t("6b54");var i=t("2909"),r=t("3835");function a(e,n){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=function(e,n){if(e){if("string"==typeof e)return u(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(t="Object"===t&&e.constructor?e.constructor.name:t)||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?u(e,n):void 0}}(e))||n&&e&&"number"==typeof e.length){t&&(e=t);var i=0;n=function(){};return{s:n,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,a=!0,c=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return a=e.done,e},e:function(e){c=!0,r=e},f:function(){try{a||null==t.return||t.return()}finally{if(c)throw r}}}}function u(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,i=new Array(n);t<n;t++)i[t]=e[t];return i}t("ac6a"),t("7f7f"),t("6762"),t("2fdb"),n.default={namespaced:!0,state:{visitedViews:[],cachedViews:[]},mutations:{ADD_VISITED_VIEW:function(e,n){e.visitedViews.some((function(e){return e.path===n.path}))||e.visitedViews.push(Object.assign({},n,{title:n.meta.title||"no-name"}))},ADD_CACHED_VIEW:function(e,n){e.cachedViews.includes(n.name)||n.meta.noCache||e.cachedViews.push(n.name)},DEL_VISITED_VIEW:function(e,n){var t,i=a(e.visitedViews.entries());try{for(i.s();!(t=i.n()).done;){var u=Object(r.a)(t.value,2),c=u[0];if(u[1].path===n.path){e.visitedViews.splice(c,1);break}}}catch(e){i.e(e)}finally{i.f()}},DEL_CACHED_VIEW:function(e,n){n=e.cachedViews.indexOf(n.name),-1<n&&e.cachedViews.splice(n,1)},DEL_OTHERS_VISITED_VIEWS:function(e,n){e.visitedViews=e.visitedViews.filter((function(e){return e.meta.affix||e.path===n.path}))},DEL_OTHERS_CACHED_VIEWS:function(e,n){n=e.cachedViews.indexOf(n.name),e.cachedViews=-1<n?e.cachedViews.slice(n,n+1):[]},DEL_ALL_VISITED_VIEWS:function(e){var n=e.visitedViews.filter((function(e){return e.meta.affix}));e.visitedViews=n},DEL_ALL_CACHED_VIEWS:function(e){e.cachedViews=[]},UPDATE_VISITED_VIEW:function(e,n){var t,i=a(e.visitedViews);try{for(i.s();!(t=i.n()).done;){var r=t.value;if(r.path===n.path){Object.assign(r,n);break}}}catch(e){i.e(e)}finally{i.f()}}},actions:{addView:function(e,n){e=e.dispatch,e("addVisitedView",n),e("addCachedView",n)},addVisitedView:function(e,n){(0,e.commit)("ADD_VISITED_VIEW",n)},addCachedView:function(e,n){(0,e.commit)("ADD_CACHED_VIEW",n)},delView:function(e,n){var t=e.dispatch,r=e.state;return new Promise((function(e){t("delVisitedView",n),t("delCachedView",n),e({visitedViews:Object(i.a)(r.visitedViews),cachedViews:Object(i.a)(r.cachedViews)})}))},delVisitedView:function(e,n){var t=e.commit,r=e.state;return new Promise((function(e){t("DEL_VISITED_VIEW",n),e(Object(i.a)(r.visitedViews))}))},delCachedView:function(e,n){var t=e.commit,r=e.state;return new Promise((function(e){t("DEL_CACHED_VIEW",n),e(Object(i.a)(r.cachedViews))}))},delOthersViews:function(e,n){var t=e.dispatch,r=e.state;return new Promise((function(e){t("delOthersVisitedViews",n),t("delOthersCachedViews",n),e({visitedViews:Object(i.a)(r.visitedViews),cachedViews:Object(i.a)(r.cachedViews)})}))},delOthersVisitedViews:function(e,n){var t=e.commit,r=e.state;return new Promise((function(e){t("DEL_OTHERS_VISITED_VIEWS",n),e(Object(i.a)(r.visitedViews))}))},delOthersCachedViews:function(e,n){var t=e.commit,r=e.state;return new Promise((function(e){t("DEL_OTHERS_CACHED_VIEWS",n),e(Object(i.a)(r.cachedViews))}))},delAllViews:function(e,n){var t=e.dispatch,r=e.state;return new Promise((function(e){t("delAllVisitedViews",n),t("delAllCachedViews",n),e({visitedViews:Object(i.a)(r.visitedViews),cachedViews:Object(i.a)(r.cachedViews)})}))},delAllVisitedViews:function(e){var n=e.commit,t=e.state;return new Promise((function(e){n("DEL_ALL_VISITED_VIEWS"),e(Object(i.a)(t.visitedViews))}))},delAllCachedViews:function(e){var n=e.commit,t=e.state;return new Promise((function(e){n("DEL_ALL_CACHED_VIEWS"),e(Object(i.a)(t.cachedViews))}))},updateVisitedView:function(e,n){(0,e.commit)("UPDATE_VISITED_VIEW",n)}}}},"8bbf":function(e,n){e.exports=Vue},"8e1f":function(e,n,t){},c653:function(e,n,t){var i={"./app.js":"d9cd","./tagsView.js":"7509","./user.js":"0f9a"};function r(e){return e=a(e),t(e)}function a(e){if(t.o(i,e))return i[e];throw e=new Error("Cannot find module '"+e+"'"),e.code="MODULE_NOT_FOUND",e}r.keys=function(){return Object.keys(i)},r.resolve=a,(e.exports=r).id="c653"},d9cd:function(e,n,t){"use strict";t.r(n);var i=t("a78e"),r=t.n(i);i={sidebar:{opened:!r.a.get("sidebarStatus")||!!+r.a.get("sidebarStatus"),withoutAnimation:!1},device:"desktop",searchSize:"medium",size:r.a.get("size")||"mini",tablebtnSize:"mini"};n.default={namespaced:!0,state:i,mutations:{TOGGLE_SIDEBAR:function(e){e.sidebar.opened=!e.sidebar.opened,e.sidebar.withoutAnimation=!1,e.sidebar.opened?r.a.set("sidebarStatus",1):r.a.set("sidebarStatus",0)},CLOSE_SIDEBAR:function(e,n){r.a.set("sidebarStatus",0),e.sidebar.opened=!1,e.sidebar.withoutAnimation=n},TOGGLE_DEVICE:function(e,n){e.device=n},SET_SIZE:function(e,n){e.size=n,r.a.set("size",n)}},actions:{toggleSideBar:function(e){(0,e.commit)("TOGGLE_SIDEBAR")},closeSideBar:function(e,n){(0,e.commit)("CLOSE_SIDEBAR",n.withoutAnimation)},toggleDevice:function(e,n){(0,e.commit)("TOGGLE_DEVICE",n)},setSize:function(e,n){(0,e.commit)("SET_SIZE",n)}}}},e332:function(e,n,t){},f121:function(e,n,t){t=t("f1e0"),e.exports=t},f1e0:function(e,n){e.exports={title:"藏金1745",baseApi:"http://api.fc.caixiao365.com/",fileURL:"https://api2.edu.futurelab.tv",appId:"wx5ac3a2c2d72b6f26",ding:{CorpId:"dingc78fa4301e1a424a35c2f4657eb6378f",AgentId:"1184953963"}}},f40c:function(e,n,t){"use strict";t("091a")}},[[0,"runtime","chunk-libs"]]]);