(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["plugins/clerk/detail/detail"],{"29c9":function(e,t,n){},"3f1c":function(e,t,n){"use strict";(function(e){n("ecb4");i(n("66fd"));var t=i(n("b583"));function i(e){return e&&e.__esModule?e:{default:e}}e(t.default)}).call(this,n("543d")["createPage"])},"41cd":function(e,t,n){"use strict";n.r(t);var i=n("e9aa"),c=n.n(i);for(var a in i)"default"!==a&&function(e){n.d(t,e,(function(){return i[e]}))}(a);t["default"]=c.a},"5bc1":function(e,t,n){"use strict";var i=n("29c9"),c=n.n(i);c.a},"6c93":function(e,t,n){"use strict";var i;n.d(t,"b",(function(){return c})),n.d(t,"c",(function(){return a})),n.d(t,"a",(function(){return i}));var c=function(){var e=this,t=e.$createElement;e._self._c;e._isMounted||(e.e0=function(t){e.isShow=!0},e.e1=function(t){e.checkPay=!e.checkPay},e.e2=function(t){e.checkPay=!e.checkPay})},a=[]},b583:function(e,t,n){"use strict";n.r(t);var i=n("6c93"),c=n("41cd");for(var a in c)"default"!==a&&function(e){n.d(t,e,(function(){return c[e]}))}(a);n("5bc1");var o,r=n("f0c5"),u=Object(r["a"])(c["default"],i["b"],i["c"],!1,null,"1a23e81c",null,!1,i["a"],o);t["default"]=u.exports},e9aa:function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n("2f62");function c(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 a(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?c(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var r=function(){Promise.all([n.e("common/vendor"),n.e("components/basic-component/app-layout/app-layout")]).then(function(){return resolve(n("f5e7"))}.bind(null,n)).catch(n.oe)},u=function(){Promise.all([n.e("common/vendor"),n.e("components/basic-component/app-form-id/app-form-id")]).then(function(){return resolve(n("ca42"))}.bind(null,n)).catch(n.oe)},l=function(){n.e("components/page-component/app-clerk-historys/app-clerk-historys").then(function(){return resolve(n("ba3c"))}.bind(null,n)).catch(n.oe)},d={name:"detail",components:{"app-layout":r,"app-form-id":u,appClerkHistorys:l},data:function(){return{detail:{start_time:"",end_time:""},card_id:null,checkPay:!1,id:null,isShow:!1}},computed:a({},(0,i.mapState)({theme:function(e){return e.mallConfig.theme},clerkImg:function(e){return e.mallConfig.__wxapp_img.clerk},mall:function(e){return e.mallConfig.mall}})),onLoad:function(t){this.$showLoading({text:"加载中..."}),t.id>0?(this.id=t.id,e.setNavigationBarTitle({title:"订单详情"})):t.card_id>0&&(this.card_id=t.card_id,e.setNavigationBarTitle({title:"卡券详情"}))},onShow:function(){this.id>0?this.getDetail():this.card_id>0&&this.getCardDetail()},methods:{toClerk:function(t){e.navigateTo({url:"/pages/order/clerk/clerk?id="+t})},toClerkCard:function(t){e.navigateTo({url:"/pages/card/clerk/clerk?cardId="+t})},getDetail:function(){var t=this;t.$request({url:t.$api.clerk.detail,data:{order_id:this.id}}).then((function(n){t.$hideLoading(),0==n.code?t.detail=n.data.order:e.showToast({title:n.msg,icon:"none",duration:1e3})})).catch((function(e){t.$hideLoading()}))},getCardDetail:function(){var t=this;t.$request({url:t.$api.clerk.card_detail,data:{cardId:this.card_id}}).then((function(n){t.$hideLoading(),0==n.code?t.detail=n.data.card:e.showToast({title:n.msg,icon:"none",duration:1e3})})).catch((function(e){t.$hideLoading()}))},clerkAffirmPay:function(){var t=this;t.$request({url:t.$api.order.clerk_affirm_pay,data:{id:t.id,action_type:1}}).then((function(n){t.$hideLoading(),0==n.code?(t.checkPay=!t.checkPay,t.getDetail()):e.showToast({title:n.msg,icon:"none",duration:1e3})})).catch((function(e){t.$hideLoading()}))}}};t.default=d}).call(this,n("543d")["default"])}},[["3f1c","common/runtime","common/vendor"]]]);