Skip to main content

Our organisation is quite new to K2 and are coming to the end of our first batch of processes.  As we have a few people developing processes we have noticed that there is a key difference in the way that we are implementing.  I am looking for advise and experience from the group on which way we should set as our standard moving forward. 


Our model is to use SmartForms to start our processes, SmartObjects (primarily SmartBox) to store the data and K2 Studio for workflow development.  The question comes when we tie these three things together.  We are using the SmartForms Integration Wizard, but we have had 2 ways of passing SmartForm data in:



  1. Creating an Item Reference (print screen attached)
  2. Creating a DataField to hold the ID then creating a Reference to the SmartObject using the ID

The benefits I can see are:


1 Item Reference Benefits



  • Quicker to develop
  • Simpler to implement
  • New future so new direction??

2 Reference from ID Benefits



  • Easier to debug (can pass an ID when starting a process from Management Workspace)
  • Easier to create a new workflow from an existing SmartObject
  • Easier to do bulk processing

Please share your thoughts and experiences.  Thanks in advance!


11945i52A3041E60C4170D.jpg

A disadvantage of using item references is that you must cast the item to its data type when you want to use it in other events or functions. For example using a date field in a date/time function will throw an error unless you convert the item to date first.


You can start a workflow using item references from the management workspace but it is a bit convoluted. You first need to un-hide the item reference (in the object browser go to Process/Activity Date and then find it in the XML fields) and then start a workflow using SmartForms. Then you can find the item reference XML in the data fields from the process instances report (Drill down into data). Then you can modify the XML to replace the ID field with the one you want, and use this when starting the workflow from WS.


 


Reply