jeudi 28 mars 2019

What is the best way to assign a user ID - Laravel

I'm creating an advert like this

public function store(Request $request) 
{
    $advert = PropertyAdvertisement::create($request->all());
    return response()->json($advert);
}

What is the best way to attach a user_id on the advert model?



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire