Record Editors
Description
Data and its format in database is fixed. Overtime these data may need to change. It may be the format of one of the field or a new field may need to be added.
The Record Editors module allows you to manage the record editors created and edit the data records defined to be editable in the editors.
Features
- Add record editor
- Edit record editor
- Upload record editor
- Delete record editor
- Download record editor
- Refresh list
- Search
Module Interfaces
Interface | Description | Required Privilege |
---|---|---|
Record Editors | Allows Record Editors access | mod-record-editor |
Record Editors | Allowed to edit Record Editors | mod-record-editor-edit |
Record Editors | Allows Record Editors management access | mod-record-editors |
Add
To add a record editor, start by clicking on the “Add” button on the upper right corner of the page.
In the “New Record Editor” dialog box, set the properties for the new record editor.
Field | Description | Mandatory | Input Type | Constraints | Default Value |
---|---|---|---|---|---|
Name | Unique name assigned to the record editor. | Y | Text field | Any text (case-sensitive) | Empty string |
Copy From | Copy from an existing record editor or create a new one. | Y | Drop-down list | Select from list | “Blank Record Editor” |
Dataset | Defines the dataset to edit. | Y | Drop-down list | Select from list | None |
In “New Record Editor” dialog box, key in the name to be given to the record editor into the “Name” field. The “Name” field must be a unique value (not used by other record editors) and it is case-sensitive.
If an existing record editor is selected in the “Copy From” field, the “Dataset” field will use the property from the existing record editor and will not be available. If a blank record editor is selected in the “Copy From” field, select the dataset to be edited in the “Dataset” field.
Click on the “OK” button in the dialog box to create the new record editor. Clicking on the “Cancel” button aborts the action.
By default, the newly added record editor is enabled and is allowed to add and delete records. No fields from the dataset is added to be editable.
Refer to Edit Tabs for the details for the tabs and simple examples on how to use some of the scripts.
Do note that if an option is selected from the drop-down list for the “Workgroup” field at the top of the page, any record editor added to the management page will have the selected workgroup added to it. For example, if “Workgroup A” is selected, a new record editor “New-Editor” is added. “New-Editor” will have “Workgroup A” added to its properties.
Upload
To upload a record editor, start by clicking on the “Upload” button on the upper right corner of the page.
The “Upload” dialog box appears on the page.
Single File
Browse to the location of the file (<filename>.record-editor.json
) to be uploaded and set the “Name” field. By default, the “Name” field uses the name of the upload file. You can change it to an appropriate name if desired. If the file to be uploaded is to replace an existing record editor, select the “Overwrite” field. Do note that the “Name” field must be unique, or an error message will appear.
Field | Description | Mandatory | Input Type | Constraints | Default Value |
---|---|---|---|---|---|
Browse File | Browse to select file to be uploaded. | Y | Text field | Any text | Empty string |
Name | Unique name assigned to the file to be uploaded. When a file is specified in the above field, this field will automatically takes in the file name of the specified file. |
Y | Text field | Any text | Empty string |
Overwrite | If selected, overwrites existing record editor. | N | Checkbox | Select or not selected | Not selected |
Click on the “OK” button to upload the selected file. Click on the “Cancel” button to abort the action. A message will appear after the file has been successfully uploaded.
If the name of the record editor to be uploaded already exist, an error message will appear.
To overwrite the existing record editor, select the “Overwrite” field in the dialog box, then click on the “OK” button.
Zip File
Browse to the location of the zip file to be uploaded. The name of the record editors will be extracted from the zip file. Click on the “OK” button to upload the record editors. The “Upload Results” dialog box will display the results of the uploading.
Those results in black are uploaded successfully while those in red indicates upload failures with their relevant messages. Click on the “Close” button to close the dialog box.
You can arrange/sort the list of record editors in ascending or descending order by clicking on the name of the desired field. By default, the list is sorted by the “Name” field in ascending order.
Edit
To modify an existing record editor’s attributes, click on the “Edit” icon under the “Actions” column corresponding the desired record desired.
The “Edit” panel displays the selected record editor’s attributes and scripts in several tabs:
- Fields
- Properties
- Layout Scripts
- Row Scripts
Refer to Edit Tabs for the details for the tabs and simple examples on how to use some of the scripts.
Open Editor
To open the record editor, click on the name of the desired record editor under the “Name” column.
The Editor page will be displayed.
In this Editor page, you can edit the records, add new records, as well as delete a record. Do note that any disabled record editor will not be able to access the Editor page.
For more information on the Editor, see Editor.
More Actions
This feature allows user to perform actions on multiple record editors at the same time.
When the “More Actions” button located at the upper right corner of the page is clicked, a list of available actions are displayed.
If no record editor is selected prior clicking the button, there will be fewer actions available. To select a record editor, select the checkbox next to the name of the record editor.
Option | Description |
---|---|
Select All | Selects all record editors in the list. |
Select None | Unselects all record editors. |
Invert Selection | Inverts the current selection. That is, any record editors selected will be unselected and vice versa. |
Set Roles | Selects the roles to be assigned to the record editors. |
Set Workgroups | Selects the workgroups to be associated with the record editors. |
Download | Downloads multiple record editors as a zip file. If only one record editor is selected, the selected record editor will be downloaded as a JSON file. |
Set Enabled True | When selected, sets the selected record editors to enable. |
Set Enabled False | When selected, sets the selected record editors to disable. |
Set Roles
To set the roles for the selected record editors, click on the “More Actions” button and select the “Set Roles” option. The “Set Roles” dialog box will appear.
Select the roles to have access to the record editors by selecting the checkboxes. Alternatively, you can search for the desired role by keying in the keyword in the search function at the top of the dialog box. You can also choose to select all, select none or invert selection by clicking on their respective icons on the right of the search function.
Click on the “OK” button to save the changes or click on the “Cancel” button to abort the action.
Set Workgroups
To set the workgroups to be associated with the selected record editors, click on the “More Actions” button and select the “Set Workgroups” option. The “Set Workgroups” dialog box will appear.
Select the workgroups to be associated with the record editors by selecting the checkboxes. Alternatively, you can search for the desired workgroup by keying in the keyword in the search function at the top of the dialog box. You can also choose to select all, select none or invert selection by clicking on their respective icons on the right of the search function.
Click on the “OK” button to save the changes or click on the “Cancel” button to abort the action.
Download
To download the selected record editors, click on the “More Actions” button and select the “Download” option.
If only one record editor is selected, the downloaded record editor has a filename of <filename>.record-editor.json
.
If more than one record editor are selected prior, the “Download” dialog box will appear.
Key in the desired name for the zip file and click on the “OK” button. The selected reports will be downloaded as a zip file with the filename provided earlier. The individual report in the zip file will have the filename format as mentioned above.
Set Enabled True / False
To enable or disable the record editors, click on the “More Actions” button and select the “Set Enabled True” or “Set Enabled False” option respectively.
The selected record editors will be enabled or disabled as selected.
An enabled record editor is represented with a green tick under the “Enabled” column, while a disabled record editor is represented with a red cross.
Delete
Deleting a record editor removes it from the list.
To delete an existing record editor from Ambience, click on the “Delete” icon under the “Actions” column corresponding the desired record editor.
There is an option to undo the deletion. A notification with an “Undo” button appears right after clicking on the “Delete” icon.
Upon clicking on the “Undo” button, the deleted record editor is restored and is added back to the list. Do note that the notification will disappear after five seconds.
Refresh
After performing actions on the browser/tab, the list is reloaded to display the record editors. The manual “Refresh” button is available and is particularly useful if there are others making changes on the same page.
The “Refresh” button is found on the upper right corner of the page. Clicking on it reloads the list.
Workgroup
The “Workgroup” field at the top left corner of the page allows you to filter the records associated with the selected workgroup.
Simply select the desired workgroup from the drop-down list and the record associated with the selected workgroup will be displayed.
Do note that if no workgroup is created in the Workgroups module, the “Workgroup” field at the top left of the page will not appear.
Search
The search bar appears on the upper left corner of the page.
This provides an easy way to search through the list. It is case-insensitive and displays records that have the entered search value in any of the values of the fields below:
- Name
- Dataset
- Owner
- Workgroups
- Roles
- Last Modified
Alternatively, you can click on the any item under the “Owner”, “Workgroups” or “Roles” columns respectively to aid the search for the records in the page.
In the example above, record that is associated with the workgroup “GroupA” is shown.
These two search methods can be combined together, with each criteria separated by a comma.