统一单入口 Go 工程与前端依赖目录,增加后台供应商配置、候选审核、计划预算、成交冲正、持仓复盘和站内通知。接入策略版本、Python 回测、可配置 A 股公开行情及 zap 文件轮转日志,补充迁移、契约与验证。
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
import {Stack} from "expo-router"
|
||||
import {StatusBar} from "expo-status-bar"
|
||||
import {SafeAreaProvider} from "react-native-safe-area-context"
|
||||
import {SessionProvider,useSession} from "../src/state/session"
|
||||
import {Body,Button,ErrorMessage,Screen,Title,colors} from "../src/components/ui"
|
||||
function Routes(){
|
||||
const {session,loading,restoreError,retry}=useSession()
|
||||
if(loading)return <Screen><Title>见势 · Veyra</Title><Body>正在恢复会话…</Body></Screen>
|
||||
if(restoreError)return <Screen><Title>连接暂时中断</Title><ErrorMessage message={restoreError}/><Button title="重新连接" onPress={retry}/></Screen>
|
||||
return <Stack screenOptions={{headerStyle:{backgroundColor:colors.background},headerTintColor:colors.text,headerShadowVisible:false,contentStyle:{backgroundColor:colors.background}}}>
|
||||
<Stack.Protected guard={!session}><Stack.Screen name="login" options={{headerShown:false}}/></Stack.Protected>
|
||||
<Stack.Protected guard={!!session}><Stack.Screen name="(tabs)" options={{headerShown:false}}/><Stack.Screen name="settings/accounts" options={{title:"账户管理"}}/><Stack.Screen name="fills/create" options={{title:"成交录入"}}/><Stack.Screen name="plans/create" options={{title:"计划预算"}}/><Stack.Screen name="candidates/[id]" options={{title:"候选证据"}}/><Stack.Screen name="notifications" options={{title:"提醒中心"}}/></Stack.Protected>
|
||||
</Stack>
|
||||
}
|
||||
export default function RootLayout(){return <SafeAreaProvider><SessionProvider><StatusBar style="dark"/><Routes/></SessionProvider></SafeAreaProvider>}
|
||||
Reference in New Issue
Block a user