Content List

As a enterprise user, you can use a content list component to dynamically display content items of a particular type.

For example, you can use a content item list on a designated detail page and when a user clicks a link to get more detailed information for a particular content item, it will automatically load the detail view for the associated content item. For example, if there is a page with multiple articles, each with a headline and image, and the user clicks a particular article, the detail page displays the full article regardless of which article is chosen.

To add a content list component to a page:

  1. Navigate to the page you want to edit and make sure that Edit switch is set to Edit.
  2. Add the component to the page.
  3. To edit the component and its appearance, click its menu icon Component Menu icon, and choose Settings.
  4. Use the General tab to modify spacing, alignment, and other presentation options.
  5. Choose from the following to set additional defaults for the content that’s displayed.
    • Content Type: Select one of the available content types. The content types are those of the content items in the site collection and includes custom digital asset types.

    • Maximum Items and Start at Item: Specify the maximum number of items to display and where the display will begin. Additional items are not displayed.

    • Pagination: Specify if you want to include pagination options with the list. If selected, you can then tailor the way the pagination is displayed with buttons or page numbers and different labels if needed.

    • Date: Use the options provided to select content items to display based the item creation date before, after, between, or within selected dates or date ranges.

    • Categories: Select categories to filter the list of content items to show only those items in a particular category or categories. Click Select Categories to open a slide-out panel you can use to select categories from the site repository. If you select more than one category in the same taxonomy, displayed items just have to have one of the selected categories assigned to them. If you select more than one category from different taxonomies, displayed items must have all of the selected categories assigned to them. For example, if you select categories for Cities and Parks from the Destination taxonomy, then items that are cities or parks are displayed. If you select the category Cities from the Destination taxonomy and the category Europe from the Regions taxonomy, then items that are cities in Europe are displayed.

      By default all children of the selected category will be available. If you prefer to limit your list to items in a specific category node, select the node and deselect Include Child Categories.

    • Language: Choose a language from those associated with the repository.

    • Additional Query String (optional): Specify additional query parameters to further refine the list of items displayed using a syntax similar to: field.dept eq "Finance". See the table below for the list of available operators.

    • Order By: Sort the items by name or date in ascending or descending order. If the content type includes other date, number, or decimal fields, you can also sort by those fields.

      You can also select Custom, and then enter a custom expression. For example, to sort by department number in ascending order, you might enter fields.deptno:asc. You could also define a URL parameter for sorting. For example, you might enter {{URLParams.sortBy}}, then you could add the following parameter to the end of your site URL: ?sortBy=fields.deptno:asc.

    • Item View: Select the layout used to display the content item. The supplied Default layout shows all fields in the content item. If the content item has other, custom layouts designed for it, you can choose any available layout. If you select a custom layout that has Add support for custom settings when used in Sites enabled, then you can add custom data to the layout by clicking Next icon entering data into the Custom Data field, and then click Back to return to the General tab.

    • Page to display individual item: If you have designated one or more pages as a detail pages, they are listed here. Choose a page to display detailed information when a user clicks the link on a the content item to view detailed information.

      Note:

      If you do not create a detail page, the link to display details is not shown for the content item in the default layout.
    • List View: Select a section layout to arrange the items. This list can include custom layouts. The following layouts are provided:

      • Horizontal: Arranges the items one after the other in a horizontal line.

      • Vertical: Arranges the items one after the other in a vertical line. This is the default if no layout is selected.

      • Two Columns: Arranges the items by twos in multiple rows.

      • Three Columns: Arranges the items by threes in multiple rows.

      Click the right arrow next to the selected layout to modify settings for the layout.

    • Empty List View: Select how an empty list should be displayed.

    • Options: choose if there should be an auto-refresh on the search query specified in the Content Search component.

    • Spacing: Choose how the items will be displayed.

  6. Use the Style tab to format the frame that contains the component with predefined styles or with your own custom choices.

Table 10-1 Query Operators

Operator Example Supported Data Types Description
eq ?q=name eq "John"

?q=type eq "DigitalAsset"

?q=type eq "Employee" and fields.DOB eq "1994/09/26T16:23:45.208"

?q=type eq "Employee" and fields.DOB eq "1994/09/26T16:23:45.208"

text, reference, number, decimal, boolean, datetime Equals operator (eq) matches the exact value supplied in the query. This operator is not applicable to multivalued data types. The value provided with this operator is not case-sensitive except for standard fields. This operator considers even special characters in the value.
co ?q=(type eq "Employee" AND name co "john alex")

?q=(type eq "Car" AND fields.features co "manual")

text, reference, number, decimal, datetime, largetext Contains operator (co) matches every word given in the criteria. The words are formed by splitting the value by special characters. It gives the results that have at least one of the words (in this example, john or alex or both). This operator does not consider special characters in the value while searching. This operator does not perform a search on stop words. Refer to Apache Lucene documentation to know more about stop words.

This operator is applicable to text, largetext in case of single-valued attributes, whereas for multivalued attributes, it is applicable to text, reference, number, decimal, datetime, largetext. To understand the possible datetime formats, refer to the Supported date/datetime formats (24Hrs) table below. The value provided with this operator is not case-sensitive.

sw ?q=type eq "Employee" AND name sw "Joh"

?q=type eq "Employee" AND fields.city sw "Los"

text Starts with operator (sw) matches only the initial character values given in the field condition. This operator is not applicable to multivalued data types. The value provided with this operator is not case-sensitive.
ge ?q=(type eq "Employee" AND fields.age ge "40")

?q=type eq "DigitalAsset" AND updatedDate ge "20171026"

number, decimal, datetime Greater than or equal to operator (ge) matches only numeric and datetime values. To understand the possible datetime formats, refer to the Supported date/datetime formats (24Hrs) table below. This operator is not applicable to multivalued data types.
le ?q=(type eq "Employee" AND fields.weight le "60.6") number, decimal, datetime Less than or equal to operator (le) matches only numeric and datetime values. To understand the possible datetime formats, refer to the Supported date/datetime formats (24Hrs) table below. This operator is not applicable to multivalued data types.
gt ?q=(type eq "Employee" AND fields.age gt "20") number, decimal, datetime Greater than operator (gt) matches only numeric and datetime values. To understand the possible datetime formats, refer to the Supported date/datetime formats (24Hrs) table below. To understand the possible datetime formats, refer to the Supported date/datetime formats (24Hrs) table below. This operator is not applicable to multivalued data types.
lt ?q=(type eq "Employee" AND fields.age lt "20")

?q=type eq "Employee" AND createdDate lt "1994/09/26T16:23:45.208"

number, decimal, datetime Less than operator (lt) matches only numeric and datetime values. To understand the possible datetime formats, please refer to the section: Supported date/datetime formats (24Hrs). This operator is not applicable to multivalued data types.
mt ?q=(type eq "Car" AND fields.review mt "petrol 20KMPL")

?q=(type eq "Employee" AND name mt "Jo?n")

?q=(type eq "Employee" AND name mt "Jo*")

?q=(type eq "Employee" AND fields.role mt "senior*")

text, largetext Phrase query or proximity search (matches) operator (mt) enables you to find words that are within a specific distance to one another. Results are sorted by best match. It is useful for searching content items when values given in the criteria "petrol 20kmpl" need to discover actual content that may contain "petrol fuel mileage runs 20KMPL in the speed way".

Matches operator also can use a wildcard within the given value and supports both single-character and multiple-character wildcard searches within a single value. Use ? for a single-character wildcard and * for multiple characters. Both "John" and "Joan" can be searched by "Jo?n" for a single character and "Jo*" for multiple characters.

This operator is applicable to both single-valued and multivalued data types. This operator does not perform a search on stop words. Refer to Apache Lucene documentation to know more about stop words. The value provided with this operator is not case-sensitive.

sm ?q=(type eq "Employee" And fields.city sm "Rome") text, largetext Similarity query operator. This operator allows searching for values that sound like specified criteria - also called fuzzy search, which uses by default a maximum of two edits to match the result. "Rome" is similar to "Dome". This operator is applicable to both single-valued and multivalued data types. The value provided with this operator is not case-sensitive.
AND ?q=(type eq "Employee" AND name eq "John" AND fields.age ge "40") N/A AND operator, can be used to put an AND condition between multiple query conditions. This takes precedence over OR.
OR type eq "Employee" AND name eq "John" OR fields.age ge "40" N/A OR operator can be used to put an OR condition between multiple query conditions.
( ) ?q=type eq "Employee" AND (name eq "John" AND fields.age ge "40")

?q=type eq "Employee" AND ( (name eq "John" AND fields.age ge "40") OR fields.weight ge 60)

N/A Parentheses, enclosing operator to group the conditions in the criteria. This takes highest precedence, followed by AND, and then by OR.