Update Value of LaborQty on Kinetic MES Work Queue, Active

Goal: Update the LaborQty field to 0.00 on the MES Work Queue, Active Tab when the page loads

Why do I want to do this? If an operator starts working on a job with qty left to complete, the system will put the operator’s last run quantity into the LaborQty field. This confuses them and contributes to wrong labor qty.

I created an event after SelectAllForWork to row update the ActiveWork.LaborQty value to 0.00. This event is working for the first row only.

I then followed the instructions to Iterate Dataview rows to update values. Kinectic Application Studio - Iterate Dataview rows to update values - #2 by klincecum
It is iterating but only updating the first row. After the first iteration, event ColumnChanged_LaborQty triggers. It does not get re-triggered after the 2nd and 3rd iteration to update the LaborQty to 0.00.

There is a second problem to my plan and it is if an operator starts labor active and has jobs on the Active tab, then logs out (not clocks out) of MES, when they log back in to the Active Work Queue tab, the Labor Qty reverts back to old numbers because SelectAllForWork never fires.

Questions)
When should I try to set the LaborQty to 0.00? Remember this is not the final labor qty but just the LaborQty for when the Active work queue page loads.
Should I be trying to accomplish this as an event or as a function as described in this post Update multiple rows in grid - #10 by hmwillett

This usually points to a wrong setting in your iterative event.

Your dataview-condition should look something like this:

In your iterative event… I’m assuming you’re doing a row-update?

Make sure that row-update is updating the Ep Binding of matches.LaborQty (or whatever the column is your trying to update). NOT ActiveWork.LaborQty.

For this portion, you’ll just need to watch what events fire and perform you dataview-condition event there as well. Possible you might need two events, one that fires after SelectAllForWork… and one that fires after whatever event you can identify that runs when they log back in to the Active Work Queue tab.

Thank you David for giving me confidence to continue on the path of the dataview-condition and thank you for giving me tips for getting it to work.

Many iterations…and with your help, I finally have it.


Result:


:grinning_face:

Next task, create a second event to deal with the logging in and going back to the active work queue.