Class: PortalUsagesView

PortalUsagesView()

A view that shows a list of Portal Usages

Constructor

new PortalUsagesView()

Since:
  • 2.14.0
Source:

Extends

Members

additionalPortalsToDisplay :Array.<SolrResult>

An array of additional SolrResult models for portals that will be displayed in this view in addition to the SolrResults found as a result of the search. These could be portals that wouldn't otherwise be found by a search but should be displayed anyway.
Type:
Inherited From:
Source:

createBtnContainer :string

A jQuery selector for the element that the Create Portal should be inserted into
Type:
  • string
Inherited From:
Source:

filters :Array.<Filter>

An array of Filter models or Filter model JSON to use in the query. If not provided, a default query will be used.
Type:
Inherited From:
Source:

listContainer :string

A jQuery selector for the element that the list should be inserted into
Type:
  • string
Inherited From:
Source:

noResultsMessage :string

The message to display when there are no portals in this list
Type:
  • string
Inherited From:
Source:

numPortals :number

The number of portals to retrieve and render in this view
Type:
  • number
Inherited From:
Default Value:
  • 100
Source:

numPortalsPerPage :number

The number of portals to dispaly per page
Type:
  • number
Inherited From:
Default Value:
  • 10
Source:

searchFields :string

A comma-separated list of Solr index fields to retrieve when searching for portals
Type:
  • string
Inherited From:
Default Value:
  • "id,seriesId,title,formatId,label,logo"
Source:

searchResults :SolrResults

A SolrResults collection that contains the results of the search for the portals
Type:
Inherited From:
Source:

template

References to templates for this view. HTML files are converted to Underscore.js templates
Inherited From:
Source:

usagesCollection :Usages

A reference to the Usages collection that is rendered in this view
Type:
Source:

Methods

createListItem() → {Element}

Creates a table row for the given portal SolrResult model
Parameters:
Type Description
SolrResult The SolrResult model that represent the portal
Inherited From:
Source:
Returns:
Type
Element

getSearchResults()

Queries for the portal objects using the SearchResults collection
Inherited From:
Source:

getSearchResultsForUsages(usages)

Using the Usages collection, this function creates Filters that search for the portal objects for those Usages
Parameters:
Name Type Description
usages Usages The Usages collection to get search results for
Source:

initialize()

Initializes a new view
Inherited From:
Source:

mergeSearchResults()

Merges the SearchResults collection with the Usages collection
Source:

render()

Renders this view
Overrides:
Source:

renderCreateButton()

Renders a "Create" button for the user to create a new portal
Inherited From:
Source:

renderList()

Renders each search result from the SolrResults collection
Inherited From:
Source:

showError()

Displays an error message when rendering this view has failed.
Inherited From:
Source:

showUsageInfo()

Shows the Usage info for each Portal in this view
Source: