mirror of
https://github.com/HASwitchPlate/openHASP.git
synced 2025-07-24 19:56:44 +00:00
Add clearpage=all
This commit is contained in:
parent
971dbe5ff0
commit
731ffb31c3
@ -871,10 +871,15 @@ void dispatch_page(const char*, const char* page)
|
|||||||
void dispatch_clear_page(const char*, const char* page)
|
void dispatch_clear_page(const char*, const char* page)
|
||||||
{
|
{
|
||||||
uint8_t pageid;
|
uint8_t pageid;
|
||||||
if(strlen(page) > 0)
|
if(strlen(page) > 0) {
|
||||||
pageid = atoi(page);
|
if(!strcasecmp_P(page, PSTR("all"))) {
|
||||||
else
|
for(pageid = 0; pageid < HASP_NUM_PAGES; pageid++) haspPages.clear(pageid);
|
||||||
|
} else {
|
||||||
|
pageid = atoi(page);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
pageid = haspPages.get();
|
pageid = haspPages.get();
|
||||||
|
}
|
||||||
haspPages.clear(pageid);
|
haspPages.clear(pageid);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user