add button with name (wo number)

This commit is contained in:
Dmitry Borisenko
2020-07-28 00:52:49 +02:00
parent 110fc167a1
commit 2e66c93814
7 changed files with 158 additions and 79 deletions

View File

@@ -13,17 +13,17 @@ bool loadWidget(const String& filename, String& buf) {
return res;
}
void createWidget(String widget, String page, String pageNumber, String filename, String topic) {
void createWidget(String descr, String page, String order, String filename, String topic) {
String buf = "{}";
if (!loadWidget(filename, buf)) {
return;
}
widget.replace("#", " ");
descr.replace("#", " ");
page.replace("#", " ");
jsonWriteStr(buf, "page", page);
jsonWriteStr(buf, "order", pageNumber);
jsonWriteStr(buf, "descr", widget);
jsonWriteStr(buf, "order", order);
jsonWriteStr(buf, "descr", descr);
jsonWriteStr(buf, "topic", prex + "/" + topic);
#ifdef LAYOUT_IN_RAM