Refactored CMS_MODULE.router (..): WSF_ROUTER design,
to create only one router object of type CMS_ROUTER.
Added optional CMS_NODE.link: CMS_LOCAL_LINK
Reviewed permissions related to node module.
Refactor and add CMS_STORAGE_SQL(_BUILDER) abstractions
for implementation relying only on SQL statements.
Factorized sql builder initialization (to work for sqlite and mysql storage builders).
Added CMS_RESPONSE.formatted_string (a_text: READABLE_STRING_GENERAL; args: TUPLE): STRING_32
Added function "translation", but not implemented for now.
Updated indexing notes and comments.
Code cleaning.
Updated CMS_NODE_API, with status, not_published, published and trashed.
Updated Form response to use permission scopes.
Updated sqlquery to retrieve user author.
Added logger info in cms_response
Updated CMS_NODE with a new status attribute.
Updated table nodes to support trashing (or soft deletes) of node using the new status field
Updated Sqlite builder to test different scenarios for users and roles.
Updated NODE_FORM_RESPONSE.edit_form feature to add a delete operation
if there is a node ie node id >0 and the current user has delete permission on it.
Updated NODE_HANDLER.do_post to handle the operation "DELETE".
Updated queries to retrieve nodes filter by no logical deleted rows (ie. status is trashed).
Signed-off-by: jvelilla <javier.hector@gmail.com>
Renamed "layout" lib as "app_env" with APPLICATION_ENVIRONMENT interface.
applied changed to callers.
Added CMS_THEME.has_region (a_name): BOOLEAN to know if a region is declared in a defined theme.
Added CMS_NODE_TYPE as descendant of CMS_CONTENT_TYPE,
in case we have content which is not a node in the future.
(probably useless, but for now, this extra abstraction is harmful)
Moved all node related code under node module cluster.
Applied comments from Javier Velilla.
Code cleaning.
but this is an example about on to add a new content type, and support it.
Fixed new node form workflow.
The current state is not final, it requires many changes, but for now, it implements a node editing workflow.
Added support for custom value stored in CMS_STORAGE.
Added optional css classes addition to CMS_BLOCK output.
Refactored storage, to manage node from node module code only (or mostly).
TODO: improved view for a cms node, for now hardcoded.
Implemented role and permission storage.
Introduced the CMS_PARTIAL_NODE and CMS_PARTIAL_USER.
Added support for node storage extension
- storage of data specific to each node content type,
- in addition to the core CMS_NODE)
- For now, only implemented for SQL storage.
Note: in current version, CMS_PAGE support is hard coded in the core,
(as opposed to be only supported by the node module.)
Commented/removed for now, the Web API code to update node summary, title, via REST request.
Protected cms service from registering many time the same module type.
Moved library/persistence/implementation/* under library/persistence/.
Moved site/www/themes to site/themes
For SQLite storage driver, auto create sqlite db file using associated sql script (to be completed).
Added code in demo module to reuse storage for module purpose.
Always call sql_post_execution in sql_query and sql_change, and not anymore by the callers.
Removed is_web and is_html from {CMS_SETUP}, it was not used.
Reused SHARED_*_ENCODER in CMS_ENCODERS
Added CMS_API.logger rather than using directly the SHARED_LOGGER.log ...
Centralize the implementation of current_user in CMS_REQUEST_UTIL
Removed the inheritance on WSF_FILTER for node handlers, since it is useless and unused.
Added CMS_NODE_API and CMS_USER_API
Prefix html id for block generated html items with "block-", to avoid css name conflict on "main", "content" or similar.
Code cleaning
Simplified schema to focus on user and node.
Now possible to have sqlite via ODBC and/or mysql support, and select using configuration file.
Updated demo example.
Reviewed configuration related feature.
Renamed JSON_CONFIGURATION as APPLICATION_JSON_CONFIGURATION_HELPER to avoid confusion.
Updated CMS_DEFAULT_SETUP to use configuration from cms configuration library.
Added {CMS_API}.module_configuration (a_module_name: READABLE_STRING_GENERAL; a_name: detachable READABLE_STRING_GENERAL): detachable CONFIG_READER to help getting access to configuration of a module (for now, only json and ini are supported, but in the future, this could support database layer directly)
Added CMS_HOOK_BLOCK_HELPER to reuse the template_block (..): ... function.
Cosmetic
Removed CMS_SETUP.smtp_server since for now, there is no need for such general setting.
Add header line "X-ServerEWF-App: CMS" as a simple way to know if request is processed by the CMS.
Renamed CMS_RESPONSE.call_..hook with invoke_..._hook
Renamed CMS_HOOK_VALUE_ALTER as CMS_HOOK_VALUE_TABLE_ALTER
Renamed CMS_HOOK_MENU_ALTER as CMS_HOOK_MENU_SYSTEM_ALTER
Added new CMS_HOOK_MENU_ALTER that acts on CMS_MENU object.
Cosmetic, comments.
Changed CMS_HOOK_BLOCK.get_block_view to accept only attached string for `a_block_id'.
Keep simple name in CMS_MENU_SYSTEM.
Module that implements a CMS_HOOK need now to redefine CMS_MODULE.register_hooks .
Added simple code for NODE_MODULE, in order to see something.
Added CMS_URL_UTILITIES that should be used to compute url for cms path such as "/foo/bar".
Implemented get_active in CMS_RESPONSE to update the "is_active" on each link.
Added NOT_IMPLEMENTED_ERROR_CMS_RESPONSE.
Implemented a few hooks in DEMO module, for testing.
Updated smarty template related code.
Reversed the design, and break dependency CMS_SETUP => CMS_API .
Now CMS_API has attribute setup: CMS_SETUP .
Moved error_handler from CMS_SETUP to CMS_API.
The instance of CMS_SETUP is used when instanciating modules.
The instance of CMS_API is used when instanciating CMS_REPONSE and Handlers/Filters.
The instance of CMS_API is passed as argument to build the CMS_MODULE.router and filter.
Prepare the module before creating the service.
Remove the possibility to add module after the creation of the service.
Renamed CMS_MODULE_CONFIGURATOR as CMS_MODULE_COLLECTION.