Compare commits

..

2 Commits

Author SHA1 Message Date
9c277df2b7 Merge pull request 'dont log pdf content' (#293) from dont-log-pdf-content into staging
Some checks failed
CI/CD Pipeline / deploy-staging (push) Blocked by required conditions
CI/CD Pipeline / deploy-main (push) Blocked by required conditions
CI/CD Pipeline / test (push) Has been cancelled
Reviewed-on: #293
2024-03-20 23:49:21 +01:00
591f9ea245 dont log pdf content
Some checks failed
CI/CD Pipeline / test (push) Failing after 1m40s
CI/CD Pipeline / deploy-staging (push) Has been skipped
CI/CD Pipeline / deploy-main (push) Has been skipped
2024-03-20 23:48:42 +01:00

View File

@ -26,7 +26,7 @@ const REGULAR: i32 = 22000;
const UNTERSTUETZEND: i32 = 2500; const UNTERSTUETZEND: i32 = 2500;
const FOERDERND: i32 = 8500; const FOERDERND: i32 = 8500;
#[derive(FromRow, Debug, Serialize, Deserialize, Clone)] #[derive(FromRow, Serialize, Deserialize, Clone)]
pub struct User { pub struct User {
pub id: i64, pub id: i64,
pub name: String, pub name: String,
@ -47,6 +47,29 @@ pub struct User {
pub membership_pdf: Option<Vec<u8>>, pub membership_pdf: Option<Vec<u8>>,
} }
impl fmt::Debug for User {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
f.debug_struct("User")
.field("id", &self.id)
.field("name", &self.name)
.field("dob", &self.dob)
.field("weight", &self.weight)
.field("sex", &self.sex)
.field("deleted", &self.deleted)
.field("last_access", &self.last_access)
.field("member_since_date", &self.member_since_date)
.field("birthdate", &self.birthdate)
.field("mail", &self.mail)
.field("nickname", &self.nickname)
.field("notes", &self.notes)
.field("phone", &self.phone)
.field("address", &self.address)
.field("family_id", &self.family_id)
// Note that membership_pdf is intentionally omitted here
.finish()
}
}
#[derive(Debug, Serialize, Deserialize)] #[derive(Debug, Serialize, Deserialize)]
pub struct UserWithRoles { pub struct UserWithRoles {
#[serde(flatten)] #[serde(flatten)]