12 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-dcf44dbe"],{"64e8":function(t,e,i){"use strict";i.r(e);var c=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",[i("div",{staticClass:"payment-top acea-row row-column row-center-wrapper"},[i("span",{staticClass:"name"},[t._v("我的余额")]),i("div",{staticClass:"pic"},[t._v("\n ¥"),i("span",{staticClass:"pic-font"},[t._v(t._s(t.now_money||0))])])]),i("div",{staticClass:"recharge"},[i("div",{staticClass:"nav acea-row row-around row-middle"},t._l(t.navRecharge,(function(e,c){return i("div",{key:c,staticClass:"item",class:t.active===c?"on":"",on:{click:function(e){return t.navRecharges(c)}}},[t._v("\n "+t._s(e)+"\n ")])})),0),i("div",{staticClass:"info-wrapper"},[t.active?i("div",[i("div",{staticClass:"money"},[i("span",[t._v("¥")]),i("input",{directives:[{name:"model",rawName:"v-model",value:t.money,expression:"money"}],attrs:{type:"number",placeholder:"0.00"},domProps:{value:t.money},on:{input:function(e){e.target.composing||(t.money=e.target.value)}}})]),i("div",{staticClass:"tip-box"},[i("span",{staticClass:"tip"},[t._v("提示:")]),i("div",{staticClass:"tip-samll"},[t._v("\n 当前可转入佣金:\n "),i("span",{staticClass:"font-color"},[t._v("¥"+t._s(t.userInfo.brokerage_price||0))])])])]):t._e(),t.active?t._e():i("div",{staticClass:"picList acea-row row-between mt-20"},[t._l(t.picList,(function(e,c){return i("div",{key:c,staticClass:"pic-box pic-box-color acea-row row-center-wrapper row-column",class:t.activePic==c?"pic-box-color-active":"",on:{click:function(i){return t.picCharge(c,e)}}},[i("div",{staticClass:"pic-number-pic"},[t._v("\n "+t._s(e.quota)),i("span",{staticClass:"pic-number"},[t._v(" 元")])]),i("div",{staticClass:"pic-number"},[t._v("赠送:"+t._s(e.price)+" 元")])])})),i("div",{staticClass:"pic-box pic-box-color acea-row row-center-wrapper",class:t.activePic==t.picList.length?"pic-box-color-active":"",on:{click:function(e){return t.picCharge(t.picList.length,t.money)}}},[i("input",{directives:[{name:"model",rawName:"v-model",value:t.money,expression:"money"}],staticClass:"pic-box-money pic-number-pic",class:t.activePic==t.picList.length?"pic-box-color-active":"",attrs:{type:"number",placeholder:"其他"},domProps:{value:t.money},on:{input:function(e){e.target.composing||(t.money=e.target.value)}}})])],2),i("div",{staticClass:"acea-row row-column"},[i("div",{staticClass:"tip mt-30"},[t._v("注意事项:")]),t._l(t.rechargeAttention,(function(e){return i("div",{key:e,staticClass:"tip-samll"},[t._v("\n "+t._s(e)+"\n ")])}))],2),i("div",{staticClass:"pay-btn bg-color-red",on:{click:t.recharge}},[t._v("\n "+t._s(t.active?"立即转入":"立即充值")+"\n ")])])])])},a=[],n=(i("f548"),i("163d"),i("08c1")),o=i("74f9"),s=i("ed08"),r=i("c24f"),p=i("9fd0"),l={name:"Recharge",props:{},data:function(){return{navRecharge:["账户充值","佣金导入"],active:0,payType:["weixin"],from:Object(s["d"])()?"weixin":"weixinh5",money:"",now_money:"",picList:[],activePic:0,numberPic:"",paid_price:"",rechargeAttention:[]}},computed:Object(n["b"])(["userInfo"]),mounted:function(){this.now_money=this.userInfo.now_money,this.getRecharge()},methods:{getRecharge:function(){var t=this;Object(r["x"])().then((function(e){t.picList=e.data.recharge_quota,t.picList[0]&&(t.paid_price=t.picList[0].price,t.numberPic=t.picList[0].quota),t.rechargeAttention=e.data.recharge_attention||[]})).catch((function(e){t.$dialog.toast({mes:e})}))},picCharge:function(t,e){this.activePic=t,t==this.picList.length?(this.paid_price="",this.numberPic=""):(this.money="",this.paid_price=e.price,this.numberPic=e.quota)},navRecharges:function(t){this.active=t,this.paid_price=this.picList[0].price,this.numberPic=this.picList[0].quota,this.activePic=0,this.money=""},recharge:function(){var t=this,e=this,i=Number(this.money);if(e.active){if(0===i)return e.$dialog.toast({mes:"请输入您要转入的金额"});if(i<.01)return e.$dialog.toast({mes:"转入金额不能低于0.01"});this.$dialog.confirm({mes:"转入余额无法在转出,请确认转入",title:"转入余额",opts:[{txt:"确认",color:!1,callback:function(){Object(r["R"])({price:i,from:e.from,type:1}).then((function(t){return e.now_money=Object(p["a"])(i,parseInt(e.userInfo.now_money)),e.userInfo.brokerage_price=Object(p["c"])(e.userInfo.brokerage_price,i),e.money="",e.$dialog.toast({mes:t.msg})})).catch((function(t){e.$dialog.toast({mes:t.msg})}))}},{txt:"取消",color:!1,callback:function(){return e.$dialog.toast({mes:"已取消"})}}]})}else{if(this.picList.length==this.activePic&&0===i)return e.$dialog.toast({mes:"请输入您要充值的金额"});if(this.picList.length==this.activePic&&i<.01)return e.$dialog.toast({mes:"充值金额不能低于0.01"});var c="",a="";i?(c=i,a=i):(c=e.numberPic,a=e.paid_price),Object(r["R"])({price:c,from:e.from,paid_price:a}).then((function(c){var a=c.data;"weixinh5"==a.type?(location.replace(a.data.mweb_url),t.$dialog.confirm({mes:"充值余额",opts:[{txt:"已充值",color:!1,callback:function(){e.$router.replace({path:"/user/account"})}},{txt:"查看余额",color:!1,callback:function(){e.$router.replace({path:"/user/account"})}}]})):Object(o["pay"])(a.data).finally((function(){e.now_money=Object(p["a"])(i,parseInt(e.userInfo.now_money)),e.$dialog.toast({mes:"支付成功"})})).catch((function(){e.$dialog.toast({mes:"支付失败"})}))})).catch((function(t){e.$dialog.toast({mes:t.msg})}))}}}},u=l,m=(i("8f6d"),i("623f")),d=Object(m["a"])(u,c,a,!1,null,"63174fa6",null);e["default"]=d.exports},"8f6d":function(t,e,i){"use strict";var c=i("9619"),a=i.n(c);a.a},9619:function(t,e,i){}}]);
- //# sourceMappingURL=chunk-dcf44dbe.785ef810.js.map
|