Append the course category to the summary

This commit is contained in:
Mylloon 2023-10-02 14:53:40 +02:00
parent be6670b02f
commit 1d9389e41b
Signed by: Anri
GPG key ID: A82D63DFF8D1317F

View file

@ -53,11 +53,11 @@ pub fn export(courses: Vec<crate::timetable::models::Course>, filename: &mut Str
event.push(Location::new(course.room)); event.push(Location::new(course.room));
// Course's name // Course's name
let mut course_name = Summary::new(course.name); let mut course_name = Summary::new(format!("{} - {}", course.category, course.name));
course_name.append(parameters!("LANGUAGE" => "fr")); course_name.append(parameters!("LANGUAGE" => "fr"));
event.push(course_name); event.push(course_name);
// Course's type // Course's category
event.push(Categories::new(course.category.to_string())); event.push(Categories::new(course.category.to_string()));
// Add the course to the calendar // Add the course to the calendar