From 356d001101cfec9921f71235689b4688838294b3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sn=C3=ADda=C5=88ov=C3=BD=20Mistr?= Date: Tue, 5 Mar 2024 17:48:25 +0100 Subject: [PATCH] =?UTF-8?q?Opravy=20bug=C5=AF=20nebo=20n=C4=9Bco?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/web/actions/create_post.rs | 2 ++ src/web/actions/user_post_actions.rs | 1 + src/web/login.rs | 1 - static/js/autofill.js | 4 ++-- templates/login.html | 2 +- templates/macros/post-actions.html | 2 +- templates/macros/post-form.html | 4 ++-- templates/staff/accounts.html | 2 +- templates/staff/boards.html | 6 +----- 9 files changed, 11 insertions(+), 13 deletions(-) diff --git a/src/web/actions/create_post.rs b/src/web/actions/create_post.rs index 35881bb..e315a94 100644 --- a/src/web/actions/create_post.rs +++ b/src/web/actions/create_post.rs @@ -25,12 +25,14 @@ use crate::{ pub struct PostForm { pub board: Text, pub thread: Option>, + #[multipart(rename = "post_name")] pub name: Text, pub email: Text, pub content: Text, #[multipart(rename = "files[]")] pub files: Vec, pub spoiler_files: Option>, + #[multipart(rename = "post_password")] pub password: Text, pub captcha_id: Option>, pub captcha_solution: Option>, diff --git a/src/web/actions/user_post_actions.rs b/src/web/actions/user_post_actions.rs index 57360be..6c9f580 100644 --- a/src/web/actions/user_post_actions.rs +++ b/src/web/actions/user_post_actions.rs @@ -23,6 +23,7 @@ pub struct UserPostActionsForm { pub remove_posts: Option, pub remove_files: Option, pub toggle_spoiler: Option, + #[serde(rename = "post_password")] pub password: String, } diff --git a/src/web/login.rs b/src/web/login.rs index d650fbb..f717a7e 100755 --- a/src/web/login.rs +++ b/src/web/login.rs @@ -32,7 +32,6 @@ pub async fn login_get(ctx: Data, req: HttpRequest) -> Result Heslo - + diff --git a/templates/macros/post-actions.html b/templates/macros/post-actions.html index 3292c8f..5da477f 100644 --- a/templates/macros/post-actions.html +++ b/templates/macros/post-actions.html @@ -29,7 +29,7 @@ Heslo - + diff --git a/templates/macros/post-form.html b/templates/macros/post-form.html index 14c9be9..13d5f6e 100644 --- a/templates/macros/post-form.html +++ b/templates/macros/post-form.html @@ -18,7 +18,7 @@ Jméno - + @@ -91,7 +91,7 @@ Heslo (na odstranění) - + {% if reply %} diff --git a/templates/staff/accounts.html b/templates/staff/accounts.html index bb6eca2..f898bb6 100755 --- a/templates/staff/accounts.html +++ b/templates/staff/accounts.html @@ -45,7 +45,7 @@ Heslo - + diff --git a/templates/staff/boards.html b/templates/staff/boards.html index 50c5445..57f4b76 100755 --- a/templates/staff/boards.html +++ b/templates/staff/boards.html @@ -35,11 +35,7 @@ {% if tcx.perms.owner() %} - {% endif %} - -
- - {% if tcx.perms.owner() || tcx.perms.board_config() %} +
Jméno