Commit 42d6f5df by 林翔

lx

parent 58c28bb2
......@@ -556,8 +556,7 @@ const actions = {
rescue: payload.rescue,
types: payload.types,
site_type: payload.site_type,
order_id: payload.order_id,
callback: payload.callback
order_id: payload.order_id
}
Services.payTodo(qs.stringify(params)).then((res) => {
let data = res.data;
......
......@@ -68,8 +68,7 @@
rescue: '1',
types: '1',
site_type: 2,
order_id: value,
callback: 1 //满足后端jsonp要求,返回页面URL
order_id: value
});
}else if (this.radio == 2) { //支付宝支付
window.location.href = productionUrlApi + "pay/todo?pay_code=alipay&rescue=1&types=1&site_type=2&order_id="+value;
......
......@@ -8,7 +8,7 @@
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var D_svnData_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/@babel/runtime-corejs2/helpers/esm/objectSpread */ \"./node_modules/_@babel_runtime-corejs2@7.3.1@@babel/runtime-corejs2/helpers/esm/objectSpread.js\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.6.6@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var vuex__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vuex */ \"./node_modules/_vuex@3.1.0@vuex/dist/vuex.esm.js\");\n/* harmony import */ var _views_common_Header_vue__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @/views/common/Header.vue */ \"./src/views/common/Header.vue\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@1.6.5@vant/es/index.js\");\n/* harmony import */ var _api_index__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../api/index */ \"./src/api/index.js\");\n\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n\n\n\nconsole.log(_api_index__WEBPACK_IMPORTED_MODULE_5__[\"productionUrlApi\"]);\nvue__WEBPACK_IMPORTED_MODULE_1__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_4__[\"RadioGroup\"]).use(vant__WEBPACK_IMPORTED_MODULE_4__[\"Radio\"]).use(vant__WEBPACK_IMPORTED_MODULE_4__[\"Cell\"]).use(vant__WEBPACK_IMPORTED_MODULE_4__[\"CellGroup\"]);\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'WalletRecharge',\n data: function data() {\n return {\n title: \"钱包充值\",\n meaushow: true,\n inputNum: this.$route.query.amount || '',\n radio: '1'\n };\n },\n computed: Object(D_svnData_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__[\"default\"])({}, Object(vuex__WEBPACK_IMPORTED_MODULE_2__[\"mapState\"])({\n walletInfoData: function walletInfoData(state) {\n return state.wallet.walletInfoData;\n },\n amountRechargeID: function amountRechargeID(state) {\n return state.wallet.amountRechargeID;\n }\n })),\n watch: {\n amountRechargeID: function amountRechargeID(value) {\n if (value) {\n if (this.radio == 1) {\n //微信支付\n this.$store.dispatch({\n type: 'payTodo',\n pay_code: 'wxpay',\n rescue: '1',\n types: '1',\n site_type: 2,\n order_id: value,\n callback: 1 //满足后端jsonp要求,返回页面URL\n\n });\n } else if (this.radio == 2) {\n //支付宝支付\n window.location.href = _api_index__WEBPACK_IMPORTED_MODULE_5__[\"productionUrlApi\"] + \"pay/todo?pay_code=alipay&rescue=1&types=1&site_type=2&order_id=\" + value;\n } else if (this.radio == 3) {\n //中国银联\n window.location.href = _api_index__WEBPACK_IMPORTED_MODULE_5__[\"productionUrlApi\"] + \"pay/todo?pay_code=unionpay&rescue=1&types=1&pay_mode=2&order_id=\" + value;\n }\n }\n }\n },\n created: function created() {\n this.$store.dispatch({\n type: 'getWalletInfo'\n });\n },\n methods: {\n recharge: function recharge() {\n //充值\n if (this.inputNum !== '') {\n console.log(this.radio); //充值申请\n\n this.$store.dispatch({\n type: 'walletRecharge',\n amount: this.inputNum\n });\n }\n }\n },\n components: {\n Header: _views_common_Header_vue__WEBPACK_IMPORTED_MODULE_3__[\"default\"]\n }\n});\n\n//# sourceURL=webpack:///./src/views/wallet/Recharge.vue?./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js??ref--12-0!./node_modules/_babel-loader@8.0.5@babel-loader/lib!./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.6.4@vue-loader/lib??vue-loader-options");
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var D_svnData_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/@babel/runtime-corejs2/helpers/esm/objectSpread */ \"./node_modules/_@babel_runtime-corejs2@7.3.1@@babel/runtime-corejs2/helpers/esm/objectSpread.js\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.6.6@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var vuex__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vuex */ \"./node_modules/_vuex@3.1.0@vuex/dist/vuex.esm.js\");\n/* harmony import */ var _views_common_Header_vue__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @/views/common/Header.vue */ \"./src/views/common/Header.vue\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@1.6.5@vant/es/index.js\");\n/* harmony import */ var _api_index__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../api/index */ \"./src/api/index.js\");\n\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n\n\n\nconsole.log(_api_index__WEBPACK_IMPORTED_MODULE_5__[\"productionUrlApi\"]);\nvue__WEBPACK_IMPORTED_MODULE_1__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_4__[\"RadioGroup\"]).use(vant__WEBPACK_IMPORTED_MODULE_4__[\"Radio\"]).use(vant__WEBPACK_IMPORTED_MODULE_4__[\"Cell\"]).use(vant__WEBPACK_IMPORTED_MODULE_4__[\"CellGroup\"]);\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'WalletRecharge',\n data: function data() {\n return {\n title: \"钱包充值\",\n meaushow: true,\n inputNum: this.$route.query.amount || '',\n radio: '1'\n };\n },\n computed: Object(D_svnData_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__[\"default\"])({}, Object(vuex__WEBPACK_IMPORTED_MODULE_2__[\"mapState\"])({\n walletInfoData: function walletInfoData(state) {\n return state.wallet.walletInfoData;\n },\n amountRechargeID: function amountRechargeID(state) {\n return state.wallet.amountRechargeID;\n }\n })),\n watch: {\n amountRechargeID: function amountRechargeID(value) {\n if (value) {\n if (this.radio == 1) {\n //微信支付\n this.$store.dispatch({\n type: 'payTodo',\n pay_code: 'wxpay',\n rescue: '1',\n types: '1',\n site_type: 2,\n order_id: value\n });\n } else if (this.radio == 2) {\n //支付宝支付\n window.location.href = _api_index__WEBPACK_IMPORTED_MODULE_5__[\"productionUrlApi\"] + \"pay/todo?pay_code=alipay&rescue=1&types=1&site_type=2&order_id=\" + value;\n } else if (this.radio == 3) {\n //中国银联\n window.location.href = _api_index__WEBPACK_IMPORTED_MODULE_5__[\"productionUrlApi\"] + \"pay/todo?pay_code=unionpay&rescue=1&types=1&pay_mode=2&order_id=\" + value;\n }\n }\n }\n },\n created: function created() {\n this.$store.dispatch({\n type: 'getWalletInfo'\n });\n },\n methods: {\n recharge: function recharge() {\n //充值\n if (this.inputNum !== '') {\n console.log(this.radio); //充值申请\n\n this.$store.dispatch({\n type: 'walletRecharge',\n amount: this.inputNum\n });\n }\n }\n },\n components: {\n Header: _views_common_Header_vue__WEBPACK_IMPORTED_MODULE_3__[\"default\"]\n }\n});\n\n//# sourceURL=webpack:///./src/views/wallet/Recharge.vue?./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js??ref--12-0!./node_modules/_babel-loader@8.0.5@babel-loader/lib!./node_modules/_cache-loader@2.0.1@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.6.4@vue-loader/lib??vue-loader-options");
/***/ }),
......
......@@ -4782,7 +4782,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var vue_
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.6.6@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@1.6.5@vant/es/index.js\");\n/* harmony import */ var _api_index__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../api/index */ \"./src/api/index.js\");\n/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../util */ \"./src/util/index.js\");\n\n\n\n\n\nvar qs = __webpack_require__(/*! qs */ \"./node_modules/_qs@6.6.0@qs/lib/index.js\");\n\nvue__WEBPACK_IMPORTED_MODULE_0__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"]);\nvar state = {\n //钱包信息\n walletInfoData: {},\n //验证安全手机——图形验证码和开始倒计时标记\n verifyShowImgCode: false,\n verifyCountDownFlag: false,\n //激活钱包——图形验证码和开始倒计时标记\n activateShowImgCode: false,\n activateCountDownFlag: false,\n //找回密码——图形验证码和开始倒计时标记\n retieveShowImgCode: false,\n retieveCountDownFlag: false,\n passwordToken: '',\n //钱包明细\n walletListData: [],\n //提现充值明细\n walletRecordData: [],\n //绑定银行卡\n bankPasswordToken: '',\n bankCountDownFlag: false,\n bindBankKey: '',\n bindBankData: '',\n //充值单ID\n amountRechargeID: '',\n //提现单ID\n amountWithdrawID: '',\n //充值提现单据详细\n rechargeWithdrawOrderDetail: []\n};\nvar mutations = {\n getWalletInfo: function getWalletInfo(state, payload) {\n state.walletInfoData = payload.data;\n },\n sendSafesms: function sendSafesms(state, payload) {\n state.verifyShowImgCode = !payload.verifyCountDownFlag;\n state.verifyCountDownFlag = payload.verifyCountDownFlag;\n },\n smsVerifyActivate: function smsVerifyActivate(state, payload) {\n state.activateShowImgCode = !payload.activateCountDownFlag;\n state.activateCountDownFlag = payload.activateCountDownFlag;\n },\n smsVerifyRetrieve: function smsVerifyRetrieve(state, payload) {\n state.retieveShowImgCode = !payload.retieveCountDownFlag;\n state.retieveCountDownFlag = payload.retieveCountDownFlag;\n },\n verifyResetsms: function verifyResetsms(state, payload) {\n state.passwordToken = payload.data;\n },\n walletListLog: function walletListLog(state, payload) {\n state.walletListData = payload.data;\n },\n walletRecordList: function walletRecordList(state, payload) {\n state.walletRecordData = payload.data;\n },\n verifySafeMobile: function verifySafeMobile(state, payload) {\n state.bankPasswordToken = payload.data;\n _util__WEBPACK_IMPORTED_MODULE_3__[\"default\"].setCookie(\"bankPasswordToken\", payload.data, 1);\n },\n getBindBankmsg: function getBindBankmsg(state, payload) {\n state.bankCountDownFlag = payload.bankCountDownFlag;\n state.bindBankKey = payload.data.access_key;\n state.bindBankData = payload.data.access_data;\n },\n walletRecharge: function walletRecharge(state, payload) {\n state.amountRechargeID = payload.data;\n },\n walletWithdraw: function walletWithdraw(state, payload) {\n state.amountWithdrawID = payload.data;\n },\n rechargeWithdrawOrderIfo: function rechargeWithdrawOrderIfo(state, payload) {\n state.rechargeWithdrawOrderDetail = payload.data;\n },\n payTodo: function payTodo(state, payload) {\n state.rechargeWithdrawOrderDetail = payload.data;\n }\n};\nvar actions = {\n getWalletInfo: function getWalletInfo(_ref, payload) {\n var commit = _ref.commit;\n var params = {};\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].getWalletInfo(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n commit({\n type: 'getWalletInfo',\n data: data.data\n });\n }\n }).catch(function (err) {});\n },\n smsVerifyActivate: function smsVerifyActivate(_ref2, payload) {\n var commit = _ref2.commit;\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].loading({\n message: '处理中...'\n });\n var params = {\n mobile: payload.mobile,\n verify: payload.imgCode,\n channel: 3\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].smsVerify(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'smsVerifyActivate',\n activateCountDownFlag: true\n });\n } else if (data.err_code == 23019 || data.err_code == 11008 || data.err_code == 11011) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'smsVerifyActivate',\n activateCountDownFlag: false\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].clear();\n });\n },\n activateWallet: function activateWallet(_ref3, payload) {\n var commit = _ref3.commit;\n var params = {\n intl_code: '',\n safe_mobile: payload.mobile,\n verify_code: payload.verifyCode,\n pay_password: payload.password,\n reconfirm: payload.passwordConfirm\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].activateWallet(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet\";\n }, 2000);\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet/activate\";\n }, 2000);\n }\n }).catch(function (err) {});\n },\n sendSafesms: function sendSafesms(_ref4, payload) {\n var commit = _ref4.commit;\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].loading({\n message: '处理中...'\n });\n var params = {\n verify: payload.imgCode,\n channel: 3\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].sendSafesms(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'sendSafesms',\n verifyCountDownFlag: true\n });\n } else if (data.err_code == 23019) {\n //请确认图形验证码\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'sendSafesms',\n verifyCountDownFlag: false\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].clear();\n });\n },\n smsVerifyRetrieve: function smsVerifyRetrieve(_ref5, payload) {\n var commit = _ref5.commit;\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].loading({\n message: '处理中...'\n });\n var params = {\n verify: payload.imgCode,\n channel: 3\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].sendSafesms(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'smsVerifyRetrieve',\n retieveCountDownFlag: true\n });\n } else if (data.err_code == 23019) {\n //请确认图形验证码\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'smsVerifyRetrieve',\n retieveCountDownFlag: false\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].clear();\n });\n },\n verifyResetsms: function verifyResetsms(_ref6, payload) {\n var commit = _ref6.commit;\n var params = {\n verify_code: payload.verify_code\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].verifyResetsms(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'verifyResetsms',\n data: data.data\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n changeWalletpwd: function changeWalletpwd(_ref7, payload) {\n var commit = _ref7.commit;\n var params = {\n token: payload.token,\n pay_password: payload.pay_password,\n reconfirm: payload.reconfirm,\n mode: payload.mode\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].changeWalletpwd(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet\";\n }, 2000);\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n walletListLog: function walletListLog(_ref8, payload) {\n var commit = _ref8.commit;\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].loading({\n message: '加载中...'\n });\n var params = {\n log_type: payload.log_type,\n stime: payload.stime,\n etime: payload.etime\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].walletListLog(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n commit({\n type: 'walletListLog',\n data: data.data.list\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].clear();\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].clear();\n });\n },\n walletRecordList: function walletRecordList(_ref9, payload) {\n var commit = _ref9.commit;\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].loading({\n message: '加载中...'\n });\n var params = {\n wallet_type: payload.wallet_type,\n stime: payload.stime,\n etime: payload.etime\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].walletRecordList(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n commit({\n type: 'walletRecordList',\n data: data.data.list\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].clear();\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].clear();\n });\n },\n verifySafeMobile: function verifySafeMobile(_ref10, payload) {\n var commit = _ref10.commit;\n var params = {\n verify_code: payload.verify_code,\n pay_password: payload.pay_password\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].verifySafeMobile(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'verifySafeMobile',\n data: data.data\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet/bind\";\n }, 2000);\n } else if (data.err_code == 11030) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = '/h5/view/#/';\n }, 2000);\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 200\n });\n }\n }).catch(function (err) {});\n },\n getBindBankmsg: function getBindBankmsg(_ref11, payload) {\n var commit = _ref11.commit;\n var params = {\n bank_user: payload.bank_user,\n bank_id: payload.bank_id,\n bank_account: payload.bank_account,\n id_type: payload.id_type,\n id_number: payload.id_number,\n account_type: payload.account_type,\n mobile: payload.mobile,\n channel: 3\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].getBindBankmsg(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'getBindBankmsg',\n bankCountDownFlag: true,\n data: data.data\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n bindBankCard: function bindBankCard(_ref12, payload) {\n var commit = _ref12.commit;\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].loading({\n message: '处理中...'\n });\n var params = {\n token: payload.token,\n wallet_bank_id: payload.wallet_bank_id,\n sms_code: payload.sms_code,\n access_key: payload.access_key,\n access_data: payload.access_data\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].bindBankCard(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet\";\n }, 2000);\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"].clear();\n });\n },\n walletRecharge: function walletRecharge(_ref13, payload) {\n var commit = _ref13.commit;\n var params = {\n amount: payload.amount\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].walletRecharge(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'walletRecharge',\n data: data.data\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n walletWithdraw: function walletWithdraw(_ref14, payload) {\n var commit = _ref14.commit;\n var params = {\n amount: payload.amount,\n pay_password: payload.pay_password\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].walletWithdraw(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: '提现申请成功,预计1个工作日后到账,节假日顺延,请耐心等待',\n duration: 2000\n });\n commit({\n type: 'walletWithdraw',\n data: data.data\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet/record\";\n }, 2000);\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n rechargeWithdrawOrderIfo: function rechargeWithdrawOrderIfo(_ref15, payload) {\n var commit = _ref15.commit;\n var params = {\n wallet_id: payload.wallet_id\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].rechargeWithdrawOrderIfo(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'rechargeWithdrawOrderIfo',\n data: data.data\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n payTodo: function payTodo(_ref16, payload) {\n var commit = _ref16.commit;\n var params = {\n pay_code: payload.pay_code,\n rescue: payload.rescue,\n types: payload.types,\n site_type: payload.site_type,\n order_id: payload.order_id,\n callback: payload.callback\n };\n _api_index__WEBPACK_IMPORTED_MODULE_2__[\"services\"].payTodo(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n if (is_miniProgram()) {\n //微信小程序\n wx.requestPayment(data.data);\n } else {\n window.location.href = data.data;\n }\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_1__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n }\n};\nvar getters = {};\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n state: state,\n mutations: mutations,\n actions: actions,\n getters: getters\n});\n\n//# sourceURL=webpack:///./src/store/modules/wallet/wallet.js?");
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es6_promise__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es6.promise */ \"./node_modules/_core-js@2.6.5@core-js/modules/es6.promise.js\");\n/* harmony import */ var core_js_modules_es6_promise__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_promise__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es6_symbol__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es6.symbol */ \"./node_modules/_core-js@2.6.5@core-js/modules/es6.symbol.js\");\n/* harmony import */ var core_js_modules_es6_symbol__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_symbol__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.6.6@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@1.6.5@vant/es/index.js\");\n/* harmony import */ var _api_index__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../api/index */ \"./src/api/index.js\");\n/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../util */ \"./src/util/index.js\");\n\n\n\n\n\n\n\nvar qs = __webpack_require__(/*! qs */ \"./node_modules/_qs@6.6.0@qs/lib/index.js\");\n\nvue__WEBPACK_IMPORTED_MODULE_2__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"]);\nvar state = {\n //钱包信息\n walletInfoData: {},\n //验证安全手机——图形验证码和开始倒计时标记\n verifyShowImgCode: false,\n verifyCountDownFlag: false,\n //激活钱包——图形验证码和开始倒计时标记\n activateShowImgCode: false,\n activateCountDownFlag: false,\n //找回密码——图形验证码和开始倒计时标记\n retieveShowImgCode: false,\n retieveCountDownFlag: false,\n passwordToken: '',\n //钱包明细\n walletListData: [],\n //提现充值明细\n walletRecordData: [],\n //绑定银行卡\n bankPasswordToken: '',\n bankCountDownFlag: false,\n bindBankKey: '',\n bindBankData: '',\n //充值单ID\n amountRechargeID: '',\n //提现单ID\n amountWithdrawID: '',\n //充值提现单据详细\n rechargeWithdrawOrderDetail: []\n};\nvar mutations = {\n getWalletInfo: function getWalletInfo(state, payload) {\n state.walletInfoData = payload.data;\n },\n sendSafesms: function sendSafesms(state, payload) {\n state.verifyShowImgCode = !payload.verifyCountDownFlag;\n state.verifyCountDownFlag = payload.verifyCountDownFlag;\n },\n smsVerifyActivate: function smsVerifyActivate(state, payload) {\n state.activateShowImgCode = !payload.activateCountDownFlag;\n state.activateCountDownFlag = payload.activateCountDownFlag;\n },\n smsVerifyRetrieve: function smsVerifyRetrieve(state, payload) {\n state.retieveShowImgCode = !payload.retieveCountDownFlag;\n state.retieveCountDownFlag = payload.retieveCountDownFlag;\n },\n verifyResetsms: function verifyResetsms(state, payload) {\n state.passwordToken = payload.data;\n },\n walletListLog: function walletListLog(state, payload) {\n state.walletListData = payload.data;\n },\n walletRecordList: function walletRecordList(state, payload) {\n state.walletRecordData = payload.data;\n },\n verifySafeMobile: function verifySafeMobile(state, payload) {\n state.bankPasswordToken = payload.data;\n _util__WEBPACK_IMPORTED_MODULE_5__[\"default\"].setCookie(\"bankPasswordToken\", payload.data, 1);\n },\n getBindBankmsg: function getBindBankmsg(state, payload) {\n state.bankCountDownFlag = payload.bankCountDownFlag;\n state.bindBankKey = payload.data.access_key;\n state.bindBankData = payload.data.access_data;\n },\n walletRecharge: function walletRecharge(state, payload) {\n state.amountRechargeID = payload.data;\n },\n walletWithdraw: function walletWithdraw(state, payload) {\n state.amountWithdrawID = payload.data;\n },\n rechargeWithdrawOrderIfo: function rechargeWithdrawOrderIfo(state, payload) {\n state.rechargeWithdrawOrderDetail = payload.data;\n },\n payTodo: function payTodo(state, payload) {\n state.rechargeWithdrawOrderDetail = payload.data;\n }\n};\nvar actions = {\n getWalletInfo: function getWalletInfo(_ref, payload) {\n var commit = _ref.commit;\n var params = {};\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].getWalletInfo(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n commit({\n type: 'getWalletInfo',\n data: data.data\n });\n }\n }).catch(function (err) {});\n },\n smsVerifyActivate: function smsVerifyActivate(_ref2, payload) {\n var commit = _ref2.commit;\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].loading({\n message: '处理中...'\n });\n var params = {\n mobile: payload.mobile,\n verify: payload.imgCode,\n channel: 3\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].smsVerify(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'smsVerifyActivate',\n activateCountDownFlag: true\n });\n } else if (data.err_code == 23019 || data.err_code == 11008 || data.err_code == 11011) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'smsVerifyActivate',\n activateCountDownFlag: false\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].clear();\n });\n },\n activateWallet: function activateWallet(_ref3, payload) {\n var commit = _ref3.commit;\n var params = {\n intl_code: '',\n safe_mobile: payload.mobile,\n verify_code: payload.verifyCode,\n pay_password: payload.password,\n reconfirm: payload.passwordConfirm\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].activateWallet(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet\";\n }, 2000);\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet/activate\";\n }, 2000);\n }\n }).catch(function (err) {});\n },\n sendSafesms: function sendSafesms(_ref4, payload) {\n var commit = _ref4.commit;\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].loading({\n message: '处理中...'\n });\n var params = {\n verify: payload.imgCode,\n channel: 3\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].sendSafesms(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'sendSafesms',\n verifyCountDownFlag: true\n });\n } else if (data.err_code == 23019) {\n //请确认图形验证码\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'sendSafesms',\n verifyCountDownFlag: false\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].clear();\n });\n },\n smsVerifyRetrieve: function smsVerifyRetrieve(_ref5, payload) {\n var commit = _ref5.commit;\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].loading({\n message: '处理中...'\n });\n var params = {\n verify: payload.imgCode,\n channel: 3\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].sendSafesms(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'smsVerifyRetrieve',\n retieveCountDownFlag: true\n });\n } else if (data.err_code == 23019) {\n //请确认图形验证码\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'smsVerifyRetrieve',\n retieveCountDownFlag: false\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].clear();\n });\n },\n verifyResetsms: function verifyResetsms(_ref6, payload) {\n var commit = _ref6.commit;\n var params = {\n verify_code: payload.verify_code\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].verifyResetsms(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'verifyResetsms',\n data: data.data\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n changeWalletpwd: function changeWalletpwd(_ref7, payload) {\n var commit = _ref7.commit;\n var params = {\n token: payload.token,\n pay_password: payload.pay_password,\n reconfirm: payload.reconfirm,\n mode: payload.mode\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].changeWalletpwd(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet\";\n }, 2000);\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n walletListLog: function walletListLog(_ref8, payload) {\n var commit = _ref8.commit;\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].loading({\n message: '加载中...'\n });\n var params = {\n log_type: payload.log_type,\n stime: payload.stime,\n etime: payload.etime\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].walletListLog(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n commit({\n type: 'walletListLog',\n data: data.data.list\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].clear();\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].clear();\n });\n },\n walletRecordList: function walletRecordList(_ref9, payload) {\n var commit = _ref9.commit;\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].loading({\n message: '加载中...'\n });\n var params = {\n wallet_type: payload.wallet_type,\n stime: payload.stime,\n etime: payload.etime\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].walletRecordList(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n commit({\n type: 'walletRecordList',\n data: data.data.list\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].clear();\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].clear();\n });\n },\n verifySafeMobile: function verifySafeMobile(_ref10, payload) {\n var commit = _ref10.commit;\n var params = {\n verify_code: payload.verify_code,\n pay_password: payload.pay_password\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].verifySafeMobile(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'verifySafeMobile',\n data: data.data\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet/bind\";\n }, 2000);\n } else if (data.err_code == 11030) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = '/h5/view/#/';\n }, 2000);\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 200\n });\n }\n }).catch(function (err) {});\n },\n getBindBankmsg: function getBindBankmsg(_ref11, payload) {\n var commit = _ref11.commit;\n var params = {\n bank_user: payload.bank_user,\n bank_id: payload.bank_id,\n bank_account: payload.bank_account,\n id_type: payload.id_type,\n id_number: payload.id_number,\n account_type: payload.account_type,\n mobile: payload.mobile,\n channel: 3\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].getBindBankmsg(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'getBindBankmsg',\n bankCountDownFlag: true,\n data: data.data\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n bindBankCard: function bindBankCard(_ref12, payload) {\n var commit = _ref12.commit;\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].loading({\n message: '处理中...'\n });\n var params = {\n token: payload.token,\n wallet_bank_id: payload.wallet_bank_id,\n sms_code: payload.sms_code,\n access_key: payload.access_key,\n access_data: payload.access_data\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].bindBankCard(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet\";\n }, 2000);\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {\n vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"].clear();\n });\n },\n walletRecharge: function walletRecharge(_ref13, payload) {\n var commit = _ref13.commit;\n var params = {\n amount: payload.amount\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].walletRecharge(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'walletRecharge',\n data: data.data\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n walletWithdraw: function walletWithdraw(_ref14, payload) {\n var commit = _ref14.commit;\n var params = {\n amount: payload.amount,\n pay_password: payload.pay_password\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].walletWithdraw(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: '提现申请成功,预计1个工作日后到账,节假日顺延,请耐心等待',\n duration: 2000\n });\n commit({\n type: 'walletWithdraw',\n data: data.data\n });\n setTimeout(function () {\n window.location.href = \"/h5/view/#/wallet/record\";\n }, 2000);\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n rechargeWithdrawOrderIfo: function rechargeWithdrawOrderIfo(_ref15, payload) {\n var commit = _ref15.commit;\n var params = {\n wallet_id: payload.wallet_id\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].rechargeWithdrawOrderIfo(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 2000\n });\n commit({\n type: 'rechargeWithdrawOrderIfo',\n data: data.data\n });\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n },\n payTodo: function payTodo(_ref16, payload) {\n var commit = _ref16.commit;\n var params = {\n pay_code: payload.pay_code,\n rescue: payload.rescue,\n types: payload.types,\n site_type: payload.site_type,\n order_id: payload.order_id\n };\n _api_index__WEBPACK_IMPORTED_MODULE_4__[\"services\"].payTodo(qs.stringify(params)).then(function (res) {\n var data = res.data;\n\n if (data.err_code == 0) {\n if (is_miniProgram()) {\n //微信小程序\n wx.requestPayment(data.data);\n } else {\n window.location.href = data.data;\n }\n } else {\n Object(vant__WEBPACK_IMPORTED_MODULE_3__[\"Toast\"])({\n message: data.err_msg,\n duration: 3000\n });\n }\n }).catch(function (err) {});\n }\n};\nvar getters = {};\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n state: state,\n mutations: mutations,\n actions: actions,\n getters: getters\n});\n\n//# sourceURL=webpack:///./src/store/modules/wallet/wallet.js?");
/***/ }),
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment