42 std::optional<json>
read(
const std::string&
id,
const json& opts)
override;
44 bool remove(
const std::string&
id,
const json& opts)
override;
45 std::vector<json>
list(
const json& opts)
override;
48 bool itemExists(
const std::string&
tableName,
const std::string&
id)
const;
Class to manage tables metadata like access rules, name, etc.
Definition sys_tables.h:22
bool setupRoutes() override
Definition sys_tables.cpp:22
std::optional< json > read(const std::string &id, const json &opts) override
Definition sys_tables_crud.cpp:240
void authWithEmailAndPassword(const Request &req, Response &res, Context &ctx) override
Definition sys_tables.cpp:465
bool hasAccess(const Request &req, Response &res, Context &ctx) override
Definition sys_tables.cpp:602
bool remove(const std::string &id, const json &opts) override
Definition sys_tables_crud.cpp:703
json create(const json &entity, const json &opts) override
Definition sys_tables_crud.cpp:22
void deleteRecord(const Request &req, Response &res, Context &ctx) override
Definition sys_tables.cpp:419
void fetchRecords(const Request &req, Response &res, Context &ctx) override
Definition sys_tables.cpp:227
void updateRecord(const Request &req, Response &res, const ContentReader &reader, Context &ctx) override
Definition sys_tables.cpp:331
std::vector< json > list(const json &opts) override
Definition sys_tables_crud.cpp:741
void fetchRecord(const Request &req, Response &res, Context &ctx) override
Definition sys_tables.cpp:161
~SysTablesUnit() override=default
void createRecord(const Request &req, Response &res, const ContentReader &reader, Context &ctx) override
Definition sys_tables.cpp:265
json update(const std::string &id, const json &entity, const json &opts) override
Definition sys_tables_crud.cpp:267
Class to model the behaviour of a table in database.
Definition tables.h:31
std::string tableName()
Definition tables.cpp:63
std::string tableId()
Definition tables.cpp:73
std::string tableType()
Definition tables.cpp:83
router.h
Definition app.h:31
nlohmann::json json
Shorten JSON namespace.
Definition crud.h:14
httplib::ContentReader ContentReader
Shorthand for httplib::ContentReader
Definition http.h:124
httplib::Response Response
Shorthand for httplib::Response
Definition http.h:121
httplib::Request Request
Shorthand for httplib::Request
Definition http.h:118