hookehuyr

fix: 将 Taro.getSystemInfoSync 替换为 Taro.getWindowInfo

更新系统信息获取方法以使用更合适的 API
1 <!-- 1 <!--
2 * @Date: 2022-09-19 14:11:06 2 * @Date: 2022-09-19 14:11:06
3 * @LastEditors: hookehuyr hookehuyr@gmail.com 3 * @LastEditors: hookehuyr hookehuyr@gmail.com
4 - * @LastEditTime: 2025-09-19 22:53:44 4 + * @LastEditTime: 2025-09-19 23:47:10
5 * @FilePath: /lls_program/src/pages/ActivitiesCover/index.vue 5 * @FilePath: /lls_program/src/pages/ActivitiesCover/index.vue
6 * @Description: 活动海报页面 - 展示活动信息并处理定位授权 6 * @Description: 活动海报页面 - 展示活动信息并处理定位授权
7 --> 7 -->
...@@ -156,7 +156,7 @@ const systemInfo = ref({}); ...@@ -156,7 +156,7 @@ const systemInfo = ref({});
156 */ 156 */
157 const getSystemInfo = () => { 157 const getSystemInfo = () => {
158 try { 158 try {
159 - const info = Taro.getSystemInfoSync(); 159 + const info = Taro.getWindowInfo();
160 systemInfo.value = info; 160 systemInfo.value = info;
161 } catch (error) { 161 } catch (error) {
162 console.error('获取系统信息失败:', error); 162 console.error('获取系统信息失败:', error);
......
1 <!-- 1 <!--
2 * @Date: 2025-08-27 17:43:45 2 * @Date: 2025-08-27 17:43:45
3 * @LastEditors: hookehuyr hookehuyr@gmail.com 3 * @LastEditors: hookehuyr hookehuyr@gmail.com
4 - * @LastEditTime: 2025-09-19 23:23:33 4 + * @LastEditTime: 2025-09-19 23:46:06
5 * @FilePath: /lls_program/src/pages/Dashboard/index.vue 5 * @FilePath: /lls_program/src/pages/Dashboard/index.vue
6 * @Description: 首页 6 * @Description: 首页
7 --> 7 -->
...@@ -478,7 +478,7 @@ const systemInfo = ref({}); ...@@ -478,7 +478,7 @@ const systemInfo = ref({});
478 */ 478 */
479 const getSystemInfo = () => { 479 const getSystemInfo = () => {
480 try { 480 try {
481 - const info = Taro.getSystemInfoSync(); 481 + const info = Taro.getWindowInfo();
482 systemInfo.value = info; 482 systemInfo.value = info;
483 } catch (error) { 483 } catch (error) {
484 console.error('获取系统信息失败:', error); 484 console.error('获取系统信息失败:', error);
......