Add checking if invoice has items before getting customer tags. #558

This commit is contained in:
Korina Cordero 2021-05-10 03:52:00 +00:00
parent d99bfedb01
commit 02bf16e787

View file

@ -71,7 +71,9 @@ class ResqInvoiceGenerator implements InvoiceGeneratorInterface
$cust_tag_info = []; $cust_tag_info = [];
if ($stype == ServiceType::BATTERY_REPLACEMENT_NEW) if ($stype == ServiceType::BATTERY_REPLACEMENT_NEW)
{ {
error_log('calling getCustomerTagInfo'); // check if criteria has entries
$entries = $criteria->getEntries();
if (!empty($entries))
$cust_tag_info = $this->getCustomerTagInfo($cv); $cust_tag_info = $this->getCustomerTagInfo($cv);
} }
// error_log($stype); // error_log($stype);