Publishing
The publishing module sets up a published and unpublished version of all the content types it applies to. Â Non-editor users see the published version. Â By default editor users see the unpublished version, but can switch to the published version if they wish. Â The module sets up the button to publish the unpublished version, which simply copies the unpublished version to the published version.
Setting up the publishing module
The publishing module requires adding the IsPubVersion, Published (date published), PubFrom and PubTo fields to the ContentItems table. This can be done by running the script at /Areas/Lynicon.Base/Admin/SQL/PublishingInit.sql.
Configuring the publishing module
You can set PublishingType to a function from Type to a bool, to return true if the content type should have publishing functionality.
Ensuring a content type can be published
A content type can be published if:
- Its container type implements IPublishable
- When input to the PublishingType function, the content type returns true
Enabling pre-publish validation for a content type
If a content type implements IPublishIssues, it can run validation checks which must succeed before the system will allow it to be published. Â This is a good point to do validation as content should be able to exist in a partially complete or inconsistent state up to the point where it is publically visible.