This commit is contained in:
despiegk 2025-04-19 11:32:36 +02:00
parent acca699f07
commit 6e9305d4e6

View File

@ -27,15 +27,17 @@ pub struct Payment {
pub amount: Currency, pub amount: Currency,
pub date: DateTime<Utc>, pub date: DateTime<Utc>,
pub method: String, pub method: String,
pub comment: String,
} }
impl Payment { impl Payment {
/// Create a new payment /// Create a new payment
pub fn new(amount: Currency, method: String) -> Self { pub fn new(amount: Currency, method: String, comment: String) -> Self {
Self { Self {
amount, amount,
date: Utc::now(), date: Utc::now(),
method, method,
comment,
} }
} }
} }