1. General information
1.1. Description of the control
History is a view table that shows changes to database records retrieved by a query from a database, with the possibility of searching and filtering records, and with the ability to export data.
- Besides the columns of the data source, the table offers the system columns of the history: “Date” (date of the change), “User” (login name of the user who performed the change), “Script” (source of the change), “Created” (record creation flag), “Deleted” (record deletion flag), “(ID)” (ID of the changed record) and “(PID)” (ID of the parent record).
- In the “Script” column, a change made by an edit form event script is shown by the form ID and the abbreviation of the event, for example “125/OBS” (“OAO” = OnAfterOpen, “OBO” = OnBeforeOpen, “OBS” = OnBeforeSave, “OAS” = OnAfterSave, “OBD” = OnBeforeDelete, “OAD” = OnAfterDelete), with a tooltip with the location of the form in the application and the name of the event. An entry about opening the record is shown by the abbreviation “OPEN” with the tooltip “OnOpen”, and a change made by a button script is shown by the numeric identification of the button (for an edit form button together with the form ID) with a tooltip with its location in the application. Other values are shown as they are stored. A detailed description of the history table and the stored values is provided in the separate guide Edit form.
- The displayed history records are limited by a time period selected above the table. The default time period starts with the value of the “From” field and ends with the value of the “To” field of the data source; if the “From” field is not filled in, it starts one month before today, and if the “To” field is not filled in, it ends on the last day of the current year.
- The time period applies to the date of the change. If the “Time span by” field is filled in in the data source, it applies to the value of the selected column in the history row instead, so history rows in which the value of this column is not stored – typically updates that did not change it – are not displayed.
- A deleted record can be restored from the history by clicking the value in the “Deleted” column in the row with the record deletion (tooltip “Restore record from history”) and confirming the question; the link is displayed to every user who can see the table. If a record with the same ID exists in the database table, the restore is not performed.
- Users with administrator privileges see the “Delete history” icon in the table header, which permanently deletes all history records matching the conditions of the data source, the current filter, search and time period, not only the records displayed on the current page.
1.2. Create a new control
A new history can be created as follows from the view page using the toolbar with controls:
- First, clicking on the view page determines the position where the new history should be placed. This will highlight the selected position with a gray horizontal line. Then just click on the “History” item in the toolbar of the view page, fill in the attributes of the new control in the newly opened dialog, and then save. This will insert a new history at a pre-selected location on the view page.
- If the desired position is not determined before inserting a new history, the new history will be inserted at the end of the view page.
1.3. Edit or delete a control
- For each existing control, a pencil icon appears to the left of the control page to change or delete the control's settings.
- Individual controls can be moved vertically on the view page using the Drag&Drop method. Moving consists of grabbing the control, preferably behind its name, and then dragging it to the desired location on the view page.
- Controls can be moved only with the “Drag&Drop” check box located above the toolbar with controls selected. For security reasons, this check box is cleared after each login to the application, so that a control is not moved by accident.
2. List of tabs in the control settings dialog
- General – Setting general properties
- View table – View table column settings
- Details – Settings for columns displayed in details
- Search – Search settings
- Rights – Rights settings
- Administration – Setting other properties
2.1. “General” tab
2.1.1. Name
- The name of the control displayed in the header of the view table.
2.1.2. Dictionary
- The dictionary lists the names of other controls, forms, view pages, categories, applications, and application groups used across the entire application.
- The dictionary search is used to design the correct control name and to maintain the consistency of the nomenclature throughout the application so that controls with the same meaning located in different places in the application are named in the same way.
2.1.3. Width
- The width of the control, expressed in pixels.
- If this input field is not filled in, the width of the view table will be determined automatically by the web browser.
2.1.4. Data source
- The data source defines the source database records displayed in the view table.
- Data source settings are made in the graphical designer of database queries. A detailed description of the database query designer is provided in the separate “Database Query Designer” guide.
2.1.5. Options
- Deny customization
- Checking this box determines whether individual users should be disabled from changing the column settings of this view table.
- Deny data export
- Checking this box hides the icon in the header of the view table that allows the displayed data to be exported to files. The denial is checked on the server as well; users with administrator privileges can still export data. A detailed description of data export from DataGrid is provided in a separate guide DataGrid data export.
- Deny opening records
- Checking this box determines whether all users should be denied access to the edit form to open the displayed database record using the pencil icon that appears at the beginning of each row of the view table.
- Show sums of columns
- Checking this box determines whether a row with the sum of the values of the individual columns should be displayed in the footer of the view table.
- This function is applied only to TextBox controls of numeric, currency and time data types and to AutoSum controls that do not have the “Hide the sum of the column in the view table” check box selected on the “General” tab.
2.2. “View table” tab
2.2.1. Options
- Show upper navigation toolbar
- Checking this box determines whether a toolbar with icons for switching between pages should be displayed in the header of the view table.
- By default, this toolbar is displayed in the footer of each view table if the number of data displayed is greater than the number of records on the page.
- Show filters
- Checking this box determines whether the view table should allow filtering of database records.
2.2.2. Columns
- Define the default settings of view table columns.
2.3. “Details” tab
2.3.1. Options
- Show details
- Checking this box determines whether the view table should display the details of each record at the bottom of the view table.
- Show tooltip
- Checking this box determines whether the view table should display the details of individual records in the tooltip when the mouse hovers over individual records.
- The tooltip is not displayed on a mobile device.
2.3.2. Columns
- Define the default settings for detail columns.
2.4. “Search” tab
2.4.1. Options
- Activate search
- Checking this box determines whether a row with a search box and a “Search” button should be automatically displayed in the header of the view table.
2.5. “Rights” tab
2.5.1. Rights
- Rights define a list of user groups and users who have permission to display the control on the view page.
- For a new control, the rights are prefilled from the control at the position selected before inserting it; if no position is selected, from the rights of the view page.
2.5.2. Replace rights to other controls
- The “Replace rights to other controls” feature is used to unify rights across the entire view page for controls that are related in terms of rights.
- Thanks to the “Show...” link, it is possible to display a list of all controls on the view page, including the setting of the rights of these controls. A check box is displayed for each control to select it. When the control is saved, the same rights are then set for the selected controls.
- An alternative for unifying rights within the entire view page is the overview of the rights settings of all controls, displayed by the “Show summary...” link on the “Rights” tab in the view page settings.
2.6. “Administration” tab
- The “Administration” tab is only displayed for existing controls.
2.6.1. Location
- Select the view page on which the control is located.
- The drop-down list contains the view pages located in the same application and in the same category as the view page on which the control stands. For a view page without a category, it offers only view pages without a category. For a new control, it contains only the current view page.
2.7. “Save”, “Save to all users”, “Delete”, and “Close” buttons
- “Save” button – Saves changes to the control settings together with the individual settings of the currently logged-in user.
- The columns on the “View table” and “Details” tabs and the “Show upper navigation toolbar”, “Show filters”, “Show sums of columns”, “Show details” and “Show tooltip” options from this dialog are applied to the individual settings of this history for the current user; the other individual settings of the current user, such as sorting, records per page, grid, search and the composed filter, are kept; the values selected in the column filters are deleted.
- Individual history settings can be opened using the gear-icon, which is available in the icon bar in the header of every history.
- Individual history settings include the following options:
- Options in the “General” tab of the individual history settings
- “Sort by”
- “Records per page”
- “Show upper navigation toolbar”
- “Show filters”
- “Show grid”
- “Show sums of columns”
- “Show details”
- “Show tooltip”
- Column settings in the “View table” tab of the individual history settings
- Column settings in the “Details” tab of the individual history settings
- Options in the “General” tab of the individual history settings
- All other users will retain their individual history settings. If the “Deny customization” box is checked, their individual settings are deleted in the same way as by the “Save to all users” button.
- “Save to all users” button – Saves changes to the control settings and deletes the individual settings of this history for all other users so that, upon the next display of the history, the default settings defined in this dialog are applied. The individual settings of the current user are updated in the same way as by the “Save” button.
- “Delete” button – Permanently deletes the control.
- “Close” button – Closes the control settings dialog without saving changes.