I’m trying to find a way to modify the Undo Purchase Receipt function to use today’s date as the posting date. I have tried changing the date through multiple event subscribers on codeunit 22 “Item Jnl.-Post Line” but it always ends up reverting back the original receipt date when the item ledger entry is posted. Where does it keep grabbing the original receipt date from?
We want to do this because we often have to return items multiple weeks after the original receipt date if it takes a long time for QA to finish inspection. We don’t like using the Purchase Return Order because users often post it with the wrong unit cost. Also, this requires us to have to add a new line to the original PO to re-receive the replacement item from the vendor. This makes the PO look like it has duplicate lines on it.