APIs

Show:
Extends Service
Module: ember-flexberry

Service for interaction between agregator's and detail's forms.

It is usually used to go after row click on FlexberryGroupeditComponent to corresponding child's route.

Warning: this service should not be used outside of addon because it can lead to unpredictable side effects.

Methods

getLastValue

(
  • propertyName
)
Object public

Returns the last value of array (or undefined if array contains no values). Array is kept at givven property.

Parameters:

  • propertyName String

    The name of property where array is kept.

Returns:

Object:

The last value of array (or undefined if array contains no values).

hasValues

(
  • currentArray
)
Boolean public

Returns a logic value showing if givven value is array and has values.

Parameters:

  • currentArray Array

    Value to check if it is array and has values.

Returns:

Boolean:

Logic value showing if givven value is array and has values..

pushValue

(
  • propertyName
  • currentArray
  • value
)
public

Pushes givven value to givven array and saves this array to givven property.

Parameters:

  • propertyName String

    Name of property to save result array to.

  • currentArray Array

    Array to add value to. If it is not array, new array will be created.

  • value Object

    A value to add to array.

Properties

modelCurrentAgregatorPathes

Object

Pathes to detail's agregators (stack of previous pathes in order to support detail of N-level). This parameter is initialized on agregator's form after click on detail. This parameter is used only on detail's form in order to get return url.

modelCurrentAgregators

Object

Current detail's agregators (stack of previous agregators in order to support detail of N-level). This parameter is initialized on agregator's form after click on detail. This parameter is used only on detail's form in order to return to proper agregator.

modelCurrentNotSaved

Object

Current not saved model. This parameter is initialized on detail's form after triggerring return to agregator's form. This parameter is used only on agregator's form in order to get already created not saved agregator object and not to create new instance.

modelLastUpdatedDetail

Object

Last updated detail. This parameter is initialized on detail's form after triggerring return to agregator's form. This parameter is used only on agregator's form in order to undestand updated detail state.

modelSelectedDetail

Object

Selected detail. Its selection triggered transition to detail's route. This parameter is initialized on agregator's form after click on not saved details. This parameter is used only on detail's new form in order to open already created not saved detail object.

saveBeforeRouteLeave

Boolean

Flag: indicates whether to save current model before going to agregator's route.