徐总多门店
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
4.1 KiB

(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/annex/offline_pay/index"],{"09b2":function(e,t,n){"use strict";n.r(t);var i=n("d3b6"),a=n("5a05");for(var o in a)["default"].indexOf(o)<0&&function(e){n.d(t,e,(function(){return a[e]}))}(o);n("211b"),n("3437");var s=n("828b"),c=Object(s["a"])(a["default"],i["b"],i["c"],!1,null,"49f25f10",null,!1,i["a"],void 0);t["default"]=c.exports},"211b":function(e,t,n){"use strict";var i=n("bcbe"),a=n.n(i);a.a},3437:function(e,t,n){"use strict";var i=n("e60b"),a=n.n(i);a.a},"5a05":function(e,t,n){"use strict";n.r(t);var i=n("962e"),a=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"]=a.a},"962e":function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n("152a"),a=n("7ba4"),o=n("8f59"),s=(getApp(),{data:function(){return{money:"",payPrice:"",payType:"weixin",alipayHtml:"",alipay:!1,wxpay:!1,yuePay:!1,paying:!1,now_money:0,isWeixin:!1,site_name:"",isCommitted:!1,isShowAuth:!1}},watch:{money:function(e,t){e&&"number"===typeof e?this.checkPrice():this.payPrice=""}},computed:(0,o.mapGetters)(["isLogin"]),onLoad:function(e){},onShow:function(){this.isLogin?this.getPayType():(0,a.toLogin)()},methods:{getPayType:function(){var t=this;(0,i.orderOfflinePayType)().then((function(n){var i=n.data,a=i.ali_pay_status,o=i.pay_weixin_open,s=i.yue_pay_status,c=i.offline_pay_status,u=i.site_name,r=i.now_money;t.alipay="1"===a,t.wxpay=1===o,t.yuePay=1===s,t.now_money=r,t.site_name=u,c||e.showModal({title:"支付提醒",content:"线下支付已关闭,请点击确认按钮返回主页",showCancel:!1,success:function(){e.switchTab({url:"/pages/index/index"})}}),u&&e.setNavigationBarTitle({title:u})})).catch((function(t){e.showToast({title:t,icon:"none"})}))},checkForm:function(t){var n=t.detail.value,i=n.money,a=n.method;i?this.combData(a):e.showToast({title:"请输入支付金额",icon:"none"})},checkPrice:function(){var t=this;(0,i.offlineCheckPrice)({pay_price:this.money}).then((function(e){t.payPrice=e.data.pay_price})).catch((function(t){e.showToast({title:t,icon:"none"})}))},combData:function(t){var n=this,a={type:3,pay_type:t,from:"weixinh5",price:this.payPrice||this.money,money:this.money};a.from="routine",this.paying||(this.paying=!0,e.showLoading({title:"正在确认…"}),(0,i.offlineCreate)(a).then((function(t){e.hideLoading(),n.callPay(t)})).catch((function(t){n.paying=!1,e.showToast({title:t,icon:"none"})})))},callPay:function(t){var n=t.data,i=n.status,a=n.result,o=a.orderId,s=a.jsConfig,c="/pages/annex/offline_result/index?site_name="+this.site_name;switch(i){case"ORDER_EXIST":case"EXTEND_ORDER":case"PAY_ERROR":this.paying=!1,this.$util.Tips({title:t.msg},{tab:5,url:c});break;case"SUCCESS":this.paying=!1,this.money="",this.$util.Tips({title:t.msg,icon:"success"},{tab:5,url:c});break;case"WECHAT_PAY":var u=this,r="";r=e.requestOrderPayment?"requestOrderPayment":"requestPayment",e[r]({timeStamp:s.timestamp,nonceStr:s.nonceStr,package:s.package,signType:s.signType,paySign:s.paySign,success:function(e){u.$util.Tips({title:"支付成功",icon:"success"},{tab:5,url:"/pages/annex/offline_result/index"})},fail:function(){e.showToast({title:"取消支付",icon:"none",success:function(){u.paying=!1}})},complete:function(){u.paying=!1,e.hideLoading()}});break;case"PAY_DEFICIENCY":this.paying=!1,this.$util.Tips({title:t.msg});break;case"WECHAT_H5_PAY":this.paying=!1,e.showToast({title:t.msg,success:function(){location.href=s.mweb_url}});break;case"ALIPAY_PAY":this.paying=!1,e.navigateTo({url:"/pages/users/alipay_invoke/index?id=".concat(o,"&link=").concat(s.qrCode)});break}}}});t.default=s}).call(this,n("df3c")["default"])},bcbe:function(e,t,n){},d3b6:function(e,t,n){"use strict";n.d(t,"b",(function(){return i})),n.d(t,"c",(function(){return a})),n.d(t,"a",(function(){}));var i=function(){var e=this.$createElement;this._self._c},a=[]},d89b:function(e,t,n){"use strict";(function(e,t){var i=n("47a9");n("7561");i(n("3240"));var a=i(n("09b2"));e.__webpack_require_UNI_MP_PLUGIN__=n,t(a.default)}).call(this,n("3223")["default"],n("df3c")["createPage"])},e60b:function(e,t,n){}},[["d89b","common/runtime","common/vendor"]]]);