diff options
author | Harald Eilertsen <haraldei@anduin.net> | 2019-08-10 17:38:21 +0200 |
---|---|---|
committer | Harald Eilertsen <haraldei@anduin.net> | 2019-08-10 17:38:21 +0200 |
commit | d4feab5b0894464201824031fb077724fba060a0 (patch) | |
tree | af680a23f650cc8ed79fdf0afb251df6d4b338fe /src | |
parent | dcfe66e4d409a2b89b93be2ead8a7a84ab863dc0 (diff) | |
download | ramaskrik-social-d4feab5b0894464201824031fb077724fba060a0.tar.gz ramaskrik-social-d4feab5b0894464201824031fb077724fba060a0.tar.bz2 ramaskrik-social-d4feab5b0894464201824031fb077724fba060a0.zip |
Rename ScreeningRecord model to Screening
Diffstat (limited to 'src')
-rw-r--r-- | src/models/screening.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/models/screening.rs b/src/models/screening.rs index feb98cc..b513362 100644 --- a/src/models/screening.rs +++ b/src/models/screening.rs @@ -35,7 +35,7 @@ pub struct NewScreening { #[derive(Deserialize, Identifiable, PartialEq, Serialize, Queryable)] #[table_name = "screenings"] -pub struct ScreeningRecord { +pub struct Screening { pub id: i32, pub film_id: i32, pub room_id: i32, @@ -56,7 +56,7 @@ pub struct AggregatedScreening { } impl AggregatedScreening { - pub fn from_query(s: Vec<(ScreeningRecord, Option<Film>, Option<Room>)>) -> Vec<AggregatedScreening> { + pub fn from_query(s: Vec<(Screening, Option<Film>, Option<Room>)>) -> Vec<AggregatedScreening> { s.iter().map(|(s, f, r)| { AggregatedScreening { id: s.id, |