Give us contact

Do you prefer to ask us directly?

Call us +420 605 203 938 (the Czech Republic)

or use this contacts

AyMINE

Related links


FI - Finance Management

Definition of the class detail

How to declare object detail view

Client application supports object-specific or view implementation. For object detail view, proprietary detail can be built from scratch or as a descendant of the default universal detail class (fUnivDetail). It is created as a standalone java script library that is dynamically linked when user opens the detail.

Before creating special detail view definition, consider advantages and disadvantages.

Advantages

  • More control over the content.
  • Support for better dynamical behaviour – dialog can react to the user better that universal dialog
  • Possibility to place user element not supported by standard (e.g. dynamical charts)

Disadvantages

  • Each changes requires application update
  • Cannot be loaded to the mobile application without rebuild
  • Make the application management more complicated

Remember:

Do not create implemented view when it is not needed. Universal dialogs have many possibilities:

  • Each dialog might use its own styles.
  • Even universal detail might update its content in response to the user
  • Universal detail might implement sophisticated controls over the input data controls.
  • Detail can contain clips with proprietary attributes and full html control of the content

Build up special dialog as a descendant of universal dialog.

Half-way for the self-defied view is the detail derived from the universal detail. Universal detail supports descendant during data loading and saving:

Internal attributes

  • Attributes from detail could be marked is internal
   "showHint":{"type":"bool","source":"internal"},

Internal attributes are not managed by server. At the client side, univDetail class calls method

  protected setInternalAttrVal(attr: detailAttr): void

for each internal attribute. Method should set that attribute value. Value is than managed in the same ways as the values loaded from server.

During save for each internal attributes is called method

  protected saveChanges_internalItem(attr: detailAttr)

Method gots the attribute with new value. And could manage its own control of that.

Manage database-loaded values

For each attribute stored by server, univDetails calls method

  protected saveChanges_objectItem(attr: detailAttr)

Overwrite default detail methods

Change save – saveChanges method

Descendant can use value or even modify before save.

Descendant can also override the method protected saveChanges() and make its own controls or operations before save. It can e.g. stop saving (do not call super method) and request user to make modifications or call its own method to save data.

Change behaviour – operButtons method

Method can implement its own operation. Buttons can be defined by the object definition including all buttons / operation details but page can manage its own behaviour. It can get full control over the system reaction and the button processing.

Let’s note, that calling its own method for the operation behaviour does not need the proprietary detail. Simply call the linked java script library with the method.

Examples

The AyMINE Framework – application contains two univDetail descendants

System user settings

Special view was needed because detail work with internal values that are not loaded from server – visual settings, behaviour settings. These values are stored only internally. Descendant integrated the setting dialog with application settings.

System settings also include proprietary dialog for password change. Although dialog might be implemented as a standalone dialog in the library, it was implemented together with the system dialog, because it is dynamically loaded library as well.

System role

System role has its own descendant that dynamically manages change of the tab visibility and right to access them. Functionality could be implemented without descendant with using only the universal detail functionality, however it is maintained as the simple example of the proprietary detail implementation.

Check the sysRole library for example with comments