mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 20:42:30 +08:00
add front end code (#27)
This commit is contained in:
12
web/src/wrappers/auth.tsx
Normal file
12
web/src/wrappers/auth.tsx
Normal file
@ -0,0 +1,12 @@
|
||||
import { Navigate, Outlet } from 'umi'
|
||||
|
||||
export default (props) => {
|
||||
// const { isLogin } = useAuth();
|
||||
console.log(props)
|
||||
const isLogin = false
|
||||
if (isLogin) {
|
||||
return <Outlet />;
|
||||
} else {
|
||||
return <Navigate to="/login" />;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user