You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 lines
6.1 KiB
1 lines
6.1 KiB
(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/order/OrderDetails/index"],{"1a6c":function(e,t,r){},"32ef":function(e,t,r){"use strict";r.r(t);var n=r("8f9c"),o=r("4c36");for(var a in o)"default"!==a&&function(e){r.d(t,e,(function(){return o[e]}))}(a);r("94de");var i,u=r("f0c5"),s=Object(u["a"])(o["default"],n["b"],n["c"],!1,null,"2770bbd7",null,!1,n["a"],i);t["default"]=s.exports},"4c36":function(e,t,r){"use strict";r.r(t);var n=r("a22d"),o=r.n(n);for(var a in n)"default"!==a&&function(e){r.d(t,e,(function(){return n[e]}))}(a);t["default"]=o.a},"8f9c":function(e,t,r){"use strict";var n;r.d(t,"b",(function(){return o})),r.d(t,"c",(function(){return a})),r.d(t,"a",(function(){return n}));var o=function(){var e=this,t=e.$createElement;e._self._c;e._isMounted||(e.e0=function(t){e.pay=!0},e.e1=function(t){return e.$yrouter.push({path:"/pages/order/Logistics/index",query:{id:e.orderInfo.orderId}})},e.e2=function(t){return e.$yrouter.push({path:"/pages/order/Logistics/index",query:{id:e.orderInfo.orderId}})},e.e3=function(t){return e.$yrouter.push({path:"/pages/order/Logistics/index",query:{id:e.orderInfo.orderId}})})},a=[]},"94de":function(e,t,r){"use strict";var n=r("1a6c"),o=r.n(n);o.a},"9fba":function(e,t,r){"use strict";(function(e){r("ef82");n(r("66fd"));var t=n(r("32ef"));function n(e){return e&&e.__esModule?e:{default:e}}e(t.default)}).call(this,r("543d")["createPage"])},a22d:function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=s(r("a34a")),o=r("2d3a"),a=r("b6d1"),i=r("2f62"),u=r("c7f0");function s(e){return e&&e.__esModule?e:{default:e}}function d(e,t,r,n,o,a,i){try{var u=e[a](i),s=u.value}catch(d){return void r(d)}u.done?t(s):Promise.resolve(s).then(n,o)}function c(e){return function(){var t=this,r=arguments;return new Promise((function(n,o){var a=e.apply(t,r);function i(e){d(a,n,o,i,u,"next",e)}function u(e){d(a,n,o,i,u,"throw",e)}i(void 0)}))}}function f(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function l(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?f(Object(r),!0).forEach((function(t){p(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):f(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function p(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var y=function(){r.e("components/OrderGoods").then(function(){return resolve(r("daac"))}.bind(null,r)).catch(r.oe)},h=function(){r.e("components/Payment").then(function(){return resolve(r("0010"))}.bind(null,r)).catch(r.oe)},m="OrderDetails",g={name:m,components:{OrderGoods:y,Payment:h},data:function(){return{offlinePayStatus:2,orderTypeName:"普通订单",orderTypeNameStatus:!0,offlineStatus:!0,id:"",orderInfo:{_status:{}},status:{},pay:!1,payType:["yue","weixin"],from:this.$deviceType,system_store:{},mapKay:"",mapShow:!1,isIntegral:!1}},computed:l({refundOrder:function(){return this.orderInfo.refund_status>0}},(0,i.mapGetters)(["userInfo"])),onShow:function(){this.id=this.$yroute.query.id,this.getDetail()},mounted:function(){this.id=this.$yroute.query.id},methods:{copyClipboard:a.copyClipboard,goGoodsReturn:function(e){this.$yrouter.push({path:"/pages/order/GoodsReturn/index",query:{id:e.orderId}})},goGroupRule:function(e){this.$yrouter.push({path:"/pages/activity/GroupRule/index",query:{id:e.pinkId}})},telPhone:function(t){e.makePhoneCall({phoneNumber:t,fail:function(){console.log("取消拨打")}})},showChang:function(e){this.$yrouter.push({path:"/pages/map/index",query:e})},goBack:function(){return"MyOrder"===this.name?void this.$yrouter.back():(console.log(this),void this.$yrouter.replace({path:"/pages/order/MyOrder/index"}))},cancelOrder:function(){var e=this;(0,u.cancelOrderHandle)(this.orderInfo.orderId).then((function(){setTimeout((function(){return e.goBack()}),300)})).catch((function(){e.getDetail()}))},takeOrder:function(){var e=this;(0,u.takeOrderHandle)(this.orderInfo.orderId).finally((function(){e.getDetail()}))},delOrder:function(){var e=this;(0,u.delOrderHandle)(this.orderInfo.orderId).then((function(){setTimeout((function(){return e.goBack()}),300)}))},setOfflinePayStatus:function(e){var t=this;t.offlinePayStatus=e,1===e&&!0===t.orderTypeNameStatus&&t.payType.push("offline")},getOrderStatus:function(){var e=this.orderInfo||{},t=e._status||{_type:0},r={},n=parseInt(t._type),o=e.deliveryType,a=e.seckillId?parseInt(e.seckillId):0,i=e.bargainId?parseInt(e.bargainId):0,u=e.combinationId?parseInt(e.combinationId):0;r={type:n,class_status:0},1==n&&u>0&&(r.type=6,r.class_status=1),2==n&&"express"==o&&(r.class_status=2),2==n&&(r.class_status=3),4!=n&&0!==n||(r.class_status=4),a||i||u||3!=n&&4!=n||(r.class_status=5),9==n&&(r.class_status=0,this.offlineStatus=!1),this.status=r},getDetail:function(){var t=this,r=this.id;r?(0,o.orderDetail)(r).then((function(e){t.orderInfo=e.data,t.getOrderStatus(),t.orderInfo.combinationId>0?(t.orderTypeName="拼团订单",t.orderTypeNameStatus=!1):t.orderInfo.bargainId>0?(t.orderTypeName="砍价订单",t.orderTypeNameStatus=!1):t.orderInfo.seckillId>0&&(t.orderTypeName="秒杀订单",t.orderTypeNameStatus=!1),t.isIntegral="integral"==e.data.payType,t.isIntegral&&(t.orderTypeName="积分兑换订单",t.orderTypeNameStatus=!1),t.system_store=e.data.systemStore||{},t.mapKey=e.data.mapKay,t.setOfflinePayStatus(t.orderInfo.offlinePayStatus)})).catch((function(t){e.showToast({title:t.response.data.msg,icon:"none",duration:2e3})})):e.showToast({title:"订单不存在",icon:"none",duration:2e3})},toPay:function(e){var t=this;return c(n.default.mark((function r(){var o;return n.default.wrap((function(r){while(1)switch(r.prev=r.next){case 0:return o=t,console.log(e,"支付方式"),r.next=4,(0,u.payOrderHandle)(t.orderInfo.orderId,e,o.from);case 4:o.getDetail();case 5:case"end":return r.stop()}}),r)})))()}}};t.default=g}).call(this,r("543d")["default"])}},[["9fba","common/runtime","common/vendor"]]]); |