APIs

Show:

Controller to support a modal windows in FlexberryLookup component.

Methods

_closeModalDialog

() private

Close current modal window if it exists.

_getNextSortDirection

(
  • currentDirection
)
String private
Get next sorting direction.

Parameters:

  • currentDirection String
    Current sorting direction.

Returns:

String: Sorting direction.

_selectMaster

(
  • master
)
private

Set master to corresponding property of editing object.

Parameters:

  • master Object

    Selected master for editing property.

actions.addColumnToSorting

(
  • column
  • sortPath
)
Add column into end list sorting.

Parameters:

  • column Object
    Column for sorting.
  • sortPath String
    Path to oldSorting.

actions.applyFilters

(
  • filters
)

Save filters and refresh list.

Parameters:

actions.createdModalDialog

(
  • modalDialog
)

Handlers create modal window action. Save created window, to have opportunity to close it later.

Parameters:

  • modalDialog JQuery

    Created modal window.

actions.loadRecords

(
  • id
  • target
  • property
  • firstRunMode
)

Redirect actions into route.

Parameters:

actions.objectListViewRowClick

(
  • record
)

Handlers OLV row click, Save selected row to object master property and close modal window.

Parameters:

actions.refreshList

()

Refresh list with actual parameters.

actions.resetFilters

()

Reset filters and refresh list.

actions.routeWillTransition

()

Handlers correcponding route's willTransition action. It closes modal window if it is opened (if Ember uses hash location type, modal window won't be closed automatically).

actions.sortByColumn

(
  • column
  • sortPath
)
Sorting list by column.

Parameters:

  • column Object
    Column for sorting.
  • sortPath String
    Path to oldSorting.

clear

(
  • initialClear
)

It clears current controller. It has to be done before each use.

Parameters:

  • initialClear Boolean

    Flag indicates whether it is clear on first load or just on reload.

getCellComponent

(
  • attr
  • bindingPath
  • modelClass
)
Object

Method to get type and attributes of component, which will be embeded in object-list-view cell.

Parameters:

  • attr Object

    Attribute of projection property related to current table cell.

  • bindingPath String

    Path to model property related to current table cell.

  • modelClass Object

    Model class of data record related to current table row.

Returns:

Object:

Object containing name & properties of component, which will be used to render current table cell ({ componentName: 'my-component', componentProperties: { ... } }).

onDeleteActionFulfilled.

()

This method will be invoked when delete operation successfully completed. Override this method to add some custom logic on delete operation success.

Example:

onDeleteActionFulfilled() {
                      alert('Delete operation succeed!');
                    }
                    

onDeleteActionRejected.

(
  • errorData
)

This method will be invoked when delete operation completed, but failed. Override this method to add some custom logic on delete operation fail.

Parameters:

  • errorData Object

    Data about delete operation fail.

Example:

onDeleteActionRejected() {
                      alert('Delete operation failed!');
                    }
                    

onDeleteActionStarted.

()

This method will be invoked before delete operation will be called. Override this method to add custom logic on delete operation start.

Example:

onDeleteActionStarted() {
                      alert('Delete operation started!');
                    }
                    

onSaveActionAlways.

(
  • data
)

This method will be invoked always when delete operation completed, regardless of save promise's state (was it fulfilled or rejected). Override this method to add some custom logic on delete operation completion.

Parameters:

  • data Object

    Data about completed save operation.

Example:

onDeleteActionAlways(data) {
                      alert('Delete operation completed!');
                    }
                    

queryParametersChanged

()

It observes query parameters changing. If query parameter (filter, current page, etc.) is changed then displayed data are reloaded.

Properties

_openedModalDialog

JQuery private

Current open a modal window.

computedSorting

Object
Dictionary with sorting data related to properties.

currentLookupRow

DS.Model

Current lookup selected record. It is used to highlight selected record.

customPropertiesData

Object

Set of properties to set for list commponent.

defaultDeveloperUserSettings

Object

Object with default developer user settings.

Default: undefined

developerUserSettings

Object

Object with developer user settings.

Default: undefined

disableHierarchicalMode

Boolean

Flag indicates whether to show hierarchical button if hierarchy is available.

Default: false

lookupController

Ember.InjectedProperty

Controller to show colsconfig modal window.

Default: controller('colsconfig-dialog')

lookupEventsService

Service

Service that triggers lookup events.

modelType

String

Type of current loaded data.

predicate

BasePredicate

Predicate to limit loaded data by.

projectionName

String

Name of projection data were loaded by.

queryParams

Array
Defines which query parameters the controller accepts. [More info](https://emberjs.com/api/ember/release/classes/Controller#property_queryParams).

Default: ['sort']

reloadContext

Object

Context for handler of data reloading call.

Default: undefined

reloadDataHandler

Function

Handler to call when parameters of loaded data changed (filter, currentPage, etc.).

reloadObserverIsActive

Boolean

Flag indicates whether to observe query parameters or they are not still initiated..

Default: false

sort

String
String with sorting parameters.

sortDefaultValue

String
Default value for sorting.

state

String

State form. A form is in different states: loading, success, error.

title

String

Title for modal window.