import Invoices fails silently if list price not included
When importing an invoice the import fails with no warning if a list price is not given.
If the vtiger_fields table is modified to make the list price mandatory. then the import interface correctly warns the user that the import requires a list price
Unfortunately the import then fails silently!
This appears to be happening because the listprice fields in the original import data is deleted at line 1304 in include/utils/InventoryUtils.php
Now because the listprice has been made a mandatory field transformForImport at line 1318 of the same file fails
The naive solution is to make the field mandatory as mentioned and then change line 130 and 1304 to the following
if($fieldName != 'productid'
&& $fieldName != 'listprice'
) $inventoryFieldData[$fieldName] = '';
an alternative is to change the line at 1318 to
$fieldData = $obj->transformForImport($inventoryFieldData, $inventoryMeta
,false
);
to disable mandatory field checking
I do not know if this will have other side effects.