SearchPanel

App.searchV2. SearchPanel

Renders the sidepanel search form.

Constructor

new SearchPanel(options)

See:
Parameters:
Name Type Description
options

Methods

(static) getMergedSections(searchform, newSections, addIfNotPresentopt) → {Object}

Parameters:
Name Type Attributes Default Description
searchform Object
newSections Object
addIfNotPresent boolean <optional>
false

Whether new section, if not present in searchform, should be added.

Returns:
  • Merged Sections
Type
Object

addToolbarItem()

Adds commands to toolbar.

applyCustomization()

Applies customization associated with search on searchform options.

applySearchCriteriaOnObjectData(Object) → {boolean}

Applies search criteria on object data and return true of object data matches with search criteria

Parameters:
Name Type Description
Object object

Data

Returns:

whether object data matches the search criteria

Type
boolean

checkDataMatches(Search, value) → {boolean}

Evaluates the value against the single search criterion and return true if value matches the criterion

Parameters:
Name Type Description
Search object

criterion

value string

against which search criterion should be applied

Returns:

whether value matches the criterion

Type
boolean

close()

destroy()

emit(event, dataopt)

Parameters:
Name Type Attributes Default Description
event Object

Event to be emitted

data Object <optional>
{}

data emitted with event

getSearchForm() → {*|null}

Returns:
Type
* | null

getSearchFormProps() → {Object}

Returns searchFormProps json object.

Returns:

searchFormProps object

Type
Object

getToolbar() → {Object}

Returns toolbar json object from save search toolbar.

Returns:

toolbar object

Type
Object

initializeToolbar()

Initialize toolbar for this search panel and adds save and load search commands.

isOpen() → {boolean}

Returns:
Type
boolean

off(event, handler)

Parameters:
Name Type Description
event Object

Event to be removed

handler function

Event handler

on(event, handler)

Parameters:
Name Type Description
event Object

Event to be registered

handler function

Event handler

onSectionsUpdated(sections)

Parameters:
Name Type Description
sections Array.<Object>

array of search form section objects

open()

registerSearchFormEvents()

Registers events on searchform associated with this searchpanel.

saveCustomization(customization)

Parameters:
Name Type Description
customization Object

setCriteria(criteria)

Sets criteria on the search form.

Parameters:
Name Type Description
criteria Object

setCriteriaAsQueryString(query)

Sets criteria on the search form.

Parameters:
Name Type Description
query string

string

toggleVisibility()

updateContentWidth(width, append)

Parameters:
Name Type Default Description
width
append false

updateSearchFormFields(data)

Parameters:
Name Type Description
data