(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pagesOrder/detail"],{"0525":function(e,t,n){"use strict";var i;n.d(t,"b",(function(){return r})),n.d(t,"c",(function(){return o})),n.d(t,"a",(function(){return i}));var r=function(){var e=this,t=e.$createElement,n=(e._self._c,e.$util.isEmpty(e.detailInfo));e.$mp.data=Object.assign({},{$root:{g0:n}})},o=[]},"1bf8":function(e,t,n){"use strict";(function(e){n("6cdc");i(n("4a15"));var t=i(n("9550"));function i(e){return e&&e.__esModule?e:{default:e}}e(t.default)}).call(this,n("f3be")["createPage"])},3161:function(e,t,n){"use strict";var i=n("a014"),r=n.n(i);r.a},"91e3":function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=c(n("4838")),r=n("3a10"),o=c(n("e350")),a=n("7602");function c(e){return e&&e.__esModule?e:{default:e}}function u(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?u(Object(n),!0).forEach((function(t){f(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):u(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function f(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t,n,i,r,o,a){try{var c=e[o](a),u=c.value}catch(s){return void n(s)}c.done?t(u):Promise.resolve(u).then(i,r)}function d(e){return function(){var t=this,n=arguments;return new Promise((function(i,r){var o=e.apply(t,n);function a(e){l(o,i,r,a,c,"next",e)}function c(e){l(o,i,r,a,c,"throw",e)}a(void 0)}))}}var p=function(){n.e("pagesOrder/components/stepStatus").then(function(){return resolve(n("cc98"))}.bind(null,n)).catch(n.oe)},h=function(){n.e("components/plugin/list-cell").then(function(){return resolve(n("1861"))}.bind(null,n)).catch(n.oe)},b={name:"orderDetail",components:{stepStatus:p,TuiListCell:h},mixins:[o.default],data:function(){return{ORDER_STATUS:a.ORDER_STATUS,pageType:"order_change",autoLoad:!1,stepActive:0,form:{name:""},detailInfo:{},freeShipModal:!1,loading:!1}},onPullDownRefresh:function(){this.init().then((function(t){e.stopPullDownRefresh()}))},onShow:function(){this.init()},methods:{freeShipModalClick:function(e){var t=this;0===e.index?this.modalCancel():(0,r.freeShipping)({id:this.detailInfo.id}).then((function(e){t.init(),t.$msg("操作成功！"),t.modalCancel()}))},modalCancel:function(){this.freeShipModal=!1},openBt:function(t,n){if("item"===t.type)this.gotoSelect();else if("selfGet"===t.type)this.freeShipModal=!0;else if("print"===t.type)this.pageTo({url:"/pagesOrder/print",query:{id:n.id}});else if("send"===t.type)this.pageTo({url:"/pagesOrder/ship",query:{id:n.id}});else if("debtPay"===t.type){var i=this;e.showModal({content:"您确认要延期收款",success:function(t){if(t.confirm)return(0,r.debtPay)({id:i.option.id}).then((function(t){console.log(t),e.showToast({title:"操作成功！",icon:"none"}),i.init()}))}})}else if("hasPay"===t.type){var o=this;e.showModal({content:"您确认已收款",success:function(t){if(t.confirm)return(0,r.hasPay)({id:o.option.id}).then((function(t){e.showToast({title:"操作成功！",icon:"none"}),o.init()}))}})}},copy:function(t){var n=this;e.setClipboardData({data:t,success:function(){n.$msg("复制成功")}})},callUp:function(t){e.makePhoneCall({phoneNumber:t})},init:function(){var e=d(i.default.mark((function e(){var t,n;return i.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(e.prev=0,!this.loading){e.next=3;break}return e.abrupt("return",new Promise.reject);case 3:return this.loading=!0,e.next=6,(0,r.getDetail)({id:this.option.id});case 6:t=e.sent,this.detailInfo=t.data,n=this.detailInfo.product,n&&this.setSelectInfoByType({type:this.pageType,info:n.map((function(e){return s(s({},e),{},{bigCount:Number(e.bigNum),smallCount:Number(e.smallNum)})}))}),e.next=14;break;case 12:e.prev=12,e.t0=e["catch"](0);case 14:return e.prev=14,this.loading=!1,e.finish(14);case 17:case"end":return e.stop()}}),e,this,[[0,12,14,17]])})));function t(){return e.apply(this,arguments)}return t}(),gotoSelect:function(){e.navigateTo({url:"/pagesOrder/select?id=".concat(this.detailInfo.id)})}}};t.default=b}).call(this,n("f3be")["default"])},9550:function(e,t,n){"use strict";n.r(t);var i=n("0525"),r=n("ca0d");for(var o in r)["default"].indexOf(o)<0&&function(e){n.d(t,e,(function(){return r[e]}))}(o);n("3161");var a,c=n("0095"),u=Object(c["a"])(r["default"],i["b"],i["c"],!1,null,"fa767cb6",null,!1,i["a"],a);t["default"]=u.exports},a014:function(e,t,n){},ca0d:function(e,t,n){"use strict";n.r(t);var i=n("91e3"),r=n.n(i);for(var o in i)["default"].indexOf(o)<0&&function(e){n.d(t,e,(function(){return i[e]}))}(o);t["default"]=r.a}},[["1bf8","common/runtime","common/vendor"]]]);