feat: batch update - gift card breakdown spec, backend APIs, miniprogram pages, ETL finance recharge, docs & migrations

This commit is contained in:
Neo
2026-03-20 01:43:48 +08:00
parent 075caf067f
commit 79f9a0e1da
437 changed files with 118603 additions and 976 deletions

View File

@@ -0,0 +1,38 @@
import { mockUserProfile } from '../../utils/mock-data'
import { getMenuRoute, navigateTo } from '../../utils/router'
// TODO: 联调时替换为真实 API 获取用户信息
Page({
data: {
userInfo: mockUserProfile,
},
onShow() {
// 同步 custom-tab-bar 选中态
const tabBar = this.getTabBar?.()
if (tabBar) tabBar.setData({ active: 'my' })
// TODO: 联调时在此刷新用户信息
},
onMenuTap(e: WechatMiniprogram.TouchEvent) {
const key = e.currentTarget.dataset.key as string
const route = getMenuRoute(key)
if (route) {
navigateTo(route)
}
},
onLogout() {
wx.showModal({
title: '确认退出',
content: '确认退出当前账号吗?',
confirmColor: '#e34d59',
success(res) {
if (res.confirm) {
wx.clearStorageSync()
wx.reLaunch({ url: '/pages/login/login' })
}
},
})
},
})