Public Access
Rules can leave a manual pick alone, Clock is an editable page, fix HA attributes
- Rules: "also over a page chosen by hand" (on by default); off, a rule waits until the manual pick ends. Schedule store version 3, version 2 records are read with the option on. - The Clock page is stored at boot from the built-in one and can be edited; Reset (deleting it) brings back the original. - Home Assistant attributes were never found: ArduinoJson 7.4 takes a char array key as a literal of its full array length. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
ab001e5d18
commit
51b8d87e86
37 files changed
+134
-42
No files matched your search
+9
-1
@@ -335,11 +335,19 @@ const char *appSavePage(const char *name, const DynamicPage &page)
|
||||
|
||||
const char *appDeletePage(const char *name)
|
||||
{
|
||||
if (scheduleUses(page_schedule, name))
|
||||
// A stored copy of a built-in page: deleting it resets the page, which stays
|
||||
bool resets = builtinPageName(name) != nullptr;
|
||||
if (!resets && scheduleUses(page_schedule, name))
|
||||
return USED_BY_SCHEDULE;
|
||||
const char *error = deletePage(name);
|
||||
if (error)
|
||||
return error;
|
||||
if (resets)
|
||||
{
|
||||
if (sameName(shown, name))
|
||||
reloadPage();
|
||||
return nullptr;
|
||||
}
|
||||
if (sameName(settings.page, name))
|
||||
setChosen(DEFAULT_PAGE);
|
||||
return nullptr;
|
||||
|
||||
Reference in new issue
Block a user