Add waiting for next period
This commit is contained in:
parent
6f2deb38e1
commit
0b0350da0e
5 changed files with 105 additions and 37 deletions
emgauwa-lib/src/models
|
@ -79,4 +79,8 @@ impl Relay {
|
|||
pub fn is_on(&self, now: &NaiveTime) -> bool {
|
||||
self.active_schedule.is_on(now)
|
||||
}
|
||||
|
||||
pub fn get_next_time(&self, now: &NaiveTime) -> Option<NaiveTime> {
|
||||
self.active_schedule.get_next_time(now)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue