Showing
4 changed files
with
23 additions
and
7 deletions
| ... | @@ -169,7 +169,7 @@ const onClose = () => { // 关闭提示框回调 | ... | @@ -169,7 +169,7 @@ const onClose = () => { // 关闭提示框回调 |
| 169 | // 跳转个人中心 | 169 | // 跳转个人中心 |
| 170 | const onSubmit = () => { | 170 | const onSubmit = () => { |
| 171 | $router.push({ | 171 | $router.push({ |
| 172 | - path: '/me/index' | 172 | + path: '/me/verifyUser' |
| 173 | }); | 173 | }); |
| 174 | } | 174 | } |
| 175 | 175 | ... | ... |
| ... | @@ -2,7 +2,7 @@ | ... | @@ -2,7 +2,7 @@ |
| 2 | * @Author: hookehuyr hookehuyr@gmail.com | 2 | * @Author: hookehuyr hookehuyr@gmail.com |
| 3 | * @Date: 2022-05-31 22:09:58 | 3 | * @Date: 2022-05-31 22:09:58 |
| 4 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 4 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 5 | - * @LastEditTime: 2022-06-09 00:43:28 | 5 | + * @LastEditTime: 2022-06-09 14:31:33 |
| 6 | * @FilePath: /tswj/src/components/DonateFlower/index.vue | 6 | * @FilePath: /tswj/src/components/DonateFlower/index.vue |
| 7 | * @Description: 捐花组件 | 7 | * @Description: 捐花组件 |
| 8 | --> | 8 | --> |
| ... | @@ -98,8 +98,11 @@ import { ref, onMounted, watch, nextTick } from 'vue' | ... | @@ -98,8 +98,11 @@ import { ref, onMounted, watch, nextTick } from 'vue' |
| 98 | import { useRouter } from 'vue-router' | 98 | import { useRouter } from 'vue-router' |
| 99 | import { $, Toast } from '@/utils/generatePackage' | 99 | import { $, Toast } from '@/utils/generatePackage' |
| 100 | import { addDonateAPI } from '@/api/C/donate.js' | 100 | import { addDonateAPI } from '@/api/C/donate.js' |
| 101 | +// import { wxJsAPI } from '@/api/wx/config' | ||
| 102 | +// import { wxPayAPI } from '@/api/wx/pay' | ||
| 101 | import agreementHtml from './agreement' | 103 | import agreementHtml from './agreement' |
| 102 | import { USER_TYPE } from '@/constant' | 104 | import { USER_TYPE } from '@/constant' |
| 105 | +// import wx from 'weixin-js-sdk' | ||
| 103 | 106 | ||
| 104 | const $router = useRouter(); | 107 | const $router = useRouter(); |
| 105 | const props = defineProps({ | 108 | const props = defineProps({ |
| ... | @@ -112,7 +115,7 @@ const emit = defineEmits(['on-close']); | ... | @@ -112,7 +115,7 @@ const emit = defineEmits(['on-close']); |
| 112 | let donate_number = ref(1); | 115 | let donate_number = ref(1); |
| 113 | const donateFlower = () => { | 116 | const donateFlower = () => { |
| 114 | if (!agreed.value) { | 117 | if (!agreed.value) { |
| 115 | - Toast.fail('请选勾选同意按钮!'); | 118 | + Toast.fail('请先查看捐赠协议,勾选同意!'); |
| 116 | return false; | 119 | return false; |
| 117 | } | 120 | } |
| 118 | // 捐钱接口 | 121 | // 捐钱接口 |
| ... | @@ -197,10 +200,22 @@ const cancelDonate = () => { | ... | @@ -197,10 +200,22 @@ const cancelDonate = () => { |
| 197 | } | 200 | } |
| 198 | 201 | ||
| 199 | // TODO: 微信支付 | 202 | // TODO: 微信支付 |
| 203 | +onMounted(async () => { | ||
| 204 | + // 获取 wx 配置文件 | ||
| 205 | + // const { data } = await wxJsAPI() | ||
| 206 | + // const cfg = data | ||
| 207 | + // wx.config(cfg); | ||
| 208 | + // wx.ready((res) => { | ||
| 209 | + // }); | ||
| 210 | + // wx.error((err) => { | ||
| 211 | + // console.error(err); | ||
| 212 | + // }); | ||
| 213 | +}); | ||
| 214 | +// const wxPay = async () => { | ||
| 215 | +// const params = { bill_id: bill_id } | ||
| 216 | +// const { data } = await wxPayAPI(params) | ||
| 217 | +// } | ||
| 200 | 218 | ||
| 201 | -onMounted(() => { | ||
| 202 | - | ||
| 203 | -}) | ||
| 204 | // 选择捐赠数量 | 219 | // 选择捐赠数量 |
| 205 | const defaultOptions = ref({ | 220 | const defaultOptions = ref({ |
| 206 | 1: '1朵金花', | 221 | 1: '1朵金花', | ... | ... |
| ... | @@ -170,7 +170,7 @@ const onClose = () => { // 关闭提示框回调 | ... | @@ -170,7 +170,7 @@ const onClose = () => { // 关闭提示框回调 |
| 170 | // 跳转个人中心 | 170 | // 跳转个人中心 |
| 171 | const onSubmit = () => { | 171 | const onSubmit = () => { |
| 172 | $router.push({ | 172 | $router.push({ |
| 173 | - path: '/me/index' | 173 | + path: '/me/verifyUser' |
| 174 | }); | 174 | }); |
| 175 | } | 175 | } |
| 176 | 176 | ... | ... |
| ... | @@ -157,6 +157,7 @@ const onClose = () => { // 关闭提示框回调 | ... | @@ -157,6 +157,7 @@ const onClose = () => { // 关闭提示框回调 |
| 157 | 157 | ||
| 158 | // 新增/编辑儿童信息 | 158 | // 新增/编辑儿童信息 |
| 159 | const handleUser = (type) => { | 159 | const handleUser = (type) => { |
| 160 | + if (!actions.value.length) return; // 实名认证不允许修改,儿童信息可以修改 | ||
| 160 | if (type === 'ADD') { | 161 | if (type === 'ADD') { |
| 161 | $router.push({ | 162 | $router.push({ |
| 162 | path: '/me/handleUser', | 163 | path: '/me/handleUser', | ... | ... |
-
Please register or login to post a comment