Linking SafetyCulture: How to Link and Fill-in Fields Automatically
Gary Hawton
Last Update 3 месяца назад
It’s easy to add new templates in SafetyCulture, and once you do so you need to sync those to your HWIT Business Management System so that the two systems can talk.
You can manage your SafetyCulture template links easily directly from HWIT. This also includes the ability to pre-fill notes and fields within the SafetyCulture report. (For details on the fields available and examples of use please see this link.)
To add the template so that it can be used within your Business Management System, access the Report Template List/Maintenance screen by first going to your Preferences Screen (click the 3 dots on the Home Watch Admin tile), open the SafetyCulture section and click on the link to Manage your Templates. You’ll be taken to this screen:
On the left side will be an array of any existing templates you have previously installed. If you need to make edits to any of those templates simply click on the name and the details will appear on the right. Edit and Save as normal and as described below when adding a new template.
To add your newly created template to the system, click on “Add New Template” and you’ll see a dropdown box appear. The selections in this box will be any templates in your SafetyCulture system that you have not yet added to Method. Select the one you want from the list. The system will pause for a few seconds while it loads all the details of the template in and you can continue adding the details as explained below.
If you do not see the dropdown, you are still on a legacy API and can follow these directions (you should also let us know so we can update you): To add your newly created template to the system, you’ll need to first get the internal code used by SafetyCulture as this is the only way to link the two systems. To get your code, go into the SafetyCulture dashboard and edit the template you wish to add. In the browser’s URL bar, you’ll see the template ID at the end of the path -- it begins with template_ and has a bunch of numbers and letters after it. Don’t let it scare you as your browser makes it very easy to copy this code -- simply double click on the part starting with template_ as in this illustration:
You’ll see that the template id is highlighted as I double clicked on it. Then just press control-C as usual to copy the template id.
Return to the Template Links screen, click the “Add New Template” button and paste that ID into the template ID field:
After pasting, simply click somewhere else on the screen or press the TAB key to move away from the TemplateID field. You’ll then encounter a slight pause while the template is loaded from SafetyCulture.
Adding the details (all versions): Once the details are loaded, the system will try to fill in the primary header fields for you. If you used the standard names (Audit Title, Prepared by, Conducted on, and Work Order No) they will be filled in automatically for you as in this shot:
If you named it something different, you can select the proper field from the dropdown on that item.
Here we called it the “Inspection Title” rather than the “Audit Title”:
Also notice the Audit Title format field -- this is where you can adjust the way that the Audit Title is filled in when the report is created. See the above linked article on variables to show you the options. The default of “Entity.LastName Residence” will be filled in for you.
Once your header fields are set you can press “Save” to save your template to the system. If it’s a new template, HWIT will be notified that you have added the new template so that we can configure the backend process (where the completed report links back into your Business Management System) -- please note this can take up to 48 hours. Once you’ve saved the template here it is immediately available for you to use to create the report, but it will take some time for the backend process to clear.
Once you’ve saved, you’ll also have the opportunity to add data to any of the lines of your SafetyCulture Report.
For example, let’s add the Requested Temperature and Owner Controlled fields to the report in the question that says “Check Thermostat for Proper Operation.”
Start by clicking the “Add New Line” button:
You can ignore the SafetyCultureID box and go straight to the dropdown. If you dropdown and look at the fields you’ll see all of your SafetyCulture questions and headings appear in order that they appear in your SafetyCulture template -- making it easy to find things. You can also type in some search text, as done here where I typed “Thermostat” as I know I want to bring up the question that has to do with checking the thermostat. Select the row you want to fill in like in this illustration:
After selecting the SafetyCulture row you want data pushed to, you can fill in the Value field as to what data you want to push.
We’ll take apart that Value string in a second, but first two rules about where the data goes:
- If the row or question in SafetyCulture is a normal “button” type of question, such as OK/Issue/NA, the text value will go in as a Note on that line.
- If the row or question in SafetyCulture is a “Text” type of question, such as “Desired temperature:”, the text value will go directly into the text box as a response to that question.
Let’s explain what we typed into the “Value” box above and what will happen when you create your SafetyCulture report using this new template. Note that all variables used are explained in the link at the beginning of this article.
We typed this text into the field:
Owner requests: Entity.LVHWRequestedTemp (Remotely controlled-Entity.LVHWOwnerControl)
What happens is that whatever text is a “Variable” or a “Field” name, will be replaced with the data from that client’s property or this particular Work Order. Anything that is regular text will be carried over. This is an example of what would now be in the Note of the Thermostat question using this Value (we’ll call it the Result):
Owner requests: 80 degrees in Summer, 60 degrees in Winter (Remotely controlled-TRUE)
This could be very handy as a note in the report as you will always see the request when looking at the thermostat, and your Client will see this as a note as well.
One more look at the Value and the resulting text, with some formatting to help make the distinction:
Owner requests: Entity.LVHWRequestedTemp (Remotely controlled-Entity.LVHWOwnerControl)
Owner requests: 80 degrees in Summer, 60 degrees in Winter (Remotely controlled-TRUE)
The text in BOLD above was simply typed in text and carries forward from the Value to the Result.
The text UNDERLINED and ITALIC UNDERLINED above are Variables/Field Names as defined in the overall list. They correspond to data normally input on either the Customer/Property screen and the Work Order screen. In this case both of these are contained on the Customer screen and the value in the fields on that screen, for the customer you are creating the report for, is populated on this report when created.
Once you’re satisfied with your info, simply Save the line. You can add as many lines as you need to populate the report accordingly.
This new capability removes the need to have individual templates by customer, and adds a huge potential for extra data on every report created. If you need help with a particular use case please let us know!
Final Footnote:
If you are linking a “Notes” field on the Property screen to a Text field on a SafetyCulture template, the data will all run into a single line even if you have the data entered on multiple lines. If you wish to preserve the multiple lines in the SafetyCulture report you will need to change the Text Type in the template to “Paragraph” as explained below.
You need to set the question type to “Text answer” and set the format to “Paragraph”.
If you make this change to a report already linked to your HWIT Method account, you will need to “sync” the change. You can easily do that by going to the Preferences Screen, then open the SafetyCulture box, and select Manage Templates. On the Manage Templates screen click the “Sync” button as shown below. The rest of the process is automatic.