I have created am item requisition workflow with MOSS and infopath using SPD. There is one list which contains the item code and the quantity available. At the start the user will create a new infopath form which shows the item code in a drop down list. So the user can select the required item/items and enter the required quantity manually. If the requested qty of a particular item is less than the qty available, then a notification is sent to the relevant manager. The original list is updated (new qty available = qty available - qty requested). Up to this point the work flow is working fine.
Now i am looking for a way to update the same original list, when the manager rejects the approval. If the manager rejects a request then the list should be updated as qty available = qty available + qty requested. If he approves then there is no need to update. How can i achieve this?
The list item contains around 50 items. The problem is upon manager's rejection, how to select the particular item out of these 50 items from the list to be updated. This should be done by comparing the item code in the infopath form against the item code column in the list. But how to run this validation as a loop for the list items.?
thanks in advance for the help