Building the smart farm app

This is part of the IoT smart farm app implementation guide.

Requirements: We need to have all the pages listed in the guide already created and available in our tenant. We will need to import the macros to the flow as well, before we begin.

Here is how we are building the app:

  1. Create a new flow called Smart farm app. (We are building a public flow for the purposes of this tutorial, but we can of course use our favorite service for authentication as well.)
  2. Drag a page layout to the canvas.

    This opens a configuration panel.
  3. Call the page Case page.
  4. Uncheck the option for Only show Page Layouts already being used in this Flow, select the Case page, and click Save Page.

    This is what the canvas looks like now:
  5. Create an outcome from Start to Case Page called Go.
  6. Next up, is a macro! Let’s drag an operator element and place it above the Case page in the canvas. We will call the operator Operator McOperator.
  7. We will add two operations now. Click New Operation.
  8. Click Select or create a new Value.
  9. Select the CaseMockLists value.
  10. We want to update the value.
  11. Select Value of as the option for How do you want to retrieve the reference Value.
  12. Select CaseMock as the value you want to reference. This is what the configuration looks like:
  13. Click Apply Operation to save the operation.
  14. Click New Operation.
  15. Click Select or create a new Value and select the CaseMockLists list value.
  16. Select Remove as the option for How do you want to change the Value.
  17. Select Value of as the option for How do you want to reference the Value.
  18. Click Select or create a new Value and select the CaseMock object value. This is what the configuration looks like:
  19. Click Apply Operation and then click Save Operator. This is what the canvas looks like now:
  20. We will create an outcome from Case Page to Operator McOperator called Get Sample Case.
  21. We will create a second outcome, this time from Operator McOperator to the Case Page called Go. This is what the canvas looks like now:
  22. Let’s drag a second operator and place in under the Case Page element on the canvas. We will call the operator Set Closed and click New Operation.
  23. Click Select or create a new Value and select the CaseMockLists list value.
  24. Select Empty as the option for How do you want to change the Value. This is what the configuration looks like:
  25. Click Apply Operation and then Save Operator. This is what the canvas looks like now:
  26. We will create an outcome from Case Page to Set closed called Close Case.

    Advanced configurations coming up! The order in which the outcome should be evaluated should be changed from 1.
    Select Case Details as the option for which component on the page we want to place this outcome with. Click Save Outcome to save the outcome when done.
  27. We will create a second outcome from Set Closed to the Case Page this time, called Go.

    This is what the canvas looks like now:
  28. We will drag and drop another operator to the canvas and place it next to Case Page.
  29. We will call the operator Set Chart Data and expand the Advanced menu.
  30. Click Add Macro.
  31. Select PopulateIoTChart and click Apply Macro.
  32. Click Save Operator.
  33. Create an outcome from Case Page to Set Chart Data called Edit.

    Expand the Advanced options. The order in which this outcome should be evaluated should be set to 0. Select Case Details as the component and click Save Outcome.

    This is what the canvas looks like now:
  34. Drag a page layout to the canvas and call it Case Detail Page. Uncheck the Only show Page Layouts already being used in this Flow option, and select the Case Detail page. Click Save Page when done.

    This is what the canvas looks like now:

  35. Drag another page layout to the canvas and call it Product Catalog. Uncheck the Only show Page Layouts already being used in this Flow option, and select the Product page. Click Save Page when done.

    This is what the canvas looks like now:

  36. Let’s connect the dots now. Or arrows as the case may be! Create an outcome from Set Chart Data to Case Detail Page called Go.
  37. Create an outcome from Case Detail Page to Product Catalog called Asset Details. We have a bit of additional configuration that needs to happen here. Expand the Advanced menu.
    Select Do not save Outcome as the option for When this Outcome is selected.

    The order in which this outcome is evaluated will be 2.
    Select Asset ID as the option for page component, and Query as the option for kind of action.
    The option for this Outcome should appear at the top of the Component should be checked. This is what the configuration looks like:

    Click Save Outcome when done. This is what the canvas looks like now:
  38. We will create an outcome from Case Detail Page to Case Page called Save. The order in which this outcome should be evaluated should be 1. The select Outcome as the option for component and Submit as the kind of action. The option for this Outcome should appear at the top of the Component should be checked. This is what the configuration looks like:

    This is what the canvas looks like now:
  39. We will create another outcome from Case Detail Page to Case Page. The order in which this Outcome should be evaluated should be 0. We will call this one Cancel. Select Outcome as the option for component and Cancel as the kind of action. The option for this Outcome should appear at the top of the Component should be checked. This is what the configuration looks like:

    This is what the canvas looks like now:
  40. We will create an outcome from the Product Catalog page to the Case Detail Page now called Provision. No fancy configurations for this one! This is what the canvas looks like now:
  41. We will create a third outcome from the Product Catalog page to the Case Detail Page. Let’s call this one Previous. When the outcome is selected we Do not save changed values. Select Cancel as the kind of action this is. This is what the configuration looks like:

    This is what the canvas looks like now:
  42. Double click the Case Detail Page to open the configuration panel. We will make sure the outcomes are in the following order: Asset Details, Save, and Cancel in decreasing order:
  43. Double click the Case Detail Page to open the configuration panel. We will make sure the outcomes are in the following order: Provision is at 1, and Previous is at 0.
  44. We will add a nice navigation now. Click the Navigation icon on the right-hand-side menu and click New Navigation.
  45. Let’s copy-paste Smart Farm in the Name and Label fields.
  46. Click the Add icon to expand the menu options.
  47. Select Case Page as the map element to navigate to. Add the label as Work list.
  48. Click Save to save Work list, and click the Add icon again.
  49. Select Set Chart Data as the map element to navigate to. The label will be Case detail. Click Save to save the navigation and click the Add icon again.
  50. Select Product Catalog as the element to navigate to.
  51. Add the label as Provision. Click Save.
  52. Click Save Navigation to save the navigation.
  53. Close the dialog box to return to the canvas.

Check out the glossary for a definition of terms and key concepts that appear in the Boomi Flow website, drawing tool, technical documentation, blogs, and marketing communications.

If you need to take a closer look, click on the images to enlarge them. Have a question? Click the Help button on the bottom right-hand corner of this page to ask.