fix invoice number has decimals

This commit is contained in:
edmondlang
2023-09-28 19:20:11 +08:00
parent d740a0fac9
commit 4c972e63cf
@@ -34,7 +34,7 @@ class GeneratesTransactionBillNumber
$attempt = 0;
while ($attempt < 10) { // Retry up to 10 times
$billNumber = $prefix . $date->format('Y') . $date->format('m') . '-' . microtime(true);
$billNumber = $prefix . $date->format('Y') . $date->format('m') . '-' . intval(microtime(true));
if (!$this->checksIfTransactionBillNumberExists->execute($billNumber)) {
return $billNumber;
}