Vacation Management Example

antoine.mottier's picture

 About

This is an official Living Application example for Bonita BPM >7.3.0

This example demonstrates the following concepts:

  • Living Application
  • Forms and pages built using the UI Designer
  • Process using BDM and contracts
  • REST API extensions

 Installation

  1. Start Bonita BPM Studio 7.3.0 or later
  2. Download the application bundle
  3. Extract the bundle to a temporary folder
  4. Import the .bos file in your Bonita BPM Studio. It contains 5 diagrams: Example-NewVacationRequest, Example-ModifyPendingVacationRequest, Example-CancelVacationRequest, Example-InitiateVacationAvailable and Example-RemoveAllBusinessData. Each diagram includes a single process definition. It also includes business data model definition, default process configuration and application page (i.e. application user interface definition). Important: importing the .bos file will ask you to override your existing business data model.
  5. Open the Example-InitiateVacationAvailable diagram and run the process (click on "Run" button in a Bonita BPM Studio). This process will initialize a business data that store vacation available counter for each Bonita BPM user declared in the default test environment (ACME organization).
  6. You can now deploy and run the "New Vacation Request", "Modify Pending Vacation Request" and "Cancel Vacation Request" processes by clicking on "Run" button in Bonita BPM Studio. Note that vacation request approval need to be performed by requester (walter.bates) manager (helen.kelly) so you might want to logout and login back with helen.kelly/bpm user. If you want to create (or cancel) several vacation requests, do not click again on "Run" button. Instead click on the "Portal" button and in "User" view go to to "Processes" tab select the process and click on "Start" button.
  7. You can now deploy the living application that give user an overview of all created vacation request.
    1. First you need to deploy a REST API extension:
      1. In the Portal, switch to "administrator" view. Use drop down list on top right corner to switch from "user" to "Administrator".
      2. Go to "Resources".
      3. Click on "Add" button.
      4. Select the rest-api-extension.zip file.
      5. Click on "Next" button.
      6. Click on "Confirm" button.
      7. Read more about http://documentation.bonitasoft.com/bonitabpm/?page=api-extensions[REST API extension] in Bonita BPM http://documentation.bonitasoft.com/bonitabpm/[official documentation].
    2. Next you need to deploy the application page:
      1. Go again in "administrator" view -> "Resources".
      2. Click on "Add" button.
      3. Select the page-ExampleVacationManagement.zip file.
      4. Click on "Next" button.
      5. Click on "Confirm" button.
      6. Read more about http://documentation.bonitasoft.com/bonitabpm/?page=pages[pages] on the Bonita BPM http://documentation.bonitasoft.com/bonitabpm/[official documentation].
  8. You are now ready to import the application definition that will use the previously deployed page:
    1. In the Portal switch to "administrator" view.
    2. Go to "Applications" tab.
    3. Click on "Import" button.
    4. Select the Application_Data.xml file.
    5. Click on "Import" button.
    6. Click on "Close" button.
    7. For more information refer to http://documentation.bonitasoft.com/bonitabpm/?page=applications[applica... in Bonita BPM official documentation.
  9. Run the Vacation Management application by accessing to this URL (the port number may vary): http://localhost:8080/bonita/apps/tahiti[http://localhost:8080/bonita/apps/tahiti]. You can find the URL of the application in the Portal "administrator view" -> "Applications".

 Screenshots

Vacation Management Living Application

Vacation Management Application

Vacation Management Living Application - Vacation request to cancel

Vacation Management Living Application - Vacation request to cancel

New Vacation Request process

New Vacation Request process

New Vacation Request process - Vacation request creation form

New Vacation Request process - Vacation request creation form

New Vacation Request process - Vacation request review form

New Vacation Request process - Vacation request review form

Modify Pending Vacation Request process

Modify Pending Vacation Request process

Cancel Vacation Request process

Cancel Vacation Request process

Cancel Vacation Request process - Vacation request canceled review form

Cancel Vacation Request process - Vacation request canceled review form

Initiate Vacation Available process

Initiate Vacation Available process

Remove all business data process

Remove all business data process

 Compatibility

This example has been created and built with Bonita BPM 7.3.0 Community Edition.

It should be compatible with any newer version as well as Subscription edition.

 Known limitations

None so far.

 Issues

Reports issues and improvement requests on GitHub tracker.

Category: 
Licence: 
Apache v2

Downloads

Total downloads: 6 197
Version BonitaBPM Version Post date Download Link
v1.3.0 for Bonita BPM 7.3.0 and onward 7.x, 7.3.x 2016-Jul-25 Download
1262 downloads
Release note
v1.2.0 for Bonita BPM 7.2.1 and onward 7.x, 7.2.x 2016-Mar-09 Download
1164 downloads
Release note
v1.1.0 for Bonita BPM 7.0.2 and onward 7.0.x 2015-Sep-11 Download
2315 downloads
Release note
v1.0.0 for Bonita BPM 7.0 7.0.x 2015-Jun-22 Download
1456 downloads
Release note

Issues

Downloads: 
183

Comments

Submitted by ntlzz93 on Wed, 02/24/2016 - 17:46

Have any report documentation for example? . It can help me easy to follow and understand what project excute.

Submitted by josep.albalat on Mon, 04/11/2016 - 20:37

Whien I try to send an e.mail to the manager with the request I have the next error:

java.lang.reflect.InvocationTargetException
org.bonitasoft.engine.bpm.connector.ConnectorExecutionException: USERNAME=install | org.bonitasoft.engine.core.connector.exception.SConnectorException:

org.bonitasoft.engine.expression.exception.SExpressionEvaluationException: Declared return type class java.lang.Long is not compatible with evaluated type class java.lang.Integer for expression processInstanceId

I have the following script in the field From
return BonitaUsers.getProcessInstanceInitiatorProfessionalContactInfo(
apiAccessor, processInstanceId).email

What is the mistake?

Testing
Notifications