This has worked fine up to 7.0.175.
I'm doing some plugins in 7.2 and I am finding that both those events fire when a sales order is loaded also, not just when a line is added.
The only event which seems to fire as a sales order line is added is SalesOrder.SalesOrderLines.AddInventoryItemStart. The problem with AddInventoryItemsStart is that it has the following arguments
- Code: Select all
string inventorySeed, JiwaFinancials.Jiwa.JiwaSales.SalesOrder.SalesOrderLineCollection.SalesOrderLineInventorySeedTypes KitSeedType, ref object NewKey ,JiwaFinancials.Jiwa.JiwaSales.SalesOrder.SalesOrderLine KitHeader, int LineNumber)
but the SalesOrderLine object KitHeader is null.
So I guess the issue is twofold
i) The line adding events fire even if you're just loading a sales order, it shouldbe when a new item is added
ii) The KitHeader object passed into AddInventoryItemsStart is null. Shouldn't it be the line object?
Cheers