From df649f1acc0d66a8f7e897ddfeb760d312bb5593 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Thu, 15 Mar 2018 11:27:45 +0100 Subject: [PATCH] fix PHP Warning: A non-numeric value encountered in line 77 caused be not set (NULL) unitprice --- timesheet/inc/class.timesheet_datasource.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/timesheet/inc/class.timesheet_datasource.inc.php b/timesheet/inc/class.timesheet_datasource.inc.php index 31c4f8f738..db6dbbc536 100644 --- a/timesheet/inc/class.timesheet_datasource.inc.php +++ b/timesheet/inc/class.timesheet_datasource.inc.php @@ -74,7 +74,7 @@ class timesheet_datasource extends datasource 'pl_id' => $data['pl_id'], 'pe_unitprice' => $data['ts_unitprice'], 'pe_used_quantity' => $data['ts_quantity'], - 'pe_used_budget' => $data['ts_quantity'] * $data['ts_unitprice'], + 'pe_used_budget' => $data['ts_quantity'] * (float)$data['ts_unitprice'], 'pe_completion' => 100, 'cat_id' => $data['cat_id'], );