mirror of
https://github.com/lumapu/ahoy.git
synced 2025-05-11 07:56:39 +02:00
improved webApi, added /api/setup for compared json (only 1 XHR is needed to get all infos)
This commit is contained in:
parent
b871ed06d2
commit
833e6c4904
4 changed files with 93 additions and 106 deletions
|
@ -4,6 +4,7 @@
|
|||
#include "dbg.h"
|
||||
#include "ESPAsyncTCP.h"
|
||||
#include "ESPAsyncWebServer.h"
|
||||
#include "AsyncJson.h"
|
||||
#include "app.h"
|
||||
|
||||
|
||||
|
@ -17,14 +18,18 @@ class webApi {
|
|||
void loop(void);
|
||||
|
||||
private:
|
||||
void onSystem(AsyncWebServerRequest *request);
|
||||
void onStatistics(AsyncWebServerRequest *request);
|
||||
void onInverterList(AsyncWebServerRequest *request);
|
||||
void onMqtt(AsyncWebServerRequest *request);
|
||||
void onNtp(AsyncWebServerRequest *request);
|
||||
void onPinout(AsyncWebServerRequest *request);
|
||||
void onRadio(AsyncWebServerRequest *request);
|
||||
void onSerial(AsyncWebServerRequest *request);
|
||||
void onApi(AsyncWebServerRequest *request);
|
||||
|
||||
void getSystem(JsonObject obj);
|
||||
void getStatistics(JsonObject obj);
|
||||
void getInverterList(JsonObject obj);
|
||||
void getMqtt(JsonObject obj);
|
||||
void getNtp(JsonObject obj);
|
||||
void getPinout(JsonObject obj);
|
||||
void getRadio(JsonObject obj);
|
||||
void getSerial(JsonObject obj);
|
||||
|
||||
void getSetup(JsonObject obj);
|
||||
|
||||
AsyncWebServer *mSrv;
|
||||
app *mApp;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue