Versions Compared
compared with
Key
- This line was added.
- This line was removed.
- Formatting was changed.
The <remform> tag allows you to add a form consisting of model attributes to the portal.
Placing more than one widget instance with the <remform> tag on a page is not recommended. Unlike the <rem> tag, <remform> is used only for creating a single record at a time.
Available attributes:
Attribute | Type | Mandatory | Description |
---|---|---|---|
isPortal | Boolean | N | Set the attribute to |
...
true to give the tag portal behavior and rendering. | ||
isUserScripts | Boolean | N |
...
To disable the client scripts execution, set the false value. The default value is |
...
true |
...
. | |||
modelId | String | N | Specify the ID of the RE model |
...
. | |||
name | String | N | This attribute stores the form name. Define the form name |
...
in the Template field:
|
...
Then, call it in the widget client script:
|
...
| |||
recordId | String | N | Specify an ID of an existing record to extend. |
saveButtonCaption | String | N | Specify the text displayed on the Save button. |
style | String | N | Specify the display settings (size, font, color, |
...
and others) of the |
...
tag elements using the CSS syntax. | |||
tableName | String | Y | Specify the name |
...
for which the extended record model was created. |
Examples:
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
<remform modelId="{data.model_id}" isPortal="true" tableName="rem_table" saveButtonCaption="Save" /> |
Code Block | |||
---|---|---|---|
|
...
| |||
(() => {
window.s_widget_custom = window.s_widget_custom || {};
const modelId = new URLSearchParams(window.location.search).get('model_id');
s_widget.setFieldValue('model_id', modelId); // Provide form of new record with model id
})(); |