pages-money-recharge.3b471118.js 12 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-money-recharge"],{2310:function(t,e,a){"use strict";var n=a("4ea4");Object.defineProperty(e,"__esModule",{value:!0}),e.spreadCommission=o,e.userBalance=c,e.wallet=r,e.extractCash=s,e.exchangeCash=l,e.extractBank=d,e.rechargeWechat=f,e.aliInfo=u,e.bankInfo=h,e.setAliInfo=g,e.setBankInfo=b,e.balance=p,e.cashList=v,e.moneyChong=m;var i=n(a("c9b6"));function o(t,e){return(0,i.default)({url:"/api/spread/commission/"+e,method:"get",data:t})}function c(t){return(0,i.default)({url:"/api/user/balance",method:"get",data:t})}function r(t){return(0,i.default)({url:"/api/wallet",method:"get",data:t})}function s(t){return(0,i.default)({url:"/api/extract/cash",method:"post",data:t})}function l(t){return(0,i.default)({url:"/api/extract/brokerage",method:"post",data:t})}function d(t){return(0,i.default)({url:"/api/extract/bank",method:"get",data:t})}function f(t){return(0,i.default)({url:"/api/recharge/wechat",method:"post",data:t})}function u(t){return(0,i.default)({url:"/api/ali/info",method:"get",data:t})}function h(t){return(0,i.default)({url:"/api/bank/info",method:"get",data:t})}function g(t){return(0,i.default)({url:"/api/ali/edit",method:"post",data:t})}function b(t){return(0,i.default)({url:"/api/bank/edit",method:"post",data:t})}function p(t){return(0,i.default)({url:"/api/user/balance",method:"get",data:t})}function v(t){return(0,i.default)({url:"/api/cash/list",method:"get",data:t})}function m(t){return(0,i.default)({url:"/api/recharge/index",method:"get",data:t})}},3731:function(t,e,a){"use strict";function n(t){var e=/(^[1-9]\d{5}(18|19|([23]\d))\d{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)\d{3}[0-9Xx]$)|(^[1-9]\d{5}\d{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)\d{2}$)/;return!1!==e.test(t)||(console.log(t),!1)}function i(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;"string"==typeof t&&(t=(+t).toFixed(2)),"number"==typeof t&&(t=t.toFixed(2));var e=t.split(""),a=e.reverse().map((function(t,e,a){return e%3==0&&e/3>1&&e!=a.length?t+",":t}));return a=a.reverse().join(""),a}function o(t){var e=(new Date).getTime(),a=t-e;a<0&&(a*=-1);var n=Math.floor(a/1e3/60/60/24),i=Math.floor(a/1e3/60/60%24),o=Math.floor(a/1e3/60%60),c=Math.floor(a/1e3%60);return{hours:i,minutes:o,seconds:c,day:n}}function c(t){return new Promise((function(t,e){wx.getSetting({success:function(a){a.authSetting["scope.userLocation"]?t():wx.showModal({title:"提示",content:"请求获取位置权限",success:function(a){if(0==a.confirm)return e(),!1;wx.openSetting({success:function(e){e.authSetting["scope.userLocation"]?t():wx.showToast({title:"此功能需获取位置信息,请重新设置",duration:3e3,icon:"none"})}})}})}})}))}function r(t){for(var e=13-(t+"").length,a=1,n=0;n<e;n++)a+="0";a=parseInt(a);var i=new Date(parseInt(t)*a),o=i.getFullYear(),c=i.getMonth()+1,r=i.getDate(),s=i.getHours(),l=i.getMinutes(),d=i.getSeconds();return o+"-"+c+"-"+r+" "+s+":"+l+":"+d}a("d81d"),a("26e9"),a("d3b7"),a("e25e"),a("ac1f"),a("1276"),Object.defineProperty(e,"__esModule",{value:!0}),e.isCardNo=n,e.getMoneyStyle=i,e.timeComputed=o,e.openMap=c,e.getTime=r},"83fa":function(t,e,a){"use strict";a.r(e);var n=a("fbb0"),i=a.n(n);for(var o in n)"default"!==o&&function(t){a.d(e,t,(function(){return n[t]}))}(o);e["default"]=i.a},"94a2":function(t,e,a){var n=a("24fb");e=n(!1),e.push([t.i,'@charset "UTF-8";\n/* 页面左右间距 */\n/* 文字尺寸 */\n/*文字颜色*/\n/* 边框颜色 */\n/*颜色*/\n/* 图片加载中颜色 */\n/* 行为相关颜色 */\n/* 功能栏字体大小 */\n/*功能栏左侧小图标*/uni-page-body[data-v-7122b95c]{height:100%;background:#fff}.top_box[data-v-7122b95c]{padding:%?20?% %?26?% %?20?% %?47?%;display:flex;align-items:center;justify-content:space-between}.top_box .yue-tit[data-v-7122b95c]{font-size:%?28?%;font-family:PingFang SC;font-weight:500;color:#333}.top_box .yue-num[data-v-7122b95c]{font-size:%?30?%;font-family:PingFang SC;font-weight:700;color:#ff6f0f}.line_box[data-v-7122b95c]{width:100%;height:%?20?%;background:#f8f8f8}.cz_box[data-v-7122b95c]{padding:%?40?% %?20?% %?20?%}.cz_box .cz_wrap[data-v-7122b95c]{display:flex;align-items:center;justify-content:space-between;padding-bottom:%?20?%;border-bottom:1px solid #e6e6e6}.cz_box .cz_wrap .cz_tit[data-v-7122b95c]{font-size:%?32?%;font-family:PingFang SC;font-weight:500}.cz_box .cz_wrap .cz_input[data-v-7122b95c]{text-align:right;font-size:%?32?%;font-family:PingFang SC;font-weight:500}.cz_box .zc_list_box[data-v-7122b95c]{display:flex;flex-wrap:wrap}.cz_box .zc_list_box .zc_list_price[data-v-7122b95c]{width:%?202?%;height:%?60?%;background:#f0f0f0;border-radius:%?8?%;margin-top:%?36?%;margin-right:%?50?%;display:flex;align-items:center;justify-content:center}.cz_box .zc_list_box .zc_list_price[data-v-7122b95c]:nth-child(3n){margin-right:0}.cz_box .zc_list_box .seletPrice[data-v-7122b95c]{background:linear-gradient(143.2747deg,#ff6a00,#ee0979);color:#fff}.recha-box[data-v-7122b95c]{padding:%?50?% %?30?% 0;display:flex;flex-wrap:wrap}.recha-box .recha-frame[data-v-7122b95c]{width:%?210?%;height:%?181?%;border:1px solid #dbdede;border-radius:%?20?%;display:flex;align-items:center;flex-direction:column;justify-content:center;margin-right:%?30?%;margin-bottom:%?30?%}.recha-box .recha-frame[data-v-7122b95c]:nth-child(3n){margin-right:0}.recha-box .recha-frame .recha-top[data-v-7122b95c]{display:flex;align-items:center}.recha-box .recha-frame .recha-top .recha-img[data-v-7122b95c]{width:%?64?%;height:%?62?%}.recha-box .recha-frame .recha-top .recha-tit[data-v-7122b95c]{margin-left:%?10?%;font-size:%?36?%;font-family:PingFang SC;font-weight:700;color:#333}.recha-box .recha-frame .recha-song[data-v-7122b95c]{margin-top:%?20?%;font-size:%?28?%;font-family:PingFang SC;font-weight:700;color:#f90}.recha-box .select-frame[data-v-7122b95c]{border:1px solid #ef041f}.rechar-box[data-v-7122b95c]{padding:%?30?% %?20?% 0}.rechar-box .rechar-title[data-v-7122b95c]{font-size:%?32?%;font-family:PingFang SC;font-weight:700;color:#333;margin-bottom:%?10?%}.rechar-box .rechar-text[data-v-7122b95c]{font-size:%?28?%;font-family:PingFang SC;font-weight:700;color:#333}.cz-type[data-v-7122b95c]{margin-top:%?22?%;display:flex;justify-content:space-between;padding:%?32?%;align-items:center}.cz-type .type-left[data-v-7122b95c]{display:flex;align-items:center}.cz-type .type-left .icon[data-v-7122b95c]{height:%?38?%}.cz-type .type-left .icon uni-image[data-v-7122b95c]{width:%?48?%;height:%?38?%}.cz-type .type-left .iconweixin[data-v-7122b95c]{color:#36cb59}.cz-type .type-left .tit[data-v-7122b95c]{margin-left:%?12?%;font-size:%?30?%;color:#333}.cz-type .type-right uni-image[data-v-7122b95c]{width:%?36?%;height:%?36?%}.add-btn[data-v-7122b95c]{margin-top:%?100?%;display:flex;align-items:center;justify-content:center;width:%?604?%;height:%?90?%;border:%?2?% solid #f21f5d;border-radius:%?10?%;font-size:%?36?%;font-family:PingFang SC;font-weight:500;color:#f21f5d;line-height:%?90?%;text-align:center}.add-btn.up[data-v-7122b95c]{color:#f21f5d}.row-box[data-v-7122b95c]{margin-top:%?30?%;padding:%?20?% %?30?%;background:#fff}.row-box .title[data-v-7122b95c]{font-size:%?30?%;color:#303133}.row-box .row[data-v-7122b95c]{display:flex;align-items:center;position:relative;height:%?80?%}.row-box .row .tit[data-v-7122b95c]{flex-shrink:0;width:%?40?%;font-size:%?30?%;color:#303133}.row-box .row .input[data-v-7122b95c]{flex:1;font-size:%?30?%;color:#303133}.row-box .row .iconlocation[data-v-7122b95c]{font-size:%?36?%;color:#909399}.row-box .row .buttom[data-v-7122b95c]{color:#5dbc7c;font-size:%?28?%}.list[data-v-7122b95c]{padding-left:%?30?%;margin-top:%?30?%;background-color:#fff}.list .box[data-v-7122b95c]{display:flex;align-items:center;width:100%;height:%?120?%;border-bottom:1px solid #ebeef5;padding-right:%?25?%}.list .box .icon[data-v-7122b95c]{font-size:%?48?%;padding-right:%?20?%;display:flex}.list .box .yongjing[data-v-7122b95c]{width:%?48?%;height:%?48?%}.list .box .iconweixin1[data-v-7122b95c]{color:#18bf16}.list .box .iconzhifubao[data-v-7122b95c]{color:#08aaec}.list .box .title-box[data-v-7122b95c]{flex-grow:1;text-align:left}.list .box .title-box .title[data-v-7122b95c]{font-size:%?30?%;color:#606266}.list .box .title-box .node[data-v-7122b95c]{font-size:%?24?%;color:#909399}[data-v-7122b95c] .uni-radio-input{width:%?45?%;height:%?45?%}.active-bg[data-v-7122b95c]{background:linear-gradient(143.2747deg,#ff6a00,#ee0979)!important;color:#fff!important}body.?%PAGE?%[data-v-7122b95c]{background:#fff}',""]),t.exports=e},a909:function(t,e,a){"use strict";var n;a.d(e,"b",(function(){return i})),a.d(e,"c",(function(){return o})),a.d(e,"a",(function(){return n}));var i=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("v-uni-view",{staticClass:"content"},[a("v-uni-view",{staticClass:"top_box"},[a("v-uni-text",{staticClass:"yue-tit"},[t._v("当前余额:")]),a("v-uni-text",{staticClass:"yue-num"},[t._v("¥"+t._s(t._f("parseFloatNum")(t.now_money)))])],1),a("v-uni-view",{staticClass:"line_box"}),a("v-uni-view",{staticClass:"cz_box"},[a("v-uni-view",{staticClass:"cz_wrap"},[a("v-uni-text",{staticClass:"cz_tit"},[t._v("¥")]),a("v-uni-input",{staticClass:"cz_input",attrs:{type:"number",placeholder:"请输入充值金额","placeholder-class":"placeholder"},on:{focus:function(e){arguments[0]=e=t.$handleEvent(e),t.changeNum()}},model:{value:t.money,callback:function(e){t.money=e},expression:"money"}})],1),a("v-uni-view",{staticClass:"zc_list_box"},t._l(t.list,(function(e,n){return a("v-uni-view",{key:n,staticClass:"zc_list_price",class:{seletPrice:t.seletNum==e.price},on:{click:function(a){arguments[0]=a=t.$handleEvent(a),t.seletChange(e,n)}}},[t._v(t._s(t._f("parseFloatNum")(e.price))+"元")])})),1)],1),a("v-uni-view",{staticClass:"line_box"}),a("v-uni-view",{staticClass:"cz-type"},[a("v-uni-view",{staticClass:"type-left"},[a("v-uni-view",{staticClass:"icon iconfont iconweixin"}),a("v-uni-view",{staticClass:"tit"},[t._v("微信充值")])],1),a("v-uni-view",{staticClass:"right"},[a("v-uni-radio",{attrs:{value:"weixin",color:" #EB001C",checked:"weixin"==t.type}})],1)],1),a("v-uni-button",{staticClass:"add-btn up",class:{"active-bg":t.payLoding},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),!t.payLoding&&t.confirm()}}},[t._v("立即充值")])],1)},o=[]},cd20:function(t,e,a){var n=a("94a2");"string"===typeof n&&(n=[[t.i,n,""]]),n.locals&&(t.exports=n.locals);var i=a("4f06").default;i("36ceec98",n,!0,{sourceMap:!1,shadowMode:!1})},ddc0:function(t,e,a){"use strict";a.r(e);var n=a("a909"),i=a("83fa");for(var o in i)"default"!==o&&function(t){a.d(e,t,(function(){return i[t]}))}(o);a("f5da");var c,r=a("f0c5"),s=Object(r["a"])(i["default"],n["b"],n["c"],!1,null,"7122b95c",null,!1,n["a"],c);e["default"]=s.exports},f5da:function(t,e,a){"use strict";var n=a("cd20"),i=a.n(n);i.a},fbb0:function(t,e,a){"use strict";var n=a("4ea4");a("acd8"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=n(a("5530")),o=a("3731"),c=a("2310"),r=a("26cb"),s={filters:{getMoneyStyle:o.getMoneyStyle,parseFloatNum:function(t){return parseFloat(t)}},data:function(){return{type:"weixin",money:"",payLoding:!1,list:["300","200","150","100","50"],now_money:"",seletNum:"300",zhuyi:[],quota:"",typeText:0}},onLoad:function(t){this.loadData()},computed:(0,i.default)({},(0,r.mapState)(["weichatObj","userInfo"])),methods:{navTo:function(t){uni.navigateTo({url:t})},changeNum:function(){this.seletNum=this.money="",console.log(this.seletNum,this.money)},seletChange:function(t,e){this.seletNum=t.price,this.seletMoney=t.price,this.money=t.price},tabRadio:function(t){this.type=t.detail.value,"weixin"==t.detail.value?this.typeText=0:this.typeText=1},rechargeXuan:function(t){this.money=t.price,this.quota=t.quota},loadData:function(){var t=this;(0,c.moneyChong)({}).then((function(e){var a=e.data;console.log(a,"123456789"),t.list=a.recharge_quota})),(0,c.userBalance)({}).then((function(e){var a=e.data;t.now_money=a.now_money}))},confirm:function(){var t=this;if(t.payLoding=!0,!t.money)return t.$api.msg("请输入金额"),void(t.payLoding=!1);(0,c.rechargeWechat)({price:this.money,from:this.type}).then((function(e){var a=e.data.data;t.weichatObj.chooseWXPay({timestamp:a.timestamp,nonceStr:a.nonceStr,package:a.package,signType:a.signType,paySign:a.paySign,success:function(t){uni.showToast({title:"充值成功",duration:2e3,position:"top",success:function(t){uni.navigateBack()}})}}),t.payLoding=!1})).catch((function(e){t.payLoding=!1,console.log(e)}))}}};e.default=s}}]);