mirror of
https://github.com/nitnelave/lldap.git
synced 2023-04-12 14:25:13 +00:00
35 lines
758 B
Rust
35 lines
758 B
Rust
use yew_router::{
|
|
components::{RouterAnchor, RouterButton},
|
|
Switch,
|
|
};
|
|
|
|
#[derive(Switch, Debug, Clone)]
|
|
pub enum AppRoute {
|
|
#[to = "/login"]
|
|
Login,
|
|
#[to = "/reset-password/step1"]
|
|
StartResetPassword,
|
|
#[to = "/reset-password/step2/{token}"]
|
|
FinishResetPassword(String),
|
|
#[to = "/users/create"]
|
|
CreateUser,
|
|
#[to = "/users"]
|
|
ListUsers,
|
|
#[to = "/user/{user_id}/password"]
|
|
ChangePassword(String),
|
|
#[to = "/user/{user_id}"]
|
|
UserDetails(String),
|
|
#[to = "/groups/create"]
|
|
CreateGroup,
|
|
#[to = "/groups"]
|
|
ListGroups,
|
|
#[to = "/group/{group_id}"]
|
|
GroupDetails(i64),
|
|
#[to = "/"]
|
|
Index,
|
|
}
|
|
|
|
pub type Link = RouterAnchor<AppRoute>;
|
|
|
|
pub type NavButton = RouterButton<AppRoute>;
|