Caplin Trader 4.7.1

Class: module:caplin/grid/refine/component/presenter/GenericRefinerPresentationModel

module:caplin/grid/refine/component/presenter/GenericRefinerPresentationModel

A generic PresentationModel for grid column refinement panels. It can be composed of PresentationNodes that handle sorting and filtering of the column.

Constructor

new module:caplin/grid/refine/component/presenter/GenericRefinerPresentationModel(nodes)

Extends:
Parameters:
Name Type Description
nodes object map of either 1 or 2 PresentationNodes
Properties
Name Type Description
sort module:caplin/presenter/node/PresentationNode responsible for applying sort order to column
filter module:caplin/presenter/node/PresentationNode responsible for applying filter to column
Implements:

Extends

Methods

apply()

Applies current refinements to the grid column. If inputs validate successfully, it triggers the module:caplin/grid/refine/GridColumnRefinerEvents#event:REFINER_ACTION_COMPLETE, signifying that it is to be closed.

clear()

Clears all refinements. It triggers the module:caplin/grid/refine/GridColumnRefinerEvents#event:REFINER_ACTION_COMPLETE, signifying that it is to be closed.

getClassName()

Returns the presentation model class name.
Inherited From:
Returns:
Presentation model class name.

getComponentFrame()

Presentation models can use this method to receive a reference to the frame containing the module:br/presenter/component/PresenterComponent that this model resides within.
Inherited From:

getPath()

Returns the path that would be required to bind this node from the view.

This method is used internally, but might also be useful in allowing the dynamic construction of views for arbitrary presentation models.

Inherited From:

nodes(sNodeName, vProperties)

Returns all nested nodes matching the search criteria reachable from this node.

Care is taken not to search up the tree in cyclic presentation models (where some of the presentation nodes have back references to presentation nodes higher up in the tree).

Parameters:
Name Type Description
sNodeName String The name of nodes to match.
vProperties Object Only nodes having this array or map of properties will be matched.
Inherited From:
See:

onClose()

Close the panel

onOpen()

Open the panel

properties(sPropertyName, vValue)

Returns all nested properties matching the search criteria reachable from this node.

Care is taken not to search up the tree in cyclic presentation models (where some of the presentation nodes have back references to presentation nodes higher up in the tree).

Parameters:
Name Type Description
sPropertyName String The name of properties to match.
vValue Object The value of properties to match.
Inherited From:
See:

removeAllListeners()

Inherited From:
Deprecated:
  • This method has been replaced by #removeChildListeners which recurses the node tree. Removes all listeners attached to the properties contained by this PresentationNode.

    removeChildListeners()

    Removes all listeners attached to the properties contained by this PresentationNode, and any nodes it contains.
    Inherited From:

    setColumn()

    Set the column which the model should apply refinements to
    Implements:

    setComponentFrame(oComponentFrame)

    Presentation models can use the module:br/presenter/PresentationModel#getComponentFrame to receive a reference to the frame containing the module:br/presenter/component/PresenterComponent that this model resides within.
    Parameters:
    Name Type Description
    oComponentFrame module:br/component/Frame The frame within which the presenter component resides.
    Inherited From: