supply chain controller

This commit is contained in:
2020-08-07 14:16:56 -05:00
parent ec315dc63f
commit 273cb2b775

View File

@@ -318,8 +318,7 @@ class SupplyChainController extends Controller
'contract_id' => $request->contract_id,
])->select('bids')->get();
//Increase the number of bids by 1
$numBids = $num->bids + 1;
dd($num);
//Update the database
SupplyChainContract::where([
@@ -354,6 +353,11 @@ class SupplyChainController extends Controller
'bid_id' => $bidId,
])->delete();
//Remove 1 from the supply chain contract total bids
$contractBids = SupplyChainContract::where([
]);
return redirect('/supplychain/dashboard')->with('success', 'Deleted supply chain contract bid.');
} else {
return redirect('/supplychain/dashboard')->with('error', 'No bid found to delete.');