When a grid (or form) pane is selected in the left 'Window Objects' pane of the Configure Window Objects dialog, the following groups of properties are available for configuration:

DataWindow or ServerDataWindow tab

Depending on whether the grid is a local DataWindow or a ServerDataWindow on the server, one of these two tabs will be available. The tab provides two panes: Form and Columns.

Form Pane

Properties

The upper, Form pane contains the following editable properties that apply to the whole object:

PropertyDescription
Data SourceThis indicates the object from which the data is being served. It can be a general java class such as DwGeneralForm which supports all the properties. However, it might also be an Oracle procedure in which case the fields will be fixed.
TableThe database table which will be updated if the data is edited, and from which the data comes (if the Data Source is a general java class).
UpdateableIndicates whether the data is editable or not. (Note that this is regardless of security settings. If this is switched off then the data will never be editable by any user.)
HiddenIndicates whether the object is visible or not.
Is Grid?When this check box is selected, the layout is a grid. When it is clear, the data is displayed as a form. (A "grid" layout shows multiple records in a table-like display; a "form" layout shows a single record at a time.)
Max RowsThe maximum number of records that may appear in the pane. Note: If the value is null, the maximum number of records is 10,000. If the value is zero, all records from the table are shown in the pane.
Sort StrConfigures how the records in the window are sorted. It is an SQL "order by" clause.
Retrieval ArgsProvides the retrieval arguments (column IDs separated by semicolons) pertinent to the table selected in the Tables pane. It is only applicable when the form is used for a linked pop-up window.
Where ClauseUsed to filter the records shown in the pane. It is an "SQL where" clause for the selected table in the Tables pane.
FilterableWhen this check box is selected, the columns in the table may be filtered via the Filter command in the right-click shortcut menus.
Access-regulatedWhen this check box is selected, the data in the table is automatically filtered to only those records where an "owner" column is the administrative unit you selected when you logged on.
Bookmark ColumnThis column specifies the internal column name by which bookmarks are set.
Default Column WidthSets the default width for the column. If it is left null, then the columns will be as wide as the column headers.
Can Reorder ColumnsWhen this check box is selected, the user can change the order of the columns without utilizing Design Mode and without affecting the order of the columns for any other users. (To move a column, the user clicks the column head and drags the column to the desired position.) The new order is retained after closing the window.
BeforeSave Script

Provides the ability to set a business rule (groovy script) that executes after a user clicks Save, but before the actual save operation (and after basic required-field and data-type checks). These scripts are usually used to verify changed rows prior to committing the data to the database. In technical terms, the data is saved to the database but not committed before this script is run. This allows you to create Groovy scripts that can query across any tables for validation purposes.

For technical information see: Advanced: Technical Information on Business Rules (Groovy Script)

AfterSave Script

Provides the ability to set a business rule (groovy script) that executes after a new row is inserted into the data pane. Typically, these scripts will set some default values in the row based on the user ID, the user's login administrative unit, or current date or time.

For technical information see: Advanced: Technical Information on Business Rules (Groovy Script)

Custom HTMLContains HTML code that customizes the appearance of the pane when in free form (single record) view (provided the pane is formatted via a CSS file). This code is activated dynamically. Note: To display the results of newly added HTML code, display the General Properties tab, click the Get CSS button, and then immediately click the Put CSS button. Then close the Change Control Properties dialog box, close the window, and re-open the window. The effect of the HTML code should be shown in the pane.
Columns HideableSets whether the user can hide columns (as a user specific setting).

Right Click Menu Actions

When you right-click a record in this pane, the system displays a shortcut menu. This menu contains the following special commands:

ActionDescription
Add Maintenance History Link

This command adds a Maintenance History column to the table (and to the Columns pane in the Data Window tab). This column contains a hyperlink that opens a new window that provides a log of maintenance that was performed on an inventory item.

Note: This command is not available if the column already exists in the table.

Add Record History Link

This command adds a Record History column to the table (and to the Columns pane in the Data Window tab). This column contains a hyperlink that opens a new window that shows changes that were made to the selected record.

Note: This command is not available if the column already exists in the table.

Create/Edit Script

This command displays a new window in which you enter a Groovy script or modify an existing script. These scripts are for server-side event handlers (mostly data checking routines) for BeforeSave and AfterSave events. After entering the script and closing the window, the new (or modified) script is available in the drop-down lists found in the BeforeSave Script and AfterSave Script columns.

Note: This command only becomes available when the cursor is in a script field.

Columns Pane

The lower, Columns pane shows the columns (fields) of the selected grid object. By default, this pane lists all columns (fields) that are in the table given in the Table property designated in the Forms pane. You may add or remove columns from this pane by utilizing the right-click Select Columns command. This in turn determines what columns are shown in the pane that you right-clicked to launch the User Control Properties dialog box.
Note: If the pane contains a column or columns that provide location information, see General Object Properties for more information.

Properties

The properties that are of particular importance are the following:

PropertyDescription
Change DDDWThis column is applicable only when the column contains a drop-down list and is used to filter the entries in the drop-down list. The Change DDDW column shows the "SQL where" clause that filters the drop-down list to just the desired items. (Note
Column IDThis column is the database column identification.
Column Label

This column is the description of the column that is used in the column heading of the window pane.

Note: The label may be edited to be more descriptive than the default label. The edited label will only appear in the window from which the Change Control Properties dialog box was accessed. (If you wish to return the label to its default version, clear the edited label from the Column Label column.)

Column WidthThis column sets the width of the column (in pixels).
CommentsThe text that appears in this column will be displayed as custom Help (along with the standard Help) when the user clicks the Help icon.
CopyableWhen this check box is selected, the data in the column will be copied to the new record that is inserted with the Insert Like command.
Custom HelpThis field shows the Help information that is displayed when the Enable Custom Help check box on the Window Properties tab is selected and the icon is clicked. You cannot edit or enter text in this field directly. Instead, you should right-click the field to display a shortcut menu and then select the Edit Custom Help command. This command displays a rich-text editor that you may use to compose Help information for the column.
Drop-down FilterableThis check box determines whether the items in the drop-down list in the column may be filtered. When selected, the items are filtered as the column is filtered. When clear, the list is not filtered (even if the column is filtered).
EditableWhen this check box is selected, data in the column may be modified (provided your security profile allows you to edit the data). When it is clear, the data is read-only. (Note
HiddenWhen this check box is selected, the column is not displayed. (While removing the column from the pane accomplishes the same thing, hiding the column allows you to easily re-display the column if you need to.)
Initial ValuePlacing a value in this column is optional. When a value is placed in this column, it is used to fill the column as each record is inserted.
Is LinkWhen this check box is selected, each value in the column is a hyperlink and displays a popup window or URL when clicked. To define the hyperlink, you use the following columns
Target Window IDThis column contains the WINDOW_ID of the pop-up window or the URL of the website that will be displayed when the hyperlink is clicked. (If the WINDOW_ID is not known, use the Setup Window Titles window in the System module, which shows the WINDOW_IDs for windows.)
Retrieval ArgsThis column provides the retrieval arguments (column IDs separated by semicolons) that are passed to the pop-up window and determine what is displayed in the window. These arguments may also be input parameters for the URL, with <1> indicating the first parameter, <2> indicating the second, and so forth.
Massive Updatable

When this check box is selected, the column will be updated when the Massive Update command is executed.

Note: If none of the columns have this check box selected, the Massive Update command will not appear in the shortcut menu that is displayed by right-clicking the window or pane.

Master Columns / Master WCThe list in a drop-down field may be configured to have different entries depending on the record selected. The Master Columns column contains the name of the column that is used to constrain what is shown in the drop-down list. The Master WC column supplies the where clause that sets what is displayed in the drop-down list.
Max RowsIf the column is a drop-down list, this column determines the number of entries in the list. If the value is null, the maximum number of entries is 10,000. If the value is zero, it is the actual number of entries (which may be greater than 10,000). Note
OnItemChange Script

This column provides a Groovy script that may be used to validate data and/or determine the value of other column(s) based on what is entered in a column. Click here for more information.

Note: The script is triggered when focus moves off of the column, not upon save. This means that if, for example, a column's value is determined from the values in two other columns and one of these values is null, the script needs to be written so that the third column's value is not generated until values exist in both of the other columns.

Note: Exercise care in creating scripts. This is a powerful feature and utilizing a large number of scripts will degrade performance.

For technical information see: Advanced: Technical Information on Business Rules (Groovy Script)

OnLinkClick ScriptThis column provides a Groovy script that executes when a user clicks a hyperlink..
OrderThis column sets the order of the columns within the pane (from left to right). If the table is created by a DW_ proc, this column is read-only.
RequiredWhen this check box is selected, data must be entered in the column. If data is not entered in the column, then when you try to save an error message will appear and the save will be disallowed.
Right to EditThis column determines the security level needed to modify data in the column. If this column is set to Null, then the security level for the window is used.
Right to SeeThis column determines the security level for viewing the column. If this column is set to Null, then the security level for the window is used.
Select StrThis column provides the SELECT statement calculation that defines this column's value. If the table is created by a DW_ proc, this column is read-only.

Right Click Menu Actions

When you right-click a record in this pane, the system displays a shortcut menu. This menu contains the following special commands:

ActionDescription
Select Columns

This command displays a new window in which appear all columns for the table shown in the Forms pane as defined in the Tables window. Select or de-select any set of column names by using the appropriate right-click selection commands. When you close the window, the set of columns in the Columns pane is adjusted accordingly.

Note: If the column is a list column, then all columns in the list column table are also available for selection and are shown as children in the list of all columns.

Note: Be careful in using the Select All command as it selects all columns including all child columns. Instead, the Select Visible Items command is generally used because it ignores these child columns.

Note: If you wish to include a column that is not in the table, use the Insert command. This command adds a new, blank record into which you may type the name of the column you wish to include.

Edit Custom HelpThis command displays a rich-text editor that you may use to compose Help information for the column. When you close the editor, the text will appear in this tab's Custom Help field.
Create/Edit ScriptThis command displays a new window in which you enter a Groovy script or modify an existing script. These scripts are for server-side event handlers (mostly data checking routines) for ItemChanged events. After entering the script and closing the window, the new (or modified) script is available in the drop-down list found in the OnItemChange Script column.
Renumber OrderThis command inserts values in the Order column for all columns that are not hidden. The values start at 10 and increment by 10 from the first record to the last record. (If values are already present in the Order column, these values are overwritten.)




  • No labels