hookehuyr

fix

...@@ -10,6 +10,11 @@ const $route = useRoute(); ...@@ -10,6 +10,11 @@ const $route = useRoute();
10 10
11 onMounted(() => { 11 onMounted(() => {
12 // php需要先跳转链接获取openid 12 // php需要先跳转链接获取openid
13 + /**
14 + * encodeURIComponent() 函数可把字符串作为 URI 组件进行编码。
15 + * 该方法不会对 ASCII 字母和数字进行编码,也不会对这些 ASCII 标点符号进行编码: - _ . ! ~ * ' ( ) 。
16 + * 其他字符(比如 :;/?:@&=+$,# 这些用于分隔 URI 组件的标点符号),都是由一个或多个十六进制的转义序列替换的。
17 + */
13 let url = encodeURIComponent(location.origin + location.pathname + $route.query.href); // 未授权的地址 18 let url = encodeURIComponent(location.origin + location.pathname + $route.query.href); // 未授权的地址
14 if (import.meta.env.DEV) { // TAG: 开发环境测试数据 19 if (import.meta.env.DEV) { // TAG: 开发环境测试数据
15 location.href = `/srv/?f=voice&a=openid_${$route.query.userType}&res=${url}&input_openid=${import.meta.env.VITE_OPENID}` 20 location.href = `/srv/?f=voice&a=openid_${$route.query.userType}&res=${url}&input_openid=${import.meta.env.VITE_OPENID}`
......