From e98078ae7cc4ec1049078ad90a0f1b2f7d03488b Mon Sep 17 00:00:00 2001 From: Bartlomiej Dworak Date: Wed, 11 Mar 2015 01:30:14 -0500 Subject: [PATCH] Fixed budget issues when approving budgets over 999.99 and a ',' was added and throwing off float_val --- app/controllers/AdminBudgetController.php | 2 +- app/views/admin/projects/overview.blade.php | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/controllers/AdminBudgetController.php b/app/controllers/AdminBudgetController.php index 36b513c..789639a 100644 --- a/app/controllers/AdminBudgetController.php +++ b/app/controllers/AdminBudgetController.php @@ -57,7 +57,7 @@ public function approve(){ //must provide request id, comments and budget approval //Post data $comment = Input::get('requestComment'); - $amount = floatval(Input::get('budgetAmount')); + $amount = floatval(str_replace(",","",Input::get('budgetAmount'))); $budgetID = Input::get('requestID'); //Pull the budget request $request = BudgetRequest::find($budgetID); diff --git a/app/views/admin/projects/overview.blade.php b/app/views/admin/projects/overview.blade.php index 6aee359..095ec67 100644 --- a/app/views/admin/projects/overview.blade.php +++ b/app/views/admin/projects/overview.blade.php @@ -12,7 +12,8 @@ Actions