Professional Documents
Culture Documents
Iga Form Builder
Iga Form Builder
2
Contents
1 Introduction 7
About Form Builder. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
How does the Form Builder Work? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
Launching the Form Builder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
5 Localization of a Form 25
Providing Translations of Form Field Labels . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
6 Troubleshooting 27
Using setFieldValue function in Logic is Not Supported on Radio Component . . . . . . . . . . . . . . . . . . . . . . . 27
Contents 3
JavaScript Code Defined in Custom Default Value Not Executed When the Component is Redrawn . . . . . 27
Unable to Overwrite the Calculated Value on Date/Time Component . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
A Appendix 29
Example of Creating a Form . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
4
About this Book
The Administrator’s Guide provides conceptual information about the Form Builder product. This
book describes how to work with the Form Builder product. It also provides step-by-step guidance
for creating forms using simple examples.
Intended Audience
This book provides information for individuals responsible for understanding the form building
concepts and using the Form Builder to create forms for their application.
Contact Information
Our goal is to provide documentation that meets your needs. If you have suggestions for
improvements, please email Documentation-Feedback@netiq.com. We value your input and look
forward to hearing from you.
For detailed contact information, see the Support Contact Information website.
For general corporate and product information, see the NetIQ Corporate website.
For interactive conversations with your peers and NetIQ experts, become an active member of our
community. The Net IQ online community provides product information, useful links to helpful
resources, blogs, and social media channels.
Forms are an integral part of any application that involves workflow process and data management.
Forms can range from simple surveys to complex resource management forms. Typically, forms are
embedded in workflows and connect to an API platform at the back end of an application, which can
make the overall form creation process complex and difficult. Moreover, integrating forms with
third-party servers and legacy systems increases the complexity. Form Builder simplifies the process
by making it a hassle-free experience for the application administrators.
The Form Builder allows you to design responsive forms that can be accessed by any application. It
provides all the basic and modern form building features, including the drag-and-drop interface, and
supports a rich set of user interface elements. Using the Form Builder, you can build, customize, test,
and deploy forms to an application. The application uses the Form Renderer component to render
these forms and generate corresponding APIs.
The application use forms at different stages of workflow process to collect the required information
and to execute relevant action for the fulfillment of the process. For example, roles and permissions
workflows often need a formal approval before they are provisioned to the users. The user requests
the role or permission by providing the required information through a request form. Once the
request is submitted, the approvers can approve or deny the request by providing the required
information through approval forms.
Introduction 7
How does the Form Builder Work?
Form Builder works as a service that provides form building capabilities to your application. For
example, the Form Builder service integrates with the Identity Governance to provide an ability to
customize the default forms or to create custom forms. You must be an authorized administrator to
build and design forms in Form Builder.
When the form is saved in Form Builder, a JSON schema is generated and stored on the Identity
Governance database server. The Form Renderer uses this JSON schema to render the form
dynamically within the application. The schema automatically generates the corresponding APIs to
pass the user and approver submissions to Identity Governance request and fulfillment workflows.
8 Introduction
2 Exploring the Form Builder User Interface
2
The Form Builder interface is simple, intuitive, and easy to use. The interface displays the required
form components, form component organization, and form component control type. You can simply
drag and drop the required form components into the workspace to design new forms. Every
component includes validation checks that are executed on both the front end and back end to
create a seamless user experience.
Form Builder user interface consists of the following elements:
Toolbar
Form Components
Workspace
Toolbar
You can locate the toolbar on the left pane of the Form Builder user interface. For a better view, click
the button to expand the toolbar and display the available options along with their labels.
The following options are available in the toolbar:
Tool Description
Form JSON Click to edit the form in the JSON editor. The editor
provides a JSON representation describing a fully-
featured form. You can also use the editor to
duplicate and edit an existing form. For more
information, see “Editing a Form in the JSON Editor”
on page 18.
Form Components
Form components are used as building blocks to create forms. A form component collects user data
and serves as the display or user interface within the system. Form components help you to define
the type of widget that is required to enter data and automatically adds a property to the resource
endpoint to interact with the form component. Each component includes functionality that enables
you to design form fields according to your requirements.
Form Builder provides a wide range of components for creating forms. You can use these
components to create a variety of forms, ranging from simple survey forms with basic form fields to
complex resource management forms with dynamic form fields, where scripts can be executed for
validation checks, and actions can be triggered when a form is submitted.
Form components are grouped into the following five broad categories:
Basic: Includes a set of common components that can be used to design simple widgets in a
form.
Advanced: Includes a set of components that can be used to design widgets with advanced
fields in a form.
Custom: Includes a set of components that allows you to design labels and titles in a form.
Layout: Includes a set of components that can be used to change the general layout of a form.
Data: Includes a set of components that allows you to customize the data layout in a form.
Basic Components
When you select Basic, the Form Builder displays the following components:
Text Field
Text Area
Number
Password
Checkbox
Advanced
When you select Advanced, the Form Builder displays the following components:
Email
URL
Phone Number
Tags
Date/Time
Day
Time
Currency
Survey
Signature
Custom
When you select Custom, the Form Builder displays the following components:
Label Element
Title Element
Layout
When you select Layout, the Form Builder displays the following components:
HTML Element
Content
Columns
Field Set
Panel
Table
Tabs
Well
Workspace
Workspace is the part of the Form Builder user interface where you drag and drop the components
to add new fields into the form. When Form Builder is launched, the default view shows a set of
predefined fields in the request or approval form in the workspace area.
Display Tab
The settings available on the Display tab define how a given component appears on the form upon
rendering.
The following elements are listed on the Display tab for a Text Field component:
Label
Label Position
Label Width
Label Margin
Placeholder
Description
Tooltip
Prefix
Suffix
Widget
Input Mask
Data Tab
The settings available on the Data tab allow you to define the default value and how the component
appears on the form.
The following elements are listed on the Data tab for the Number component:
Multiple Values
Default Value
Use Thousands Separator
Decimal Places
Require Decimal
Input Format
Redraw On
Clear Value when Hidden
Custom Default Value
Calculated Value
Allow the calculated value to be overridden manually
Validation Tab
The settings available on the Validation tab allow you to add validation checks on the component.
You can set the component as mandatory to ensure that the user fills it before submitting the form.
The following elements are listed on the Validation tab for the Select component:
Validate On
Required
Error Label
API Tab
The settings available on the API tab allow you to define the property name and configure any
custom properties for the selected component.
The following elements are listed on the API tab for the Phone Number component:
Property Name
Field Tags
Custom Properties
Conditional Tab
The settings available on the Conditional tab allow you to determine the conditions for displaying or
hiding the selected component in a form. You can define a simple conditional logic based on the
following rules to determine when to hide or display the component:
Select True to display the component or False to hide the component.
The visibility depends on another component within the same form.
The logic is activated when the dependent component contains the defined plain text value.
In addition to simple conditional logic, you can also use advanced conditional logic, which allows you
to enter custom JavaScript code or custom JSON logic for any combination of conditions.
Advanced conditional logic will override the results of the simple conditional logic.
Logic Tab
The settings available on the Logic tab allow you to define and configure multiple logic and actions
for the selected component, which helps you design a form that can perform certain defined actions
for the defined logic.
Layout Tab
The settings available on the Layout tab allow you to define the HTML attributes for the component
and map those attributes with the component’s input element. You cannot edit the component type
from the values you specify in this tab. For example, if you select a Text Field component, you cannot
change the component type to a different value such as a Checkbox.
Using Form Builder, you can either create custom request and approval forms, or customize the
default forms that comes with the application. Let us understand how to perform both these
operations in the Form Builder through the Identity Governance application.
TIP: Click Add Another button to add new label and value fields.
5. (Optional) Verify the Laptop Type drop-down list functions correctly in the Preview area.
6. Click Save.
7. To add choices for laptop color, drag and drop the Select Boxes component into the workspace.
function laptopType_CustomDefaultValue () {}
function laptopType_CalculateValue () {}
2e Configure the custom default value as:
function laptopType_CalculateValue () {}
TIP: You can use the IG Request option to add the context.flowdata.laptopType;
flowdata. Click IG Request > Flowdata, and select Laptop Type.
2f Click .
function choiceOfColor_CustomDefaultValue () {}
function choiceOfColor_CalculateValue () {}
3f Configure the custom default value as:
function choiceOfColor_CalculateValue () {}
3g Click .
4 Click to preview the form.
5 Click on the Home screen.
NOTE
You can use the Simulate Request Workflow option to review the form fields by simulating the
requester and approver action.
In the Form Builder, you can create inline scripts that can be used as helper functions. Be aware,
however, that since these inline scripts are published to the global javascript context,
unexpected results may occur. One example of this is in the compare to draft to published area,
where one has two forms up at the same time. In this case, both forms will end up sharing the
same inline function, even if the definition of the function was different between the draft and
published form.
Editing a Form
You can edit a form as follows:
“Editing a Form Using the Form Builder User Interface” on page 18
“Editing a Form in the JSON Editor” on page 18
“Editing a Form in the JS Editor” on page 19
NOTE: You can move the components across the workspace in a form. Select next to the
component you want to move, drag and drop it to the desired location.
TIP: Do not directly edit the form in the JSON editor unless you are very comfortable using the editor.
You must make a backup of the form before editing it.
The example form described in the “Example of Creating a Form” on page 29 can be designed using
the JSON editor as well.
You can use the same JSON schema to duplicate the form. You can make edits to the form using the
JSON editor directly.
instance.setFieldValue(response.attributes,'attributeKey','displayName');
}, function(err) {
console.log(err);
});
}
The following section discusses different ways to use the IG Request attributes:
“Using Flowdata Attribute to Pass Data from Request to Approval Form” on page 20
“Requesting Resource from Identity Governance REST API” on page 21
“Requesting a Resource From an External API” on page 22
function(response) {
instance.setFieldValue(response.principal);
},
function(err) {
console.log(err);
});
You can edit the endpoint and response in this sample method to retrieve the desired resource from
the Identity Governance REST API. For example, if you want to create a drop-down list using the
Select component in the Form Builder, the options in this list should be fetched dynamically from the
Identity Governance REST API. To accomplish this requirement, perform the following actions:
1. In Form Builder, go to Basic Components, then drag and drop the Select component into the
workspace.
2. On the Display tab, type Group Attributes in the Label field.
3. On the Data tab, select Asynchronous API as Data Source Type.
4. Click Save.
5. Open the JS Editor and look for the following function:
function laptop_CustomDefaultValue () {}
function laptop_CalculateValue () {}
6. Configure the custom default value as:
function laptop_CustomDefaultValue () {
utils.get('','/api/dcs/schema/GROUP', '', '',
function(response) {
console.log(response);
instance.setFieldValue(response.attributes,'attributeKey','displayName
');
}, function(err) {
console.log(err);
});
}
NOTE: The request made to the Identity Governance REST API server will add the OAuth header
automatically.
8. Click and verify that the options are listed under the Group Attributes drop-down list.
You want to create a drop-down list using the Select component, where the options in the list are
fetched from a file <filename>.json which is hosted on AWS. While requesting the file, you want
to ensure that the component does not add an OAuth header in the URL. To accomplish this
requirement, perform the following actions:
1. In Form Builder, go to Basic Components, then drag and drop the Select component into the
workspace.
2. On the Display tab, type Laptop in the Label field.
3. On the Data tab, select Asynchronous API as Data Source Type.
4. Click Save.
5. Open the JS Editor and look for the following function:
function laptop_CustomDefaultValue () {}
function laptop_CalculateValue () {}
6. Configure the custom default value as:
function laptop_CustomDefaultValue () {
$.get(url,
function(response) {
instance.setFieldValue(response.laptops, 'value', 'label');
function laptop_CalculateValue () {}
7. Click .
8. Click and verify that the options are listed correctly under the Laptop drop-down list.
Forms created in the Form Builder are rendered on the application through a Form Renderer. The
Form Renderer uses the form JSON schema to render the forms dynamically on the front-end of the
application. The schema automatically generates the corresponding APIs to receive the data when
the form is submitted. Form Renderer uses custom CSS styles specific to the application to render
the default look and feel of the form.
The purpose and usage of forms created using the Form Builder varies with the audience and the
application where it is embedded. Form Builder offers the capability of translating forms into the
language of your choice. The built-in Localization option provides multiple language support for
translating forms. You need to provide the translated values for the label key and value in the
preferred language, and the resulting form will be rendered on your application in the language set
on the browser.
The following languages are supported:
Chinese (Taiwan)
Chinese (China)
Swedish
Russian
Portuguese
Polish
Dutch
Norwegian
Japanese
Italian
French
Spanish
German
Danish
English
Localization of a Form 25
NOTE: When creating or editing a form in Form Builder, some field and button labels in the Editing
pane appear in English, rather than language selected for localization. The completed form will be
correctly localized, however. You can click on the left navigation to verify that the form is correctly
localized.
26 Localization of a Form
6 Troubleshooting
6
The following section contains information about troubleshooting the issues when the Form Builder
or its component may not function as intended.
},1000)
}
function radio_CalculateValue () {}
function fetchValuesForRadio(){
return ['1','2''3','4'];
}
Troubleshooting 27
Unable to Overwrite the Calculated Value on Date/Time
Component
Issue: On Date/Time component, when you define a JavaScript code using moment() function to
calculate the date and time based on user input in the Number component, the value is calculated as
expected. However, if you select the Allow the calculated value to be overridden manually check box,
you will not be able to change the calculated value in form preview mode. This issue occurs because
the time is updated continuously on the Date/Time component, which does not allow the calculated
value to be overwritten manually.
Workaround: You can resolve this issue by using the startOf('day') or endOf('day') function
in the code to ensure that the set time does not change when the value is calculated on the Date/
Time component. Perform the following actions:
1 From the Basic Components, drag and drop the Number component into the workspace, then
provide a label in the Label field and click Save.
2 From the Advanced components, drag and drop the Date/Time component into the workspace.
3 (Conditional) To set the time to 12:00 AM (start of day), click the Data tab and provide the
following JavaScript code in the Calculated Value field:
value = moment().startOf('day').add(data.number, 'days')
4 (Conditional) To set the time to 11:59 PM (end of day), click the Data tab and provide the
following JavaScript code in the Calculated Value field:
value = moment().endOf('day').add(data.number, 'days')
5 Select the Allow the calculated value to be overridden manually check box.
6 Click Save.
28 Troubleshooting
A Appendix
A
The following section provide additional reference information and advanced topics for the Form
Builder.
Select the required widgets, drag and drop them into the workspace, and configure the settings. The
following table lists the components and settings used to create the registration form:
Appendix 29
Field Name Component/Widget Settings Reference
Used
Enter the patient Label Element (Custom) On the Display tab, type For more
details below Enter the patient information, see
Used to add a non- details below: in the Label Element.
editable, information- Label field.
only field in the form.
Select the Hide Colon check
box to hide the colon symbol
next to the label.
Patient Name Text Field (Basic) On the Display tab, type For more
Patient Name in the Label information, see Text
Used to provide a text field. Field.
input field in the form.
To mark this component as
mandatory in the form, go to
the Validation tab and select
the Required check box.
Gender
Age
Type of patient
Registration Number
Age Day (Advanced) On the Display tab, type Age in the For more
Label field. information, see Day.
Used to allow the user to
input their date of birth in
month, day, and year
format.
30 Appendix
Field Name Component/Widget Settings Reference
Used
Type of patient Radio (Basic) On the Display tab, type Type For more
of patient in the Label information, see
Used to provide a list of field. Radio.
two or more options that
are mutually exclusive. On the Data tab, add the first
The user will be allowed Label as New and the second
to select only one option as Existing.
from the list.
Registration Number Number (Basic) On the Display tab, type For more
Registration Number in information, see
Used to restrict the user the Label field. Number.
to input a numerical
value. To add an instruction which
will appear when the field is
empty, type (Applicable
for patient who has
an existing
registration number.)
in the Placeholder field.
Select the Select (Basic) On the Display tab, type For more
Department Select the Department information, see
Used to provide values in the Label field. Select.
that will display as
options in a drop-down On the Data tab, select the
list for selection. Data Source Type as Values.
Add the following labels in the
Data Source Values field:
1. Cardiology
2. Neurology
3. Oncology
4. Obstetrics
5. Gynecology
Appendix 31
Field Name Component/Widget Settings Reference
Used
Choose a Doctor for Select (Basic) On the Display tab, type For more
Consultation Choose a Doctor for information, see
Used to provide values Consultation in the Label Select.
that will display as field.
options in a drop-down Values populated in
list for selection. On the Data tab, select the
Choose a Doctor for
Data Source Type as Custom
Consultation field
and provide the following
depend on the user
logic in the Custom Values
selection in the
field: Select the
let dept = Department field.
data.selectTheDepartme Use the JS Editor to
nt; define the logic to
let choices = calculate the value in
getDoctors(); this field. For more
let optionsToSet = []; information, see
for(let i=0; i < “Editing the Hospital
choices.length; i++){ Registration Form
Using JS Editor” on
if(choices[i].departme page 33.
nt == dept) {
optionsToSet =
choices[i].doctors;
break;
}
}
values = optionsToSet;
Appointment Date Date/Time (Advanced) On the Display tab, type For more
Appointment Date in the Label information, see
Used to allow the user to field. Date/Time.
input either a date or a
time or both, as desired.
Mobile Number Phone Number On the Display tab, type Mobile For more
(Advanced) Number in the Label field. information, see
Phone Number.
Used to allow the user to
enter a phone number in
the form.
Enter patient’s Text Area (Basic) On the Display tab, type For more
complaint/problems Enter patient's information, see Text
here Used to provide a multi- complaint/problems Area.
line input field in the here in the Label field.
form that enables the
user to enter longer text. On the Validation tab, add the
Maximum Word Length as
200.
Submit Button (Basic) On the Display tab, type Submit in For more
the Label field and select the information, see
Used to perform actions Action as Submit. Button.
within the form.
32 Appendix
Field Name Component/Widget Settings Reference
Used
Reset Button (Basic) On the Display tab, type Reset in For more
the Label field and select the information, see
Used to perform actions Action as Reset. Button.
within the form.
TIP: Each component has a Preview area on the right hand side that displays how the form would render
when you make the changes or edits to any field.
You can create or make edits to an existing form using the JSON or JS editor. For more information
about using the JSON Editor, see “Editing a Form in the JSON Editor” on page 18.
To define the logic for the Choose a Doctor for Consultation field:
function getDoctors() {
return [
{department: 'cardiology', doctors : ['Dr. Adam Hasting','Dr.
Raymond Chase']},
{department: 'neurology', doctors : ['Dr. Robert Calling','Dr.
Homes']},
{department: 'oncology', doctors : ['Dr. Steve Lambart','Dr.
Shyama Mukerjee']},
{department: 'obstetrics', doctors : ['Dr. Daniel Cruise','Dr.
Angelika Sun']},
{department: 'gynecology', doctors : ['Dr. Katie Homes','Dr.
Ludwig Cunnings']}
]
}
3 Click to verify the behavior of the two form fields and preview how the final form would
appear after rendering.
4 Click on the Home screen.
Appendix 33
34 Appendix