I'm New in Laravel I controller trying to get decrement (subtract) two input request value and pass result in ( balance_amount ) column.
example
input price request 100
input paid_amount request 50
result balance_amount 50
my Controller
public function pay(Request $request)
{
$request['price'] = $request->price;
$request['paid_amount'] = $request->paid_amount;
$request['balance_amount'] = $request->balance_amount;
Installment::create($request);
}
return redirect( )->with('success',' PAID SUCCESSFULLY');
}
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire