Class: DataCatalogViewWithFilters

DataCatalogViewWithFilters()

A DataCatalogView that uses the Search collection and the Filter models for managing queries rather than the Search model and the filter literal objects used in the parent DataCatalogView. This accommodates custom portal filters. This view is deprecated and will eventually be removed in a future version (likely 3.0.0)

Constructor

new DataCatalogViewWithFilters()

Deprecated:
  • Yes
Source:

Extends

Members

className :string

The HTML class names for this view element
Type:
  • string
Source:

editorView :PortalEditorView

A reference to the PortalEditorView
Type:
Source:

filterGroupsContainer :string

The jQuery selector for the FilterGroupsView container
Type:
  • string
Source:

fixedHeight :Boolean

If true, the view height will be adjusted to fit the height of the window If false, the view height will be fixed via CSS
Type:
  • Boolean
Inherited From:
Source:

searchModel :Search

The Search model to use for creating and storing Filters and constructing query strings. This property is a Search model instead of a Filters collection in order to be quickly compatible with the superclass/superview, DataCatalogView, which was created with the (eventually to be deprecated) SearchModel. A Filters collection is set on the Search model and does most of the work for creating queries.
Type:
Source:

solrError500Message :string

The user-friendly text to show when a solr request gives a status 500 error. If none is provided, then the error message that is returned from solr will be displayed.
Type:
  • string
Since:
  • 2.15.0
Inherited From:
Source:

solrErrorTitle :string

The general error message to show as a title in the error box when there is an error fetching results from solr
Type:
  • string
Since:
  • 2.15.0
Inherited From:
Default Value:
  • "Something went wrong while getting the list of datasets"
Source:

sortOrder :string

The sort order for the Solr query
Type:
  • string
Source:

tagName :string

The HTML tag name for this view element
Type:
  • string
Source:

template :Underscore.template

The primary HTML template for this view
Type:
  • Underscore.template
Overrides:
Source:

Methods

addAll()

Add all items in the **SearchResults** collection This loads the first 25, then waits for the map to be fully loaded and then loads the remaining items. Without this delay, the app waits until all records are processed
Inherited From:
Source:

addAnnotationFilter()

addAnnotationFilter - Add the annotation filter to the view
Inherited From:
Source:

addMarkers()

Get the details on each marker And create an infowindow for that marker
Inherited From:
Source:

addOne()

Add a single SolrResult item to the list by creating a view for it and appending its element to the DOM.
Inherited From:
Source:

addTileInfoWindows()

Get the details on each tile - a list of ids and titles for each dataset contained in that tile And create an infowindow for that tile
Inherited From:
Source:

closeInfoWindows()

Iterate over each infowindow that we have stored in the view and close it. Pass an infoWindow object to this function to keep that infoWindow open/skip it
Parameters:
Type Description
infoWindow An infoWindow to keep open
Inherited From:
Source:

createFilterGroups()

Creates UI Filter Groups and renders them in this view. UI Filter Groups are custom, interactive search filter elements, grouped together in one panel, section, tab, etc.
Source:

drawTile(options, geohash, label)

With the options and label object given, add a single tile to the map and set its event listeners
Parameters:
Name Type Description
options object
geohash string
label string
Inherited From:
Source:

drawTiles()

Create a tile for each geohash facet. A separate tile label is added to the map with the count of the facet.
Inherited From:
Source:

getResults(page)

getResults gets all the current search filters from the searchModel, creates a Solr query, and runs that query.
Parameters:
Name Type Description
page number The page of search results to get results for
Overrides:
Source:

hideClearButton()

Overload this function with an empty function since the Clear button has been moved to the FilterGroupsView
Source:

hideResultOnMap(e)

Hide the marker, infoWindow, and bounding coordinates polygon on the map when the user stops hovering on the marker icon in the result list
Parameters:
Name Type Description
e Event The event that brought us to this function
Inherited From:
Source:

removeMarkers()

Iterate over all the markers in the view and remove them from the map and view
Inherited From:
Source:

removeTiles()

Remove all the tiles and text from the map
Inherited From:
Source:

render()

Override DataCatalogView.render() to render this view with filters from the Filters collection
Source:

renderMap()

Render the map based on the mapModel properties and search results
Source:

resetMap()

Reset the map to the defaults
Source:

showClearButton()

Overload this function with an empty function since the Clear button has been moved to the FilterGroupsView
Source:

showError(model, response)

When the SearchResults collection has an error getting the results, show an error message instead of search results
Parameters:
Name Type Description
model SolrResult
response XMLHttpRequest.response
Inherited From:
Source:

showResultOnMap(e)

Show the marker, infoWindow, and bounding coordinates polygon on the map when the user hovers on the marker icon in the result list
Parameters:
Name Type Description
e Event
Inherited From:
Source:

toggleClearButton()

Overload this function with an empty function since the Clear button has been moved to the FilterGroupsView
Source:

toggleMapFilter()

Toggle the map filter to include or exclude it from the Solr query
Source:

toggleMapMode()

Toggle between map and list mode
Source: