Skip navigation
All Places > Alfresco Process Services & Activiti (BPM) > Blog > Authors alfresco

We often create little demos of Alfresco Activiti to introduce people to the range of capabilities available. I thought it would be useful to list a few links to videos of these demos:

 

A mix of demos

A client on-boarding demo

alfresco

What's New in Activiti 1.4

Posted by alfresco Employee Aug 31, 2016

A new release of Alfresco Activiti always brings with it a bundle of shiny new features and enhancements to old favorites. The team have worked hard to make this the kind of release you expect from us, so what I’ve highlighted below is really just a hint of what delights you will find.

 

Activiti Engine

  • Activiti 5.19.0 supported
  • Dynamic BPMN Service for modifying process instance without redeploying
  • Improved support for Terminate End Event

 

Business Rules – Decision Tables

  • Easily manage business rules through spreadsheet-like Decision Tables
  • DMN Open Standard compatible

 

Box Connector

  • Attach metadata from Box
  • Publish metadata to Box

 

Google Connector

  • Attach metadata from Google Drive
  • Publish metadata to Google Drive

 

Forms Enhancements

  • Column spanning for controls
  • JavaScript customization per form
  • Improved REST handling
  • Additional custom event listeners
  • Extended datatypes for Form Stencils
  • Amount field supported in dynamic tables
  • Import Form Stencil by file update

 

Kickstart Editor Enhancements

  • Duplicate Step model as BPMN model
  • Force Process App deployment to user’s landing page
  • Full support of variables in nested subprocesses and due dates
  • Enhanced validation of models
  • Custom script tasks available in Stencils
  • Complex condition builder in Step and BPMN Editors

 

Administration

  • Configure whether non-tenant users can be involved

 

Documentation

  • Provided for User, Administrator and Developer

 

Developer API for Suite Services

  • Pluggable authentication
  • Public REST API for Kickstart capabilities
  • Customizable HTTP headers
  • Direct URLs to Start Process forms
  • Interface for custom user and group synchronization
alfresco

Form Stencils 101

Posted by alfresco Employee Aug 31, 2016

Okay, I know. It’s frustrating. You’ve got Alfresco Process Services running and people interested, but you find it doesn’t have a particular form control that is essential for you to use it. Stress not, there is an easy way to create or link in your own custom controls, and I’ll give you the most trivial introduction to it here. Or, if life is too short, you can watch a short video here.

 

For this simple example, we’re using a publicly available image service that provides some random images (http://lorempixel.com).

 

Not surprisingly, you’re going to have to do all this from the Stencils page in App Designer.

 

 

Click Create Stencil to get started, and enter a name for the stencil and choose the type of stencil. I don’t need to tell you to pick Form editor, do I?

 

 

You then get taken to the stencil’s detail page. Just click the Stencil Editor button to be able to actually modify the new stencil (which starts with the default set of form controls already there).

 

 

With any of the existing controls, you can rename them, hide them, change their icon and so on. However, we’re interested in create a new control, so click the Add new item link.

 

 

For this example, we’re going to create a custom image control that gets a random cat image and renders it in a configurable height and width. The first thing is to give our control a name and optionally a description.

 

 

We can then upload an icon to use for the control in the form editor. You can download this image to use as the icon:

 

 

In the next area we need to give the HTML and JavaScript necessary to render the control when it needs to be displayed in a form at runtime. We’re doing a really easy example and just using an image URL that takes a couple of variable placeholders for the height and width (field.params.customProperties). Copy and paste the following text (without the space character in the url!):

 

<img ng-src="http://lorempixel.com/{{field.params.customProperties.width}}/

{{field.params.customProperties.height}}/cats/"></img>

 

We can then give the HTML and JavaScript that should be used to represent the control at design time in the form editor. Again, you can copy and paste the text below:

 

<i>Random cat image here</i>

 

 

Now to define the custom configuration properties for width and height. Click the Edit link next to Tabs and properties.

 

In the Edit stencil properties dialog, click the Add new tab link and give the new tab the name ‘Size’. This means when we drag the new control onto a form in the form editor, clicking to configure the field will now also show a tab for size.

 

Click Add new property and give the property name ‘Width’ and ID of ‘width’, then select the datatype of Text (even though it’s a number we’re getting, we’re still just passing it directly to the image URL).

 

 

Do the same to add a property named ‘Height’.

 

 

Close the dialog.

 

 

Save the new form control, then save the stencil until you are back at the stencil details page. Unless you just want to keep this exciting stencil to yourself, you’ll want to share it with others. Click the share icon to allow other users or groups to use it.

 

 

You only need to give the users read access, but you can give someone write access if you’d like them to be able to extend the stencil as well.

 

 

There we go, you’ve created a custom form control. Rather than resting on your laurels, you should now try it out. In the screens below, I’ve used the example REST process from an earlier blog. On the last step of that process it displayed some data from a REST call. I’m going to add a nice relaxing cat picture to the information. I need to create a new form for that step, selecting the Cats Form stencil.

 

 

You should now see your cats image control in the left-hand list of field types. Drag and drop the field onto the form.

 

 

The design time view of your custom control is displayed as the field placeholder.

 

 

Bring up the configuration dialog for this field by clicking the edit icon.

 

 

You will see the standard configuration tabs as well as the new one you added. Click on the Size tab and you’ll see the width and height properties. Fill in some values for these. When this form is displayed as part of a process, these values will be passed to the image service to request a cat image of that specific size. In another form you might use different values to get a different size image.

 

 

Finally, save the form and process, re-publish the process app that includes it and start the process. If everything has gone to plan and technology is playing nice with you, you should see something like the screen below.

 

 

It will be clear to those brain boxes out there that I avoided going into a deeper example of using external Javascript libraries and specialized controllers. There is an example of this in the Developer documentation here.

 

Now go and create your own custom form controls and stencils. Better still, create a blog or video about it to share here!

alfresco

Rest Call Task 101

Posted by alfresco Employee Aug 31, 2016

The easiest way to integrate Alfresco Process Services with other systems is by using REST calls. Alfresco Process Services allows you to make calls as part of a process or to populate form controls, such as a dropdown list of values. I’m going to take you through a really simple example that you can download and try yourself - all you need is a current version of the product and a few minutes. Or, if life is too short, you can watch a short video here.

 

The first thing we’ll do is get the example App imported into Alfresco Process Services. There’s a zip here that was created with Alfresco Process Services 1.6 that you can download and import. To load it, go into App Designer from your landing page

 Landing page

 

Navigate to the Apps page.

 

Apps

 

And click the Import button.

 

 

On this dialog, navigate to where you downloaded the zip above and select it. If successful, the dialog will close and you’ll be taken to the App details for the just imported Process App.

 

You can see there’s just one process model in this Process App.

 

 

Click on the Edit icon to open the model in the Step Editor.

 

 

There’s 2 steps after the initial start form. Click Open form in the start event to see the details of the form.

 

 

 

In the form there is just one form field. a dropdown control. Click on the Edit icon to bring up the dialog to configure the dropdown field. The tab we’re interested in is the Options tab; once in there, select the Rest service button to see the configuration for populating the dropdown through the REST call.

 

 

For this simple example, we’re using a publicly available REST service that provides some demo data about users (http://jsonplaceholder.typicode.com) Normally, you’d create a standard endpoint as Administrator in the Identity Management > Tenant page, but for this example it’s easier to use a simple URL approach.

 

We need to select the JSON properties that get returned into the ID and label variables for the dropdown. The label will be displayed to the user, but to make working with a selected value, an ID for the selected item is also set. This makes it easier to use in later calls or conditions. We can see what the example REST call makes by clicking the Test button.

 

 

From the response you can see why we’ve configured the ID property to be ‘id’ and the label property to be ‘name’. Now when the start form is displayed, it will make the REST call, create a dropdown of all the ‘name’ values returned, then set the ID as the field value and the name as the field value label for whatever is selected by the user. Now we’re going to use the selected name in a REST step to get more details on the selected user.

 

 

If you look at the Endpoint tab for the REST step, you’ll see something similar to the dropdown configuration we’ve just done. This time there isn’t an ID and Label field to map because we may want to map completely arbitrary data.

 

We are still working in a simple example, so we’re just using the URL and passing request variable on the URL - in this case, the ‘name’ form field that contains the ID of the selected user. You may prefer to use the Request mapping for more serious use. Next thing is to see how we map data from the response to the call. Click on the Response tab.

 

 

Here you can see we have mapped the JSON property for the user’s email into a process variable ‘Email’. Similarly for their website. Select the email row and click the Edit button and you should see the dialog to configure the JSON and process variable mapping.

 

 

The final step is to show the values we’ve collected, and the easiest way is to create a task with a form displaying the details.

 


To use display the value of a variable set by a REST call, you need to use the Variable option for Display field, rather than Form field.

 

 

Finally, publish the imported Process App and add it to your landing page.

 

 

Click on the new App and its Start page to see a single process available with the start form we saw earlier. Click on the dropdown and you will see all the user names returned by the REST call.

 

Select one and then click Start Process.

 

 

 

The view will switch to the history of the new process, so click the Tasks page to see if you have the results task.

 

 

There you have the results of making the REST call based on the user you selected. The demo data that the REST service returns does mean that names and emails do not necessarily match, but you can check by making the REST calls yourself directly in your browser, e.g.

http://jsonplaceholder.typicode.com/users/3 

Well, that was a very quick and simple introduction to making REST calls using the REST call task available in Alfresco Process Services. You can also use the BPMN Editor and use a REST Task if you prefer that to the Step Editor. We used a REST Step to get data from another service, but you can use a REST Step or Task to publish data to an external service as well. In forms, you can use REST calls to populate dropdowns, radio buttons and the typeahead (auto-complete) text field.

 

Now go and create an integration to your own REST services. Better still, do it against a service that might be useful to others and create a blog or video to share it here!

alfresco

Welcome

Posted by alfresco Employee Aug 31, 2016

Welcome to our new site specifically created to help you do more with Alfresco Activiti. We realized there was a gap between what is provided on the Activiti Community pages and what people need when they want to find out more about the Enterprise version of Activiti.

 

First of all, this is the place to come for the most up to date documentation about Alfresco Activiti, whether you are an administrator setting up or looking after an Alfresco Activiti deployment, or a developer looking to find ways of extending and customizing all aspects of the Alfresco Activiti product - from integrations to UI enhancements. If you are a user looking for more advanced uses of Activiti, or ready-made examples to show what can be done with Activiti, there’s plenty for you too.

 

As well as documentation, there will be videos of Activiti in action, especially new features, and clips showing interesting uses or integrations with other applications. We won’t be limiting the material to just content that we produce, we will also share videos and guest blogs from customers and partners (unless they contain such a blatant sale pitch that the useful information gets lost in the wonderfulness of the organization creating it). Obviously, anything we produce will be a lesson in awesomeness 

 

It will take a bit of time to build up the content and it will be updated frequently, so make sure you come back here frequently to see what’s new.