Widget Displaying
Widgets contain client and server logic, template, and styles. For the real interaction, it is required to place an implemented widget on a specific object. In SimpleOne, you can place a widget on a record form or on a portal page.
Add a widget on a record form
Forms display a set of fields of various types. Forms can also include widgets.
Before adding a widget to a form, configure it. To do so, complete the following steps:
- Create a widget. See the Widget Scripts article to learn how to create it.
- Define the behavior and appearance of the widget, define its server and client logic.
- Specify the tables of the records where a widget should appear. These tables can be selected in the Tables field of the widget creation form. To display a widget on the records of the child tables, use the Inheritance attribute.
- Add a widget to a form using the Form Layout base functionality.
For example, you need to create a widget to be displayed on records of all child tables of the ITSM Task table (Incidents, Change Requests, Problems, and so on).
When creating a widget, specify the ITSM Tasks table in the Tables field and select the Inheritance checkbox. The widget will be displayed on records of the ITSM Task table and its child tables.
Add a widget on a portal page
To place a widget on a portal page, use the Widget Instances (sys_widget_instance) table. These elements define a specific location of widgets according to the portal column specified, and customize the widget options with the option schema.
To configure widget displaying, complete the steps below:
- Navigate to Portal Structure → Widget Instances.
- Click New to create a new widget instance record.
- Fill in the fields.
- Click Save or Save and exit to apply the changes.
Widget Instance form fields
Field | Mandatory | Description |
---|---|---|
Widget | N | Select the widget you need to display. |
Page column | N | Select a page column you need to add a widget to. This field will be prefilled if you reach this form from the Related Lists area of a Page Column record. |
Option values | N | Fill in the field with widget overridden options. |
Active | N | Select this checkbox to activate this widget instance. |
Public | N | Select this checkbox to make this widget instance available to unauthorized users. |
Order | N | Specify the order of the widget in the portal column. |
The new widget instance record appears in the Related Lists area of the Widget record and the Portal Column record forms.
If you have multiple instances of the same widget, adjust their options to distinguish between them. For more information, see the Page Structure article.