Portlet Factory, Version 6.1.2


 

Data Column Modifier builder inputs

This topic describes the inputs for the Data Column Modifier builder.

 

General Inputs

Table 1. General Inputs
Input name Description
Name Name for this builder call. The WebSphere Portlet Factory Designer displays this name in the builder call list.
Container Field Select a field over which the data page repeats. For example, you might use the select box to choose a value similar to the following.
[page1]ShowData/RowSet/Row

 

Settings to control paging of the table data

Table 2. Settings to control paging of the table data inputs
Input name Description
Enable Paging Displays returned data in a paged format. A Paging Assistant builder is added to the model to implement paging.

Note: If you enable paging, specify the number of entries per page in the Page Size input.

Page Size

This input is available when you set the Enable Paging input.

Enter the number of records to fetch per page.

Check For New Data This input is available when you set the Enable Paging input.

Enable to test whether the underlying data changed before the next fetch from the data variable. If the data changed, the display is reset.

 

HTML Template File

The following input is not categorized.

Table 3. HTML Template File input
Input name Description
HTML Template File Select an HTML page automation template file that is used to generate all pages in the application.

 

Settings for Add and Delete Row Operations

Table 4. Settings for Add and Delete Row Operations inputs
Input name Description
Delete Column Style Choose a style for the delete column.

No Delete Column

Disables delete column functionality.

Link

A hyperlink is placed in each cell of the Delete column. If you select this choice, the Delete Link Text is available, in which you can enter link text.

Button

A button is placed in each cell of the Delete column. If you select this choice, the Delete Button Text input is available, in which you can enter text for the button label.

Checkboxes

A check box is placed in each cell of the Delete column. When a box is enabled, the row is deleted. Multiple rows can be selected for delete.

No column but generate Remove/Add methods

Adds delete functionality but no user-visible delete UI elements. You can call the generated delete and add methods manually.
Delete Link Text Enter the text to be used for the delete links.

This input is available if the Delete Column Style input is set to Link.

Delete Method Type

This input is available if the Delete Column Style input is set to a value other than No Delete Column. The Page Automation builder creates a delete column and a method. The Page Automation builder calls the method when the end-user specifies to delete a row, either by pressing the link or button or by checking the checkbox and submitting the page. The default behavior of this method is to delete just the row of XML (or the bean) in the variable. However, you can expand the scope of this operation to take some additional action. This input enables you to provide a method that is called with the information to identify the row that was selected for deletion. The method that you provide can indicate the row by one of the following means.

  • by Ordinal, a 1-based index that corresponds to automatic numbering of row

  • by Key field, the value of one of the columns

If your method calls a backend service and is about to refresh the data anyway, you can skip the automatic step of deleting the row of XML or the bean in the variable. When you choose which type of method you are providing, you also can specify whether the generated code skips the deletion with one of the following choices.

None (removes data from XML)

No method is being provided.

The row is removed from the variable.

by Ordinal (removes data from XML)

Deletes rows according to an integer 1-based value. The row is removed from the variable.

by Ordinal (skips remove step)

Deletes rows according to an integer 1-based value.

Removing the row from the variable is omitted.

by Key Field (removes data from XML)

Deletes rows according to a key field value. The row is removed from the variable.

by Key Field (skips remove step)

Deletes rows according to a key field value. Removing the row from the variable is omitted.
Delete Row Method This input is available if the Delete Column Style input is set to a value other than No Delete Column.

Specify a Java method that you provide to be called for the delete operation. This method can be created with a Method builder, Action List builder, or Linked Java Object builder.

Delete method arguments

The number and format of the arguments to the delete method are determined by the choice for the Delete Method Type input. For the Method builder, the method takes one argument in one of the following formats.

  • If you use by Ordinal, the argument must be an int format.

  • If you use by Key Field, the argument must be a String format.

For an LJO, the method can have one or two arguments. If it has a single argument, it must be of the type described for the Method builder. Alternately, you can make the first argument a WebAppAccess object and the second argument the type described for the Method builder.

Add Row Method This input is available if the Delete Column Style input is set to a value other than No Delete Column.

Specify a Java method to be used for the add row operation.

Key Field This input is available when the Delete Method Type input is by Key Field.

Select a column in the data table. The selected column is used as the key for the delete operation. This value is passed to the delete method.

Add Counter Column Adds a counter column to the table.
Add Columns Enter a comma-delimited list of column names to add to the table. You can act upon these new columns with other builder calls (for example, adding a Button or a Link builder) by the column name as the builder call page location tag value.
Manage Columns Accesses the column management functionality of this builder.

When this input is enabled, a column management table is displayed (see the Column Table input).

Note: If the database query is profile-enabled, you might not want to manage columns explicitly because the columns returned by the query can vary depending on user or role. If this is the case, consider using the Add Counter Column input.

Column Table Use the column table to define how to treat each column in the table. You can change the position of a column by dragging and dropping its row in the column table.

For each column in the row, the Data Column Modifier builder lets you define the following behavior.

Column Name

Read-only cell that indicates the name of column.

Status

Choose to hide or show the column. You can also designate the column to be a counter column, in which case the current row number is displayed as the value for this column.

Column Heading

You have the following options.

[Do Not Change]

Prevents the Data Column Modifier builder from setting the text of the heading and allows the value that comes from the Rich Data Definition (RDD) file to be used. This the default, which can be overridden by the following bowstreet.properties setting in override.properties.
bowstreet.dataColumnModifier.initializeHeadingToDoNotChange=false

[Blank]

If the heading is set to an empty string, this condition shows in the table as [Blank].

text

Specify text for the column heading to display something other than the column name as defined in the database or in the RDD file.

Column Width

Specify a number in pixels to determine the width of the displayed column.

Alignment

Specify one of Left, Center, or Right to define how values for the columns are aligned in the displayed table. If an HTML template specifies this setting, this input selection is ignored.

Column Sort Type

Whether the displayed column is to be sortable and what type of sort should be implemented.
Counter Column Head This input is available when the Add Counter Column input is enabled.

Use this input to identify the header of the column to use as the counter column

Place Added Columns This input is available when Manage Columns is disabled (not checked) and there is a value in the Add Columns input.

Select the location of the added columns.

Before Existing Columns

Added columns are placed to the left of existing columns.

After Existing Columns

Added columns are placed to the right of existing columns.

After "Delete" Column

Added columns are placed to the right of Delete column.

 

Settings to control when the table is empty

Table 5. Settings to control when the table is empty inputs
Input name Description
Empty Data Action Select what displays if there is no data in the table.

Display headers and an optional message beneath them

Show only the text for the table headings and text for a message if it is specified in the Empty Data Message input.

Hide entire table and optionally display a message

Do not display any of the table but display text for a message if it is specified in the Empty Data Message input.

Display a message and hide a custom location

Display text specified in the Empty Data Message input and do not display a specified location on the page.

This makes the Location to be hidden input available.

Empty Data Message Enter the text to be used for the message about empty data table or select a file that contains the text.
Location override for message Page location at which the empty data message is to be displayed. This location can be defined in the HTML template.
Location to be hidden This input is available if the Empty Data Action input is set to Display a message and hide a custom location.

Location on the page that is not to be displayed if the table of data is empty.

 

Advanced

Table 6. Advanced inputs
Input name Description
Flatten Groups Within Flatten complex structures that are returned by web services. If the model calls a web service that returns a complex result, for example, a nested structure, use this input to display that result as a simple structure on a page, for example, as a flat table.
Loop Variable Name Name of a variable that does not currently exist. The builder uses the variable to hold the row data while the page rendering is processing the repeated region. If this input is left blank, the variable name is the name of the container element (the last part of the value specified in the Container Field input) followed by LoopVar. Because the container element name is often Row, it can be confusing to have, in your model, names like RowLoopVar and RowLoopVar2. This input enables you to differentiate the variable names more clearly.
Counter Variable Name Name of a variable that does not currently exist. The builder uses it to hold the counter variable while the page rendering is processing the repeated region.
Paging Assistant Name Name of a variable that does not currently exist. The name is applied to the Paging Assistant Linked Java Object that is created to manage the paging for the table.

Parent topic: Data Column Modifier builder


Library | Support |