Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
docs:3500:0800:0850 [2023/04/05 05:40] seandocs:3500:0800:0850 [2025/06/12 04:00] (current) – Change to AwareIM aware_support3
Line 1: Line 1:
-{{tag>}}+{{tag>Programmers_Reference Client_Side_Plugins Modify_Fields}}
 [<10>] [<10>]
 ====== Modifying default presentation of individual fields on forms ====== ====== Modifying default presentation of individual fields on forms ======
Line 5: Line 5:
 To modify the default presentation of an individual field on an object form you need to go to the presentation properties of the corresponding attribute and click on the "Advanced" property. There is only one script available for you here.  To modify the default presentation of an individual field on an object form you need to go to the presentation properties of the corresponding attribute and click on the "Advanced" property. There is only one script available for you here. 
  
-As explained in the "Architecture of the client-side code" the controller of the form prepares the HTML markup of the form as well as the list of Kendo UI widgets that the form includes. Apart from other things the markup of the form contains markups of individual fields present on the form. And the collection of widgets for the form includes widgets used by individual fields (note that not all fields use widgets, some use markup only). Each type of field on the form is represented by its own //**Aware IM**// Javascript object (see the table below).+As explained in the "Architecture of the client-side code" the controller of the form prepares the HTML markup of the form as well as the list of Kendo UI widgets that the form includes. Apart from other things the markup of the form contains markups of individual fields present on the form. And the collection of widgets for the form includes widgets used by individual fields (note that not all fields use widgets, some use markup only). Each type of field on the form is represented by its own //**AwareIM**// Javascript object (see the table below).
  
 The form controller asks every individual field on the form to prepare its markup and the collection of widgets. Then it assembles the result into the final markup and widget collection of the form. The script for each indivisual field is executed just before it is given to the form controller, so that the script has a chance to modify the markup or widget configuration. The form controller asks every individual field on the form to prepare its markup and the collection of widgets. Then it assembles the result into the final markup and widget collection of the form. The script for each indivisual field is executed just before it is given to the form controller, so that the script has a chance to modify the markup or widget configuration.
Line 11: Line 11:
 There are three objects exposed to the script: There are three objects exposed to the script:
  
-  "field" – this is Aware IM object representing the field (see the table below) +  "field" – this is AwareIM object representing the field (see the table below) 
-  "markup" – this is the HTML markup of the field (jQuery object) +  "markup" – this is the HTML markup of the field (jQuery object) 
-  "config" – this is the object that represents a widget configuration of the field or null if the field does not use a widget. The object has the following properties: +  "config" – this is the object that represents a widget configuration of the field or null if the field does not use a widget. The object has the following properties: 
-    "type" – type of the widget +    "type" – type of the widget 
-    "id" – the id of the element in the markup used by the widget +    "id" – the id of the element in the markup used by the widget 
-    "config" – the Kendo UI configuration of the widget+    "config" – the Kendo UI configuration of the widget
 You can modify modify any of these object. For example, if you want to hide the field you can write the following script: You can modify modify any of these object. For example, if you want to hide the field you can write the following script:
  
Line 39: Line 39:
 The following table lists all different field types and the corresponding Kendo UI widgets. The following table lists all different field types and the corresponding Kendo UI widgets.
  
-|**Aware IM attribute type**|**Kendo UI widget**|** Aware IM field object**||+|**AwareIM attribute type**|**Kendo UI widget**|** AwareIM field object**||
 |Plain Text (no choices, 1 line)|None|AwareApp_TextField| |Plain Text (no choices, 1 line)|None|AwareApp_TextField|
 |Plain Text (no choices, several lines)|None|AwareApp_TextAreaField| |Plain Text (no choices, several lines)|None|AwareApp_TextAreaField|
  • Last modified: 2023/04/05 05:40