Vous consultez actuellement l'aide de la version:

The OSGi service Day CQ WCM Undo Configuration (com.day.cq.wcm.undo.UndoConfigService) exposes several properties that control the behavior of the undo and redo commands for editing pages.

Default Configuration

In a standard installation the default settings are defined as properties on the sling:OsgiConfig node:


This node contains cq.wcm.undo.whitelist and cq.wcm.undo.blacklist properties, for the other properties the defaults are taken.

Attention :

You must not change anything in the /libs path.

This is because the content of /libs is overwritten the next time you upgrade your instance (and may well be overwritten when you apply either a hotfix or feature pack).

Configuring Undo and Redo

You can configure these OSGi service properties for your own instance.

Remarque :

When working with AEM there are several methods of managing the configuration settings for such services; see Configuring OSGi for more details and the recommended practices.

The following lists the properties as displayed in the Web console, followed by the name of the corresponding OSGi parameter, together with a description and the default value (where appropriate):

  • Enable

    • Description: Determines whether page authors can undo and redo changes.
    • DefaultSelected
    • Type: Boolean
  • Path

    • Description: The repository path for persisting binary undo data. When authors change binary data such as images, the original version of the data is persisted here. When changes to binary data is undone, this binary undo data  is restored to the page.
    • Default/var/undo
    • TypeString

    Remarque :

    By default, only administrators can access the /var/undo node. Authors can perform undo and redo operations on binary content only after they are given permissions to access the binary undo data.

  • Min. validity

    • Description: The minimum amount of time that binary undo data is stored, in hours. After this time period, the binary data is available for deletion, to conserve disk space.
    • Default10
    • TypeInteger
  • Steps

    • Description: The maximum number of page actions that are stored in the undo history.
    • Default20
    • TypeInteger
  • Persistence

    • Description: The class that persists undo history. Two persistence classes are provided:
      • CQ.undo.persistence.WindowNamePersistence: Persists history using the window.name property.
      • CQ.undo.persistence.CookiePersistance: Persists history using cookies.
    • DefaultCQ.undo.persistence.WindowNamePersistence
    • TypeString
  • Persistence mode

    • Description: Determines when undo history is persisted. Select this option to persist undo history after each page edit. Clear this option to persist only when a page reload occurs (for example, the user navigates to a different page).

      Persisting undo history uses web browser resources. If your users' browser reacts slowly to page edits, try persisting the undo history on page reloads.
    • DefaultSelected
    • TypeBoolean
  • Marker mode

    • Description: Specifies the visual cue to use for indicating which paragraphs are affected when an undo or redo occurs. The following values are valid:
      • flash: The selection indicator of the paragraphs flash temporarily.
      • select: The paragraph is selected.
    • Defaultflash
    • TypeString
  • Good components

    • Description: A list of components that you want to be affected by undo and redo commands. Add component paths to this list when they function correctly with undo/redo. Append an asterisk (*) to specify a group of components:
      • The following value specifies the foundation text component:
      • The following value specifies all foundation components:
    • When undo or redo is issued to a component that is not in this list, a message appears that indicates that the command can be unreliable.

    • Default: The property is populated with many components that AEM provides.
    • TypeString[]
  • Bad components

    • Description: A list of components and/or component operations that you do not want to be affected by the undo command. Add components and component operations that do not behave correctly with the undo command:
      • Add a component path when you want none of the component's operations in the undo history, for example collab/forum/components/post
      • Append a colon (:) and an operation to the path when you want that specific operation to be omitted from the undo history  (other operations function correctly), for example collab/forum/components/post:insertParagraph.

    Remarque :

    When an operation is on this list, it is still added to the undo history. Users cannot undo operations that exist earlier than a Bad Component operation in the undo history.

    • Typical operation names are as follows:
      • insertParagraph: The component is added to the page.
      • removeParagraph: The component is deleted.
      • moveParagraph: The paragraph is moved to a different location.
      • updateParagraph: The paragraph properties are changed.
    • Default: The property is populated with several component operations.
    • TypeString[]

Ce produit est distribué sous licence Creative Commons Attribution - Pas d’utilisation commerciale - Partage à l’identique 3.0 non transposé  Les publications Twitter™ et Facebook ne sont pas couvertes par les dispositions Creative Commons.

Mentions légales   |   Politique de confidentialité en ligne