feat: 新增用户和师傅消息中心及订单页重构

- 新增用户消息中心组件 UserMessageView
- 新增师傅消息中心组件 MasterMessageView
- 新增用户订单列表组件 UserOrdersView
- 重构订单列表页,复用独立组件
- 新增系统工具 getWindowInfoSafe 兼容多端系统信息获取
- 重构 TabBar 组件,支持单母页模式和事件回调
- 优化消息跳转逻辑,支持角色自适应 Tab 切换
这个提交包含在:
YuanWen
2026-11-05 16:52:12 +08:00
父节点 f60b2df7b3
当前提交 cd0da0324b
共有 23 个文件被更改,包括 4088 次插入 和 3538 次删除

30
yjyf-app/utils/system.js 普通文件
查看文件

@@ -0,0 +1,30 @@
/**
* 系统与窗口信息工具
* 兼容微信小程序新版规范(废弃 wx.getSystemInfoSync,推荐 getWindowInfo)
*/
export function getWindowInfoSafe() {
try {
if (typeof uni.getWindowInfo === 'function') {
const win = uni.getWindowInfo();
if (win && (win.statusBarHeight !== undefined || win.windowWidth !== undefined)) {
return win;
}
}
if (typeof uni.getSystemInfoSync === 'function') {
return uni.getSystemInfoSync();
}
} catch (e) {
// 忽略异常,降级兜底
}
return {
statusBarHeight: 20,
windowWidth: 375,
windowHeight: 667,
screenWidth: 375,
screenHeight: 667
};
}
export default {
getWindowInfoSafe
};