In this article, you will learn:
- Why it is important for your app to have a Complete button
Note: This topic is featured in the "Introduction to App Building" course in Tulip University.
In order to save information from a Tulip app, an operator must "complete the app." In order to enable that, you need to add a Complete button to your app.
Whenever an operator uses the "Complete" button, a new row will be added in the "Completions" tab. Each row holds these values:
- App completion info, like station name, badge ID of operator, and date/time of starting and ending the app.
- All of the variables and their values at the time that the app was completed.
- If any Table Records were loaded into the app, the values of the fields in those Table Records will be stored as well.
Every variable that is defined in your app, (e.g. barcode, operator logged in, time spent, inspection result) would be a column in this view. When an operator "completes the app", you create another row in the list.
The values in all Form Steps will be stored and cleared when you complete an app.
In fact, if you navigate to the Completions tab in each individual App, that's exactly what you will see.
There are a couple ways to "complete the app" when an app has been finished by an operator.
You can use the Complete Button which is built into the App Builder or you could build a custom Trigger with a "complete app" transition.
Using the Complete Button
Select the button from the Toolbar. Choose "Complete."
You can manually add the app completion transition via the "Add New Transition" button:
Using a Custom Trigger:
In this case above, the Complete Button logic defaults to:
- When, "the button is pressed;"
- Then, "App" -> "Complete App."
However, you can add this transition into any trigger that corresponds to the end of the workflow. For example:
- When, "Device," "GPIO," outputs at "this station" with events "pin down"
- If, "Device Output" "pin" "=" "Static Value" "integer" "2"
- Then, "App" "Complete App"
In this example, any IoT device sending a pin down signal to the GPIO Gateway pin 2 on this step will cause the app to complete.
Besides "Complete App", there are 2 other options:
Complete Then Change To: Complete the app then change to another app.
Complete Then Change To Step: Complete the app then change to another step within the same app, or a specific step in a different app.
Complete And Go To Splash Screen: Complete the app then go to the splash screen of the app. The app will not start until an operator presses the "Begin" button.
Complete Then Logout Current User: Completes app then logs out the current user
Complete Then Change App By Name: Completes the app then goes to another app that can be specified via a value from the app in a variable etc.
Complete Then Go To Step By Name: Completes the app then goes to another step in the same app that can be specified via a value from the app in a variable etc.
Note: Apps can only be competed when being run from the Tulip Player. When an app is complete, the operator will see a message as shown below.
Cancelling An App
Let's say that you do NOT want to save data from the given usage of an app. In this case, you will want to "cancel the app" and likely return to a specific step. This will erase all data from the time since the app was last opened.
There are 4 trigger transitions that directly correspond to the app completion trigger transitions:
- Cancel App
- Cancel Then Change To
- Cancel Then Change To Step
- Cancel And Go To Splash Screen
- Cancel Then Logout Current User
Technical Details of App Completion
Here are all the data points that are automatically saved with every app completion or cancellation:
- Start Time: The date and time when the operator opened the first step
- End Time: The date and time when the operator pressed the "Complete" or "Cancel" button
- Duration: The time between the start and end time
- Logged In User: Based on the badge ID of the person who logged into the Tulip Player
- Station Name: The name of the Station where the app was used, as determined by the Shop Floor tab
- Comments: Any comments that were made for the app as a whole in the Player menu
- Version: The version of the app when it was completed
- Canceled: Whether the app was canceled or not
- Execution ID: The unique ID of that specific run of the app
Deleting Data from App Completions
In order to comply with GxP standards of Manufacturing, the data in Tulip cannot be deleted.
However, there is a work-around. You can copy the app and delete the old one and then you will have a new table with no entries.
Hiding Completions Data from Analytics
It is likely that you are hoping to omit some data from the completions tab from your analytics. You can now do this by finding the record you would like to omit in the Completions tab, and unmark the "Include in Analytics" box. This will filter the analytic to not include this record.
Excluding this record from the analytic will not remove it from the completions data, so exports of this data will not be affected.
Did you find what you were looking for?
You can also head to community.tulip.co to post your question or see if others have faced a similar question!