Announcement

Collapse
No announcement yet.

Sum of Entity Field in Report

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Sum of Entity Field in Report

    Hello,

    I have an entity that tracks hours of employees for an activity. The entity has the ability to add multiple users as sometimes it involves other employees.

    What I am looking for is to keep a running total of total hours for this entity type. I am not very knowledgeable on writing scripts and there isn't really an example for this in the documentation.

    Essentially it looks like this.

    A user creates a new record for the entity. They select the users that are involved in the activity, which has the duration calculated automatically as it's considered an event. The total duration should be added to a field within the users profile that I added as a Float number. Each time an activity is created, it takes the previous sum of hours and adds the new amount to this field.

    What would be the best way to achieve this?

    Thanks

  • #2
    I have figured that a workflow is going to be the best choice for this. So here is what I need help with, after the record is saved, I want the workflow to take the value of the recorded entry and add it to the running total field in a users profile.

    On the actions, I have Update Related Entity, in which I link the field that holds the running total. The only part I need help with now is the formula.

    What would be the correct formula that takes the value of a field of the record being saved and adds it to a field of another entity?

    Comment

    Working...
    X