Add ability to schedule when the kiln starts #59
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
@jbruce12000 I implemented this PR in cooperation with my friend @marktilles who had this idea for the delayed start of the kiln and has been in contact with you previously. What follows is the description of this implementation.
This PR adds the possibility to use a datepicker in the modal after clicking the start button to schedule when the kiln should start running by itself automatically followed by clicking the newly created appropriate button.
The timer is implemented in the backend and the start is triggered there so closing or refreshing the browser does not stop it.
When the kiln start gets scheduled, the frontend state changes so that the glowing timer icon is now shown instead of the
previously unused door icon (hope that's ok). The state is also displayed as SCHEDULED and above it the info states when it's due to start: "Start at: ..."
Now this state is shown whenever the page is opened in the browser until the kiln starts running. To cancel the scheduled run, one just needs to click the "Stop" button in the same way as when stopping the running kiln.
Would appreciate if you and anyone else could review and test this. Any feedback is welcome and I can make changes as needed.