Hello,
I have implemented a user required where the packing is done for an intercompany sales order in company B which in turn will do the packing of a related sales order in company A (By means of a packing PO).
The code is as follows:
SalesFormLetter salesFormLetter = SalesFormLetter::construct(DocumentStatus::PackingSlip);
salesFormLetter.interCompanyPosted(true);
salesFormLetter.update(salesTableInterco,
DateTimeUtil::getSystemDate(DateTimeUtil::getUserPreferredTimeZone()),
SalesUpdate::All,
AccountOrder::None,
NoYes::No,
NoYes::No,
NoYes::No);
However, there is an issue where the packing slip of the sales order in company A is generated upon packing. This is not the desired outcome as the codes will do the intercompany packing for multiple records. This will cause a problem.
Is there any way to set the intercompany packing print form letter to false in this scenario?
The problem is that the value of the field PrintSalesPackingslip is true in the table InterCompanyEndpointActionPolicy for the corresponding vendor. This is what causes the print form letter. The user wishes for the parameter to remain true but however bypass the parameter when called in my custom logic. Is there any way to do it?
André Arnaud de Cal...
291,979
Super User 2025 Season 1
Martin Dráb
230,848
Most Valuable Professional
nmaenpaa
101,156