allow to add reason for canceled event; fixes #530
This commit is contained in:
		@@ -223,16 +223,17 @@ WHERE day=?
 | 
			
		||||
                .rower;
 | 
			
		||||
            for user in rowers {
 | 
			
		||||
                if let Some(user) = User::find_by_name(db, &user.name).await {
 | 
			
		||||
                    let notes = match update.notes {
 | 
			
		||||
                        Some(n) if !n.is_empty() => n,
 | 
			
		||||
                        _ => ".",
 | 
			
		||||
                    let notes = if let Some(notes) = update.notes {
 | 
			
		||||
                        format!("Grund der Absage: {notes}")
 | 
			
		||||
                    } else {
 | 
			
		||||
                        String::from("")
 | 
			
		||||
                    };
 | 
			
		||||
 | 
			
		||||
                    Notification::create(
 | 
			
		||||
                        db,
 | 
			
		||||
                        &user,
 | 
			
		||||
                        &format!(
 | 
			
		||||
                            "Die Ausfahrt von {} am {} um {} wurde abgesagt{}",
 | 
			
		||||
                            "Die Ausfahrt von {} am {} um {} wurde abgesagt. {}",
 | 
			
		||||
                            update.cox.user.name,
 | 
			
		||||
                            update.trip.day,
 | 
			
		||||
                            update.trip.planned_starting_time,
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user