2.
Introduction to Salesforce.com Cloud Flow
Designer
Provide an overview to developing a simple
wizard
Show a more complex wizard developed
using Cloud Flow Designer
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
2
3.
Purpose of the flows is to guide users through
screens for collecting and updating data – in my
case I used them to guide volunteers to enter and
schedule trips for volunteers
Elements are the building blocks of flows
Each element represents an action
Actions are connected into flows and then
variables, formulas are used to manipulate the
data throughout and if you really want to
manipulate the data you can plug-in an Apex
class
Visual Workflow has 3 aspects:
◦ Flow design
◦ Flow Management
◦ Flow Run time
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
3
4.
Loading data from the Donation system requires multiple steps.
To reduce the manual steps an intermediate temporary object
was created and a trigger was attached to the object.
The reason was that the Account ID is needed to load the
opportunity for the NPSP implementation. The trigger cannot be
attached to the opportunity object because there are 6 triggers
associated with that object and we don’t have the code for the 5
managed packages. In addition I really did not want to change
these managed packages.
This left me with the solution of creating an intermediate object
for the data being loaded in opportunity (donation) where I could
hold the data until I populated it with the Account ID from the
recently loaded Contacts.
The downside is that this intermediate object would have data in
it that would not be monitored or cleaned up since I could not
delete it with the trigger I just added on the intermediate object
since the commit was not complete.
The solution was a single wizard once the loading was complete
the person doing the loading would select a single button that
would do the final cleanup.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
4
5.
Define your problem –
Understand your data
design – Entity Relationship
Diagram.
Develop a high level
design.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
5
6. Select setup
To start with you will
select a Flows
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
6
7. Get Started
Start with a new flow
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
7
8. The first time you start Cloud Flow
you will get the opportunity to
watch videos to get started. Watch
the Video it will go through all the
icons on the screen .
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
8
9. Once you clear the video you will
start with a blank canvas.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
9
10. Sketch out your design using the
Step Draft tool from the palette.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
10
11. Record Look up
First you will identify if you will
be looking up a Standard or
Custom Object
Then identify Standard or
Custom field in the Object
Then select the operator
If you want to add additional
filters then add a row.
Then enter the value you can
create a new value or as in this
case use a system value
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
11
12. Save flow
Note Error if you go to save.
Unless you are going to save
the fields to variables you will
get this select the trash can to
allow you to save.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
12
13. Save flow
You will get the warnings when you
save because of the steps still in
the flow and because I have not
identified a starting point.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
13
14. Identify the start of the flow
This is how you select the starting
element.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
14
15. Make a Decision
The Default Outcome would
be the else outcome
The decision logic from the Palette
acts much like an If then else
conditional statement. Provide a
name and it will appear when you
make the connection
What is your conditional
statement? You can add multiple
conditions and either “and” them
or “or” them
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
15
16. Create a loop
Placing this decision and the
lookup created a loop in the logic
the loop is a “do while” there is still
a record to look up in the object
delete it
The else condition
The names from the decision
of the statements
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
16
17. Delete a Record
Identify the Object
Define the criteria of the
records to delete add as
many rows as needed to
specify the select for the
records.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
17
18. Display Content to the Screen
This is the component that you will use
to interact with your user, to request
input and to provide information. In
this case I displayed the output that the
wizard was complete. The field output
can be formatted using HTML markup.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
18
19. Activate the Flow
The flow will need to be activated and
once activated its status will become
Active. Further modifications will be
saved to a new version of the flow.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
19
20.
The next steps is to make the wizard
available
Select the app or apps for the wizard
Make a tab using visualforce tab and assign
to an app.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
20
21.
The following slides introduce additional
choices for the selections available for
components
You may not use all that is available but there
are many choices.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
21
22. Complex flow
Available sub-flows will
appear on the palette
One flow can invoke other
sub-Flows
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
22
23. Invoking Sub-Flows
When invoking a sub-flow
you can assign elements
or values to pass but they
have to be defined
appropriately
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
23
24. Invoking Sub-Flows
When invoking a sub-flow
you can assign elements
or values to pass but they
have to be defined
appropriately not as local
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
24
25. Record Create
As part of CRUD this is the
“C” and to create a record.
Begin identifying the object
and then set the fields and
the values
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
25
26. Record Update
As part of CRUD this is the
“U” and to update a record.
Begin identifying the object
select the record to update.
Once the record is identified
then update the fields
specified.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
26
27.
Not everything can be done through Cloud flow and
sometimes you need an APEX class.
You can develop an APEX class and an APEX test class and
integrate it into your cloud flow for even more flexibility.
From Setup, click Create | Workflow &
Approvals | Flows and open a new or existing flow.
From the Palette, drag an Apex Plug-in element onto the
canvas. The class name and plug-in description are taken
from the plug-in code.
Enter a name for your new plug-in element.
If you haven’t already added a description, click Add
Description to do so.
On the Inputs tab, assign values to the Apex parameters.
Required parameters are automatically listed as targets.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
27
28. APEX Plug-in Classes
global class CleanTripName implements Process.Plugin
{
global Process.PluginResult invoke(Process.PluginRequest request)
{
}
global Process.PluginDescribeResult describe()
{
};
}
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
28
29. Adding APEX Classes
In addition to adding the APEX classes to the
palette you can pass arguments to the class
and get return values from the APEX class.
All the information within this
document remain the property of
Coquisoft, Inc
2/5/2014
29