Table of Contents | ||
---|---|---|
|
Requirements
Structure
...
Plugin PACKAGED_Versions
This plugin holds all the services needed for the correct execution of the version management feature and thus needs to be activated on a project that wants to use the feature.
Structure
The version management feature is available only for assets with a workcopy-compliant structure. A An asset structure is considered workcopy-compliant if it has includes the following properties:
Property | Type | Description |
---|---|---|
| Child |
→ #self | References the current version of the asset to |
replace. | ||
| Text | Unique identifier linking asset versions in the format |
. |
This field is empty for current versions that |
have not been replaced |
yet. | ||
| Integer | Indicates the version number. |
Info |
---|
These properties are can be verified in the Wizards tab of the object structure administration interface. |
For the need to identify Additionally, for identifying archived versions, a new property has been added to the assets' structure :
...
Property | Type |
...
Description |
...
Arounf the tab “Versions”
...
| Word | Stores version-related data, such as the reason for archiving (e.g., obsolete). |
Configuration
Display Setup
The version management feature is accessible on the front end via the tab Versions from the Versions tab on the asset detail page.
...
To configure the tab display of that tab, use the following entry point can be used:
Code Block |
---|
$.common.namedDisplays.defaultAssetDetailTabVersions |
...
By default, this configuration is included in the tab settings delivered via:
Code Block |
---|
$.common.namedDisplays.defaultAssetDetailMeta.column.tabs |
...
Security
...
Under the security property of the tab configuration(defaultAssetDetailTabVersions.security
), it is possible to define which security domain(s) should be evaluated to display the versions tab.
By default, it is preconfigured with :
...
language | json |
---|
Configuration
The tab’s visibility depends on its security configuration:
Entry Point:
defaultAssetDetailTabVersions.security
Default Security Domain:
["objectdata/insert"]
This means that the “Versions” default setup ensures the Versions tab is by default displayed visible to users allowed to create instances in the instance’s object visualized on the detail page.It is possible to use the following . Additional security domains include:
objectdata/insert
objectactions/create
objectactions/multiupdate
objectactions/delete
objectactions/view
objectactions/changestatus
Note |
---|
If |
...
multiple security domains |
...
are |
...
specified, the user must be granted all listed permissions to see the |
...
Versions tab. |
Actions on
...
Versions
The available actions depend on the version type of versions and user permissions of the user.:
Draft
...
Version
Preview
and edit& Edit:
OnlyAllowed if the user
is allowed tocan edit the instance.
Delete:
OnlyAllowed if the user
is allowed tocan delete the instance.
Publish:
The publish action of a draft version is accessible from the previsualization interface. This action is enabled onlyAccessible through the preview interface if the user has permission to execute a workflow action
that can taketransitioning the instance to an online status.
Archived
...
Version
Preview:
WorksAllowed if the user
is allowed tocan edit the instance.
Delete:
OnlyAllowed if the user
is allowed tocan delete the instance.
Restore:
It’s possible to restore an archived version and make it become the current one. This action is displayed onlyPossible if the user has
the right to process an action that can takepermission to transition the asset from
thearchived
statusto
anonline status.
Current
...
Version
No actions are available
...
in the
...
Versions tab.
...
Related actions are accessible from the header section.
Note |
---|
Versions are still assets, and thus, they are evaluated through security the same way as assets not involved in version management (through their status, for instance). |
Identification of versions
...
Version Identification
In certain situations, such as security assessments or base evaluations, it may be helpful to distinguish between the different types of versions. You can use the following table The table below describes how to do so this:
Version |
---|
Type | Description | Key Characteristics |
---|---|---|
Current |
Version | The active version of an asset. |
|
|
|
|
|
|
|
Draft |
Version | Represents the initial state of |
a new version. |
|
copietravail
should always be populated with
|
uid
property is filled with asset_id
|
|
Archived |
Version | Represents past current versions, replaced by a draft version |
. |
|
|
|
The field versionsdata
contains the value obsolete
|
Miscellaneous features
...
Tag: pkg/versions/keep/on/publish
A new The tag pkg/versions/keep/on/publish
has been introduced to be able to identify fields on assets structure that need to be kept and not overridden or changed when instances are replaced by new versions.
It is by default assigned to the portals field.
For example, let’s consider an asset identifies fields that must be retained when an instance is replaced by a new version.
Example:
Asset X (current version)
...
is assigned to sections A and B
...
.
A new draft version of X
...
is created, retaining sections A and B.
While the
...
draft is
...
being worked on, Asset X is
...
assigned to a new section C
...
.
This assignment does not affect the draft version
...
The tag pkg/versions/keep/on/publish
prevents the deletion of reference C from being deleted after the publication of the draft version when it will replace the active version.
To sum up, this tag is used to identify properties that we don’t want to change when the current version is replaced by the draft version. It can be added to other properties that will work on the same principle as portals
.
Filtering of archived versions on the front end
Archived versions are not displayed on the front end by default. They are masked via a service of the plugin PACKAGED_Versions
and are filtered by default when requesting the following types of API endpoints :
...
.
Result: After publishing the draft version, section C remains assigned due to the retention tag.
Filtering Archived Versions on the Frontend
Archived versions are hidden by default via the PACKAGED_Versions plugin. They are filtered when using these API endpoints:
api/rest/dam/asset
...
(ASSET)
api/rest/dam/data/asset
...
(SEARCH)
api/rest/dam/data/asset1,asset2
...
(TOPSEARCH)
api/rest/dam/asset/aggs
...
(ASSET_AGGS)
api/rest/dam/data/aggs/asset1,asset2
...
(MULTI_AGGS)
Customization Tip: Extend the APIBaseWhereBusinessServiceAdapter
( using the field versionsdata
) inside a project plugin if you want to filter additional endpoint types on the front end or submit an amelioration ticket on the product if you find it useful to restrict more endpoints by default versionsdata
field to filter additional endpoints as needed. Alternatively, consider submitting a product enhancement request.