lundi 19 décembre 2016

Rails3. Create new record in db using 2 ids

Db Cart must have user_id, product_id. There is some method like

 @user = current_user
 @photo = @user.photos.build(params[:photo])

for creating new record but using 2 ids?

Aucun commentaire:

Enregistrer un commentaire