1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-f17d7a9e"],{"0afc":function(t,o,e){t.exports=e.p+"img/noneData.919a3c84.png"},1175:function(t,o,e){},"1ccf":function(t,o){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAD5klEQVRYCcVXW4hNURj+v33mzClETO4eiCgPHmhKXlySNORSmjBmSm41Z6akmAeFlMjDRG4pTzN4OCVRLimN5EHhhWJoCGnGGSTGNA6ds3xr7dnb3nP22XsPMqvO2Wut//v/71+3f/0LErOoTKZcsj8XixRWCWS2iJokAv50UZ2sd4qSpyLWVRmfbEN19Q9bFv6PcDFNn8pMEJXbR+M1bI2MwttyfKWTFwSpg0hXvw/TKemAun49JS8/7aXyLhIPDzNSWoZeypplesUhVFXlgnCBDphRF3KXSTw/SGnwfbgvVmpt0GwUOaBOX5wj+fw1kk8ZPFGYBt5xn1ShcdMTL8rnQP/IH8Qjp0GoRzQ6TJSaR6NjvIaD69SxUpXemXAd6F/zO5HTDnyk8TQaajMOCU9IQrq/7xGFA9Qvd/qDv1yO6RWLnD1huSCz4SLWHPJTymSpl1zr88jl0VB3WCzZ5torWSGHvbkNwsxA/9R30PuI3W4d5Ro2lbRNgTrRepv/S8IwdLmXSzFDL4U9A/qcR5LTJORWuOGYGM1lOBm2TIQzQSbStEgi8TISpdSrSIwGkFNzW3Z4jRnh8gWG4IhiIRpjTJCToZ1LwNgeuxTWhkHNaVAyGHurLPtiCTPrk21Rp84v8/V4G925JsaEud6u0DovNaiTLc+5HjNDgT4heMvhoIwqHENdnY71os60jJM8jpB8sw8a1YC8oAOtPVQcEYV15cBdOryAtFw+tDMaMhLKVCMHOmhrhouNqgDf7GMYBdRy8L4XrGMQWsjWCf6oq2b/Jpcrkt40i5idxH7TKtFF6VHoZCKiAJ8FyaVorL1kkMNG7idRl6sFfBGVrAdQIOY4fVtBeZyEpEtPY7gDQJ4G1yC9/plDiC2rezj+3U6bI96Nxg2uHTTU3BVYW115yQo6LU4h06iQotQVY3AABOlaZjzcD5A2qa85N0As1Gml7N7Afl+b3JwB5nBhBQlOaYmSUGk6sZ1TrwIRsErrGgXrKkwozuY+cC8U53uQ17zlpgUaj9FpAlP39yxnuaIYzrxxfGqsZbJXnUAGFSW8If+86GuaOUJ7oAVyam4uAQuzV/6ZoOIH442//QctBF1O5DKc5iyT2k6dm4vMQ/Lq7MNkUX/MDtXWVkbrfQHwZictgyMsmZJBGClxmzv6hiRTN7Gj+q2jE/RV5zJjpO/Hcu6pldRZzsg42o/zp2SuAxoULynl5hHJMgRnOTo+OlQfN9lEkk1mexIJR/kJva2QpNSB/e+03N6EDju/qN/4WKfOrN33dP9l1TxMKge+CbRR3xJ4WYb0aeZzZKgep14ndN2OmP/+ef4L6y16rc+hJ3QAAAAASUVORK5CYII="},2241:function(t,o,e){"use strict";var n,s=e("1988"),i=e("8bbf"),l=e.n(i),a=e("2638"),r=e.n(a),c=e("d282"),p=e("ea8e"),u=e("b1d2"),d=e("6605"),h=e("b650"),m=e("9884"),f=Object(c["a"])("goods-action"),g=f[0],w=f[1],A=g({mixins:[Object(m["b"])("vanGoodsAction")],props:{safeAreaInsetBottom:{type:Boolean,default:!0}},render:function(){var t=arguments[0];return t("div",{class:w({unfit:!this.safeAreaInsetBottom})},[this.slots()])}}),v=e("48f4"),y=Object(c["a"])("goods-action-button"),b=y[0],D=y[1],C=b({mixins:[Object(m["a"])("vanGoodsAction")],props:Object(s["a"])({},v["c"],{type:String,text:String,icon:String,color:String,loading:Boolean,disabled:Boolean}),computed:{isFirst:function(){var t=this.parent&&this.parent.children[this.index-1];return!t||t.$options.name!==this.$options.name},isLast:function(){var t=this.parent&&this.parent.children[this.index+1];return!t||t.$options.name!==this.$options.name}},methods:{onClick:function(t){this.$emit("click",t),Object(v["b"])(this.$router,this)}},render:function(){var t=arguments[0];return t(h["a"],{class:D([{first:this.isFirst,last:this.isLast},this.type]),attrs:{size:"large",type:this.type,icon:this.icon,color:this.color,loading:this.loading,disabled:this.disabled},on:{click:this.onClick}},[this.slots()||this.text])}}),B=Object(c["a"])("dialog"),S=B[0],T=B[1],U=B[2],x=S({mixins:[Object(d["a"])()],props:{title:String,theme:String,width:[Number,String],message:String,className:null,callback:Function,beforeClose:Function,messageAlign:String,cancelButtonText:String,cancelButtonColor:String,confirmButtonText:String,confirmButtonColor:String,showCancelButton:Boolean,overlay:{type:Boolean,default:!0},allowHtml:{type:Boolean,default:!0},transition:{type:String,default:"van-dialog-bounce"},showConfirmButton:{type:Boolean,default:!0},closeOnPopstate:{type:Boolean,default:!0},closeOnClickOverlay:{type:Boolean,default:!1}},data:function(){return{loading:{confirm:!1,cancel:!1}}},methods:{onClickOverlay:function(){this.handleAction("overlay")},handleAction:function(t){var o=this;this.$emit(t),this.value&&(this.beforeClose?(this.loading[t]=!0,this.beforeClose(t,(function(e){!1!==e&&o.loading[t]&&o.onClose(t),o.loading.confirm=!1,o.loading.cancel=!1}))):this.onClose(t))},onClose:function(t){this.close(),this.callback&&this.callback(t)},onOpened:function(){this.$emit("opened")},onClosed:function(){this.$emit("closed")},genRoundButtons:function(){var t=this,o=this.$createElement;return o(A,{class:T("footer")},[this.showCancelButton&&o(C,{attrs:{size:"large",type:"warning",text:this.cancelButtonText||U("cancel"),color:this.cancelButtonColor,loading:this.loading.cancel},class:T("cancel"),on:{click:function(){t.handleAction("cancel")}}}),this.showConfirmButton&&o(C,{attrs:{size:"large",type:"danger",text:this.confirmButtonText||U("confirm"),color:this.confirmButtonColor,loading:this.loading.confirm},class:T("confirm"),on:{click:function(){t.handleAction("confirm")}}})])},genButtons:function(){var t,o=this,e=this.$createElement,n=this.showCancelButton&&this.showConfirmButton;return e("div",{class:[u["e"],T("footer")]},[this.showCancelButton&&e(h["a"],{attrs:{size:"large",loading:this.loading.cancel,text:this.cancelButtonText||U("cancel")},class:T("cancel"),style:{color:this.cancelButtonColor},on:{click:function(){o.handleAction("cancel")}}}),this.showConfirmButton&&e(h["a"],{attrs:{size:"large",loading:this.loading.confirm,text:this.confirmButtonText||U("confirm")},class:[T("confirm"),(t={},t[u["c"]]=n,t)],style:{color:this.confirmButtonColor},on:{click:function(){o.handleAction("confirm")}}})])},genContent:function(t,o){var e=this.$createElement;if(o)return e("div",{class:T("content")},[o]);var n=this.message,s=this.messageAlign;if(n){var i,l,a={class:T("message",(i={"has-title":t},i[s]=s,i)),domProps:(l={},l[this.allowHtml?"innerHTML":"textContent"]=n,l)};return e("div",{class:T("content",{isolated:!t})},[e("div",r()([{},a]))])}}},render:function(){var t=arguments[0];if(this.shouldRender){var o=this.message,e=this.slots(),n=this.slots("title")||this.title,s=n&&t("div",{class:T("header",{isolated:!o&&!e})},[n]);return t("transition",{attrs:{name:this.transition},on:{afterEnter:this.onOpened,afterLeave:this.onClosed}},[t("div",{directives:[{name:"show",value:this.value}],attrs:{role:"dialog","aria-labelledby":this.title||o},class:[T([this.theme]),this.className],style:{width:Object(p["a"])(this.width)}},[s,this.genContent(n,e),"round-button"===this.theme?this.genRoundButtons():this.genButtons()])])}}}),E=e("a142");function L(t){return document.body.contains(t)}function O(){n&&n.$destroy(),n=new(l.a.extend(x))({el:document.createElement("div"),propsData:{lazyRender:!1}}),n.$on("input",(function(t){n.value=t}))}function k(t){return E["g"]?Promise.resolve():new Promise((function(o,e){n&&L(n.$el)||O(),Object(s["a"])(n,k.currentOptions,t,{resolve:o,reject:e})}))}k.defaultOptions={value:!0,title:"",width:"",theme:null,message:"",overlay:!0,className:"",allowHtml:!0,lockScroll:!0,transition:"van-dialog-bounce",beforeClose:null,overlayClass:"",overlayStyle:null,messageAlign:"",getContainer:"body",cancelButtonText:"",cancelButtonColor:null,confirmButtonText:"",confirmButtonColor:null,showConfirmButton:!0,showCancelButton:!1,closeOnPopstate:!0,closeOnClickOverlay:!1,callback:function(t){n["confirm"===t?"resolve":"reject"](t)}},k.alert=k,k.confirm=function(t){return k(Object(s["a"])({showCancelButton:!0},t))},k.close=function(){n&&(n.value=!1)},k.setDefaultOptions=function(t){Object(s["a"])(k.currentOptions,t)},k.resetDefaultOptions=function(){k.currentOptions=Object(s["a"])({},k.defaultOptions)},k.resetDefaultOptions(),k.install=function(){l.a.use(x)},k.Component=x,l.a.prototype.$dialog=k;o["a"]=k},"2fcb":function(t,o,e){},3347:function(t,o){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAEFklEQVRYCcVXXUgUURQ+Z9zdoEz7oT/rwaAfMCjoj9wN+kFCKiQhevEp+nkoiBTNh6CWIirTLesp6C18CSIUogjEEDX7eykqK4uK0JaCMo1IW2/fmfYut93ZmbGoLgxz77nf+b5z75y5c4bJZ4s+UqHBAVpHispGFRUxUYHCJe7o96HfZzE9xqBlYj61RRfxsB9q+Lq3mjtqZmKEDkGgAuJ57ujkLNNnEDflBOnIqZX8zs0nawBnn6txr+J0EM5VEJ/gRpJtDuRfMBcrnEHH9s3nb044xwDsVQ/TFQivcnIaqw0i3TkhKnfajYwAqrvV4kSCrmK754xVyBXP9Bb5sfF0mB+auF8CkJV/H6G7vsSFkOg+KxoP4mVK0RST2LEPn0CQVpg7kQog+cxvem07HD5YObS3vpgvaZFLSuV036IDCDyKQELa7nSHfzdyYq3OCUuDJOG8xLHSEQpSiSku/tuYE7EwH8f8Ls2X7S4ayeS2IfYOJJOuF5Ou2c5MdbEI12YjF3tlp2rFTqx3w0D0C5JynjwKeweS77mruE3IdMONWOZA7omRhYqm4C054WCokIFXCzG98MIggpeeGABEU7St5PHq64QbTlCRJzmOaU+MAHCqiraFTpkvBwExlbth5W3AyvzzQduSD4sbqTkH8h01nWqDaTP7tzupFgtaatrc+vZHrapDPQXxAjegOYc3Qb5yR6xcOlO/hOWsp+pONR0cJ0C43cR69ZGwz7iyQw0CmOsF1vMIoB2rDONxyOPrUYyTUFGhzGOuFwfRPI31cR9KHUReYJD34dqKc2CNsugchCysukiLI6DmvDAttCzaD64hLz6ZB59CDUF9XmBgPgYsKoH4ZcEGR+kwbv3aD0QDQUV7osyjDWFuBOkm2LwLEkX9sgqvABIg21JXzE+0YN1qHsTW1egx7jWwpXgaItyOoHca845d0bbsMspxOmVsFsLUKNlpWM1NCKwdV1tDmC5kzEf4IoLoSLebY9G28OxaTGN6H6DGdJseYxf2Igl3M+Oj7NAQXFZfGw5tluNw4BO9RzJlnoZMr05HeK4Dty+THEy3uigO7qkZDqgb8yfRNEuqV2xVUwZADIp6He0+jfKZBkePE1w0Rdt+DaV6hcE+VEwwbK/N8W/1HT5OoiWawmcHkCyRYukCeL6J8/dUMN3ud4zyKADsVwd8TJdlCOZny1aSIZHkpGzF/VogRNdPLuc32sfpXtmlpDYsRVpuxvaXIjsnmzgI/lKSpQIQkK+iFMkDaBwCceyQ/HR8hdAsvE2zQVaAEzJfuBybW1GqHf51WW7ngBaXe/0qfiCls2yVaf+TvnAJZ/o/gXBmBCBGSRApneF4FFfG2yEYP018hUO4dNKl+2HevdkV8//4OU0P62/9nv8AxwV3K84ldD8AAAAASUVORK5CYII="},4257:function(t,o,e){},"4cf9":function(t,o,e){},"66b9":function(t,o,e){"use strict";e("68ef"),e("9d70"),e("3743"),e("e3b3"),e("bc1b")},"8d6b":function(t,o,e){"use strict";var n=function(){var t=this,o=t.$createElement,e=t._self._c||o;return e("div",{ref:"mescroll",staticClass:"mescroll"},[e("div",[t._t("default")],2)])},s=[],i=e("f868"),l=e.n(i),a=(e("f2fd"),{name:"MeScrollVue",data:function(){return{mescroll:null,lastScrollTop:0,lastBounce:null}},props:{up:Object,down:Object},mounted:function(){this.mescroll=new l.a(this.$refs.mescroll,{up:this.up,down:this.down}),this.$emit("init",this.mescroll)},methods:{beforeRouteEnter:function(){var t=this;this.mescroll&&(this.lastScrollTop&&(this.mescroll.setScrollTop(this.lastScrollTop),setTimeout((function(){t.mescroll.setTopBtnFadeDuration(0)}),16)),null!=this.lastBounce&&this.mescroll.setBounce(this.lastBounce))},beforeRouteLeave:function(){this.mescroll&&(this.lastScrollTop=this.mescroll.getScrollTop(),this.mescroll.hideTopBtn(0),this.lastBounce=this.mescroll.optUp.isBounce,this.mescroll.setBounce(!0))}}}),r=a,c=e("2877"),p=Object(c["a"])(r,n,s,!1,null,null,null);o["a"]=p.exports},"99af":function(t,o,e){"use strict";var n=e("23e7"),s=e("da84"),i=e("d039"),l=e("e8b5"),a=e("861d"),r=e("7b0b"),c=e("07fa"),p=e("8418"),u=e("65f0"),d=e("1dde"),h=e("b622"),m=e("2d00"),f=h("isConcatSpreadable"),g=9007199254740991,w="Maximum allowed index exceeded",A=s.TypeError,v=m>=51||!i((function(){var t=[];return t[f]=!1,t.concat()[0]!==t})),y=d("concat"),b=function(t){if(!a(t))return!1;var o=t[f];return void 0!==o?!!o:l(t)},D=!v||!y;n({target:"Array",proto:!0,forced:D},{concat:function(t){var o,e,n,s,i,l=r(this),a=u(l,0),d=0;for(o=-1,n=arguments.length;o<n;o++)if(i=-1===o?l:arguments[o],b(i)){if(s=c(i),d+s>g)throw A(w);for(e=0;e<s;e++,d++)e in i&&p(a,d,i[e])}else{if(d>=g)throw A(w);p(a,d++,i)}return a.length=d,a}})},a119:function(t,o,e){"use strict";e.r(o);var n,s=function(){var t=this,o=t.$createElement,n=t._self._c||o;return n("div",{staticClass:"page",class:{pb100:"1"==t.type}},[n("div",{staticClass:"fixedTop"},[n("div",{staticClass:"headerBg"}),n("div",{staticClass:"integralMsg flex-row align-center"},[n("div",{staticClass:"flex-sub flex-column justify-center align-center"},[n("span",{staticClass:"font40 fontWeight color384855"},[t._v(t._s(t.integralTotal.all_intregral))]),n("span",{staticClass:"color384855 mt10"},[t._v("共获得积分")])]),n("div",{staticClass:"flex-sub flex-column justify-center align-center"},[n("span",{staticClass:"font40 fontWeight color384855"},[t._v(t._s(t.integralTotal.all_already))]),n("span",{staticClass:"color384855 mt10"},[t._v("已核销积分")])]),n("div",{staticClass:"line"}),n("div",{staticClass:"flex-sub flex-column justify-center align-center"},[n("span",{staticClass:"font40 fontWeight color384855"},[t._v(t._s(t.integralTotal.no_already))]),n("span",{staticClass:"color384855 mt10"},[t._v("约等于"+t._s(t.integralTotal.no_already_money)+"元")])]),n("div",{staticClass:"flex-sub flex-column justify-center align-center",on:{click:t.viewRule}},[n("span",{staticClass:"font28 fontWeight color249EFB"},[t._v("核销")]),n("span",{staticClass:"font28 fontWeight color249EFB"},[t._v("规则")])])]),n("div",{staticClass:"integralTab flex-row align-center justify-center"},[n("div",{staticClass:"flex-sub flex-row align-center justify-center",class:"1"==t.type?"color249EFB":"",on:{click:function(o){return t.swtichTab("1")}}},[n("van-icon",{attrs:{name:"points mgr10",size:"18"}}),n("span",{staticClass:"font32"},[t._v("积分详情")])],1),n("div",{staticClass:"flex-sub flex-row align-center justify-center",class:"2"==t.type?"color249EFB":"",on:{click:function(o){return t.swtichTab("2")}}},[n("van-icon",{attrs:{name:"orders-o mgr10",size:"18"}}),n("span",{staticClass:"font32"},[t._v("核销记录")])],1)])]),n("mescroll-vue",{ref:"wordListBox",staticClass:"customerBoxmescroll",attrs:{down:t.mescrollDown,up:t.mescrollUp},on:{init:t.mescrollInit}},["2"==t.type?[t._l(t.writeOfflist,(function(o){return n("div",{key:o.id,staticClass:"integralItem flex-row"},[n("div",{staticClass:"flex-four flex-column justify-between"},[n("span",{staticClass:"font28 color384855"},[t._v("核销:"+t._s(o.integral)+"积分 "+t._s(o.good_name?" (兑换商品:"+o.good_name+")":" (即"+o.money+"元)"))]),n("span",{staticClass:"font24 color9DB6CF mt20"},[t._v("时间:"+t._s(o.addtime))])]),n("div",{staticClass:"flex-sub flex-row justify-end align-center"},[n("span",{staticClass:"color249EFB font28"},[t._v(t._s(o.status))])])])})),n("nonedata",{attrs:{len:t.writeOfflist.length,datashow:t.datashow}})]:[t._l(t.integrallist,(function(o){return n("div",{key:o.id,staticClass:"integralItem flex-row"},[n("div",{staticClass:"flex-five flex-column justify-between"},["customer"==o.from?[n("span",{staticClass:"font28 color384855 flex-row"},[n("div",{staticClass:"circle mgr10"},[o.customer?[n("img",{directives:[{name:"show",rawName:"v-show",value:o.customer&&1==o.customer.sex,expression:"item.customer && item.customer.sex == 1"}],attrs:{src:e("3347"),width:"20px",height:"20px",alt:""}}),n("img",{directives:[{name:"show",rawName:"v-show",value:o.customer&&2==o.customer.sex,expression:"item.customer && item.customer.sex == 2"}],attrs:{src:e("1ccf"),width:"20px",height:"20px",alt:""}})]:[n("img",{attrs:{src:e("3347"),width:"20px",height:"20px",alt:""}})]],2),t._v(" "+t._s(o.customer?o.customer.name:"未知")+":"+t._s(o.state)+" ")]),n("span",{staticClass:"font24 color9DB6CF mt20"},[t._v("时间:"+t._s(o.addtime))])]:[n("span",{staticClass:"font28 color384855"},[t._v(t._s(o.state))]),n("span",{staticClass:"font24 color9DB6CF mt20"},[t._v("时间:"+t._s(o.addtime))])]],2),n("div",{staticClass:"flex-sub flex-column justify-center align-end"},[n("span",{staticClass:"color249EFB font28"},[t._v("+"+t._s(o.integral))]),n("span",{staticClass:"color249EFB font28"},[t._v("积分")])])])})),n("nonedata",{attrs:{len:t.integrallist.length,datashow:t.datashow}})]],2),n("div",{directives:[{name:"show",rawName:"v-show",value:"1"==t.type,expression:"type=='1'"}],staticClass:"fixedBottomBtn"},[n("van-button",{attrs:{type:"info"},on:{click:function(o){t.showIntegral=!0}}},[t._v("核销申请")])],1),t.showIntegral?n("div",{staticClass:"xq-integral-mask flex align-center justify-center"},[n("div",{staticClass:"xq-integral-block",on:{click:function(t){t.stopPropagation()}}},[n("div",{staticClass:"xq-integral-title color384855 font28 fontw600"},[n("span",[t._v("核销申请")]),n("img",{attrs:{src:e("b1e4"),width:"25px",alt:""},on:{click:function(o){t.showIntegral=!1}}})]),n("div",{staticClass:"xq-integral-content"},[n("div",{staticClass:"font28 color384855"},[t._v("核销积分")]),n("div",{staticClass:"xq-integral-number flex align-center"},[n("img",{attrs:{src:e("f6ee"),width:"20px",alt:""}}),n("input",{directives:[{name:"model",rawName:"v-model",value:t.integralNumber,expression:"integralNumber"}],attrs:{type:"number",placeholder:"请输入积分"},domProps:{value:t.integralNumber},on:{input:function(o){o.target.composing||(t.integralNumber=o.target.value)}}})]),n("div",{staticClass:"xq-integral-msg"},[n("span",{staticClass:"color384855"},[t._v("当前可核销积分"+t._s(t.integralTotal.ke_already)+",")]),n("span",{staticClass:"color249EFB",on:{click:t.setWriteOff}},[t._v("全部核销")])]),n("div",{staticClass:"xq-integral-btn"},[n("van-button",{attrs:{type:"info",loading:t.loading,"loading-text":"正在提交数据...",disabled:t.loading},on:{click:t.submitWriteOff}},[t._v("提交")])],1)])])]):t._e()],1)},i=[],l=e("fc11"),a=(e("66b9"),e("b650")),r=(e("e17f"),e("2241")),c=(e("b0c0"),e("ac1f"),e("5319"),e("99af"),e("8c11")),p=e("8d6b"),u=e("a92e"),d={components:(n={},Object(l["a"])(n,r["a"].name,r["a"]),Object(l["a"])(n,a["a"].name,a["a"]),Object(l["a"])(n,"nonedata",u["a"]),Object(l["a"])(n,"MescrollVue",p["a"]),n),data:function(){return{type:"1",brokerId:"",integralNumber:"",loading:!1,datashow:!1,loadFlag:!0,wloading:!1,showIntegral:!1,mescroll:null,integrallist:[],writeOfflist:[],integralTotal:{},mescrollDown:{},mescrollUp:{callback:this.getFuncList,page:{num:0,size:10},htmlLoading:"",htmlNodata:"",noMoreSize:0}}},mounted:function(){var t=this.getQueryStringArgs(window.location.href);t.brokerId&&(this.brokerId=t.brokerId)},methods:{getQueryStringArgs:function(t){t=null==t?window.location.href:t;var o=t.substring(t.lastIndexOf("?")+1),e={},n=/([^?&=]+)=([^?&=]*)/g;return o.replace(n,(function(t,o,n){var s=decodeURIComponent(o),i=decodeURIComponent(n);return i=String(i),e[s]=i,t})),e},swtichTab:function(t){this.type=t,this.mescroll.resetUpScroll()},setWriteOff:function(){this.integralNumber=this.integralTotal.ke_already},submitWriteOff:function(){var t=this;this.integralNumber&&this.integralNumber<0||this.integralNumber&&this.integralNumber>this.integralTotal.ke_already?this.$toast("请填写正确的积分数额"):(this.loading=!0,Object(c["e"])({wiped_integral:this.integralNumber}).then((function(o){t.loading=!1,0==o.data.code&&(t.$toast("申请成功!"),t.showIntegral=!1,t.mescroll.resetUpScroll())})).catch((function(o){t.loading=!1})))},viewRule:function(){var t=this;this.wloading||(this.wloading=!0,Object(c["C"])({agent_id:this.brokerId}).then((function(o){t.wloading=!1,0==o.data.code&&r["a"].alert({title:"核销规则",message:o.data.data,confirmButtonColor:"#28A1FF"}).then((function(){}))})).catch((function(o){t.wloading=!1})))},getIntegralStatictis:function(){var t=this;Object(c["l"])({}).then((function(o){0==o.data.code&&(t.integralTotal=o.data.data)}))},mescrollInit:function(t){this.mescroll=t},getFuncList:function(t,o){var e=this,n=this,s={page:t.num,limit:10};1==this.type?Object(c["k"])(s).then((function(s){"0"==s.data.code&&(1===t.num&&(n.integrallist=[]),n.integrallist=n.integrallist.concat(s.data.data),n.$nextTick((function(){o.endSuccess(s.data.data.length)})),e.getIntegralStatictis()),e.loadFlag=!1,e.datashow=!0})):Object(c["i"])(s).then((function(s){"0"==s.data.code&&(1===t.num&&(n.writeOfflist=[]),n.writeOfflist=n.writeOfflist.concat(s.data.data),n.$nextTick((function(){o.endSuccess(s.data.data.length)})),e.getIntegralStatictis()),e.loadFlag=!1,e.datashow=!0}))}}},h=d,m=(e("bdc3"),e("2877")),f=Object(m["a"])(h,s,i,!1,null,"182c862d",null);o["default"]=f.exports},a92e:function(t,o,e){"use strict";var n=function(){var t=this,o=t.$createElement,n=t._self._c||o;return n("div",{staticClass:"nonedata",staticStyle:{margin:"auto"}},[n("div",{directives:[{name:"show",rawName:"v-show",value:"0"==t.len&&t.datashow,expression:"len == '0' && datashow"}],staticClass:"noneDataBox"},[n("img",{attrs:{src:e("0afc")}}),n("div",[t._v(t._s(t.text))])])])},s=[],i=(e("a9e3"),{name:"nonedata",props:{len:{type:Number,default:0},datashow:{type:Boolean,default:!1},text:{type:String,default:"暂无数据展示"}},data:function(){return{}},created:function(){},methods:{},mounted:function(){}}),l=i,a=(e("bf10"),e("2877")),r=Object(a["a"])(l,n,s,!1,null,"e6e9b0c4",null);o["a"]=r.exports},b1e4:function(t,o){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACwAAAAsCAYAAAAehFoBAAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAALKADAAQAAAABAAAALAAAAAD8buejAAAHKElEQVRYCe2Za2wUVRSA752Z7bu1hT6ki8SEQHz84NGqqBBFf5hYkYBSEh8oIVgSaJHSWgWEEZQAhfISTUEwQU2g+CKgfzQhQINECkJi8BWIAruxbIG1j+3udmaO50w709nH7KPQRhMm2dw795x77nfP3HvuYxm7/QyuB/itML9t27ep4qj8whRJzNIA0kUmSWRXZYoicN7NAj0d3a7rnqqqpwM3297NAPMPD5+7XwL1HiaK4xmDUgZ8FOeQj1AZfWA+AN6Gsr8Y56eZqp7VBO23irLSn1EOA4FPGliWj0jFJbmzBYE/D4xP5JyNSrLhywDsDAP4XHMp+ysqSnuSqZ8U8K7Dp6cwQVyClSYzxguSaShcFwDa0E6zwrTNC8omHguX270nBDyrqUl8KnPMbPToBs65087YQMoR3AUa1H3X/ce+A+XlajwbcYHXH2zOHiZlLkWP1iKsMTbj2U1KjtA+4GzjjZ7OjXXTJ3fEqhwTmGCHS9lrGGeLYxm5ZTJgW68pHW/HghbsGqPJlefIqhkyWAJBxwwTs2qpbTsuW+CRD+SWC8DftKs4WOU47OqobTv7UYdE46Gzk0WR7ccuF9tVHNxycKsqm10xbXxzeDsRHm5oOpEuCowm2Yhw5aF75yMEkVXLHx9JC28zAjgrPX0mhq/HUDGq9w0DOLN/x98J4z3xFM5TKIujz3HVfLw4P/e5cL0QYFmWBVrBcPXKC1e0vuOaeoEralkgEHgWGKzEn2KVR80DqLjP2ByA4JNY/wmyEVWvr5AYiIWYrHohL0WlM+6j5daqEDUPzNujSu2LZj50raPTt5EDJ2jbJZY6hID1/ht+eWHZg38r0OHBnYQ7qm1LIbEQk6WIhQDTRiaRvQHqlEgpbHHjoZaM6vJHun0XXA0IsBt/QatxyuveB7bPe42/W/XSpHba2UksZx7amBKuG/5OLPrmyiIwgeWmppTeXZdFGiPLBbZMEMQ3aJLStrEzCG+h+kfW4YGbHA2JP2GKv6Z2zriuxsYWR9ro4oUIsj6G6VAR7gSpnlFoAhek3F2EO6gSQ5BIyrmwKicr4330dP6SGRO86OlqtLFMHx44ZjFdpWnKovnTJ7Vu+/RkDndKDZzxegQ2243bDjIJ+UqRoWdWpM03fQJDkHAK7BWRO9bSpyZPu656t6NXV+JvNWhKQ8W0Uh95KD0vbQ1+lYqkYAmCs7tYqiPb4DGB6aSAhclvGTkXQYBXM0Y79bgpz53qd129saXd56snWOoIHylVomcX4M/8tAZAvBRja2Efm67av2YLDgfGx0z0QNKPDsLZyuLCPBHH9CaaiGSEAn9aQd5iNLkKPZWStGGsgPMgkyGbUdf0sFEw0BQ7CwLjantXACNY75OTmYr9Bwn3BwNwQ68NMmDYo7QfWOvpQWGXVZhwHsMZWl1B4Y2GBEUO8i552uXxbtI0kPWJmLDBfkW028WQzSgxgfXTLWMeQ5BoSiA4xnbCFWU7TTqKzdlZGTXOgtylOjh2wH/RvQU/7R7Ujb8iRjbs6WPTJSZwUFE70eilSH37EoqzoLFGv9e/nA6TBCtwPPMBjlmByzlZ6ZXkaepIMBBYjuNir701Gwmwy3RNYEhNYE/wz1b9KG5I4qQ6LINacCnVtILtOniySBCk93G4voN2RJyIEm5g1jqLchs+OHw8j5ZxVVUqsZ4cx3SoGK8HtDap1Sg0geXy8iDdGxiCeCk2XOe/4N5Bnq3fey6TSakbMBK8TLBmXQIHYZ5DyF5H4Y3CnKb11OO4fM/UiZdBJutVgAlM9RQu/oogl+LZQJ3jCmvfTZ+aVrDc4bACQV/QvRpeuTeczaU4TWOaoLs71a0491vCVcPfiQVjzy/W8hDg1pavzmMUOWNViJrnrFji2QU7vvnxzrS8NBnHZm1U2L7KKHMAh9U0GWkZz0iFO/CUHHMLS1WJxX3m6xDgiPi489BPL3JB2I4hLqbB3k04b0e9e6N2yr7wB1wN8vGLjLFX0e+xruMOuuq1aRM+s+qFeJgEnd3dX2LPjmI2JGBbK1EeJ5dzALBU9eF4sKiDbcNRd5v3C6pgfSI8TML/1SGUgOm0CqDVYD8jNuQkH9SH2gSojXZipnYjhoQB4zr1zwGNwzrjfahSavPKKW+TXXtRh4ShrN+rObJXo9LrRtmgpglcVcUEJrihugzESVZ/XenaFOtejXj6VyV6i/J8v29PsGTsiGM5zrEXMTZMwuiQE0XtJorAjVGp0nXq4I4VC+bE/UshroetJHShjattNUb0RxE++dOJ1RgDD8auZqapm+c/U3I8RBTjJSlgskPnM3GkOAuBZ9G9AcbiZM+B+l8GoGkH3Ke9+2V5alJbzqSBLZ03/5TBlXEcequ0D548b1x8+zDvoT0BNtSCkOeG/E8ZC7CZpTsNpziqkE63dGCM9reXS710Vd8RmrVuZ/6bHvgXSxH8wD7z4I4AAAAASUVORK5CYII="},bdc3:function(t,o,e){"use strict";e("4257")},bf10:function(t,o,e){"use strict";e("c93c")},c93c:function(t,o,e){},e17f:function(t,o,e){"use strict";e("68ef"),e("a71a"),e("9d70"),e("3743"),e("4d75"),e("e3b3"),e("bc1b"),e("1175"),e("4cf9"),e("2fcb")},f2fd:function(t,o,e){},f6ee:function(t,o){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAABO9JREFUWEfFV1tsVFUUXeveedQEQUM7NWoIMFMblfhh8QkxCEIsfIgxmvj4oDOlfGj9UWN8JNTERyJ8MfpBZWb4UGMwCMQABuQRQn1josEY7AwQAirTURQxdu7MvcucO9OxUqAdoHCSk3sms8/e65yz134Ql3nwfOy3pnQlgmiUU2oy+xkKDqCEwoEE/6pX3zkBTM3omoDnzAOtxYBiABsBmNlwFkODAAqACgCzkLexbIV2HO7gr2cDNgJAdK3TRpfzAdwLYkFtI+lAyAPK+18qT7MGIDACMQIiArM2XylU2ytsA7BLtrbnloT2DQdTAzDtneItAdt+UlBXVcCF0Edij6jN2Y7QF/Vcbyzj3ElxkYR7QMwCYPvPBfaWXfftQ0vD31d+A5ieKS+0pF4A1wH4EVDSVnDTgQR/rsfo2WRbU7rWZekBgN0AbgRwzCO7DnYEtrA1pVaX7l5AjQJe5qmTyezTk09eDMOn64it+m2iJkzsJvAqwIItezZb0qUVAp4lrOf74/ab42F4BJBM+WFI6wisZCxd2gKgPewFJv/Qyd8vBQBjI5YufQMgz1jGWQMxQfKh/o7AR5cCQCytm4ByH6j1bMmU5qtCk2MSl+YSga3jCSKaKrfT0goIN5NY4LMgli69AOB13zD1HoVkfzz05cUE0pJ27hDRDfHxqt4Xs/HgGxUA72qiHLed0HMA2nwBoQ8W9lrE9p+WBHecD5gb1pbmecJ8eJhdjQVGzT6ByQbP/tj43NAN9AG4OxsPMpp2ukirHVI7gHDV8CkAn0PKw+Jx33nM2rP8SAjLi4iMAIjAUzMq67sATKjuL4LcKnlbc/FQbyxdEoDPsvHgLMZSxR7QWg55r2QT4Z6hk07N6CrbdebQthdCerCaA+q5iALIDXLdLa4d2n24g38MbfYPCa42NhlNl9ZTmpFNhFrPpX36ak2iXWyibTVSViPgNYF+cgJkko81IHoFuWaGBw4u45/n0hdLl04I2GniwDqBt+XigWn1HO9CZaPp8iFCXzNWjUoAPnTdYvehpRPMG4/raEk5q0R2g3yk4oRVPxB4mFRykvNdct+ymaWLjaL69ibbtg35XC0dR9OllypJwh/fEtgpcO/1R+zNu3tYPh8wc3oUODrFXURotkx9UaW4yQH98aChfCUdR9PO+wQflaWZlmd1ibgf0pSq0X8A7AGxx6ehvDwZPm4FkA/DFChAEYh4ZUSkYjNoRXwamjoA/rzC10MeofCJZ3m99LhS0C+5eOixGg2HozLy01POTMvC7RBNZTQPwtV13QJxAsIOULs8D18dTIRM8vHHCBoCvHU0FowbDccaB+o6/RiEYynngMj9/0VC8K1B7+/lRzsnjXtNMDz6VmiYKW+AtBjAfnl8LdcZ+GAMh6hbpFp7PgNgrtlsck+NhrF0OQnoqYpWZihsdsv2p6OF1NFQGN+xA+59smASXKJCPfb2xwPLajSseedap82nofQAiGYADoA+CNtkaOi5eTaE89kneMai1U/rg8UILDvCSjlu+gpTkocgHCe5ydBweG9wxs5oakYNtlueA3pz6XdFaDntpIOmQSH81AxBzX5DMrJj6pe8jZC107UDJiOazul/Y0y9YXRNcQYtOwoLjXDVBJr2TE2stGoGgGnFBiAUYHMAHgry3FyuM7x/tCcaE4DRlFzI/5cdwL+ls0ymzrNg7QAAAABJRU5ErkJggg=="},f868:function(t,o,e){var n,s;(function(i,l){n=l,s="function"===typeof n?n.call(o,e,o,t):n,void 0===s||(t.exports=s)})(0,(function(){var t=function(t,o){var e=this;if(e.version="1.4.0",e.isScrollBody=!t||"body"===t,e.scrollDom=e.isScrollBody?document.body:e.getDomById(t),e.scrollDom){e.options=o||{};var n=navigator.userAgent,s=!!n.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/),i="undefined"===typeof window.orientation,l=n.indexOf("Android")>-1||n.indexOf("Adr")>-1;e.os={ios:s,pc:i,android:l},e.isDownScrolling=!1,e.isUpScrolling=!1;var a=e.options.down&&e.options.down.callback;e.initDownScroll(),e.initUpScroll(),setTimeout((function(){e.optDown.use&&e.optDown.auto&&a&&(e.optDown.autoShowLoading?e.triggerDownScroll():e.optDown.callback&&e.optDown.callback(e)),e.optUp.use&&e.optUp.auto&&!e.isUpAutoLoad&&e.triggerUpScroll()}),30)}};return t.prototype.extendDownScroll=function(o){t.extend(o,{use:!0,auto:!0,autoShowLoading:!1,isLock:!1,isBoth:!1,offset:80,inOffsetRate:1,outOffsetRate:.2,bottomOffset:20,minAngle:45,hardwareClass:"mescroll-hardware",mustToTop:!1,warpId:null,warpClass:"mescroll-downwarp",resetClass:"mescroll-downwarp-reset",textInOffset:"下拉刷新",textOutOffset:"释放更新",textLoading:"加载中 ...",htmlContent:'<p class="downwarp-progress"></p><p class="downwarp-tip"></p>',inited:function(t,o){t.downTipDom=o.getElementsByClassName("downwarp-tip")[0],t.downProgressDom=o.getElementsByClassName("downwarp-progress")[0]},inOffset:function(t){t.downTipDom&&(t.downTipDom.innerHTML=t.optDown.textInOffset),t.downProgressDom&&t.downProgressDom.classList.remove("mescroll-rotate")},outOffset:function(t){t.downTipDom&&(t.downTipDom.innerHTML=t.optDown.textOutOffset)},onMoving:function(t,o,e){if(t.downProgressDom){var n=360*o;t.downProgressDom.style.webkitTransform="rotate("+n+"deg)",t.downProgressDom.style.transform="rotate("+n+"deg)"}},beforeLoading:function(t,o){return!1},showLoading:function(t){t.downTipDom&&(t.downTipDom.innerHTML=t.optDown.textLoading),t.downProgressDom&&t.downProgressDom.classList.add("mescroll-rotate")},afterLoading:function(t){return 0},callback:function(t){t.resetUpScroll()}})},t.prototype.extendUpScroll=function(o){var e=this.os.pc;t.extend(o,{use:!0,auto:!0,isLock:!1,isBoth:!1,isBounce:!0,callback:null,page:{num:0,size:10,time:null},noMoreSize:5,offset:100,toTop:{warpId:null,src:null,html:null,offset:1e3,warpClass:"mescroll-totop",showClass:"mescroll-fade-in",hideClass:"mescroll-fade-out",fadeDuration:.5,duration:300,supportTap:!1,btnClick:null},loadFull:{use:!1,delay:500},empty:{warpId:null,icon:null,tip:"暂无相关数据~",btntext:"",btnClick:null,supportTap:!1},clearId:null,clearEmptyId:null,hardwareClass:"mescroll-hardware",warpId:null,warpClass:"mescroll-upwarp",htmlLoading:'<p class="upwarp-progress mescroll-rotate"></p><p class="upwarp-tip">加载中..</p>',htmlNodata:'<p class="upwarp-nodata">-- END --</p>',inited:function(t,o){},showLoading:function(t,o){o.innerHTML=t.optUp.htmlLoading},showNoMore:function(t,o){o.innerHTML=t.optUp.htmlNodata},onScroll:null,scrollbar:{use:e,barClass:"mescroll-bar"},lazyLoad:{use:!1,attr:"imgurl",showClass:"mescroll-lazy-in",delay:500,offset:200}})},t.extend=function(o,e){if(!o)return e;for(var n in e)null==o[n]?o[n]=e[n]:"object"===typeof o[n]&&t.extend(o[n],e[n]);return o},t.prototype.initDownScroll=function(){var t=this;if(t.optDown=t.options.down||{},t.extendDownScroll(t.optDown),t.touchstartEvent=function(o){t.isScrollTo&&t.preventDefault(o),t.startPoint=t.getPoint(o),t.lastPoint=t.startPoint,t.maxTouchmoveY=t.getBodyHeight()-t.optDown.bottomOffset,t.inTouchend=!1;var e=t.getScrollTop();t.isKeepTop=0===e,t.os.pc&&e<=0&&(t.scrollDom.addEventListener("mousemove",t.touchmoveEvent,{passive:!1}),document.ondragstart=function(){return!1})},t.scrollDom.addEventListener("mousedown",t.touchstartEvent),t.scrollDom.addEventListener("touchstart",t.touchstartEvent),t.touchmoveEvent=function(o){if(t.startPoint){var e=t.getScrollTop();e>0&&(t.isKeepTop=!1);var n=t.getPoint(o),s=n.y-t.startPoint.y;if(s>0){if(e<=0&&(t.preventDefault(o),t.optDown.use&&!t.inTouchend&&!t.isDownScrolling&&!t.optDown.isLock&&(!t.isUpScrolling||t.isUpScrolling&&t.optUp.isBoth))){if(t.optDown.mustToTop&&!t.isKeepTop)return;var i=Math.abs(t.lastPoint.x-n.x),l=Math.abs(t.lastPoint.y-n.y),a=Math.sqrt(i*i+l*l);if(0!==a){var r=Math.asin(l/a)/Math.PI*180;if(r<t.optDown.minAngle)return}if(t.maxTouchmoveY>0&&n.y>=t.maxTouchmoveY)return t.inTouchend=!0,void t.touchendEvent();var c=n.y-t.lastPoint.y;t.downHight||(t.downHight=0),t.downHight<t.optDown.offset?(1!==t.movetype&&(t.movetype=1,t.optDown.inOffset(t),t.downwarp.classList.remove(t.optDown.resetClass),t.isMoveDown=!0,t.os.ios&&!t.isKeepTop&&(t.scrollDom.classList.add(t.optDown.hardwareClass),t.scrollDom.style.webkitOverflowScrolling="auto",t.isSetScrollAuto=!0)),t.downHight+=c*t.optDown.inOffsetRate):(2!==t.movetype&&(t.movetype=2,t.optDown.outOffset(t),t.downwarp.classList.remove(t.optDown.resetClass),t.isMoveDown=!0,t.os.ios&&!t.isKeepTop&&(t.scrollDom.classList.add(t.optDown.hardwareClass),t.scrollDom.style.webkitOverflowScrolling="auto",t.isSetScrollAuto=!0)),t.downHight+=c>0?c*t.optDown.outOffsetRate:c),t.downwarp.style.height=t.downHight+"px";var p=t.downHight/t.optDown.offset;t.optDown.onMoving(t,p,t.downHight)}}else if(s<0){var u=t.getScrollHeight(),d=t.getClientHeight(),h=u-d-e;!t.optUp.isBounce&&h<=0&&t.preventDefault(o),t.optUp.use&&!t.optUp.isLock&&t.optUp.hasNext&&!t.isUpScrolling&&(!t.isDownScrolling||t.isDownScrolling&&t.optDown.isBoth)&&(d+t.optUp.offset>=u||h<=0)&&t.triggerUpScroll()}t.lastPoint=n}},t.scrollDom.addEventListener("touchmove",t.touchmoveEvent,{passive:!1}),t.touchendEvent=function(){t.optDown.use&&t.isMoveDown&&(t.downHight>=t.optDown.offset?t.triggerDownScroll():(t.downwarp.classList.add(t.optDown.resetClass),t.downHight=0,t.downwarp.style.height=0),t.isSetScrollAuto&&(t.scrollDom.style.webkitOverflowScrolling="touch",t.scrollDom.classList.remove(t.optDown.hardwareClass),t.isSetScrollAuto=!1),t.movetype=0,t.isMoveDown=!1),t.os.pc&&(t.scrollDom.removeEventListener("mousemove",t.touchmoveEvent),document.ondragstart=function(){return!0})},t.scrollDom.addEventListener("mouseup",t.touchendEvent),t.scrollDom.addEventListener("mouseleave",t.touchendEvent),t.scrollDom.addEventListener("touchend",t.touchendEvent),t.scrollDom.addEventListener("touchcancel",t.touchendEvent),t.optDown.use){t.downwarp=document.createElement("div"),t.downwarp.className=t.optDown.warpClass,t.downwarp.innerHTML='<div class="downwarp-content">'+t.optDown.htmlContent+"</div>";var o=t.optDown.warpId?t.getDomById(t.optDown.warpId):t.scrollDom;t.optDown.warpId&&o?o.appendChild(t.downwarp):(o||(o=t.scrollDom),o.insertBefore(t.downwarp,t.scrollDom.firstChild)),setTimeout((function(){t.optDown.inited(t,t.downwarp)}),0)}},t.prototype.preventDefault=function(t){t&&t.cancelable&&!t.defaultPrevented&&t.preventDefault()},t.prototype.getPoint=function(t){return{x:t.touches?t.touches[0].pageX:t.clientX,y:t.touches?t.touches[0].pageY:t.clientY}},t.prototype.triggerDownScroll=function(){this.optDown.beforeLoading(this,this.downwarp)||(this.showDownScroll(),this.optDown.callback&&this.optDown.callback(this))},t.prototype.showDownScroll=function(){this.isDownScrolling=!0,this.optDown.showLoading(this),this.downHight=this.optDown.offset,this.downwarp.classList.add(this.optDown.resetClass),this.downwarp.style.height=this.optDown.offset+"px"},t.prototype.endDownScroll=function(){var t=this,o=function(){t.downHight=0,t.downwarp.style.height=0,t.isDownScrolling=!1,t.downProgressDom&&t.downProgressDom.classList.remove("mescroll-rotate")},e=t.optDown.afterLoading(t);"number"===typeof e&&e>0?setTimeout(o,e):o()},t.prototype.lockDownScroll=function(t){null==t&&(t=!0),this.optDown.isLock=t},t.prototype.initUpScroll=function(){var t,o=this;(o.optUp=o.options.up||{use:!1},o.extendUpScroll(o.optUp),o.optUp.scrollbar.use&&o.scrollDom.classList.add(o.optUp.scrollbar.barClass),o.optUp.isBounce||o.setBounce(!1),!1!==o.optUp.use)&&(o.optUp.hasNext=!0,o.upwarp=document.createElement("div"),o.upwarp.className=o.optUp.warpClass,o.optUp.warpId&&(t=o.getDomById(o.optUp.warpId)),t||(t=o.scrollDom),t.appendChild(o.upwarp),o.preScrollY=0,o.lazyStartTime=(new Date).getTime(),o.lazyTag="mescroll-lazying",o.scrollEvent=function(){var t=o.getScrollTop(),e=t-o.preScrollY>0;if(o.preScrollY=t,!o.isUpScrolling&&(!o.isDownScrolling||o.isDownScrolling&&o.optDown.isBoth)&&!o.optUp.isLock&&o.optUp.hasNext){var n=o.getScrollHeight()-o.getClientHeight()-t;n<=o.optUp.offset&&e&&o.triggerUpScroll()}var s=o.optUp.toTop;if((s.src||s.html)&&(t>=s.offset?o.showTopBtn():o.hideTopBtn()),o.optUp.lazyLoad.use){var i=(new Date).getTime();o.lazyTimer&&clearTimeout(o.lazyTimer),i-o.lazyStartTime>=o.optUp.lazyLoad.delay?(o.lazyStartTime=i,o.lazyLoad(0)):o.lazyTimer=o.lazyLoad()}o.optUp.onScroll&&o.optUp.onScroll(o,t,e)},o.isScrollBody?window.addEventListener("scroll",o.scrollEvent):o.scrollDom.addEventListener("scroll",o.scrollEvent),setTimeout((function(){o.optUp.inited(o,o.upwarp)}),0))},t.prototype.setBounce=function(t){!this.isScrollBody&&this.os.ios&&(!1===t?(this.optUp.isBounce=!1,window.addEventListener("touchmove",this.bounceTouchmove,{passive:!1})):(this.optUp.isBounce=!0,window.removeEventListener("touchmove",this.bounceTouchmove)))},t.prototype.bounceTouchmove=function(t){var o=this,e=t.target,n=!0;while(e!==document.body&&e!==document){var s=e.classList;if(s){if(s.contains("mescroll")||s.contains("mescroll-touch")){n=!1;break}if(s.contains("mescroll-touch-x")||s.contains("mescroll-touch-y")){var i=t.touches?t.touches[0].pageX:t.clientX,l=t.touches?t.touches[0].pageY:t.clientY;o.preWinX||(o.preWinX=i),o.preWinY||(o.preWinY=l);var a=Math.abs(o.preWinX-i),r=Math.abs(o.preWinY-l),c=Math.sqrt(a*a+r*r);if(o.preWinX=i,o.preWinY=l,0!==c){var p=Math.asin(r/c)/Math.PI*180;if(p<=45&&s.contains("mescroll-touch-x")||p>45&&s.contains("mescroll-touch-y")){n=!1;break}}}}e=e.parentNode}n&&t.cancelable&&!t.defaultPrevented&&"function"===typeof t.preventDefault&&t.preventDefault()},t.prototype.triggerUpScroll=function(){this.optUp.callback&&!this.isUpScrolling&&(this.showUpScroll(),this.optUp.page.num++,this.isUpAutoLoad=!0,this.optUp.callback(this.optUp.page,this))},t.prototype.showUpScroll=function(){this.isUpScrolling=!0,this.upwarp.classList.add(this.optUp.hardwareClass),this.upwarp.style.visibility="visible",this.upwarp.style.display="block",this.optUp.showLoading(this,this.upwarp)},t.prototype.showNoMore=function(){this.upwarp.style.visibility="visible",this.upwarp.style.display="block",this.optUp.hasNext=!1,this.optUp.showNoMore(this,this.upwarp)},t.prototype.hideUpScroll=function(t){t?this.upwarp.style.display="none":this.upwarp.style.visibility="hidden",this.upwarp.classList.remove(this.optUp.hardwareClass);var o=this.upwarp.getElementsByClassName("upwarp-progress")[0];o&&o.classList.remove("mescroll-rotate")},t.prototype.endUpScroll=function(t,o){null!=t&&(t?this.showNoMore():this.hideUpScroll(o)),this.isUpScrolling=!1},t.prototype.resetUpScroll=function(t){if(this.optUp&&this.optUp.use){var o=this.optUp.page;this.prePageNum=o.num,this.prePageTime=o.time,o.num=1,o.time=null,this.isDownScrolling||!1===t||(null==t?(this.removeEmpty(),this.clearDataList(),this.showUpScroll()):this.showDownScroll()),this.isUpAutoLoad=!0,this.optUp.callback&&this.optUp.callback(o,this)}},t.prototype.setPageNum=function(t){this.optUp.page.num=t-1},t.prototype.setPageSize=function(t){this.optUp.page.size=t},t.prototype.clearDataList=function(){var t=this.optUp.clearId||this.optUp.clearEmptyId;if(t){var o=this.getDomById(t);o&&(o.innerHTML="")}},t.prototype.endByPage=function(t,o,e){var n;this.optUp.use&&null!=o&&(n=this.optUp.page.num<o),this.endSuccess(t,n,e)},t.prototype.endBySize=function(t,o,e){var n;if(this.optUp.use&&null!=o){var s=(this.optUp.page.num-1)*this.optUp.page.size+t;n=s<o}this.endSuccess(t,n,e)},t.prototype.endSuccess=function(t,o,e){var n=this;if(n.isDownScrolling&&n.endDownScroll(),n.optUp.use){var s;if(null!=t){var i=n.optUp.page.num,l=n.optUp.page.size;if(1===i&&(n.clearDataList(),e&&(n.optUp.page.time=e)),t<l||!1===o)if(n.optUp.hasNext=!1,0===t&&1===i)s=!1,n.showEmpty();else{var a=(i-1)*l+t;s=!(a<n.optUp.noMoreSize),n.removeEmpty()}else s=!1,n.optUp.hasNext=!0,n.removeEmpty()}var r=!n.optUp.hasNext;n.endUpScroll(s,r),n.loadFull(),n.optUp.lazyLoad.use&&n.lazyLoad(16)}},t.prototype.endErr=function(){if(this.isDownScrolling){var t=this.optUp.page;t&&this.prePageNum&&(t.num=this.prePageNum,t.time=this.prePageTime),this.endDownScroll()}this.isUpScrolling&&(this.optUp.page.num--,this.endUpScroll(!1))},t.prototype.loadFull=function(){var t=this;t.optUp.loadFull.use&&!t.optUp.isLock&&t.optUp.hasNext&&t.optUp.callback&&t.getScrollHeight()<=t.getClientHeight()&&setTimeout((function(){t.getScrollHeight()<=t.getClientHeight()&&t.triggerUpScroll()}),t.optUp.loadFull.delay)},t.prototype.lockUpScroll=function(t){null==t&&(t=!0),this.optUp.isLock=t},t.prototype.showEmpty=function(){var t=this,o=t.optUp.empty,e=o.warpId||t.optUp.clearEmptyId;if(null!=e){var n=t.getDomById(e);if(n){t.removeEmpty();var s="";if(o.icon&&(s+='<img class="empty-icon" src="'+o.icon+'"/>'),o.tip&&(s+='<p class="empty-tip">'+o.tip+"</p>"),o.btntext&&(s+='<p class="empty-btn">'+o.btntext+"</p>"),t.emptyDom=document.createElement("div"),t.emptyDom.className="mescroll-empty",t.emptyDom.innerHTML=s,n.appendChild(t.emptyDom),o.btnClick){var i=t.emptyDom.getElementsByClassName("empty-btn")[0];o.supportTap?i.addEventListener("tap",(function(e){e.stopPropagation(),t.preventDefault(e),o.btnClick()})):i.onclick=function(){o.btnClick()}}}}},t.prototype.removeEmpty=function(){this.removeChild(this.emptyDom)},t.prototype.showTopBtn=function(t){if(!this.topBtnShow){this.topBtnShow=!0;var o,e=this,n=e.optUp.toTop;if(null==e.toTopBtn)n.html?(e.toTopBtn=document.createElement("div"),e.toTopBtn.innerHTML=n.html):(e.toTopBtn=document.createElement("img"),e.toTopBtn.src=n.src),e.toTopBtn.className=n.warpClass,n.supportTap?e.toTopBtn.addEventListener("tap",(function(t){t.stopPropagation(),e.preventDefault(t);var o=n.btnClick&&n.btnClick();!0!==o&&e.scrollTo(0,e.optUp.toTop.duration)})):e.toTopBtn.onclick=function(){var t=n.btnClick&&n.btnClick();!0!==t&&e.scrollTo(0,e.optUp.toTop.duration)},n.warpId&&(o=e.getDomById(n.warpId)),o||(o=document.body),o.appendChild(e.toTopBtn);e.toTopBtn.classList.remove(n.hideClass),e.toTopBtn.classList.add(n.showClass),e.setTopBtnFadeDuration(t)}},t.prototype.hideTopBtn=function(t){this.topBtnShow&&this.toTopBtn&&(this.topBtnShow=!1,this.toTopBtn.classList.remove(this.optUp.toTop.showClass),this.toTopBtn.classList.add(this.optUp.toTop.hideClass),this.setTopBtnFadeDuration(t))},t.prototype.setTopBtnFadeDuration=function(t){if(this.toTopBtn){var o=(null!=t?t:this.optUp.toTop.fadeDuration)+"s";this.toTopBtn.style.animationDuration=o,this.toTopBtn.style.webkitAnimationDuration=o}},t.prototype.scrollTo=function(t,o){var e=this,n=e.getScrollTop(),s=t;if(s>0){var i=e.getScrollHeight()-e.getClientHeight();s>i&&(s=i)}else s=0;e.isScrollTo=!0,e.scrollDom.style.webkitOverflowScrolling="auto",e.getStep(n,s,(function(t){e.setScrollTop(t),t===s&&(e.scrollDom.style.webkitOverflowScrolling="touch",e.isScrollTo=!1)}),o)},t.prototype.getStep=function(t,o,e,n,s){var i=o-t;if(0!==n&&0!==i){n=n||300,s=s||30;var l=n/s,a=i/l,r=0,c=window.setInterval((function(){r<l-1?(t+=a,e&&e(t,c),r++):(e&&e(o,c),window.clearInterval(c))}),s)}else e&&e(o)},t.prototype.lazyLoad=function(t){var o=this,e=null!=t?t:o.optUp.lazyLoad.delay,n=setTimeout((function(){for(var t=o.scrollDom.querySelectorAll("["+o.optUp.lazyLoad.attr+"]"),e=t.length,n=0;n<e;n++){var s=t[n];if("true"!==s.getAttribute(o.lazyTag)&&o.isInSee(s,o.optUp.lazyLoad.offset)){var i=s.getAttribute(o.optUp.lazyLoad.attr),l=new Image;l.onload=function(){var t=this.src,e=this.dom,n=o.optUp.lazyLoad.showClass;n&&e.classList.add(n),"IMG"===e.tagName?e.src=t:e.style.backgroundImage="url("+t+")",e.removeAttribute(o.optUp.lazyLoad.attr),e.removeAttribute(o.lazyTag)},l.onerror=function(){this.dom.removeAttribute(o.lazyTag)},l.onabort=function(){this.dom.removeAttribute(o.lazyTag)},l.src=i,s.setAttribute(o.lazyTag,"true"),l.dom=s}}}),e);return n},t.prototype.isInSee=function(t,o){o=o||0;var e=this.getOffsetTop(t),n=this.getScrollTop()-o,s=e+t.offsetHeight,i=n+o+this.getClientHeight()+o;return e<i&&e>=n||s<=i&&s>n},t.prototype.getOffsetTop=function(t){var o=t.offsetTop,e=t.offsetParent;while(null!=e&&e!==this.scrollDom)o+=e.offsetTop+e.clientTop,e=e.offsetParent;return o},t.prototype.getScrollHeight=function(){return this.scrollDom.scrollHeight},t.prototype.getClientHeight=function(){return this.isScrollBody&&"CSS1Compat"===document.compatMode?document.documentElement.clientHeight:this.scrollDom.clientHeight},t.prototype.getBodyHeight=function(){return document.body.clientHeight||document.documentElement.clientHeight},t.prototype.getScrollTop=function(){return this.isScrollBody?document.documentElement.scrollTop||document.body.scrollTop:this.scrollDom.scrollTop},t.prototype.getToBottom=function(){return this.getScrollHeight()-this.getClientHeight()-this.getScrollTop()},t.prototype.setScrollTop=function(t){"number"===typeof t&&(this.isScrollBody?(document.documentElement.scrollTop=t,document.body.scrollTop=t):this.scrollDom.scrollTop=t)},t.prototype.getDomById=function(t){var o;return t&&("string"===typeof t?o=document.getElementById(t):t.nodeType&&(o=t)),o||console.error('the element with id as "'+t+'" can not be found: document.getElementById("'+t+'")==null'),o},t.prototype.removeChild=function(t){if(t){var o=t.parentNode;o&&o.removeChild(t),t=null}},t.prototype.destroy=function(){var t=this;t.scrollDom.removeEventListener("touchstart",t.touchstartEvent),t.scrollDom.removeEventListener("touchmove",t.touchmoveEvent),t.scrollDom.removeEventListener("touchend",t.touchendEvent),t.scrollDom.removeEventListener("touchcancel",t.touchendEvent),t.scrollDom.removeEventListener("mousedown",t.touchstartEvent),t.scrollDom.removeEventListener("mousemove",t.touchmoveEvent),t.scrollDom.removeEventListener("mouseup",t.touchendEvent),t.scrollDom.removeEventListener("mouseleave",t.touchendEvent),t.removeChild(t.downwarp),t.isScrollBody?window.removeEventListener("scroll",t.scrollEvent):t.scrollDom.removeEventListener("scroll",t.scrollEvent),t.removeChild(t.upwarp),t.removeChild(t.toTopBtn),t.setBounce(!0)},t}))}}]);
|