SBM Relations - Part 2

0 Likes
over 5 years ago

 

Relating Records in SBM - Part 2

 

SBM Blueprint built using version 11.  Download Here ->  RelationsPart2.zip.

 

In the previous post, well previous…previous post, I introduced the ability to selected related records via the Relational Grid.  Or you could go the old fashioned route and use the relational fields themselves.  Either way is fine, the Relational Grid gives your users a better experience.

 

The example we will cover this time picks up once I select those related items, how do I go and update the downstream record’s relational field so that regardless of which record I am looking at, I can see the relations.

 

 

The short answer is to create an orchestration that sets the relational fields.  Then pretty up the presentation using Relational Grids.

 

The included blueprint contains two applications.  Primary Relationship Management and Children.  The Primary Relationship Management contains the parent records and the Children the children with the notion of a one (Primary) to many (children) relationship.  In the Primary workflow, there are two transitions.

 

1.      Create Child – This uses a post transition to create a child record into the Children workflow and establishes the relationship through the post transition properties and setting the relational fields when the child is created.

 

2.      Adopt Child – This transition allows the user to select one or more children, then when the user clicks OK, an orchestration is run to set the relational fields in both the parent and child records.  All of the forms, and orchestration steps are documented in the blueprint for your reference.

 

Then for fun, I decided to add orchestration on the Children workflow for them to select parents.  There are two transitions/orchestrations.

 

1.      Pick My Parent – Uses an asynchronous orchestration to update the parent record with the new child.

 

2.      SyncPickMyParent - Uses a synchronous orchestration to update the parent record with the new child.

 

To enhance the visibility you will notice that I have used Relational Grids.  The columns for a Relational Grid are defined with a Composer report.  This gives you a lot of flexibility in what you want to display about the records you are selecting or have selected.  In my opinion they are much more pleasing to the eye than the relational fields themselves.

 

Also notice that with the Relational Grids you can allow for searching by using the “Other Controls” on the palette.  I chose to have the user click a button to update the search results, you could as easily have the results auto refresh when the other control value changes.  These settings will be in the Results properties of the Relational Grid.

 

Included below are a couple of screenshots.  You can play around with the default and create more “Grid Styles” if you want to alter the coloring as I have with the purple you see below.

 

Selection of the available children:

State form with selected children:

 

Embedded Parent Record in child:
This is configured by setting the URL for the parent record in a field and then rendering that field in a webpage widget on the form.

 

 

Labels:

How To-Best Practice
Comment List
Anonymous
Related Discussions
Recommended