mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Fixes for product transformer
This commit is contained in:
parent
820c76ea4d
commit
deffec538b
@ -74,7 +74,7 @@ class ProductTransformer extends EntityTransformer
|
|||||||
'notes' => $product->notes ?: '',
|
'notes' => $product->notes ?: '',
|
||||||
'cost' => (float) $product->cost ?: 0,
|
'cost' => (float) $product->cost ?: 0,
|
||||||
'price' => (float) $product->price ?: 0,
|
'price' => (float) $product->price ?: 0,
|
||||||
'quantity' => (float) is_numeric($product->quantity) ? $product->quantity : 1.0,
|
'quantity' => is_numeric($product->quantity) ? (float) $product->quantity : (float) 1.0,
|
||||||
'tax_name1' => $product->tax_name1 ?: '',
|
'tax_name1' => $product->tax_name1 ?: '',
|
||||||
'tax_rate1' => (float) $product->tax_rate1 ?: 0,
|
'tax_rate1' => (float) $product->tax_rate1 ?: 0,
|
||||||
'tax_name2' => $product->tax_name2 ?: '',
|
'tax_name2' => $product->tax_name2 ?: '',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user