I have to fields: "Time Spent" and "Total Time". Here is my

I have to fields: "Time Spent" and "Total Time". Here is my scenario. A user wishes to have a simple time tracking system setup for tasks. He opens a record (form) and enters 3 in Time Spent and upon Closing the 3 also appears in Total Time. The next day he enters Time Spent 4 and Total Time is now 7. As you can see I want to add the Time Spent to the Total Time so they can track how much time they spend on a given task. Any thoughts? Thanks!...

OriginalPostID-75987

OriginalPostID-75987

  Discussion posts and replies are publicly visible

  • There are many ways to approach this, the following is the first that comes to mind:

    Have a User Input task with a read-only field for 'Total Time' and an editable field for 'Time Spent.' The user kicks off the action, enters the time spent, and click submit. The flow routes through an XOR gateway, adds the 'Time Spent' to 'Total Time,' and returns to the task. The user now has a task that shows the updated 'Total Time' and the field to enter another 'Time Spent' value. When the user is finished entering times for this task, the user clicks another button, 'Complete,' and the flow routes through the XOR and ends the process.
  • Another idea: If the form where you capture the time spent and display the "Total Time" could be a Quick Task (so it would show under "retaled actions" in the Record view) then the setup could be much easier.
    As Colton said, design the form so that you have an editable "Time Spent" field and a read only "Total Time". Total time should be pre-populated from a PV storing the total time. "Time Spent" should be mapped to an ACP.
    In the Output tab of the node create a custom output and set it up to:
    =ac!timeSpent + pv!totalTime
    and store that into the totalTime pv.

    That's it! Next time the Quick task is accessed via the related actions, you will see the latest value.

    Side notes: Be sure to play around with the Other tab memory options such as "Delete Previously Complete instances" to save memory.

    Also, if the time spent is based on the time spent working on certain Appian Tasks, this could also be calculated automatically using the task start and completion times.
  • great guys thanks for the input! I'll give them a shot!