• No results found

G r a p h i c a l A p p l i c a t i o n D e v e l o p m e n t w i t h B o n i t a S t u d i o

N/A
N/A
Protected

Academic year: 2021

Share "G r a p h i c a l A p p l i c a t i o n D e v e l o p m e n t w i t h B o n i t a S t u d i o"

Copied!
21
0
0

Loading.... (view fulltext now)

Full text

(1)

Contents

1. Introduction

2. A Simple Process in Bonita Studio

3. Defining and Customizing the Fields of a Form 4. Adding a Customized Confirmation When a Form is Submitted

5. How Forms are Built in Bonita Open Solution 6. Anatomy of a Form Presented in a Web App 7. Defining the Global Page Template

8. Defining the Template for the Web App 9. Conclusion

1. Introduction

Bonita Open Solution is a 3-in-1 suite composed of:

 Bonita Studio, an integrated process-based application builder based on BPMN2 modeling and drag-and-drop form customization,

 Bonita Execution Engine, a powerful and scalable BPM engine, and  Bonita User Experience, a breakthrough end-user interface.

Bonita Studio is used to graphically model a business process with BPMN notation and

generate a process-based application designed to automate this process. Bonita Studio’s Whiteboard allows the process designer to draw the process flow graphically, and apply connectors to connect the process to external information systems such as database, email, calendar, LDAP, ERP and so on. Various forms of data can be defined to be input, acted upon, passed along, and output throughout the process.

In addition, “human” steps in a process require interaction with an end user. This interaction generally takes place through a web application composed of a set of forms presented in a web browser, allowing process actors to perform the required tasks to complete process cases.

The Web Application Builder in Bonita Studio allows the designer to create customized forms for the end user. This white paper describes an example of how this can be done. The Web Application Builder allows the user to create the list of variables accessible from a step, and specify how they can be updated.

(2)

2. A Simple Process in Bonita Studio

To illustrate how forms are built and customized, this paper will refer to a very simple process example: New Employee Start.

Figure 1. A simple 2-step process to start a new employee

In this process, the initiator is a newly hired employee who is returning a signed employment contract. Thus there is a form presented via a Web interface which is completed by this new employee.

In the first step, Human Resources receives the information, and adds the start date. In the next step, another HR agent receives this information and then sends a letter to the

employee to indicate when he/she should report for their first working day.

Thus there are 3 forms needed: an initial form, a form for the step Receive new employee and a form for the step Send confirmation/welcome letter.

Before forms can be created, the data for the process must be defined. In this process there are 7 global variables and one local variable. Each variable name is followed by its type (Attachment, a List of Options titled Department, Text, Date, and Boolean.)

(3)

Figure 3. Local variable

At each step in a process where a person is involved (i.e. a Human Step in Bonita Open Solution), Bonita Open Solution automatically creates a default Bonita Form with fields based on the data variables defined. The Process designer can then customize these forms.

3. Defining and Customizing the Fields of a Form

The arrangement of fields in a form is generated at the step level. The first things to do when customizing a Form are to define which fields it will contain, decide what variables are to be

associated with those fields, and determine how the fields should be arranged. The Web Application Builder in Bonita Studio provides a set of widget tools for this.

The following Figure shows that the designer can begin by choosing which data variables are to be given fields in the initial form. The Web Application Builder then adds widgets based on the variables selected.

< Figure 4. Create a New Form by selecting which field widgets to add

(4)

The Web Application Builder allows the designer to manipulate fields in the form of cells in a grid. The data variables selected are presented first as a series of cells in a single vertical column. Web Application Builder adds a Submit button at the bottom of the column.

Figure X. Using the Web Application Builder

The field cells can be re-arranged. Rows and columns can be added and deleted; cells can be moved and merged.

The field labels can be customized, so the end user sees a descriptive label instead of the variable name.

(5)

Figure 5. Form fields can be rearranged and given descriptive labels

Forms can be previewed. This initial form, in Preview mode, shows which variables are defined for which fields (this is not seen in the final version – see the difference between this and Figure 18.)

(6)

characteristics of form fields. In this section, the Form designer can:

• Label a field (static labels are shown in Figures 5 and 6, above). Labels can also be dynamic, defined with variables that will be filled at runtime, by applying a

Groovy expression.

• Restrict the type of data a field will accept by applying a validator, as shown in Figure 7 below).

Figure 7. A validator added to a field restricts the type of input it will accept

The designer can also apply the following, some of which are shown in the next figures. These examples are from the second form in this process:

• Add a tooltip on any field (Figure 8); • Change the field type – for example:

o from one that is “live” to one that is “read-only” (Figure 9); o from a dropdown list to a set of radio buttons (Figure 10); o from an upload (“live”) to a download (read-only) (Figure 11);

• Define the variable or data the field is to enter, process, and/or output (Figure 12);

• Change the appearance of an individual cell, label, or field (Figures 13-15); and • Change or remove the name of the form, including a dynamic variable if desired

(see Figure 19). Dynamic variables like the one applied in the title of the form (“Assign a start date to ${newEmployeeFirstName} + ${newEmployeeLastName}”) can also be applied in any of the form labels.

(7)

Figure 8. Add a tooltip to a field

Figure 9. Change a “live” field (text) to “read-only” field (TextArea)

(8)

Figure 11. Change an attachment upload to a download only

Figure 12. The data management editor is used to

(9)

Figure 13. The Groovy editor is available in form fields (and for variable definition, labels, validators, and more) to allow the use of dynamic expressions

Defining the variable or data that each field in a Form is to enter, process, or output is a critical application of the Web Application Builder. Each field widget presents options specific to each type of data field, and most allow the From designer to specify what variables the field will accept, validate the type of input, choose a default value, and manipulate that data in an expression (ie concatenate, apply operators, and so on). The Figures above show an example of a text field that takes the variables

newEmployeeFirstName and newEmployeeLastName, concatenates them and saves the result as a new variable newEmployeeName. (See Figure 19 and 20 which show two different examples of a dynamic label in a form as it is presented to an end user).

(10)

Figure 14. Change the appearance of a date field

Each field widget allows for some fine tuning the grids, and the appearance of cells, grids, labels, and field contents.

Figure 15. Change appearance of field label

(11)

Here’s a look at the 3 forms defined in this process:

(12)

Figure 19. Form presented at first step (dynamic label circled)

(13)

Figure 21. The first page of a multi-page form

Each page of a multipage form has a Next Page and/or a Previous button. The last page has the Submit button to complete the form. Buttons can be re-named.

(14)

4. Adding a customized confirmation page

A “confirmation page” is shown at the end of each user’s sequence of steps, that is, after the last form for that user to complete – in a series of one or more steps – has been submitted. The contents of this page can be easily modified. (Its look-and-feel can be further

customized as described in the following sections.)

Figure 23. Confirmation page with customized message

5. How forms are built in Bonita Open Solution

The end user interface (form) can be designed and customized in the following ways: • Customize the fields and contents of a Form for a step (in what order the fields are

presented, how the fields are labeled, the characteristics of the fields such as read-only, image, text, and so on). This is described in Section 2.

Further customize the layout of an step Form by modifying or replacing the Global

Page Template; and/or by modifying or replacing the html template for the individual

form; and/or

(15)

Figure 24. default Bonita Open Solution Form (uncustomized form in default page and Process templates) At this stage, the user form is not very useful! Some customization will result in a form with just the fields wanted with the appropriate options to complete or see them. More

customization will result in a form with the look-and-feel desired.

Each Form created for a Step has essentially 3 levels that define its look-and-feel. The following illustrations show how those 3 levels come together.

The Figure below shows the Process Template around the Global Page Template.

Figure 25. Process (Web application) template Process Template (Web application)

Global Page Template

goes here

(16)

Notice that the Process Template here has:

• a black exterior frame with a link to open Bonita User Experience; and

• a grey-and-white interior frame with the Bonita Open Solution name and logo, the name of the user (admin), a link to log out, the process name, and a message at the bottom.

In the next Figure, the form data fields have been selected and customized as described in Section 2, the Bonita Global Page Template has been applied, and all of this is presented in the Process Template.

Figure 26. Customizable Page template

The following sections describe how it is possible to further customize these templates.

7. Defining the Global Page Template

When the fields of the Form(s) for a step are defined, a default page template is generated by Bonita Open Solution and linked with an html file that directs how the Form is to be displayed inside the Global Page Template.

This can be modified in Bonita Studio Web Application Builder. The Web Application Builder permits the download of the default Page Template – the designer can save the generated html file for modification and re-upload.

Step level page template = Step Form + Global Page Template

(17)

Figure 27. Download form template generated by Bonita Open Solution

Individual page Forms are generated with a unique bonita_form_container code, according to how the fields have been defined in the Web Application Builder.

For each data field in the Form, the html file contains a <div id> with its name as the “id”. (Validators, if used, also have <div id> with the data field name and “validator”.) All of these must be included in any modified html code in order to display the form fields as desired. The entire Form is displayed inside the Process level template where

<element ID=”bonita_form”> </div>

is located.

The designer can save the generated html file for modification and re-upload.

A new Global Page Template can be created by re-uploading the modifed html file (in

Applications.)

(18)

and instead modify the Process Template.

8. Defining the Process Template for the Web Application

The built-in, default template in which all Forms are presented is an html file called at the Process level. Five built-in process templates are provided in Bonita Open Solution. Each contains the bonita_form <div ID> which is filled with the appropriate form at runtime. The templates provided are located in Applications.

The designer can save the generated html file for modification and re-upload.

Figure 29. Upload a built-in html template for all process Forms

(19)

Figure X. Choose a template for all forms presented in this Process

When a built-in template is selected, its resources are uploaded automatically.

The Process Template can be entirely customized by embedding the Global page template into another html file and uploading the resources it calls.

The html code must contain

<element ID=”bonita_form”> </div>

Recall that in the Process Template example in Part 1, the following dynamic elements are shown:

• a link to open Bonita User Experience; • the name of the user;

• a link to log out; and • the process name.

(20)

ELEMENT ID Defines

bonita_user_xp_link link to open Bonita User Experience bonita_username user’s name

bonita_logout_box link to logout bonita_process_label process name

Table 1. Some of the element IDs for forms defined at the Process level

Here is an example of a process template slightly customized externally through the

application of an html file (with a different CSS and image). The look-and-feel can be entirely changed with other CSS and image files.

(21)

modified, or replaced from within Bonita Studio to change the look-and-feel of the forms and the frames in which they are presented externally.

Total customization of forms allows the process owner to run Bonita Open Solution “behind the scenes.” Developers enjoy the benefit of Bonita Studio’s power and simplicity, and the end user enjoys the benefit of easy-to-use interaction.

About BonitaSoft

BonitaSoft is the leading provider of open source business process management (BPM) software. Created in 2009 by the founders of Bonita project, BonitaSoft democratize the use of BPM in companies of all sizes with an intuitive and powerful solution with an optimum cost. The Bonita solution has been downloaded more than 370.000 times to date by companies and organizations worldwide.

Sales inquiries : sales@bonitasoft.com | Partner inquiries : partners@bonitasoft.com

References

Related documents

accommodate the first three words of its gloss quite readily. However, the problem seems to settle upon the spelling of the fourth. 2257 provides a very thorough reading: “foueam

One early article (1989) uses fractal geometry and self-similarity to geometrically generate entire central place hierarchies associated with arbitrary Löschian numbers (Figure

Our aim was to ascertain the rate of management (percentage of encounters) of WAD among patients attending Australian general practice, and to review management of these

Using Bland-Altman plots stating limit of agreement and mean disagreement, the fragment overlap methods (Silva et al. and Hill et al.) showed good consistency with each other but

In the prior analysis we found that individuals living in neighborhoods with low levels of social support and high levels of neighborhood stressors such as violence reported

The primary aim of this study was to determine the validity of the LLAS in identifying lower limb hypermo- bility in an adult population. This was achieved by: i) evaluating the

The TargET-Knee-Pain study will test the principle that a home-based exercise programme, specifically targeted at particular physical impairments of muscular weak- ness,

Results: The proteomic approach revealed significantly increased expression of carbonic anhydrase I (CA1) in the synovial membrane of patients with AS as compared with the RA and