[Rails] Re: Store search paramters in database based on the current_user

2009-07-30 Thread jhaagmans
> Hi Jaap, > > Zie dat je ned bent, dus ik vervolg in het ned. Prima! > > Het gewenste proces is als volgt. > > 1)Gebruiker logt in > 2)Zoekt in zoekbox op vertrek en aankomst + datum (bijv amst - > barcelona, 22 maart 2010) > 3)Waarde van de zoekbox (search[params] moeten worden doorgegeven aan

[Rails] Re: Store search paramters in database based on the current_user

2009-07-30 Thread Remco Swoany
jhaagmans wrote: > If I understand correctly you want to log these searches in the > database, so you would probably want to do something like: > > Search.new(:date => params[:date], :arrival => params > [:arrival], :departure => params[:departure], :user_id => > current_user.id).save > > You mi

[Rails] Re: Store search paramters in database based on the current_user

2009-07-30 Thread jhaagmans
If I understand correctly you want to log these searches in the database, so you would probably want to do something like: Search.new(:date => params[:date], :arrival => params [:arrival], :departure => params[:departure], :user_id => current_user.id).save You might need to change current_user.i