Content attribute

From VYRE

Jump to: navigation, search

Content Attribute or Content Structure is used to define the content of an item in a Datastore. The Content Attribute/Structure can be accessed through Datastores.

Contents

Creation

  • Click on a Datastore and click over Edit from the top contextual menu.
  • In the next screen hover over the top contextual menu and select Content Structure.
  • Click on Add Attribute which will allow a new content attribute to be created.

First the following fields need to be filled:

Create an attribute definition

  • Name: Mandatory identifier used to reference the attribute
  • Description: Mandatory descriptive text to help identify the attribute
  • Attribute type: Data type to be represented by the attribute e.g. text, date or boolean value.
  • Cardinality: Whether value for this attribute is optional or mandatory.
  • Presentation rule: A context sensitive drop-down relating to the type of data being stored in the field. The presentation rules can be custom or predefined. For instance 'Long Text' can be displayed as a text box or HTML editor that allows the user to use a WYSIWYG (TinyMCE Editor).
  • Default value: The value to be displayed as the default e.g. the default value of a check box can either be checked or not

Index options

This options allows the user to choose whether the attribute should be indexed and the priority of the index. The indexed attributes are shown within search (this allows control over search usability).

  • Index attribute: whether this attribute should be indexed in Lucene
  • Index name: (only makes sense if the above attribute is enabled), allows to specify the name of this attribute to be used in index. I.e. if the name is foo, the query for value bar in Lucene would be foo:bar.
  • Add attribute to the default index field - this will include value of this attribute into a catch-all field, providing chances this item is found if a generic query (which does not contain field name) is issued.
  • Attribute boost factor - allows to boost search rankings of this attribute at index time.
  • Allow sorting by this attribute - adds extra field in Lucene so search results can be sorted by this attribute either in ascending or descending order.

XML Mapping

  • XML Name - allows specifying the XML element name for this attribute to be used when the item file is persisted in the content repository / XML format.

Use the 'Save' button on the top contextual menu to create the attribute.

Sections

Sections are used to separate and group various attributes. Use the 'Add Section' at the top of the contextual menu to create a new section.

Editing

To edit an existing attribute, select the attribute and then click on 'Edit' on top menu. This will direct the user to the editing screen.

Usage

Content structure/attribue is used to describe the content of an item within the datastore. For example 'News' datastore can contain different forms of news. To be able to create a news item you will need to identify separate entities which combined will give the full structure of the news.

Example

For a 'News' item, different attributes can be created to define separate sections/entities of the news item.

  • Headline: This is the name or headline of the news.
  • Summary: This is a brief description for the content of the news.
  • Body: This is the full content of the news.

This example shows that a news item can have 3 different attributes which the users (news editors) can edit to create the whole news.

Personal tools