Details
-
Task
-
Status: Closed
-
Normal
-
Resolution: Fixed
-
None
-
None
-
2
-
Quasar
-
Puma Sprint 231
Description
ExperiencePageComponentResource
The ExperiencePageComponentResource its methods will have something like RolesAllowed for perhaps 'editor' or 'author' or which role we come up with that an experience page CM user has to have. When the cms user is allowed to modify the experience page, the changes will be written directly to the unpublished variant! The reason for this is that if we'd first obtain editable instance, write to the draft, and then commit the editable instance, then all the Experience Page components will have different UUIDs since during copy from draft -> preview the hst:page would be replaced. Therefor, changes must be directly written to the unpublished variant. Since the CMS users cannot write to this variant, the actual writing must be delegated to a service. This service can impersonate to a workflow session and write the changes with this session to the unpublished variant. After this, we need to also change the state of the document such that it becomes publishable. Most likely this state change we want to do by invoking normal document workflow (note we most likely have to add support for this in the document workflow to explicitly mark a document modified).