diff --git a/app/Http/Controllers/ContractController.php b/app/Http/Controllers/ContractController.php index 45f55609d..7b5371cf4 100644 --- a/app/Http/Controllers/ContractController.php +++ b/app/Http/Controllers/ContractController.php @@ -69,8 +69,8 @@ class ContractController extends Controller //Count the number of bids, and add them to the arrays foreach($contracts as $contract) { dd($contract); - $tempCount = Bid::where(['contract_id' => $contract['id']])->count('contract_id'); - $bids = Bid::where(['contract_id' => $contract['id']])->get()->toArray(); + $tempCount = Bid::where(['contract_id' => $contract['contract_id']])->count('contract_id'); + $bids = Bid::where(['contract_id' => $contract['contract_id']])->get()->toArray(); $contract['bid_count'] = $tempCount; $contract['bids'] = $bids;