Edit profile and templates update
This commit is contained in:
@@ -25,9 +25,16 @@ where
|
||||
#[template(path = "user/profile.html")]
|
||||
pub struct UserTemplate {
|
||||
pub user: UserEntry,
|
||||
pub session_username: Option<String>,
|
||||
pub posts: Vec<PostEntry>,
|
||||
}
|
||||
|
||||
#[derive(Template)]
|
||||
#[template(path = "user/edit.html")]
|
||||
pub struct UserEditTemplate {
|
||||
pub user: UserEntry,
|
||||
}
|
||||
|
||||
#[derive(Template)]
|
||||
#[template(path = "message.html")]
|
||||
pub struct MessageTemplate {
|
||||
@@ -147,6 +154,8 @@ pub enum ErrorTemplate {
|
||||
NotFound,
|
||||
#[template(path = "error/500.html")]
|
||||
InternalServer,
|
||||
#[template(path = "error/403.html")]
|
||||
Forbidden,
|
||||
}
|
||||
|
||||
#[derive(Template)]
|
||||
|
||||
Reference in New Issue
Block a user