|
|
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-order-list"],{"0091":function(t,e,n){var a=n("6561");"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var r=n("4f06").default;r("6c54e124",a,!0,{sourceMap:!1,shadowMode:!1})},"2ba7":function(t,e,n){"use strict";n.r(e);var a=n("9989"),r=n("958e");for(var o in r)"default"!==o&&function(t){n.d(e,t,(function(){return r[t]}))}(o);n("3cae"),n("dc99");var i,s=n("f0c5"),u=Object(s["a"])(r["default"],a["b"],a["c"],!1,null,"6ab97961",null,!1,a["a"],i);e["default"]=u.exports},"336e":function(t,e,n){"use strict";n.r(e);var a=n("eabf"),r=n("5bed");for(var o in r)"default"!==o&&function(t){n.d(e,t,(function(){return r[t]}))}(o);var i,s=n("f0c5"),u=Object(s["a"])(r["default"],a["b"],a["c"],!1,null,"27d4e601",null,!1,a["a"],i);e["default"]=u.exports},"3cae":function(t,e,n){"use strict";var a=n("0091"),r=n.n(a);r.a},4136:function(t,e,n){"use strict";var a=n("4ea4");Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=a(n("1687")),o=(n("c0d4"),n("5767")),i={components:{UiRadioPicker:r.default},props:{show:{type:Boolean,default:!1},order:{type:Object,default:function(){return{}}}},data:function(){return{options:[{label:"微信支付",value:"wxpay"},{label:"支付宝支付",value:"alipay"}]}},methods:{confirm:function(t){var e=this.order.orderId;"wxpay"===t.value?((0,o.Wxpay)({orderId:e,openId:this.$store.state.openId}),this.close()):uni.$u.toast("暂不支持支付宝支付")},close:function(){this.$emit("update:show",!1)}}};e.default=i},"595c":function(t,e,n){"use strict";var a=n("4ea4");n("99af"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,n("96cf");var r=a(n("1da1")),o=a(n("8832")),i=a(n("359f")),s=n("c0d4"),u=a(n("336e")),d=a(n("7932")),c=a(n("eb0d")),l=a(n("dd25")),f={components:{BsEmpty:o.default,UiButton:i.default,BsPay:u.default,UiGoodsInfo:d.default,UiGoodsInfoMax:c.default,UiMoney:l.default},data:function(){return{tabListData:[{key:"-1",name:"全部"},{key:"1",name:"待付款"},{key:"3",name:"待发货"},{key:"4",name:"待收货"}],currentTabKey:this.$Route.query.tab||"-1",orderListData:[],loadingStatus:"loading",pageIndex:1,pageSize:10,payShow:!1,payOrder:null}},onLoad:function(){this.getOrderList()},onReachBottom:function(){this.next()},methods:{changeTab:function(t){this.currentTabKey=t,this.pageIndex=1,this.orderListData=[],this.getOrderList()},getOrderList:function(){var t=this;return(0,r.default)(regeneratorRuntime.mark((function e(){var n,a,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t.loadingStatus="loading",e.next=3,(0,s.ApiGetOrderList)({length:t.pageSize,pageIndex:t.pageIndex,orderStatus:t.currentTabKey>-1?t.currentTabKey:null});case 3:if(n=e.sent,a=n.error,r=n.result,!a){e.next=9;break}return uni.$u.toast(a.message),e.abrupt("return",!1);case 9:r.records.length<t.pageSize&&(t.loadingStatus="nomore"),t.orderListData=t.orderListData.concat(r.records);case 11:case"end":return e.stop()}}),e)})))()},next:function(){if("nomore"===this.loadingStatus)return!1;this.pageIndex++,this.getOrderList()},pay:function(t){this.payShow=!0,this.payOrder=t},receive:function(t){var e=this;return(0,r.default)(regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:e.$msb.confirm({content:"确认已经收到货了吗?",confirm:function(){var n=(0,r.default)(regeneratorRuntime.mark((function n(){var a,r;return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return n.next=2,(0,s.ApiPutOrderReceive)({orderId:t.orderId});case 2:if(a=n.sent,r=a.error,!r){n.next=7;break}return uni.$toast(r.message),n.abrupt("return",!1);case 7:e.$Router.push("/orderSuccess");case 8:case"end":return n.stop()}}),n)})));function a(){return n.apply(this,arguments)}return a}()});case 1:case"end":return n.stop()}}),n)})))()}}};e.default=f},"5bed":function(t,e,n){"use strict";n.r(e);var a=n("4136"),r=n.n(a);for(var o in a)"default"!==o&&function(t){n.d(e,t,(function(){return a[t]}))}(o);e["default"]=r.a},6561:function(t,e,n){var a=n("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 这里是uni-app内置的常用样式变量\n *\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\n *\n */\n/**\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\n *\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\n */\n/* 颜色变量 */\n/* 行为相关颜色 */\n/* 文字基本颜色 */\n/* 背景颜色 */\n/* 边框颜色 */\n/* 透明度 */\n/* 尺寸变量 */\n/* 文字尺寸 */\n/* 间距 */\n/* 图片尺寸 */\n/* Border Radius */\n/* 水平间距 */\n/* 垂直间距 */uni-page-body[data-v-6ab97961]{background:#f8f8f8}body.?%PAGE?%[data-v-6ab97961]{background:#f8f8f8}',""]),t.exports=e},"958e":function(t,e,n){"use strict";n.r(e);var a=n("595c"),r=n.n(a);for(var o in a)"default"!==o&&function(t){n.d(e,t,(function(){return a[t]}))}(o);e["default"]=r.a},9989:function(t,e,n){"use strict";n.d(e,"b",(function(){return r})),n.d(e,"c",(function(){return o})),n.d(e,"a",(function(){return a}));var a={uLoadmore:n("c153").default},r=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("v-uni-view",[a("v-uni-view",{staticClass:"tabs"},t._l(t.tabListData,(function(e){return a("v-uni-text",{key:e.key,class:e.key===t.currentTabKey&&"tabs__active",on:{click:function(n){arguments[0]=n=t.$handleEvent(n),t.changeTab(e.key)}}},[t._v(t._s(e.name))])})),1),t.orderListData.length||"nomore"!==t.loadingStatus?t._e():a("BsEmpty",{attrs:{tips:"暂无订单记录呢~",icon:n("5151")}},[a("ui-button",{attrs:{slot:"btn",type:"line"},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.$Router.pushTab("/")}},slot:"btn"},[t._v("去逛逛")])],1),t._l(t.orderListData,(function(e){return a("v-uni-view",{key:e.orderId,staticClass:"orders"},[a("v-uni-view",{staticClass:"orders--title"},[a("v-uni-text",{staticClass:"orders--name"},[t._v("官方自营")]),a("v-uni-text",{staticClass:"orders--status",class:[1,3].includes(e.orderStatus)&&"orders--status__warn"},[t._v(t._s(e.orderStatusDesc))])],1),t._l(e.products,(function(e){return a("UiGoodsInfoMax",{key:e.orderProductId,attrs:{data:e},on:{click:function(n){arguments[0]=n=t.$handleEvent(n),t.$Router.push("/orderDetail?id="+e.orderId)}}})})),a("v-uni-view",{staticClass:"orders--total"},[a("v-uni-text",{staticClass:"orders--total__amount"},[t._v("合计")]),a("UiMoney",{staticClass:"orders--total__amount",attrs:{money:e.totalAmount,float:!0,prefix:!0,suffix:!0}}),a("v-uni-text",{staticClass:"orders--total__pay "},[t._v("应付")]),a("UiMoney",{staticClass:"orders--total__pay",attrs:{money:e.totalAmount,float:!0,prefix:!0,suffix:!0}})],1),a("v-uni-view",{staticClass:"orders--footer"},[1===e.orderStatus?a("UiButton",{attrs:{size:"min",type:"gradual"},on:{click:function(n){arguments[0]=n=t.$handleEvent(n),t.pay(e)}}},[t._v("去支付")]):t._e(),[2,3].includes(e.orderStatus)?a("UiButton",{attrs:{size:"min"},on:{click:function(n){arguments[0]=n=t.$handleEvent(n),t.$Router.push("/orderDetail?id="+e.orderId)}}},[t._v("查看详情")]):t._e(),e.orderStatus>=4?a("UiButton",{attrs:{size:"min"},on:{click:function(n){arguments[0]=n=t.$handleEvent(n),t.$Router.push("/logisitcsInfo?orderId="+e.orderId)}}},[t._v("查看物流")]):t._e(),4===e.orderStatus?a("UiButton",{attrs:{size:"min",type:"gradual"},on:{click:function(n){arguments[0]=n=t.$handleEvent(n),t.receive(e)}}},[t._v("确认收货")]):t._e()],1)],2)})),"loading"===t.loadingStatus?a("u-loadmore",{attrs:{status:t.loadingStatus}}):t._e(),a("BsPay",{attrs:{show:t.payShow,order:t.payOrder},on:{"update:show":function(e){arguments[0]=e=t.$handleEvent(e),t.payShow=e}}})],2)},o=[]},a1d0:function(t,e,n){var a=n("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 这里是uni-app内置的常用样式变量\n *\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\n *\n */\n/**\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\n *\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\n */\n/* 颜色变量 */\n/* 行为相关颜色 */\n/* 文字基本颜色 */\n/* 背景颜色 */\n/* 边框颜色 */\n/* 透明度 */\n/* 尺寸变量 */\n/* 文字尺寸 */\n/* 间距 */\n/* 图片尺寸 */\n/* Border Radius */\n/* 水平间距 */\n/* 垂直间距 */.tabs[data-v-6ab97961]{height:%?100?%;background:#fff;position:-webkit-sticky;position:sticky;top:var(--window-top);z-index:99;display:flex;justify-content:space-between;align-items:center;padding:0 %?40?%;font-size:%?28?%;color:#666}.tabs__active[data-v-6ab97961]{color:#ff875b;position:relative}.tabs__active[data-v-6ab97961]::after{display:block;content:"";height:%?4?%;background:#ff875b;border-radius:%?4?%;position:absolute;bottom:%?-20?%;left:45%;width:50%;-webkit-transform:translateX(-50%);transform:translateX(-50%)}.orders[data-v-6ab97961]{background:#fff;padding:%?30?%;margin:%?20?% 0}.orders--title[data-v-6ab97961]{display:flex;justify-content:space-between;align-items:center}.orders--name[data-v-6ab97961]{font-size:%?32?%;color:#333;font-weight:700}.orders--status[data-v-6ab97961]{font-size:%?24?%;color:#999}.orders--status__warn[data-v-6ab97961]{color:#ff875b}.orders--total[data-v-6ab97961]{display:flex;align-items:center;justify-content:flex-end;margin-top:%?30?%}.orders--footer[data-v-6ab97961]{display:flex;justify-content:flex-end;align-items:center;margin-top:%?30?%}[data-v-6ab97961] .orders--footer .ui-btn{margin:0 0 0 %?20?%;width:%?180?%;padding:0}[data-v-6ab97961] .orders--total__amount,[data-v-6ab97961] .orders--total__pay{font-size:%?24?%}[data-v-6ab97961] .orders--total__amount uni-text,[data-v-6ab97961] .orders--total__pay uni-text{font-size:%?36?%;font-weight:700}[data-v-6ab97961] .orders--total__amount .ui-money--prefix,[data-v-6ab97961] .orders--total__pay .ui-money--prefix{font-size:%?24?%}[data-v-6ab97961] .orders--total__amount .ui-money--suffix,[data-v-6ab97961] .orders--total__pay .ui-money--suffix{font-size:%?24?%}[data-v-6ab97961] .orders--total__amount{color:#999}[data-v-6ab97961] .orders--total__amount uni-text{color:#999}[data-v-6ab97961] .orders--total__amount .ui-money--suffix{margin-right:%?20?%}',""]),t.exports=e},b4e4:function(t,e,n){var a=n("a1d0");"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var r=n("4f06").default;r("5b1dd866",a,!0,{sourceMap:!1,shadowMode:!1})},dc99:function(t,e,n){"use strict";var a=n("b4e4"),r=n.n(a);r.a},eabf:function(t,e,n){"use strict";var a;n.d(e,"b",(function(){return r})),n.d(e,"c",(function(){return o})),n.d(e,"a",(function(){return a}));var r=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("UiRadioPicker",{attrs:{title:"请选择支付方式",show:t.show,options:t.options},on:{close:function(e){arguments[0]=e=t.$handleEvent(e),t.close.apply(void 0,arguments)},confirm:function(e){arguments[0]=e=t.$handleEvent(e),t.confirm.apply(void 0,arguments)}}})},o=[]}}]); |