fhem / Timer

FHEM - Module
https://fhem.de/
1 stars 3 forks source link

Am 30.12.2021 lässt sich kein Timer für den 31.12.2021 09:00:00 Uhr anlegen. #10

Closed elektron-bbs closed 8 months ago

elektron-bbs commented 2 years ago

Diese Zeile verhindert das:

if ((time() - fhemTimeLocal($sec, $min, $hour, $mday, $month - 1, $year)) > 0) { return 'ERROR: The time is in the past. Please set a time in the future!'; }

Damit geht es:

if ((time() - fhemTimeLocal($sec, $min, $hour, $mday, $month, $year)) > 0) { return 'ERROR: The time is in the past. Please set a time in the future!'; }

Das die Monate mit 0 im Januar anfangen zu zählen, wird ja schon einige Zeilen darüber berücksichtigt:

if ($i == 2) { $month = $selected_buttons[$i]-1; }

Die darauf folgende Zeile ist mir auch unklar, was soll sie bewirken?

if ((fhemTimeLocal($sec, $min, $hour, $mday, $month, $year) - time()) < 60) { return 'ERROR: The next switching point is too small!'; }

MfG Guten Rutsch ins neue Jahr :-)

HomeAutoUser commented 8 months ago

@elektron-bbs das Problem sollte ja in der neuen Version behoben sein, oder?

elektron-bbs commented 8 months ago

Sollte eigentlich so sein.