I have a list of workers, whom all needs to have an amount paid by way of their hours times a value.
I have a WorkerModel class:
Then I have a CompanyModel that contains the workers:
And then I have a ViewModel that allows me to bind to the view:
Lastly my view looks like this:
My goal is to have the HoursWorking from the WorkerModel, multiply with the PayoutPerHour thats in the ViewModel. I have in this example made the PayoutPerHour a static value, which it is not in my full example. I need the Expressioncolumn to update whenever either of those two properties are updated. But I can't tell the viewmodel what the WorkerModel is doing, since they are in a collection in the CompanyModel.
Any clever way to do this?