From 47b428432635d26f54ef749f17a021a1eabc9a59 Mon Sep 17 00:00:00 2001 From: "DESKTOP-GMUNQ1B\\k" <1154079537@qq.com> Date: Fri, 22 Mar 2024 10:50:55 +0800 Subject: [PATCH] 1 --- api/order.js | 8 + api/payment.js | 7 + components/payPwd/index.vue | 92 ++ components/popups/index.vue | 248 ++++ components/popups/index_backup.vue | 167 +++ pages/payment/get_payment.vue | 452 ++++--- pages/payment/settlement.vue | 1864 ++++++++++++++-------------- pages/users/embody/embody.vue | 82 +- static/del.webp | Bin 0 -> 1400 bytes static/shop_logo.webp | Bin 0 -> 1424 bytes 10 files changed, 1842 insertions(+), 1078 deletions(-) create mode 100644 components/payPwd/index.vue create mode 100644 components/popups/index.vue create mode 100644 components/popups/index_backup.vue create mode 100644 static/del.webp create mode 100644 static/shop_logo.webp diff --git a/api/order.js b/api/order.js index f9df010..141e935 100644 --- a/api/order.js +++ b/api/order.js @@ -9,6 +9,14 @@ // +---------------------------------------------------------------------- import request from "@/utils/request.js"; +/** + * 校验支付密码是否正确 + * @param numType + */ +export function verifyPwd(data) { + return request.post("order/verifyPwd", data); +} + /** * 获取购物车列表 * @param numType boolean true 购物车数量,false=购物车产品数量 diff --git a/api/payment.js b/api/payment.js index 4d7f58d..0b8bb14 100644 --- a/api/payment.js +++ b/api/payment.js @@ -16,6 +16,13 @@ export function addCart(data) { return request.post(`user/cart/create`, data); } +/** + * 根据店铺 获取商品 + */ +export function getProductInfo1(data) { + return request.get(`order_mix`, data); +} + /** * 根据店铺id 获取店铺信息 */ diff --git a/components/payPwd/index.vue b/components/payPwd/index.vue new file mode 100644 index 0000000..fdf46c7 --- /dev/null +++ b/components/payPwd/index.vue @@ -0,0 +1,92 @@ + + + + + + \ No newline at end of file diff --git a/components/popups/index.vue b/components/popups/index.vue new file mode 100644 index 0000000..4b9b696 --- /dev/null +++ b/components/popups/index.vue @@ -0,0 +1,248 @@ + + + + + \ No newline at end of file diff --git a/components/popups/index_backup.vue b/components/popups/index_backup.vue new file mode 100644 index 0000000..166054a --- /dev/null +++ b/components/popups/index_backup.vue @@ -0,0 +1,167 @@ + + + + + \ No newline at end of file diff --git a/pages/payment/get_payment.vue b/pages/payment/get_payment.vue index 1cae073..07d2cbf 100644 --- a/pages/payment/get_payment.vue +++ b/pages/payment/get_payment.vue @@ -1,66 +1,73 @@ - \ No newline at end of file diff --git a/pages/users/embody/embody.vue b/pages/users/embody/embody.vue index 4db0222..82f5782 100644 --- a/pages/users/embody/embody.vue +++ b/pages/users/embody/embody.vue @@ -186,8 +186,15 @@ :order_id="currentTab"> - + + + + + + @@ -198,7 +205,6 @@ getLisApplyAPI, getAccountApplyAPI, postAccountApplyAPI, - } from '@/api/user.js' import { extractCash, @@ -217,10 +223,18 @@ import { Toast } from '../../../libs/uniApi'; + import { + verifyPwd + } from '@/api/order.js'; + import payPwd from "@/components/payPwd/index.vue"; + import popups from "@/components/popups/index.vue"; + export default { components: { cash, - authorize + authorize, + payPwd, + popups }, data() { return { @@ -278,7 +292,8 @@ pay_close: false, pay_type: [], source: '', - merId: '' + merId: '', + modes: {} }; }, computed: { @@ -487,18 +502,20 @@ financial_bank_branch: this.mode.bank_address, financial_type: 1 } - console.log(mode); - postCreateApplyAPI(this.merId, mode).then(res => { + this.modes = mode; + + this.$refs.popups.handleOpen(); + }, + + trueWithdraw() { + postCreateApplyAPI(this.merId, this.modes).then(res => { // 提现申请 - // that.postCreate(e.detail.value.extract_price) Toast(res.message) setTimeout(() => { uni.navigateBack({ delta: 1 }) }, 1000) - - console.log(res); }).catch(err => { Toast(err) setTimeout(() => { @@ -509,6 +526,53 @@ }) }, + + // 输入密码回调 + handleConfirm(e) { + // 验证密码是否正确 + verifyPwd({ + withdrawal_pwd: e + }).then(res => { + // 密码是否有效 状态码判断 + const code = res.data.code; + this.$set(this.modes, 'withdrawal_pwd', e); + + if (code == 100) { //密码正确 + uni.showLoading({ + title: '订单支付中', + mask: true + }); + this.trueWithdraw(); + } else { + this.$refs.payPwd.handleOpen(code); + } + }).catch(err => { + console.log(err) + }) + }, + + // 弹框左边按钮 101 未设置密码 102 忘记密码 都去设置密码 + handleLeft(code) { + uni.navigateTo({ + url: "/pages/users/user_modify_pwd/index?type=payPwd" + }); + this.$refs.payPwd.handleClose(); + }, + + // 弹框右边按钮 取消 重试 + handleRight(code) { + if (code == 101) { //取消 + this.$refs.payPwd.handleClose(code); + } else { + this.$refs.payPwd.handleClose(); + this.$refs.popups.handleOpen(); + } + }, + + handleClear() {}, + handleChange() {}, + + async postCreate(price) { const data = { extract_money: price, diff --git a/static/del.webp b/static/del.webp new file mode 100644 index 0000000000000000000000000000000000000000..7348c6ed1603f78f43a0b0ae669cdb845dd9731c GIT binary patch literal 1400 zcmWIYbaN|UWnc(*bqWXzu!!JdU|=u+VpTBmbaoCn!3g9sFrEOBEI_H;ypp0IcPE92 z$S4K&2Mmlr2nLDC#RU)+RuZV{+ck*V%eq)q;1}dfNi9wWD)|7!Dn&rcfo>83vPIG% zYz+`Q3BtAkvCB&eN`PttK=2?(*InG6iuTNxN6ZXv`}7BDdI zw=ghlJC6`Ugh@eSQ6ktl79h!#md3#FX*mM}ZzKbQ@C612u4u3vkig+K1)!7+&|UdJ zn9h*HkjkLI;K`83kj$V5WElY?)sVpq7{fk|%nS_rst%k2@=q-$skpD4=Uo4h>3{C! z3#~?n3ROJ&f^5|vc8mYWpWUW+e4>h_*Vj2M`f(5T=SuC8*_JDP!ZY~o-G}jt4GbI( zhZ%W5j%v94ci-p77e9Z$eC_rB@;!HB;@4lk_WAqkg1z5<{m;&>-x;uVY1Zo8-JfG_ zhs>`1{^xI>*V0>Z$3t?1bx&XV`+4KNZ7Ugaqt|L*{rfp{Z*F#V$mva2wyB&yBV#I> zkmgmynA=}9>CfaPaaT9#RR8^-rUn#ctI4fzn0Ya5(&A|8`C$|H11oqGQ)p=l<0;h6(UGFlds25?;JbG{2^UaUBe4PIAy#4XZ zjhB9Y=w%Z>ygpUO%;V0B_aDAJS;1nsHh=H$)`Lc0oc)&k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