Watch the video below for an overview of the solution...
Creating, finding and analysing data
Data is the fuel for location-based analysis. In this series you can find out more about capturing your own data, finding data that’s available in ArcGIS and analysing the data. The videos look at working with ArcGIS Pro and smart editing with Sweet for ArcGIS. Find out how to tap into the Living Atlas and see how exploratory analysis with ArcGIS Insights helps you understand it
How do I build this for myself?
The following section provides details of how you can build the solution for yourself.
As mentioned in the video, some businesses will have their own mechanisms for capturing or inferring staff locations. In this case you simply need to design an ETL process to surface the data that you are interested in reporting on and move to the Visualisation of Results section.For those wishing to follow the example featured in the video, please read on...
Data Capture using Survey 123
The survey has been built using Survey123 Connect. This approach allows the creation of a dynamic smart-form by editing a Microsoft Excel document.
The form asks three questions of the users, but has a a few calculations hidden in the background;
Greeting - This field is a note which combines a precooked text string with the pulldata() function to lookup an associated csv. The same command can be used to call an existing feature service using JavaScript. See below where "ServicePerson" is the name of the csv being called.
"Welcome " + pulldata('ServicePerson','name','username',property('username')) + ". Please record your whereabouts for today."
The pulldata() function does not need to be used if you only want to record the users 'username'
UserName - This field is using the same pulldata() function but storing only the users name. This field is used in the list columns within the Staff Interactions Dashboard.
DateSubmitted - This field captures and displays the current date to the user within the Survey123 form. It is important to use a date field, and not a datetime field as this will ensure that the value is recorded at 00:00 hours. Date is calculated using: now()
dateString - The hidden dateString field is not presented to the user and records the date as a formatted string: format-date(${DateSubmitted},'%d/%m/%Y')
WorkLocation - This field offers the user a select_one choice where the can select the location they intend to work.
LocationDateStamp - This field is hidden from the Survey123 user and is the "magic" behind calculating staff to staff interactions. Every staff member who submits a response for the same office, on the same day, will share the same value in their LocationDateStamp field. The calculation in Survey 123 is as follows: format-date(${DateSubmitted},'%a %d/%m/%Y') + " " + ${WorkLocation}
geometry - If left out, Survey123 will capture the geometry of the users device where available. As this may be a point of contention for some users, I have hidden the question using the "relevant" field, and pre-populated all results to return coordinates 0,0
And that is it! You now have a simple app to record staff working locations on a daily basis. You can go on to extent the survey in any number of ways if you wish;
Include additional staff details (Like first aiders, Fire Safety Wardens, etc)
Allow staff to report how they are feeling
Adjust styling and symbols
etc
Figure 1 - Survey design using Survey123 Connect
Data visualisation using Operations Dashboard
The Staff Interaction Dashboard has been build using Operations Dashboard which is an incredibly configurable product from Esri.
Figure 2 - Element filtering driven by user interaction
This dashboard consists of four main sections;
The following section will talk you through configuring each of these;
Counts of staff : broken down by office location, and date
List of staff who used an office: broken down by date
List of date and and office locations
Staff Selector
NOTE: It is important to use three separate hosted feature layer views (or feature layers if you wish) to drive elements 1, 2, and 3. Element 4 should share the same feature layer as Element 3.
This approach allows you to determine the attribute relationships between the various elements, which is important when displaying staff to staff interactions.
It is wise to configure your hosted feature layer view to give the best results in your dashboard. It is recommended that you configure the following;
Read only access
Appropriate symbology
An appropriate refresh interval
Count of Staff
The count of staff is a series of indicator elements arranged to record date and location.
Filters have been configured to return results where the data "is within the last" AND "is before the last" (in hours) AND a location which "equals" a specific value.
Combinations of the above filter criteria allow you to create a unique indicator for every office, for every day of the week.
The same approach is also used to create the list of response percentages displayed along to top of the dashboard.
Layout Tip: Indicators are arranged tightly together by holding the shift key whiles placing the element to snap them together.
Figure 3 - Configuration of the Indicator element
List of staff who used an office
Unsurprisingly this functionality is driven through the use of the List dashboard element to show staff who interacted with either of the Esri Ireland offices.
Again the element has been filtered using hours to capture only responses submitted on a specific day.
A second filter has been included to ensure the location recorded is "not equal" to Home Working.
Before the data source is selected, the symbology is set to match that of the colour scheme used within the dashboard for that office.
Finally a No Data value of "Office not used" has been configured. This will display when no staff use offices on a particular day, or the user filters the user interactions for a specific individual who was home working on a particular day.
Figure 4 - Configuration of the List element
List of date and office locations
As with the staff lists this functionality is driven through the use of the List element.
The list is filtered to display all records in the last 168 hours (or 7 days).
The attribute displayed is set to the "LocationDateStamp" field.
Again, the feature layer has been symbolised to ensure consistence with the selected office location colour scheme.
This is the first element where we configure Actions.
Note: It is important that this element pulls its data source from a different hosted feature layer view (or feature layer) to the indicators, and the Staff Lists. The data will be in sync as all layers are looking at the same underlying table, but the difference is that when using separate hosted feature layers the dashboard creator has the ability to choose the fields on which to build the action relationship.
The action relationship is built using the LocationDateStamp field which is shared by every worker who shared an office on a specific day.
Figure 5 - Configuration of the List element
Staff Selector
This element uses the Category Selector to provide a list of unique values found within the feature service. The category selector must reside inside a header or side panel. In the demo dashboard it is built on the header.
The staff selector has been configured to group values found within the 'UserName' field. (displayed in the dropdown under the Survey123 alias "Survey relates to user:")
Categories have been loaded into the element and which gives a list of every unique user.
An option of "None Selected" has been configured to allow the dashboard user to see all users information at the same time.
The final element configuration is the Actions section. As the Staff Selector element is running off the same hosted feature layer view as the List of dates and locations, we do not need to configure the attribute relationship. Instead the action will automatically filter the list of dates and locations using the username selected in the staff selector.
Figure 6 - Configuration of the Category Selector element
Summary
The above guide will provide you will all the information that you need to get started in designing and building your own Staff Interaction Audit Solution.
At a time where there is so much uncertainly it can be hard to find a way to engage and use your skills to make a help others . Safeguarding others one of the simplest ways that each of us can do our part to help slow the spread of COVID-19, and protect those around us.
Possible next steps?
There are so many ways that you can extend this solution to meet your own business needs;
Small tweaks would allow you to see available workforce numbers for any given day.
Lookups for staff details would allow you to ensure that appropriate numbers of first aiders or fire safety wardens are in your premises when they are being used by staff
A self-isolation reporting survey can be created to allow automated emails to be sent to line managers if a staff member reports the need to isolate
We hope that this example provokes ideas for how you might be able to use your GIS skills to colleagues, friends and family.
Figure 7 - Element filtering driven by user interaction
Author
Adam Glover
Adam is a solution architect with Esri Ireland, and all round tinkerer of GIS technology. Adam is based in our Holywood office and is responsible for turning it into a real-time observation station reporting on boat (AIS) and plane (ADSB) locations. Over the past 13 years he has shared his expertise across a wide range of sectors including Local and Central Government, Utilities, Public Safety, Charity and Education. Adam is a lover of all board sports and when disconnected from technology can be found on, over or under the water.