Details
-
Sub-task
-
Resolution: Fixed
-
High
-
2015.07
-
None
Description
EZP-24701 adds versioning for roles, and therefore for policies.
However, data is not handled in the same way than in legacy.
In legacy, a role draft is created as verbatim copy of the original role, with its own ID. In ezrole table, version field has a misleading name as it doesn't store a version number, but a reference to the original role ID.
The same occur for policies, with original_id field in ezpolicy table. It is supposed to track the original policy ID the policy draft is created from.
Consequences:
- Data BC is broken between Platform and Legacy, which is annoying for migration.
- In ezpolicy table, role_id column holds a reference to the parent role, being a draft or not. A role draft is a normal role decorating another one.
- Role draft has policies with no reference to original policies, which is annoying especially for policy editing in PlatformUI.