text: webpackJsonp([5],{CADk:function(t,e){},V7yS:function(t,e){},"Vf/K":function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=i("Gu7T"),s=i.n(n),o=i("woOf"),a=i.n(o),r=i("Dd8w"),h=i.n(r),c=i("fxnj"),d=i.n(c),l=i("NYxO"),u=i("qV47"),f=i("4FCr"),p=i("pFYg"),m=i.n(p);function v(t,e){!/^javas/.test(t)&&t&&("object"===(void 0===t?"undefined":m()(t))||e&&"string"==typeof t&&!/http/.test(t)?"object"===(void 0===t?"undefined":m()(t))&&!0===t.replace?e.replace(t):"BACK"===t?e.go(-1):e.push(t):window.location.href=t)}var g={mounted:function(){this.value>=0&&(this.currentIndex=this.value),this.updateIndex()},methods:{updateIndex:function(){if(this.$children&&this.$children.length){this.number=this.$children.length;for(var t=this.$children,e=0;e<t.length;e++)t[e].currentIndex=e,t[e].currentSelected&&(this.index=e)}}},props:{value:Number},watch:{currentIndex:function(t,e){e>-1&&this.$children[e]&&(this.$children[e].currentSelected=!1),t>-1&&this.$children[t]&&(this.$children[t].currentSelected=!0),this.$emit("input",t),this.$emit("on-index-change",t,e)},index:function(t){this.currentIndex=t},value:function(t){this.index=t}},data:function(){return{index:-1,currentIndex:this.index,number:this.$children.length}}},_={props:{selected:{type:Boolean,default:!1}},mounted:function(){this.$parent.updateIndex()},beforeDestroy:function(){var t=this.$parent;this.$nextTick(function(){t.updateIndex()})},methods:{onItemClick:function(t){var e=this;this.$parent.preventDefault?this.$parent.$emit("on-before-index-change",this.currentIndex):(void 0!==this.disabled&&!1!==this.disabled||(this.currentSelected=!0,this.$parent.currentIndex=this.currentIndex,this.$nextTick(function(){e.$emit("on-item-click",e.currentIndex)})),!0===t&&v(this.link,this.$router))}},watch:{currentSelected:function(t){t&&(this.$parent.index=this.currentIndex)},selected:function(t){this.currentSelected=t}},data:function(){return{currentIndex:-1,currentSelected:this.selected}}},x=(Number,String,String,String,String,Boolean,Function,String,Boolean,{name:"tab",mixins:[g],mounted:function(){var t=this;this.$nextTick(function(){setTimeout(function(){t.hasReady=!0},0)})},props:{lineWidth:{type:Number,default:3},activeColor:String,barActiveColor:String,defaultColor:String,disabledColor:String,animate:{type:Boolean,default:!0},customBarWidth:[Function,String],preventDefault:Boolean},computed:{barLeft:function(){return this.currentIndex*(100/this.number)+"%"},barRight:function(){return(this.number-this.currentIndex-1)*(100/this.number)+"%"},innerBarStyle:function(){return{width:"function"==typeof this.customBarWidth?this.customBarWidth(this.currentIndex):this.customBarWidth,backgroundColor:this.barActiveColor||this.activeColor}},barStyle:function(){var t={left:this.barLeft,right:this.barRight,display:"block",height:this.lineWidth+"px",transition:this.hasReady?null:"none"};return this.customBarWidth?t.backgroundColor="transparent":t.backgroundColor=this.barActiveColor||this.activeColor,t},barClass:function(){return{"vux-tab-ink-bar-transition-forward":"forward"===this.direction,"vux-tab-ink-bar-transition-backward":"backward"===this.direction}}},watch:{currentIndex:function(t,e){this.direction=t>e?"forward":"backward",this.$emit("on-index-change",t,e)}},data:function(){return{direction:"forward",right:"100%",hasReady:!1}}}),b={render:function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"vux-tab",class:{"vux-tab-no-animate":!t.animate}},[t._t("default"),t._v(" "),t.animate?i("div",{staticClass:"vux-tab-ink-bar",class:t.barClass,style:t.barStyle},[t.customBarWidth?i("span",{staticClass:"vux-tab-bar-inner",style:t.innerBarStyle}):t._e()]):t._e()],2)},staticRenderFns:[]};var y=i("VU/8")(x,b,!1,function(t){i("X4DQ")},null,null).exports,w=i("taJy"),k=(String,Boolean,String,String,String,{name:"tab-item",mixins:[_],props:{activeClass:String,disabled:Boolean,badgeBackground:{type:String,default:"#f74c31"},badgeColor:{type:String,default:"#fff"},badgeLabel:String},computed:{style:function(){return{borderWidth:this.$parent.lineWidth+"px",borderColor:this.$parent.activeColor,color:this.currentSelected?this.$parent.activeColor:this.disabled?this.$parent.disabledColor:this.$parent.defaultColor,border:this.$parent.animate?"none":"auto"}}}}),C={render:function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"vux-tab-item",class:[t.currentSelected?t.activeClass:"",{"vux-tab-selected":t.currentSelected,"vux-tab-disabled":t.disabled}],style:t.style,on:{click:t.onItemClick}},[t._t("default"),t._v(" "),void 0!==t.badgeLabel&&""!==t.badgeLabel?i("span",{staticClass:"vux-tab-item-badge",style:{background:t.badgeBackground,color:t.badgeColor}},[t._v("\n  "+t._s(t.badgeLabel))]):t._e()],2)},staticRenderFns:[]},I=i("VU/8")(k,C,!1,null,null,null).exports,$=i("mvHQ"),O=i.n($),S=i("Zrlr"),T=i.n(S),L=i("wxAW"),j=i.n(L),R=i("BEQ0"),D=i.n(R),E=function(t){return Array.prototype.slice.call(t)},B=function(){function t(e){if(T()(this,t),this._default={container:".vux-swiper",item:".vux-swiper-item",direction:"vertical",activeClass:"active",threshold:50,duration:300,auto:!1,loop:!1,interval:3e3,height:"auto",minMovingDistance:0},this._options=D()(this._default,e),this._options.height=this._options.height.replace("px",""),this._start={},this._move={},this._end={},this._eventHandlers={},this._prev=this._current=this._goto=0,this._width=this._height=this._distance=0,this._offset=[],this.$box=this._options.container,this.$container=this._options.container.querySelector(".vux-swiper"),this.$items=this.$container.querySelectorAll(this._options.item),this.count=this.$items.length,this.realCount=this.$items.length,this._position=[],this._firstItemIndex=0,this.count)return this._init(),this._auto(),this._bind(),this._onResize(),this}return j()(t,[{key:"_auto",value:function(){var t=this;t.stop(),t._options.auto&&(t.timer=setTimeout(function(){t.next()},t._options.interval))}},{key:"updateItemWidth",value:function(){this._width=this.$box.offsetWidth||document.documentElement.offsetWidth,this._distance="horizontal"===this._options.direction?this._width:this._height}},{key:"stop",value:function(){this.timer&&clearTimeout(this.timer)}},{key:"_loop",value:function(){return this._options.loop&&this.realCount>=3}},{key:"_onResize",value:function(){var t=this;this.resizeHandler=function(){setTimeout(function(){t.updateItemWidth(),t._setOffset(),t._setTransform()},100)},window.addEventListener("orientationchange",this.resizeHandler,!1)}},{key:"_init",value:function(){this._height="auto"===this._options.height?"auto":this._options.height-0,this.updateItemWidth(),this._initPosition(),this._activate(this._current),this._setOffset(),this._setTransform(),this._loop()&&this._loopRender()}},{key:"_initPosition",value:function(){for(var t=0;t<this.realCount;t++)this._position.push(t)}},{key:"_movePosition",value:function(t){if(t>0){var e=this._position.splice(0,1);this._position.push(e[0])}else if(t<0){var i=this._position.pop();this._position.unshift(i)}}},{key:"_setOffset",value:function(){var t=this,e=t._position.indexOf(t._current);t._offset=[],E(t.$items).forEach(function(i,n){t._offset.push((n-e)*t._distance)})}},{key:"_setTransition",value:function(t){var e="none"===(t=t||this._options.duration||"none")?"none":t+"ms";E(this.$items).forEach(function(t,i){t.style.webkitTransition=e,t.style.transition=e})}},{key:"_setTransform",value:function(t){var e=this;t=t||0,E(e.$items).forEach(function(i,n){var s=e._offset[n]+t,o="translate3d("+s+"px, 0, 0)";"vertical"===e._options.direction&&(o="translate3d(0, "+s+"px, 0)"),i.style.webkitTransform=o,i.style.transform=o})}},{key:"_bind",value:function(){var t=this,e=this;e.touchstartHandler=function(t){e.stop(),e._start.x=t.changedTouches[0].pageX,e._start.y=t.changedTouches[0].pageY,e._setTransition("none")},e.touchmoveHandler=function(i){if(1!==e.count){e._move.x=i.changedTouches[0].pageX,e._move.y=i.changedTouches[0].pageY;var n=e._move.x-e._start.x,s=e._move.y-e._start.y,o=s,a=Math.abs(n)>Math.abs(s);"horizontal"===e._options.direction&&a&&(o=n),t._options.loop||t._current!==t.count-1&&0!==t._current||(o/=3),(e._options.minMovingDistance&&Math.abs(o)>=e._options.minMovingDistance||!e._options.minMovingDistance)&&a&&e._setTransform(o),a&&i.preventDefault()}},e.touchendHandler=function(t){if(1!==e.count){e._end.x=t.changedTouches[0].pageX,e._end.y=t.changedTouches[0].pageY;var i=e._end.y-e._start.y;"horizontal"===e._options.direction&&(i=e._end.x-e._start.x),0!==(i=e.getDistance(i))&&e._options.minMovingDistance&&Math.abs(i)<e._options.minMovingDistance||(i>e._options.threshold?e.move(-1):i<-e._options.threshold?e.move(1):e.move(0),e._loopRender())}},e.transitionEndHandler=function(t){e._activate(e._current);var i=e._eventHandlers.swiped;i&&i.apply(e,[e._prev%e.count,e._current%e.count]),e._auto(),e._loopRender(),t.preventDefault()},e.$container.addEventListener("touchstart",e.touchstartHandler,!1),e.$container.addEventListener("touchmove",e.touchmoveHandler,!1),e.$container.addEventListener("touchend",e.touchendHandler,!1),e.$items[1]&&e.$items[1].addEventListener("webkitTransitionEnd",e.transitionEndHandler,!1)}},{key:"_loopRender",value:function(){var t=this;t._loop()&&(0===t._offset[t._offset.length-1]?(t.$container.appendChild(t.$items[0]),t._loopEvent(1)):0===t._offset[0]&&(t.$container.insertBefore(t.$items[t.$items.length-1],t.$container.firstChild),t._loopEvent(-1)))}},{key:"_loopEvent",value:function(t){var e=this;e._itemDestoy(),e.$items=e.$container.querySelectorAll(e._options.item),e.$items[1]&&e.$items[1].addEventListener("webkitTransitionEnd",e.transitionEndHandler,!1),e._movePosition(t),e._setOffset(),e._setTransform()}},{key:"getDistance",value:function(t){return this._loop()?t:t>0&&0===this._current?0:t<0&&this._current===this.realCount-1?0:t}},{key:"_moveIndex",value:function(t){0!==t&&(this._prev=this._current,this._current+=this.realCount,this._current+=t,this._current%=this.realCount)}},{key:"_activate",value:function(t){var e=this._options.activeClass;Array.prototype.forEach.call(this.$items,function(i,n){i.classList.remove(e),t===Number(i.dataset.index)&&i.classList.add(e)})}},{key:"go",value:function(t){var e=this;return e.stop(),t=t||0,t+=this.realCount,t%=this.realCount,t=this._position.indexOf(t)-this._position.indexOf(this._current),e._moveIndex(t),e._setOffset(),e._setTransition(),e._setTransform(),e._auto(),this}},{key:"next",value:function(){return this.move(1),this}},{key:"move",value:function(t){return this.go(this._current+t),this}},{key:"on",value:function(t,e){return this._eventHandlers[t]&&console.error("[swiper] event "+t+" is already register"),"function"!=typeof e&&console.error("[swiper] parameter callback must be a function"),this._eventHandlers[t]=e,this}},{key:"_itemDestoy",value:function(){var t=this;this.$items.length&&E(this.$items).forEach(function(e){e.removeEventListener("webkitTransitionEnd",t.transitionEndHandler,!1)})}},{key:"destroy",value:function(){if(this.stop(),this._current=0,this._setTransform(0),window.removeEventListener("orientationchange",this.resizeHandler,!1),this.$container.removeEventListener("touchstart",this.touchstartHandler,!1),this.$container.removeEventListener("touchmove",this.touchmoveHandler,!1),this.$container.removeEventListener("touchend",this.touchendHandler,!1),this._itemDestoy(),this._options.loop&&2===this.count){var t=this.$container.querySelector(this._options.item+"-clone");t&&this.$container.removeChild(t),(t=this.$container.querySelector(this._options.item+"-clone"))&&this.$container.removeChild(t)}}}]),t}(),F=(Array,String,Boolean,Boolean,String,String,Boolean,Boolean,Number,Number,Number,String,Number,Number,Number,{name:"swiper",created:function(){this.index=this.value||0,this.index&&(this.current=this.index)},mounted:function(){var t=this;this.hasTwoLoopItem(),this.$nextTick(function(){t.list&&0===t.list.length||t.render(t.index),t.xheight=t.getHeight(),t.$emit("on-get-height",t.xheight)})},methods:{hasTwoLoopItem:function(){2===this.list.length&&this.loop?this.listTwoLoopItem=this.list:this.listTwoLoopItem=[]},clickListItem:function(t){v(t.url,this.$router),this.$emit("on-click-list-item",JSON.parse(O()(t)))},buildBackgroundUrl:function(t){return t.fallbackImg?"url("+t.img+"), url("+t.fallbackImg+")":"url("+t.img+")"},render:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;this.swiper&&this.swiper.destroy(),this.swiper=new B({container:this.$el,direction:this.direction,auto:this.auto,loop:this.loop,interval:this.interval,threshold:this.threshold,duration:this.duration,height:this.height||this._height,minMovingDistance:this.minMovingDistance,imgList:this.imgList}).on("swiped",function(e,i){t.current=i%t.length,t.index=i%t.length}),e>0&&this.swiper.go(e)},rerender:function(){var t=this;this.$el&&!this.hasRender&&(this.hasRender=!0,this.hasTwoLoopItem(),this.$nextTick(function(){t.index=t.value||0,t.current=t.value||0,t.length=t.list.length||t.$children.length,t.destroy(),t.render(t.value)}))},destroy:function(){this.hasRender=!1,this.swiper&&this.swiper.destroy()},getHeight:function(){var t=parseInt(this.height,10);return t?this.height:t?void 0:this.aspectRatio?this.$el.offsetWidth*this.aspectRatio+"px":"180px"}},props:{list:{type:Array,default:function(){return[]}},direction:{type:String,default:"horizontal"},showDots:{type:Boolean,default:!0},showDescMask:{type:Boolean,default:!0},dotsPosition:{type:String,default:"right"},dotsClass:String,auto:Boolean,loop:Boolean,interval:{type:Number,default:3e3},threshold:{type:Number,default:50},duration:{type:Number,default:300},height:{type:String,default:"auto"},aspectRatio:Number,minMovingDistance:{type:Number,default:0},value:{type:Number,default:0}},data:function(){return{hasRender:!1,current:this.index||0,xheight:"auto",length:this.list.length,index:0,listTwoLoopItem:[]}},watch:{auto:function(t){t?this.swiper&&this.swiper._auto():this.swiper&&this.swiper.stop()},list:function(t){this.rerender()},current:function(t){this.index=t,this.$emit("on-index-change",t)},index:function(t){var e=this;t!==this.current&&this.$nextTick(function(){e.swiper&&e.swiper.go(t)}),this.$emit("input",t)},value:function(t){this.index=t}},beforeDestroy:function(){this.destroy()}}),H={render:function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"vux-slider"},[i("div",{staticClass:"vux-swiper",style:{height:t.xheight}},[t._t("default"),t._v(" "),t._l(t.list,function(e,n){return i("div",{staticClass:"vux-swiper-item",attrs:{"data-index":n},on:{click:function(i){t.clickListItem(e)}}},[i("a",{attrs:{href:"javascript:"}},[i("div",{staticClass:"vux-img",style:{backgroundImage:t.buildBackgroundUrl(e)}}),t._v(" "),t.showDescMask?i("p",{staticClass:"vux-swiper-desc"},[t._v(t._s(e.title))]):t._e()])])}),t._v(" "),t._l(t.listTwoLoopItem,function(e,n){return t.listTwoLoopItem.length>0?i("div",{staticClass:"vux-swiper-item vux-swiper-item-clone",attrs:{"data-index":n},on:{click:function(i){t.clickListItem(e)}}},[i("a",{attrs:{href:"javascript:"}},[i("div",{staticClass:"vux-img",style:{backgroundImage:t.buildBackgroundUrl(e)}}),t._v(" "),t.showDescMask?i("p",{staticClass:"vux-swiper-desc"},[t._v(t._s(e.title))]):t._e()])]):t._e()})],2),t._v(" "),i("div",{directives:[{name:"show",rawName:"v-show",value:t.showDots,expression:"showDots"}],class:[t.dotsClass,"vux-indicator","vux-indicator-"+t.dotsPosition]},t._l(t.length,function(e){return i("a",{attrs:{href:"javascript:"}},[i("i",{staticClass:"vux-icon-dot",class:{active:e-1===t.current}})])}))])},staticRenderFns:[]};var N=i("VU/8")(F,H,!1,function(t){i("V7yS")},null,null).exports,z={render:function(){var t=this.$createElement;return(this._self._c||t)("div",{staticClass:"vux-swiper-item"},[this._t("default")],2)},staticRenderFns:[]},W=i("VU/8")({name:"swiper-item",mounted:function(){var t=this;this.$nextTick(function(){t.$parent.rerender()})},beforeDestroy:function(){var t=this.$parent;this.$nextTick(function(){t.rerender()})}},z,!1,null,null,null).exports,P=i("62KO"),q=(f.a,w.a,P.a,u.a,h()({},Object(l.b)(["orderList","orderCancelReason","cancelOrder","deleteOrder","confirmReceipt"]),{shopping:function(){d.a.miniProgram.switchTab({url:"/pages/home/index"})},sureOre:function(t){this.showLoading(),this.confirmReceipt({data:{orderId:t},this:this,s:1,method:this.confirmReceipt})},mo:function(){this.getList(0,this.demo)},onConfirm:function(t,e){this.listIndex=e,this.showLoading(),this.deleteOrder({data:{orderId:t},this:this,method:this.deleteOrder})},delOd:function(t,e){var i=this;this.$vux.confirm.show({content:"确认删除订单",onCancel:function(){},onConfirm:function(){i.onConfirm(t,e)}})},goBack:function(){this.hideLoading();var t=this.dataObj[this.index+""].list.slice(0);t.splice(this.listIndex,1),this.dataObj[this.index+""]=a()({},this.dataObj[this.index+""],{list:t})},cancelOrd:function(t){this.orderId=t,this.orderCancelReason({this:this}),this.show1=!0},setRe:function(t){t=t.map(function(t){return{name:t.description,value:t.description}}),this.menus1=[t]},hxcz:function(){this.showTost("取消订单成功"),this.getList(0,this.demo)},goCe:function(){console.log(this.slected[0]);var t={orderId:this.orderId,operateReason:this.slected[0]};this.cancelOrder({data:t,this:this}),this.show1=!1},choseWhy:function(t){console.log(t)},goDetail:function(t){this.def=!0,this.$router.push({name:"orderDetail",query:{id:t.orderId}})},qh:function(t,e){this.demo=e||this.list[t],this.index=t,"全部"==this.demo?this.dataObj[this.index+""].t&&this.getList(0):this.dataObj[this.index+""].t&&this.getList(0,this.demo)},getList:function(t,e,i){this.hideTost(),this.showLoading(),e||(e=""),"全部"==e&&(e=""),this.orderList({method:this.orderList,this:this,size:i||"",data:{page:t,pageSize:this.pageSize,orderStatusType:e}})},ontouchstart:function(t){this.sy=t.changedTouches[0].pageY},ontouchend:function(t){this.ey=t.changedTouches[0].pageY,this.sy-this.ey>30&&this.bindScroll(),this.ey-this.sy>50&&this.reFresh()},seeWl:function(t){var e=t.companyId,i=t.deliverId;i&&e?window.location.href="https://m.kuaidi100.com/index_all.html?callbackurl="+this.sendurl+"?path=kd100&type="+e+"&postid="+i:this.showTost("缺少相应的物流参数")},lijifk:function(t){var e="";t.wishId&&(e="&wishId="+t.wishId),t.giftId&&(e="&giftId="+t.giftId),t.togetherId&&(e="&togetherId="+t.togetherId),console.log(e),d.a.miniProgram.navigateTo({url:"/pages/payGd/index?id="+t.orderId+"&m="+t.grandTotal+e})},concatData:function(t){this.onFetching.splice(this.index,1,!1);var e=this.dataObj[this.index+""].list.slice(0);e.push.apply(e,s()(t)),this.dataObj[this.index+""]=a()({},this.dataObj[this.index+""],{list:e})},reFresh:function(){if(!this.onFetchings[this.index+""]){var t="hdObj"+this.index;0==document.getElementsByClassName(t)[0].scrollTop&&(this.onFetchings.splice(this.index,1,!0),this.getList(0,this.demo))}},bindScroll:function(){if(0!=this.dataObj[this.index+""].max){if(this.dataObj[this.index+""].max==this.dataObj[this.index+""].list.length)return this.onFetching.splice(this.index,1,!0),this.tip.splice(this.index,1,"没有更多了"),void this.isOver.splice(this.index,1,!1);if(!this.onFetching[this.index+""]){var t="hdObj"+this.index,e=document.getElementsByClassName(t)[0],i=e.scrollTop,n=e.clientHeight,s="contHt"+this.index;if(document.getElementsByClassName(s)[0].clientHeight-i<=n){this.onFetching.splice(this.index,1,!0);var o=Math.ceil(this.dataObj[this.index+""].list.length/this.pageSize),a=this.list[this.index+""];this.getList(o,a,!0)}}}},copyData:function(t){switch(this.onFetchings.splice(this.index,1,!1),(t=h()({},t,{t:0})).status){case"已取消":this.dataObj[4]=a()({},t),console.log(this.dataObj[4]);break;case"已完成":this.dataObj[3]=a()({},t);break;case"待付款":this.dataObj[1]=a()({},t);break;case"待收货":this.dataObj[2]=a()({},t);break;default:this.dataObj[0]=a()({},t)}}}),{0:{max:0,list:null,t:1},1:{max:0,list:null,t:1},2:{max:0,list:null,t:1},3:{max:0,list:null,t:1},4:{max:0,list:null,t:1}}),M={components:{Tab:y,TabItem:I,Swiper:N,SwiperItem:W,LoadMore:f.a,Picker:w.a,Confirm:P.a,backHome:u.a},data:function(){return{def:!1,listIndex:0,slected:[""],menus1:[[{name:"",value:""}]],isOver:[!0,!0,!0,!0,!0],tip:["正在加载","正在加载","正在加载","正在加载","正在加载"],isOvers:[!0,!0,!0,!0,!0],tips:["正在刷新","正在刷新","正在刷新","正在刷新","正在刷新"],pageSize:10,onFetching:[!1,!1,!1,!1,!1],onFetchings:[!1,!1,!1,!1,!1],dataObj:q,index:0,demo:"全部",list:["全部","待付款","待收货","已完成","已取消"],sy:"",ey:"",show1:!1,orderId:""}},mounted:function(){document.title="我的订单",this.$route.query.token&&localStorage.setItem("token",decodeURIComponent(this.$route.query.token)),this.$route.query.refreshToken&&localStorage.setItem("refreshToken",decodeURIComponent(this.$route.query.refreshToken)),this.$route.query.cs?(this.demo=decodeURIComponent(this.$route.query.cs),this.index=this.$route.query.csi,this.getList(0,this.demo)):this.getList(0)},methods:h()({},Object(l.b)(["orderList","orderCancelReason","cancelOrder","deleteOrder","confirmReceipt"]),{shopping:function(){d.a.miniProgram.switchTab({url:"/pages/home/index"})},sureOre:function(t){this.showLoading(),this.confirmReceipt({data:{orderId:t},this:this,s:1,method:this.confirmReceipt})},mo:function(){this.getList(0,this.demo)},onConfirm:function(t,e){this.listIndex=e,this.showLoading(),this.deleteOrder({data:{orderId:t},this:this,method:this.deleteOrder})},delOd:function(t,e){var i=this;this.$vux.confirm.show({content:"确认删除订单",onCancel:function(){},onConfirm:function(){i.onConfirm(t,e)}})},goBack:function(){this.hideLoading();var t=this.dataObj[this.index+""].list.slice(0);t.splice(this.listIndex,1),this.dataObj[this.index+""]=a()({},this.dataObj[this.index+""],{list:t})},cancelOrd:function(t){this.orderId=t,this.orderCancelReason({this:this}),this.show1=!0},setRe:function(t){t=t.map(function(t){return{name:t.description,value:t.description}}),this.menus1=[t]},hxcz:function(){this.showTost("取消订单成功"),this.getList(0,this.demo)},goCe:function(){console.log(this.slected[0]);var t={orderId:this.orderId,operateReason:this.slected[0]};this.cancelOrder({data:t,this:this}),this.show1=!1},choseWhy:function(t){console.log(t)},goDetail:function(t){this.def=!0,this.$router.push({name:"orderDetail",query:{id:t.orderId}})},qh:function(t,e){this.demo=e||this.list[t],this.index=t,"全部"==this.demo?this.dataObj[this.index+""].t&&this.getList(0):this.dataObj[this.index+""].t&&this.getList(0,this.demo)},getList:function(t,e,i){this.hideTost(),this.showLoading(),e||(e=""),"全部"==e&&(e=""),this.orderList({method:this.orderList,this:this,size:i||"",data:{page:t,pageSize:this.pageSize,orderStatusType:e}})},ontouchstart:function(t){this.sy=t.changedTouches[0].pageY},ontouchend:function(t){this.ey=t.changedTouches[0].pageY,this.sy-this.ey>30&&this.bindScroll(),this.ey-this.sy>50&&this.reFresh()},seeWl:function(t){var e=t.companyId,i=t.deliverId;i&&e?window.location.href="https://m.kuaidi100.com/index_all.html?callbackurl="+this.sendurl+"?path=kd100&type="+e+"&postid="+i:this.showTost("缺少相应的物流参数")},lijifk:function(t){var e="";t.wishId&&(e="&wishId="+t.wishId),t.giftId&&(e="&giftId="+t.giftId),t.togetherId&&(e="&togetherId="+t.togetherId),console.log(e),d.a.miniProgram.navigateTo({url:"/pages/payGd/index?id="+t.orderId+"&m="+t.grandTotal+e})},concatData:function(t){this.onFetching.splice(this.index,1,!1);var e=this.dataObj[this.index+""].list.slice(0);e.push.apply(e,s()(t)),this.dataObj[this.index+""]=a()({},this.dataObj[this.index+""],{list:e})},reFresh:function(){if(!this.onFetchings[this.index+""]){var t="hdObj"+this.index;0==document.getElementsByClassName(t)[0].scrollTop&&(this.onFetchings.splice(this.index,1,!0),this.getList(0,this.demo))}},bindScroll:function(){if(0!=this.dataObj[this.index+""].max){if(this.dataObj[this.index+""].max==this.dataObj[this.index+""].list.length)return this.onFetching.splice(this.index,1,!0),this.tip.splice(this.index,1,"没有更多了"),void this.isOver.splice(this.index,1,!1);if(!this.onFetching[this.index+""]){var t="hdObj"+this.index,e=document.getElementsByClassName(t)[0],i=e.scrollTop,n=e.clientHeight,s="contHt"+this.index;if(document.getElementsByClassName(s)[0].clientHeight-i<=n){this.onFetching.splice(this.index,1,!0);var o=Math.ceil(this.dataObj[this.index+""].list.length/this.pageSize),a=this.list[this.index+""];this.getList(o,a,!0)}}}},copyData:function(t){switch(this.onFetchings.splice(this.index,1,!1),(t=h()({},t,{t:0})).status){case"已取消":this.dataObj[4]=a()({},t),console.log(this.dataObj[4]);break;case"已完成":this.dataObj[3]=a()({},t);break;case"待付款":this.dataObj[1]=a()({},t);break;case"待收货":this.dataObj[2]=a()({},t);break;default:this.dataObj[0]=a()({},t)}}}),beforeDestroy:function(){this.def},beforeRouteLeave:function(t,e,i){console.log(e),console.log(t),console.log("beforeRouteLeave"),"orderDetail"==t.name||"personCenter"==t.name?i():d.a.miniProgram.switchTab({url:"/pages/me/index"})}},A={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"myOrder"},[n("tab",{attrs:{"line-width":3,"active-color":"#ff5a5f","bar-active-color":"#ff5a5f"},model:{value:t.index,callback:function(e){t.index=e},expression:"index"}},t._l(t.list,function(e,i){return n("tab-item",{key:e,staticClass:"vux-center",attrs:{selected:t.demo===e},nativeOn:{click:function(n){t.qh(i,e)}}},[t._v(t._s(e))])})),t._v(" "),n("swiper",{attrs:{"show-dots":!1,height:"100%"},on:{"on-index-change":t.qh},model:{value:t.index,callback:function(e){t.index=e},expression:"index"}},t._l(t.list,function(e,s){return n("swiper-item",{key:e,class:"hdObj"+s,nativeOn:{touchend:function(e){e.stopPropagation(),t.ontouchend(e)},touchstart:function(e){e.stopPropagation(),t.ontouchstart(e)}}},[n("load-more",{directives:[{name:"show",rawName:"v-show",value:t.onFetchings[s],expression:"onFetchings[index]"}],staticStyle:{margin:"0 auto"},attrs:{tip:t.tips[s],"show-loading":t.isOvers[s]}}),t._v(" "),t.dataObj[s+""].max||t.dataObj[s+""].t?t._e():n("div",{staticClass:"list_none"},[n("img",{attrs:{src:i("pvWE"),alt:""}}),t._v(" "),n("div",{staticClass:"textCenter"},[n("button",{staticClass:"zdy_btn gw",on:{click:t.shopping}},[t._v("去购物")])])]),t._v(" "),n("div",{class:"contHt"+s},t._l(t.dataObj[s+""].list,function(e,i){return t.dataObj[s+""].max?n("div",{key:e.orderId,staticClass:"goods_lb",on:{click:function(i){t.goDetail(e)}}},[n("div",{staticClass:"goods_lb_1 flex flexjustify bf"},[n("span",{staticClass:"span1"},[t._v(t._s(e.storeName))]),t._v(" "),"Y"==e.isReallyWaitShip?n("span",{staticClass:"span2"},[t._v("待发货")]):n("span",{staticClass:"span2"},[t._v(t._s(e.orderStatus))])]),t._v(" "),n("div",{class:{"moulp  flex":e.products.length>1}},t._l(e.products,function(e,i){return n("dl",{key:e.productId+i,staticClass:"goods_lb_2 flex"},[n("dt",{staticClass:"goods_img"},[n("img",{attrs:{src:e.mediumImageUrl}})]),t._v(" "),n("dd",{staticClass:"flex flexcolumn flexaround"},[n("div",{staticClass:"lineclamp good_content"},[t._v("\n                "+t._s(e.productName)+"\n              ")]),t._v(" "),n("div",{staticClass:"p_jh"},[n("p",{staticClass:"good_fg"},[t._v("数量：x"+t._s(parseInt(e.quantity)))])])])])})),t._v(" "),n("div",{staticClass:"flex flexcenter flexjustify xhsw bf"},[n("span",[t._v("共"+t._s(e.num)+"件，应付金额\n            "),n("i",{staticClass:"money bold"},[t._v("￥"),n("b",[t._v(t._s(e.grandTotal))])])]),t._v(" "),"待付款"==e.orderStatus?[n("div",{staticClass:"flex"},[n("button",{staticClass:"zdy_btn",on:{click:function(n){n.stopPropagation(),t.cancelOrd(e.orderId,i)}}},[t._v("取消订单")]),n("button",{staticClass:"zdy_btn",on:{click:function(i){i.stopPropagation(),t.lijifk(e)}}},[t._v("立即付款")])])]:t._e(),t._v(" "),"待收货"==e.orderStatus&&"Y"!=e.isReallyWaitShip?[n("div",{staticClass:"flex"},[n("button",{staticClass:"zdy_btn",on:{click:function(i){i.stopPropagation(),t.seeWl(e)}}},[t._v("查看物流")]),n("button",{staticClass:"zdy_btn",on:{click:function(i){i.stopPropagation(),t.sureOre(e.orderId)}}},[t._v("确认收货")])])]:t._e(),t._v(" "),"交易关闭"==e.orderStatus?[n("div",{staticClass:"flex"},[n("button",{staticClass:"zdy_btn",on:{click:function(n){n.stopPropagation(),t.delOd(e.orderId,i)}}},[t._v("删除订单")])])]:t._e(),t._v(" "),"交易成功"==e.orderStatus?[n("div",{staticClass:"flex"},[n("button",{staticClass:"zdy_btn",on:{click:function(n){n.stopPropagation(),t.delOd(e.orderId,i)}}},[t._v("删除订单")])])]:t._e()],2)]):t._e()})),t._v(" "),n("load-more",{directives:[{name:"show",rawName:"v-show",value:t.onFetching[s],expression:"onFetching[index]"}],attrs:{tip:t.tip[s],"show-loading":t.isOver[s]}})],1)})),t._v(" "),t.show1?[n("div",{staticStyle:{position:"fixed",bottom:"0",left:"0",right:"0",top:"0","background-color":"rgba(0,0,0,0.3)"},on:{click:function(e){t.show1=!t.show1}}}),t._v(" "),n("div",{staticClass:"myPk"},[n("div",{staticClass:"flex flexcenter"},[n("span",{on:{click:function(e){e.stopPropagation(),t.goCe(e)}}},[t._v("完成")])]),t._v(" "),n("picker",{staticClass:"bf",attrs:{data:t.menus1},on:{"on-change":t.choseWhy},model:{value:t.slected,callback:function(e){t.slected=e},expression:"slected"}})],1)]:t._e(),t._v(" "),n("confirm",{on:{"on-confirm":t.onConfirm}}),t._v(" "),"share"==t.$route.query.i?n("back-home"):t._e()],2)},staticRenderFns:[]};var U=i("VU/8")(M,A,!1,function(t){i("CADk"),i("sS8u")},null,null);e.default=U.exports},X4DQ:function(t,e){},pvWE:function(t,e,i){t.exports=i.p+"static/img/list_none.fc18b43.png"},sS8u:function(t,e){}});
  //# sourceMappingURL=5.6973cc60f9f04eb221df.js.map