hookehuyr

✨ feat(实名认证相关): 没儿童只有实名认证不能点击头像,没有实名认证提示直接跳转实名认证页面

......@@ -169,7 +169,7 @@ const onClose = () => { // 关闭提示框回调
// 跳转个人中心
const onSubmit = () => {
$router.push({
path: '/me/index'
path: '/me/verifyUser'
});
}
......
......@@ -2,7 +2,7 @@
* @Author: hookehuyr hookehuyr@gmail.com
* @Date: 2022-05-31 22:09:58
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-06-09 00:43:28
* @LastEditTime: 2022-06-09 14:31:33
* @FilePath: /tswj/src/components/DonateFlower/index.vue
* @Description: 捐花组件
-->
......@@ -98,8 +98,11 @@ import { ref, onMounted, watch, nextTick } from 'vue'
import { useRouter } from 'vue-router'
import { $, Toast } from '@/utils/generatePackage'
import { addDonateAPI } from '@/api/C/donate.js'
// import { wxJsAPI } from '@/api/wx/config'
// import { wxPayAPI } from '@/api/wx/pay'
import agreementHtml from './agreement'
import { USER_TYPE } from '@/constant'
// import wx from 'weixin-js-sdk'
const $router = useRouter();
const props = defineProps({
......@@ -112,7 +115,7 @@ const emit = defineEmits(['on-close']);
let donate_number = ref(1);
const donateFlower = () => {
if (!agreed.value) {
Toast.fail('请选勾选同意按钮!');
Toast.fail('请先查看捐赠协议,勾选同意!');
return false;
}
// 捐钱接口
......@@ -197,10 +200,22 @@ const cancelDonate = () => {
}
// TODO: 微信支付
onMounted(async () => {
// 获取 wx 配置文件
// const { data } = await wxJsAPI()
// const cfg = data
// wx.config(cfg);
// wx.ready((res) => {
// });
// wx.error((err) => {
// console.error(err);
// });
});
// const wxPay = async () => {
// const params = { bill_id: bill_id }
// const { data } = await wxPayAPI(params)
// }
onMounted(() => {
})
// 选择捐赠数量
const defaultOptions = ref({
1: '1朵金花',
......
......@@ -170,7 +170,7 @@ const onClose = () => { // 关闭提示框回调
// 跳转个人中心
const onSubmit = () => {
$router.push({
path: '/me/index'
path: '/me/verifyUser'
});
}
......
......@@ -157,6 +157,7 @@ const onClose = () => { // 关闭提示框回调
// 新增/编辑儿童信息
const handleUser = (type) => {
if (!actions.value.length) return; // 实名认证不允许修改,儿童信息可以修改
if (type === 'ADD') {
$router.push({
path: '/me/handleUser',
......