Page tree
Skip to end of metadata
Go to start of metadata
Your Rating: Results: 1 Star2 Star3 Star4 Star5 Star 118 rates

This use case describes how to pre-populate metadata fields such as Date and Author at the point of content entry. The goal is to read any available invisible metadata that the system creates automatically and create corresponding user-editable metadata properties. This way editors don't need to fill all fields by hand. Tracked as DOCU-259@Jira.

Example scenario

  1. An editor creates a new article page.
  2. The system creates the page content node and sets hidden metadata such as mgnl:authorid and mgnl:creationdate.
  3. Some customized mechanism reads the metadata and sets corresponding visible metadata properties author and date under the page node.
  4. When the editor opens the page and edits the article header dialog, the Author and Date fields are already populated.

Metadata on the Standard Article page

You can check the available metadata fields on a new page with the Query tool.

/demo-project/about/subsection-articles/article/MetaData/mgnl:authorid=superuser
/demo-project/about/subsection-articles/article/MetaData/mgnl:activatorid=superuser
/demo-project/about/subsection-articles/article/MetaData/jcr:uuid=aed3d0e8-7af6-4001-98b9-f58f368ede91
/demo-project/about/subsection-articles/article/MetaData/mgnl:lastaction=2012-02-17T12:43:43.194+01:00
/demo-project/about/subsection-articles/article/MetaData/mgnl:creationdate=2008-11-17T16:34:13.992+01:00
/demo-project/about/subsection-articles/article/MetaData/jcr:createdBy=admin
/demo-project/about/subsection-articles/article/MetaData/mgnl:template=standard-templating-kit:pages/stkArticle
/demo-project/about/subsection-articles/article/MetaData/jcr:created=2012-03-02T09:13:27.293+01:00
/demo-project/about/subsection-articles/article/MetaData/mgnl:activated=true
/demo-project/about/subsection-articles/article/MetaData/jcr:primaryType=mgnl:metaData
/demo-project/about/subsection-articles/article/MetaData/mgnl:lastmodified=2012-03-07T13:35:17.372+01:00

Mapping between system metadata and user editable fields

Some of them can be mapped to user-editable metadata fields.

System metadata

User-editable metadata

mgnl:authorid

author

mgnl:activatorid

 

jcr:uuid

 

mgnl:lastaction

 

mgnl:creationdate

date

jcr:createdBy

 

mgnl:template

 

jcr:created

 

mgnl:activated

 

jcr:primaryType

 

mgnl:lastmodified

 

Metadata on the Standard Article page

To do: Create a similar table for an image uploaded to DMS.

Creating custom metadata fields

To do: What to do if you can't find a system metadata field but you want to populate a default value anyway? This would be the case for example for setting the copyright on uploaded images always to the same value.

  • No labels