12 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-ee623db8"],{"0890":function(e,t,n){},"64e8":function(e,t,n){"use strict";n.r(t);var o=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[n("div",{staticClass:"recharge"},[n("div",{staticClass:"nav acea-row row-around row-middle"},e._l(e.navRecharge,function(t,o){return n("div",{key:o,staticClass:"item",class:e.active===o?"on":"",on:{click:function(t){return e.navRecharges(o)}}},[e._v("\n "+e._s(t)+"\n ")])}),0),n("div",{staticClass:"info-wrapper"},[n("div",{staticClass:"money"},[n("span",[e._v("¥")]),n("input",{directives:[{name:"model",rawName:"v-model",value:e.money,expression:"money"}],attrs:{type:"number",placeholder:"0.00"},domProps:{value:e.money},on:{input:function(t){t.target.composing||(e.money=t.target.value)}}})]),e.active?n("div",{staticClass:"tips"},[e._v("\n 提示:当前佣金为"),n("span",[e._v("¥"+e._s(e.userInfo.brokerage_price||0))])]):n("div",{staticClass:"tips"},[e._v("\n 提示:当前余额为"),n("span",[e._v("¥"+e._s(e.now_money||0))])]),n("div",{staticClass:"pay-btn bg-color-red",on:{click:e.recharge}},[e._v("\n "+e._s(e.active?"立即转入":"立即充值")+"\n ")])])])])},a=[],c=(n("a481"),n("c5f6"),n("2f62")),i=n("74f9"),s=n("ed08"),r=n("c24f"),u=n("9fd0"),l={name:"Recharge",components:{},props:{},data:function(){return{navRecharge:["账户充值","佣金导入"],active:0,payType:["weixin"],from:Object(s["d"])()?"weixin":"weixinh5",money:"",now_money:""}},computed:Object(c["b"])(["userInfo"]),mounted:function(){this.now_money=this.userInfo.now_money},methods:{navRecharges:function(e){this.active=e},recharge:function(){var e=this,t=this,n=Number(this.money);if(t.active){if(0===n)return t.$dialog.toast({mes:"请输入您要转入的金额"});if(n<.01)return t.$dialog.toast({mes:"转入金额不能低于0.01"});this.$dialog.confirm({mes:"转入余额无法在转出,请确认转入",title:"转入余额",opts:[{txt:"确认",color:!1,callback:function(){Object(r["P"])({price:n,from:t.from,type:1}).then(function(e){return t.now_money=Object(u["a"])(n,parseInt(t.userInfo.now_money)),t.userInfo.brokerage_price=Object(u["c"])(t.userInfo.brokerage_price,n),t.money="",t.$dialog.toast({mes:e.msg})}).catch(function(e){t.$dialog.toast({mes:e.msg})})}},{txt:"取消",color:!1,callback:function(){return t.$dialog.toast({mes:"已取消"})}}]})}else{if(0===n)return t.$dialog.toast({mes:"请输入您要充值的金额"});if(n<.01)return t.$dialog.toast({mes:"充值金额不能低于0.01"});Object(r["P"])({price:n,from:t.from}).then(function(o){var a=o.data;"weixinh5"==a.type?(location.replace(a.data.mweb_url),e.$dialog.confirm({mes:"充值余额",opts:[{txt:"已充值",color:!1,callback:function(){t.$router.replace({path:"/user/account"})}},{txt:"查看余额",color:!1,callback:function(){t.$router.replace({path:"/user/account"})}}]})):Object(i["pay"])(a.data).finally(function(){t.now_money=Object(u["a"])(n,parseInt(t.userInfo.now_money)),t.$dialog.toast({mes:"支付成功"})}).catch(function(){t.$dialog.toast({mes:"支付失败"})})}).catch(function(e){t.$dialog.toast({mes:e.msg})})}}}},m=l,f=(n("e558"),n("2877")),d=Object(f["a"])(m,o,a,!1,null,"789370b6",null);t["default"]=d.exports},e558:function(e,t,n){"use strict";var o=n("0890"),a=n.n(o);a.a}}]);
|