Rename active_schedule to override_schedule and add EmgauwaNow

This commit is contained in:
Tobias Reisinger 2024-05-26 22:48:22 +02:00
commit 473832f58a
Signed by: serguzim
GPG key ID: 13AD60C237A28DFE
10 changed files with 217 additions and 34 deletions

View file

@ -1,8 +1,10 @@
mod emgauwa_now;
mod emgauwa_uid;
mod request;
mod schedule_uid;
use actix::Message;
pub use emgauwa_now::EmgauwaNow;
pub use emgauwa_uid::EmgauwaUid;
pub use request::*;
pub use schedule_uid::ScheduleUid;
@ -14,7 +16,13 @@ use crate::models::{Controller, Relay};
pub type Weekday = i64;
pub type RelayStates = Vec<Option<bool>>;
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct RelayState {
pub active_schedule: DbSchedule,
pub is_on: Option<bool>
}
pub type RelayStates = Vec<RelayState>;
#[derive(Debug, Serialize, Deserialize, Message)]
#[rtype(result = "Result<(), EmgauwaError>")]