1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-10 05:02:36 +01:00

Fix for invoice number pattern

This commit is contained in:
Hillel Coren 2017-11-21 11:36:17 +02:00
parent d9facaa060
commit 34d8b68f63

View File

@ -136,6 +136,10 @@ trait GeneratesNumbers
*/
public function hasClientNumberPattern($invoice)
{
if (! $this->isPro()) {
return false;
}
$pattern = $invoice->invoice_type_id == INVOICE_TYPE_QUOTE ? $this->quote_number_pattern : $this->invoice_number_pattern;
return strstr($pattern, '$client') !== false || strstr($pattern, '$idNumber') !== false;