2022-02-05 02:45:53 +01:00
|
|
|
#ifndef PAGED_ARTICLES_H
|
|
|
|
#define PAGED_ARTICLES_H
|
|
|
|
|
|
|
|
#include "core/containers/vector.h"
|
|
|
|
#include "core/string.h"
|
|
|
|
|
|
|
|
#include "core/file_cache.h"
|
2022-02-05 15:30:48 +01:00
|
|
|
#include "web/http/web_node.h"
|
2022-02-05 02:45:53 +01:00
|
|
|
|
2022-02-05 15:30:48 +01:00
|
|
|
#include "web/http/request.h"
|
2022-02-05 02:45:53 +01:00
|
|
|
|
|
|
|
//todo pagination
|
|
|
|
|
|
|
|
class PagedArticles : public WebNode {
|
|
|
|
RCPP_OBJECT(PagedArticles, WebNode);
|
|
|
|
|
|
|
|
public:
|
|
|
|
void _handle_request_main(Request *request);
|
|
|
|
|
|
|
|
void load();
|
2022-02-05 13:27:33 +01:00
|
|
|
void generate_index_page();
|
2022-02-05 02:45:53 +01:00
|
|
|
|
|
|
|
void _notification(const int what);
|
|
|
|
|
|
|
|
PagedArticles();
|
|
|
|
~PagedArticles();
|
|
|
|
|
|
|
|
String folder;
|
|
|
|
|
|
|
|
protected:
|
2022-02-05 13:27:33 +01:00
|
|
|
String index_page;
|
2022-02-05 02:45:53 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|