[Vtigercrm-developers] Inventory Record copying
Alan Lord
alanslists at gmail.com
Mon Nov 6 10:52:21 GMT 2017
> See function "saveInventoryProductDetails()" in
> include/utils/InventoryUtils.php
Sorry, I don't think I was very clear.
In the Salesorder.php class in the save_module function is this bit of
legacy code:
> //in ajax save we should not call this function, because this will delete all the existing product values
> if($_REQUEST['action'] != 'SalesOrderAjax' && $_REQUEST['ajxaction'] != 'DETAILVIEW'
> && $_REQUEST['action'] != 'MassEditSave' && $_REQUEST['action'] != 'ProcessDuplicates'
> && $_REQUEST['action'] != 'SaveAjax' && $this->isLineItemUpdate != false) {
> //Based on the total Number of rows we will save the product relationship with this entity
> saveInventoryProductDetails($this, 'SalesOrder');
> }
This calls saveInventoryProductDetails when the workflow is triggered
when I save a Quote in Edit View, but NOT when I save a Quote in Detail
View. And, of course, from a custom workflow function I do not have
access to a request object. I could interrogate the $_REQUEST super
global but that doesn't seem to be the right way seeing as very little
of the vtiger MVC arch sine version 6 uses this any more.
Al
More information about the vtigercrm-developers
mailing list