Reference:
https://laravel.com/docs/5.6/eloquent#insert-update-delete
Reference code:
here: inside store function, updateorcreate([1],[2]);
1: database maa store garyaa data ko change nahuni attribute to assure which to update
2: update garni data along with not changing data.
https://laravel.com/docs/5.6/eloquent#insert-update-delete
Reference code:
here: inside store function, updateorcreate([1],[2]);
1: database maa store garyaa data ko change nahuni attribute to assure which to update
2: update garni data along with not changing data.
SeatPrice::updateOrCreate(['busno' => $busno,'seattype' => $request->input($seattype)],[
'busno' => $busno,
'seattype' => $request->input($seattype),
'price' =>$request->input($price),
]);
Comments
Post a Comment