diff --git a/SConstruct b/SConstruct index a25a6b1..7888e8d 100644 --- a/SConstruct +++ b/SConstruct @@ -226,6 +226,7 @@ if env_base["databases"]: modfol = env_base["module_folders"].split(";") modfol.append("modules") +modfol.append("web_modules") #temporarily, these should be handled in a different pass modfol.append("backends") module_folders = list() diff --git a/core/http/web_root.cpp b/core/http/web_root.cpp index 523a7e6..f8f9b64 100644 --- a/core/http/web_root.cpp +++ b/core/http/web_root.cpp @@ -35,14 +35,14 @@ void WebRoot::setup_middleware() { // --- UserSessionSetupMiddleware --- // This one looks up users based on sessions - // (#include "modules/users/user_controller.h") + // (#include "web_modules/users/user_controller.h") // _middlewares.push_back(Ref(new UserSessionSetupMiddleware())); // --- RBACUserSessionSetupMiddleware / RBACDefaultUserSessionSetupMiddleware --- // Same as the previous, but if you want the RBAC system to work use one of these // UserSessionSetupMiddleware is not needed if you need these - // (#include "modules/rbac_users/rbac_user_controller.h") + // (#include "web_modules/rbac_users/rbac_user_controller.h") // _middlewares.push_back(Ref(new RBACUserSessionSetupMiddleware())); // _middlewares.push_back(Ref(new RBACDefaultUserSessionSetupMiddleware())); diff --git a/modules/.gitkeep b/modules/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/modules/admin_panel/SCsub b/web_modules/admin_panel/SCsub similarity index 100% rename from modules/admin_panel/SCsub rename to web_modules/admin_panel/SCsub diff --git a/modules/admin_panel/admin_node.cpp b/web_modules/admin_panel/admin_node.cpp similarity index 100% rename from modules/admin_panel/admin_node.cpp rename to web_modules/admin_panel/admin_node.cpp diff --git a/modules/admin_panel/admin_node.h b/web_modules/admin_panel/admin_node.h similarity index 100% rename from modules/admin_panel/admin_node.h rename to web_modules/admin_panel/admin_node.h diff --git a/modules/admin_panel/admin_panel.cpp b/web_modules/admin_panel/admin_panel.cpp similarity index 100% rename from modules/admin_panel/admin_panel.cpp rename to web_modules/admin_panel/admin_panel.cpp diff --git a/modules/admin_panel/admin_panel.h b/web_modules/admin_panel/admin_panel.h similarity index 100% rename from modules/admin_panel/admin_panel.h rename to web_modules/admin_panel/admin_panel.h diff --git a/modules/admin_panel/detect.py b/web_modules/admin_panel/detect.py similarity index 100% rename from modules/admin_panel/detect.py rename to web_modules/admin_panel/detect.py diff --git a/modules/folder_pages/SCsub b/web_modules/folder_pages/SCsub similarity index 100% rename from modules/folder_pages/SCsub rename to web_modules/folder_pages/SCsub diff --git a/modules/folder_pages/detect.py b/web_modules/folder_pages/detect.py similarity index 100% rename from modules/folder_pages/detect.py rename to web_modules/folder_pages/detect.py diff --git a/modules/folder_pages/static_folder_page.cpp b/web_modules/folder_pages/static_folder_page.cpp similarity index 100% rename from modules/folder_pages/static_folder_page.cpp rename to web_modules/folder_pages/static_folder_page.cpp diff --git a/modules/folder_pages/static_folder_page.h b/web_modules/folder_pages/static_folder_page.h similarity index 100% rename from modules/folder_pages/static_folder_page.h rename to web_modules/folder_pages/static_folder_page.h diff --git a/modules/list_page/SCsub b/web_modules/list_page/SCsub similarity index 100% rename from modules/list_page/SCsub rename to web_modules/list_page/SCsub diff --git a/modules/list_page/detect.py b/web_modules/list_page/detect.py similarity index 100% rename from modules/list_page/detect.py rename to web_modules/list_page/detect.py diff --git a/modules/list_page/list_page.cpp b/web_modules/list_page/list_page.cpp similarity index 100% rename from modules/list_page/list_page.cpp rename to web_modules/list_page/list_page.cpp diff --git a/modules/list_page/list_page.h b/web_modules/list_page/list_page.h similarity index 100% rename from modules/list_page/list_page.h rename to web_modules/list_page/list_page.h diff --git a/modules/message_page/SCsub b/web_modules/message_page/SCsub similarity index 100% rename from modules/message_page/SCsub rename to web_modules/message_page/SCsub diff --git a/modules/message_page/detect.py b/web_modules/message_page/detect.py similarity index 100% rename from modules/message_page/detect.py rename to web_modules/message_page/detect.py diff --git a/modules/message_page/message_page.cpp b/web_modules/message_page/message_page.cpp similarity index 100% rename from modules/message_page/message_page.cpp rename to web_modules/message_page/message_page.cpp diff --git a/modules/message_page/message_page.h b/web_modules/message_page/message_page.h similarity index 100% rename from modules/message_page/message_page.h rename to web_modules/message_page/message_page.h diff --git a/modules/paged_article/SCsub b/web_modules/paged_article/SCsub similarity index 100% rename from modules/paged_article/SCsub rename to web_modules/paged_article/SCsub diff --git a/modules/paged_article/detect.py b/web_modules/paged_article/detect.py similarity index 100% rename from modules/paged_article/detect.py rename to web_modules/paged_article/detect.py diff --git a/modules/paged_article/paged_article.cpp b/web_modules/paged_article/paged_article.cpp similarity index 100% rename from modules/paged_article/paged_article.cpp rename to web_modules/paged_article/paged_article.cpp diff --git a/modules/paged_article/paged_article.h b/web_modules/paged_article/paged_article.h similarity index 100% rename from modules/paged_article/paged_article.h rename to web_modules/paged_article/paged_article.h diff --git a/modules/paged_article/paged_articles.cpp b/web_modules/paged_article/paged_articles.cpp similarity index 100% rename from modules/paged_article/paged_articles.cpp rename to web_modules/paged_article/paged_articles.cpp diff --git a/modules/paged_article/paged_articles.h b/web_modules/paged_article/paged_articles.h similarity index 100% rename from modules/paged_article/paged_articles.h rename to web_modules/paged_article/paged_articles.h diff --git a/modules/paged_article/paged_articles_md_index.cpp b/web_modules/paged_article/paged_articles_md_index.cpp similarity index 100% rename from modules/paged_article/paged_articles_md_index.cpp rename to web_modules/paged_article/paged_articles_md_index.cpp diff --git a/modules/paged_article/paged_articles_md_index.h b/web_modules/paged_article/paged_articles_md_index.h similarity index 86% rename from modules/paged_article/paged_articles_md_index.h rename to web_modules/paged_article/paged_articles_md_index.h index a5f2351..ebde828 100644 --- a/modules/paged_article/paged_articles_md_index.h +++ b/web_modules/paged_article/paged_articles_md_index.h @@ -5,8 +5,8 @@ #include "core/http/web_node.h" -#include "modules/list_page/list_page.h" -#include "modules/paged_article/paged_article.h" +#include "web_modules/list_page/list_page.h" +#include "web_modules/paged_article/paged_article.h" // Inherit from PagedArticles and override generate_index_page -> load and process md files in the set folder // SHould probably be called something else. PagedArticlesMDIndex ? diff --git a/modules/rbac/SCsub b/web_modules/rbac/SCsub similarity index 100% rename from modules/rbac/SCsub rename to web_modules/rbac/SCsub diff --git a/modules/rbac/detect.py b/web_modules/rbac/detect.py similarity index 100% rename from modules/rbac/detect.py rename to web_modules/rbac/detect.py diff --git a/modules/rbac/rbac_controller.cpp b/web_modules/rbac/rbac_controller.cpp similarity index 99% rename from modules/rbac/rbac_controller.cpp rename to web_modules/rbac/rbac_controller.cpp index 9f3e2d4..9107afa 100644 --- a/modules/rbac/rbac_controller.cpp +++ b/web_modules/rbac/rbac_controller.cpp @@ -9,7 +9,7 @@ #include "core/http/request.h" #include "core/http/session_manager.h" #include "rbac_default_permissions.h" -#include "modules/users/user.h" +#include "web_modules/users/user.h" #include "core/database/database.h" #include "core/database/database_manager.h" diff --git a/modules/rbac/rbac_controller.h b/web_modules/rbac/rbac_controller.h similarity index 98% rename from modules/rbac/rbac_controller.h rename to web_modules/rbac/rbac_controller.h index 947cc3d..b155cfe 100644 --- a/modules/rbac/rbac_controller.h +++ b/web_modules/rbac/rbac_controller.h @@ -3,7 +3,7 @@ #include -#include "modules/admin_panel/admin_node.h" +#include "web_modules/admin_panel/admin_node.h" #include "core/containers/vector.h" #include "core/string.h" diff --git a/modules/rbac/rbac_default_permissions.h b/web_modules/rbac/rbac_default_permissions.h similarity index 100% rename from modules/rbac/rbac_default_permissions.h rename to web_modules/rbac/rbac_default_permissions.h diff --git a/modules/rbac/rbac_permission.cpp b/web_modules/rbac/rbac_permission.cpp similarity index 100% rename from modules/rbac/rbac_permission.cpp rename to web_modules/rbac/rbac_permission.cpp diff --git a/modules/rbac/rbac_permission.h b/web_modules/rbac/rbac_permission.h similarity index 100% rename from modules/rbac/rbac_permission.h rename to web_modules/rbac/rbac_permission.h diff --git a/modules/rbac/rbac_rank.cpp b/web_modules/rbac/rbac_rank.cpp similarity index 100% rename from modules/rbac/rbac_rank.cpp rename to web_modules/rbac/rbac_rank.cpp diff --git a/modules/rbac/rbac_rank.h b/web_modules/rbac/rbac_rank.h similarity index 100% rename from modules/rbac/rbac_rank.h rename to web_modules/rbac/rbac_rank.h diff --git a/modules/rbac_users/SCsub b/web_modules/rbac_users/SCsub similarity index 100% rename from modules/rbac_users/SCsub rename to web_modules/rbac_users/SCsub diff --git a/modules/rbac_users/detect.py b/web_modules/rbac_users/detect.py similarity index 100% rename from modules/rbac_users/detect.py rename to web_modules/rbac_users/detect.py diff --git a/modules/rbac_users/rbac_user.cpp b/web_modules/rbac_users/rbac_user.cpp similarity index 100% rename from modules/rbac_users/rbac_user.cpp rename to web_modules/rbac_users/rbac_user.cpp diff --git a/modules/rbac_users/rbac_user.h b/web_modules/rbac_users/rbac_user.h similarity index 85% rename from modules/rbac_users/rbac_user.h rename to web_modules/rbac_users/rbac_user.h index 203b943..f86acf1 100644 --- a/modules/rbac_users/rbac_user.h +++ b/web_modules/rbac_users/rbac_user.h @@ -3,8 +3,8 @@ #include "core/string.h" -#include "modules/users/user.h" -#include "modules/rbac/rbac_rank.h" +#include "web_modules/users/user.h" +#include "web_modules/rbac/rbac_rank.h" class Request; class FormValidator; diff --git a/modules/rbac_users/rbac_user_controller.cpp b/web_modules/rbac_users/rbac_user_controller.cpp similarity index 97% rename from modules/rbac_users/rbac_user_controller.cpp rename to web_modules/rbac_users/rbac_user_controller.cpp index b06e506..9611b59 100644 --- a/modules/rbac_users/rbac_user_controller.cpp +++ b/web_modules/rbac_users/rbac_user_controller.cpp @@ -3,8 +3,8 @@ #include "core/http/http_session.h" #include "core/http/request.h" -#include "modules/rbac/rbac_controller.h" -#include "modules/rbac/rbac_default_permissions.h" +#include "web_modules/rbac/rbac_controller.h" +#include "web_modules/rbac/rbac_default_permissions.h" #include "rbac_user.h" Ref RBACUserController::db_get_user(const int id) { diff --git a/modules/rbac_users/rbac_user_controller.h b/web_modules/rbac_users/rbac_user_controller.h similarity index 96% rename from modules/rbac_users/rbac_user_controller.h rename to web_modules/rbac_users/rbac_user_controller.h index 428eb15..044ba17 100644 --- a/modules/rbac_users/rbac_user_controller.h +++ b/web_modules/rbac_users/rbac_user_controller.h @@ -1,7 +1,7 @@ #ifndef RBAC_USER_CONTROLLER_H #define RBAC_USER_CONTROLLER_H -#include "modules/users/user_controller.h" +#include "web_modules/users/user_controller.h" #include "core/http/middleware.h" diff --git a/modules/static_pages/SCsub b/web_modules/static_pages/SCsub similarity index 100% rename from modules/static_pages/SCsub rename to web_modules/static_pages/SCsub diff --git a/modules/static_pages/detect.py b/web_modules/static_pages/detect.py similarity index 100% rename from modules/static_pages/detect.py rename to web_modules/static_pages/detect.py diff --git a/modules/static_pages/static_page.cpp b/web_modules/static_pages/static_page.cpp similarity index 100% rename from modules/static_pages/static_page.cpp rename to web_modules/static_pages/static_page.cpp diff --git a/modules/static_pages/static_page.h b/web_modules/static_pages/static_page.h similarity index 100% rename from modules/static_pages/static_page.h rename to web_modules/static_pages/static_page.h diff --git a/modules/users/SCsub b/web_modules/users/SCsub similarity index 100% rename from modules/users/SCsub rename to web_modules/users/SCsub diff --git a/modules/users/detect.py b/web_modules/users/detect.py similarity index 100% rename from modules/users/detect.py rename to web_modules/users/detect.py diff --git a/modules/users/user.cpp b/web_modules/users/user.cpp similarity index 100% rename from modules/users/user.cpp rename to web_modules/users/user.cpp diff --git a/modules/users/user.h b/web_modules/users/user.h similarity index 100% rename from modules/users/user.h rename to web_modules/users/user.h diff --git a/modules/users/user_controller.cpp b/web_modules/users/user_controller.cpp similarity index 100% rename from modules/users/user_controller.cpp rename to web_modules/users/user_controller.cpp diff --git a/modules/users/user_controller.h b/web_modules/users/user_controller.h similarity index 100% rename from modules/users/user_controller.h rename to web_modules/users/user_controller.h