Magnolia DAM JCR implementation

Edition DX Core

License

MLA

Issues

DAM

Maven site

DAM

Latest

3.0.9

Modules

  • magnolia-dam-jcr

    • Magnolia specific DAM implementation based on JCR.

    • Stores DAM data in the JCR workspace dam.

    • Provides and configures the JCR specific AssetProvider JcrAssetProvider.

  • magnolia-dam-imaging

Installing with Maven

Maven is the easiest way to install the module. Add the following to your bundle:

<dependency>
  <groupId>info.magnolia.dam</groupId>
  <artifactId>magnolia-dam-jcr</artifactId>
  <version>3.0.9</version>
</dependency>
<dependency>
  <groupId>info.magnolia.dam</groupId>
  <artifactId>magnolia-dam-imaging</artifactId>
  <version>3.0.9</version>
</dependency>

Magnolia DAM JCR configuration

As mentioned above, the configuration for JcrAssetProvider and ImagingBasedAssetRenderer are set by their modules. Finally the configuration looks like this:

image

NoOpAssetRenderer is configured by DAM core module but is shown here the sake completeness.

Displaying asset sizes in the asset browser

In the default configuration, asset sizes are not shown in the asset browser since this information is regarded as less important to content editors. However, you can use the definition decoration mechanism to reconfigure the default column composition and add a column that will display the sizes. The sort-by-size function will be also available through the up/down arrows in the column header.

DAM assets JCR subapp with bytesize column added via definition decoration

To add the column to the default configuration, create a definition decorator file in your light module, as shown in the example below. Use the YAML !override directive to specify the position of the column in the column list.

$magnolia.resources.dir/<your-module>/decorations/dam-assets-app/apps/dam.subApps.yaml
jcrBrowser:
  workbench:
    contentViews:
      - name: tree
        columns: !override
          jcrName: &name
          title: &title
          jcr:content/size: &size
            type: java.lang.Long
            label: Size (bytes)
Feedback