How to post purchase order packing slip with WMSJournalId

I was requested to post the packing slip of purchase order automatically after post the item arrival. Below is the main code to post packing slip with WMSJournal

void SIT_Post_PurchFormLetter_PackingSlip(WMSJournalTable _WMSJournalTable)
{
PurchFormLetter_PackingSlip purchFormLetter_PackingSlip = PurchFormLetter::construct(DocumentStatus::PackingSlip);
;

purchFormLetter_PackingSlip.SIT_ParmWMSJournalId(_WMSJournalTable.journalId);
purchFormLetter_PackingSlip.transDate(today());
purchFormLetter_PackingSlip.update(_WMSJournalTable, _WMSJournalTable.JournalId, today(), PurchUpdate::Recorded);
}

Comments

Gom said…
How did you implement SIT_ParmWMSJournalId? did you have to make other changes? when I try posting packing slip and send the WMSJournalTable parameter I get the packing slip created for all open orders for the respective vendor instead of just the POs that belong to the Arrival journal I am trying to receive.

Popular posts from this blog

Post packing slip of sales order in X++