Portlet Factory, Version 6.1.2

 

Data Page builder inputs

 

+

Search Tips   |   Advanced Search

 

  1. General inputs
  2. Bean settings
  3. Created Element Settings
  4. Input Control Settings
  5. Required Fields and Input Validation Settings
  6. Label Translation Settings
  7. Advanced

 

General inputs

Input name Description
Name Name for this builder call. The WebSphere Portlet Factory Designer displays this name in the builder call list.
Variable Variable that contains or returns the data. For example, to specify the results of a service call, use the following indirect reference:

Variables/ServiceCallName_reply

Use the variable/schema chooser to specify one of the following as the variable:

  • Schema typed variable
  • XML typed variable
  • A schema
  • Create New Variable From HTML/From Input Elements
  • Create New Variable From HTML/From Input and Empty Span Elements
  • A variable name with a wildcard character

The Data Page builder supports Java™ Beans. If the variable supplied is of type Object, or a Linked Java Object not of type java.lang.xx (excluding java.lang.Object), Data Page builder introspects that Bean class (or collection of such) and displays the related inputs.

Page in Model Select the page in the model that is used to display the elements in the variable.
Page Type How elements in the variable are displayed on the form:

Infer from HTML

Allows the HTML page to determine whether an element is displayed as a form input or a read-only field. The Data Page builder reads the HTML directive of the field (input_<field_name>) to determine the field type.

Data Entry

Displays elements from the variable as form inputs.

View Only

Displays elements from the variable as read-only fields on the page.

 

Bean settings

Input name Description
Object Handling If the source variable is of type Object, this builder input appears. Specify how the runtime object is to be treated. Options are:

toString

Avoids Bean functionality and treats the objects as Strings in traditional Data Page builder fashion.

Bean

Specifies that the variable holds a single Bean at runtime.

Collection of Beans

Specifies that the variable holds a Java object of a type that extends Collection or Iterator.

The actual Bean class name being used is specified in the next builder input. If the source variable is of a type that extends java.util.Collection or java.util.Iterator, then Collection is implied and this input is not presented.

Note: If the source variable is not java.lang.xx and is not one that extends java.util.Collection or java.util.Iterator, a Bean class is assumed and neither the Java Class Name nor the Object Handling builder input is displayed.

Java Class Name This input is displayed if the source variable is of type Object or a type that extends Collection or Iterator.

Specify the real Bean class name so that the underlying Data Page builder functionality can introspect the class and determine available attributes and properties. Example:

com.bowstreet.qa.beans.OrgChart

Note: If the source variable is not java.lang.xx and is not one that extends java.util.Collection or java.util.Iterator, a Bean class is assumed and neither the Java Class Name nor the Object Handling builder input is displayed.

 

Created Element Settings

These inputs manage the behavior of page elements that are created from the schema. Elements are not created if their names match named elements that are already on the page.

Input name Description
Make UI from Data Add any tags that do not match existing HTML elements.

The following inputs are available when this input is selected: Location for New Tags, Use Theme, Generate Labels, and Add Names to HTML.

Location for New Tags

This input is available if the Make UI from Data input is selected.

Define the place on the page where any new tags to be constructed should go.

Use Theme This input is available if the Make UI from Data input is selected.

Set this input to use the properties specified in the default WebApp theme where applicable. Setting this input also overrides any related base page, HTML template, and style sheet inputs with values from the default WebApp theme. The related builder inputs are not available if this input is set.

HTML Template File

Select an HTML page automation template file that is used to generate all pages in the application.

Note: When an HTML template file is in use, a number of inputs that have to do with HTML class name generation are not displayed.

This input is available if the Use Theme input is clear. Any value specified here is overridden if the Use Theme input is set.

Style Sheet Override

File to be used to override the default style sheet from the HTML template.

This input is available if the Use Theme input is clear. Any value specified here is overridden if the Use Theme input is set.

Generate Labels This input is available if the Make UI from Data input is selected.

Specify that labels are generated with the UI control for the element.

Add Names to HTML This input is available if the Make UI from Data input is selected.

Determine whether the generated HTML elements are assigned names. You can choose:

Add Names

Automatically assigns element names.

Names are helpful if you add additional builders to modify the look and behavior of various elements.

Leave elements nameless

Omits assigning names.

 

Input Control Settings

These inputs do not apply to View Only pages.

Input name Description
Clear data before saving Have the variable that contains the form input values to contain only those values specified on the form. If the variable contains data, the Data Page builder call removes that data from the variable prior to storing the input values.
Infer Control from HTML Take the input type from that specified in the HTML source.
Enumerated Controls Default type for enumerated controls (for example, Select or Radio) that are not taken from the HTML source.
Enumerated Options Whether the options for enumerated control types should be determined by the schema, the HTML file, or a combination of both.
Initialize Inputs Control initialization if you have data field modifiers that assign an initial value to one or more fields.

Select one of the following to control when the initialization method is called:

On Model Load

Default behavior. Initialization method runs when page is loaded.

On Page Load (Except for Validation Errors)

If no validation errors exist when page is loaded, initialization method is run. Useful when working with a multiple page new-record creation form.

Never

Initialization method is never automatically called. Method (pagename_initialize) is automatically generated, but call it manually.

 

Required Fields and Input Validation Settings

Input name Description
Validate From Schema Use the type, required, and other schema information to determine whether input values are valid.
Post-Save Method Use this input if you have additional work that you want your code to do after the data is saved to your variable from RequestInputs. A Post-Save method can be a hook for you to add your own Java code for this process.

Note: You can add error messages for individual fields in your Post-Save method and control whether or not the Post-Save method is called when other fields have already failed validation.

Post-Save Method Behavior Select the behavior of the Post-Save method invocation. You can choose to:

Always call post save method

Method is called regardless of validation outcome.

Call Post-save only if all fields were valid

Method called if validation is successful.
Success Action Select the page, method, or other model action to execute when all input values are validated.

These entries are used in creating the method inputPage_NextAction, which you can see in the WebApp view. This method tests to see whether there were any validation errors for the page and calls the appropriate action.

Failure Action Select the page, method, or other model action to execute when input values are invalid. Typically, you want to set this to the action that displays the form. If you configured the form to display error messages, the messages are displayed as well.

Note: If you leave the Failure Action input empty, the default failure action is to return to the same page.

Full Error Location Enter the named location (<span /> tag) at which you want the general error message to appear.
Required Prompt Text Enter a character to denote a required field. The default prompt is an asterisk (*).
Required (*) Placement Select where to display the Required Prompt Text in relation to the field.

 

Label Translation Settings

Input name Description
Localized Resource This input is available when a Localized Resource builder is present in the model and positioned above the Data Page builder in the builder call list.

Specify the localized resource to use with this Data Page builder. You can choose:

Add a new Localized Resource to the WebApp

Specifies that a new resource bundle file is to be used by this Data Page builder. The other inputs in this group are available. You can create a new resource bundle or use an existing one.

Neither use nor create a localized resource

If you select this option, the other inputs in this group related to a localized resource are not available.

LocaleData

Uses localization information specified in the Localized Resource builder and stored in the variable created by that builder. (By default, this variable is named LocaleData, but that name can be changed.)

Other Data Page Builder Name

Additional selections are available when other Data Page builders are present in the model. Select one of these choices to use a resource bundle created by one of these Data Page builders.

Note: When specifying a Column Heading Resource Key, make sure the key contains only legal XML characters. For example, underscores are allowed in a key name but dots (.) are not.

Create Resource Bundle This input is available when Add New localized resource to WebApp is selected in the Localized Resource input.

Click Create Resource Bundle to create a properties file that contains the label name and default value for each element used in the form.

Include the .properties extension in the name you enter for the properties file. You can use this generated property file as the basis for creating the final resource bundle used by this page.

Resource Bundle Name Enter the fully qualified name of the property file or Java class that serves as the default resource bundle. For example, enter com.acme.LabelResources for the property file stored as WEB-INF/work/source/com/acme/LabelResources.properties
Resource Key Prefix This input is available if you are using a resource bundle, either by specifying one directly in the Resource Bundle Name input, or by referring to a Localized Resource builder in the model.

This input allows you to have a single resource bundle for an entire model, or even several models, while avoiding name conflicts. Enter a prefix to be placed before existing element names when applying that name to the resource bundle. Then all elements generated by this Data Page builder incorporate that prefix in their names.

For example, if the value in this input is DP3_ , and one of the elements generated by this Data Page builder is CUSTOMER, the resource key that this builder uses in the resource bundle is DP3_CUSTOMER.

Another Data Page builder in the model can also generate an element named CUSTOMER, and use the same resource bundle and access a non-prefixed resource key for CUSTOMER to avoid a name conflict.

Translate HTML-based labels Supports translation of label text in HTML content. The localization resource specified above is used as the basis for translation.

 

Advanced

Input name Description
Create Sample HTML Click Create Sample HTML to create an HTML page based on the elements in the variable and the Page Type that you specified. The Data Page builder saves the generated HTML file to the directory you specified when you click OK or Apply in the Data Page builder call editor.

Use this generated page to provide an HTML designer with a start to the final HTML page. Use an Imported Page builder call to import the generated page into the model.

Note: Create Sample HTML adds class names to certain types of fields. Use HTML Class Settings in Data Field Modifier builder to view a list of classes and the builder inputs that control the naming of them.

Note: Relative URLs (for example, those used to define images) that are imported during the course of this builder operation are converted to absolute URLs. This might preclude the use of images in certain situations.

Disable Submit Event Prevent the builder from running a submit event and saving data.

Disable this feature to allow an external event provided by the caller to determine control flow and resulting save behavior.

Parent topic: Data Page builder