继续完善购物逻辑闭环,consumer模块完成度75%

This commit is contained in:
2026-01-26 17:15:51 +08:00
parent be90f1213b
commit f2f208f258
21 changed files with 2516 additions and 217 deletions

View File

@@ -1,4 +1,4 @@
import supa, { supaReady } from '@/components/supadb/aksupainstance.uts'
import { supabase as supa, ensureSupabaseReady } from '@/components/supadb/aksupainstance.uts'
import type { UserProfile, UserStats } from '@/pages/user/types.uts'
import type { DeviceInfo } from '@/pages/sense/types.uts'
import { SenseDataService, type DeviceParams } from '@/pages/sense/senseDataService.uts'
@@ -50,7 +50,7 @@ export const setUserProfile = (profile : UserProfile) => {
// 获取当前用户信息(含补全 profile
export async function getCurrentUser() : Promise<UserProfile | null> {
try {
await supaReady
await ensureSupabaseReady()
} catch (_) {}
const sessionInfo = supa.getSession()