cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Runtime Permissions and Source

Participant

Runtime Permissions and Source

I have a user that is assigned to a single thing via the OU structure. I use a calculation service to use the value of the thing as a source in the mashup to do a basic calculation. This is all working as it should.

Where I am struggling is with assigning multiple things to a single user in order to add up the thing value using the source in the mashup.

To put this into context:

We have a building where each individual apartment has a cold water meter and a hot water meter. Our app allows the user to monitor the TOTAL water consumption per hour. So effectively we need to add the 2-meter values together and display it on a Bar chart in the mashup.

Please advise, as we have been through all of the snippets etc and cannot figure out a way to do this.
2 REPLIES 2

Re: Runtime Permissions and Source

Hi @Darryl to better understand the situation could you please clarify if these values which you want to Total up for each user are being stored in separate Things? Or are these values being entered manually at mashup's runtime?

 

Generically speaking this could be done via an InfoTable / DataTable that could pre-calculate and store Total values which you can pull via a service to display this Total value on the Bar chart.

Re: Runtime Permissions and Source

Assuming that a user has proper visibility and property read permissions.

1. retrieve the Things and their property values (something like GetImplementingThingsWithData for example)

2. use DeriveFields to create the aggregated column (Here is an example that pulls in additional properties, but you can do mathematical logic as well https://community.ptc.com/t5/IoT-AR-Tech-Tips/Powerful-Things-you-can-do-with-DeriveFields/m-p/53526...)

 

Announcements

Thingworx Navigate content has a new home! Click here to access the new Thingworx Navigate forum! ______________________________