Singular (admin) account system
This commit is contained in:
@ -1,19 +1,28 @@
|
||||
// In this file, all Page components from 'src/pages` are auto-imported. Nested
|
||||
// directories are supported, and should be uppercase. Each subdirectory will be
|
||||
// prepended onto the component name.
|
||||
//
|
||||
// Examples:
|
||||
//
|
||||
// 'src/pages/HomePage/HomePage.js' -> HomePage
|
||||
// 'src/pages/Admin/BooksPage/BooksPage.js' -> AdminBooksPage
|
||||
|
||||
import { Router, Route, Set } from '@redwoodjs/router'
|
||||
|
||||
import { useAuth } from './auth'
|
||||
import AccountbarLayout from './layouts/AccountbarLayout/AccountbarLayout'
|
||||
import NavbarLayout from './layouts/NavbarLayout/NavbarLayout'
|
||||
|
||||
const Routes = () => {
|
||||
return (
|
||||
<Router>
|
||||
<Router useAuth={useAuth}>
|
||||
<Set wrap={AccountbarLayout} title="Create Admin Account">
|
||||
<Route path="/create-admin" page={SignupPage} name="signup" />
|
||||
</Set>
|
||||
|
||||
<Set wrap={AccountbarLayout} title="Login">
|
||||
<Route path="/login" page={LoginPage} name="login" />
|
||||
</Set>
|
||||
|
||||
<Set wrap={AccountbarLayout} title="Forgot Password">
|
||||
<Route path="/forgot-password" page={ForgotPasswordPage} name="forgotPassword" />
|
||||
</Set>
|
||||
|
||||
<Set wrap={AccountbarLayout} title="Reset Password">
|
||||
<Route path="/reset-password" page={ResetPasswordPage} name="resetPassword" />
|
||||
</Set>
|
||||
|
||||
<Set wrap={NavbarLayout}>
|
||||
<Route path="/" page={HomePage} name="home" />
|
||||
</Set>
|
||||
|
Reference in New Issue
Block a user