Renamed node_api and node_storage by blog_api and blog_storage in related CMS_BLOG_* classes. Mainly to avoid confusion with NODE_ classes.
Merged CMS_BLOG_CONFIG with CMS_BLOG_API. In CMS_BLOG_API, prefer argument of type CMS_USER, rather than using directly user id. Added a CMS_EDITOR_CONTENT_FORMAT for now, to be the format editable by the WYSIWYG editor. Added CMS_MODULE.is_initialized: BOOLEAN to equip router, and module_api with expected preconditions. Fixed typo, especially in log output. Corrected a few routine names such as add_authors that should not be a function according to its name. Converted various function returning html content, to procedure appending html content to an output string to minimize temporary string object creation. Cosmetic: added spaces to make code easier to read, and indentation.
This commit is contained in:
@@ -32,10 +32,19 @@ feature {CMS_API} -- Module Initialization
|
||||
-- Initialize Current module with `api'.
|
||||
require
|
||||
is_enabled: is_enabled
|
||||
is_not_initialized: not is_initialized
|
||||
do
|
||||
-- Redefine to process specific module initialization.
|
||||
is_initialized := True
|
||||
ensure
|
||||
is_initialized: is_initialized
|
||||
end
|
||||
|
||||
feature -- Status
|
||||
|
||||
is_initialized: BOOLEAN
|
||||
-- Is Current module initialized?
|
||||
|
||||
feature {CMS_API} -- Access: API
|
||||
|
||||
module_api: detachable CMS_MODULE_API
|
||||
@@ -68,6 +77,8 @@ feature -- Router
|
||||
|
||||
setup_router (a_router: WSF_ROUTER; a_api: CMS_API)
|
||||
-- Setup url dispatching for Current module.
|
||||
require
|
||||
is_initialized: is_initialized
|
||||
deferred
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user