search for: user_param

Displaying 3 results from an estimated 3 matches for "user_param".

Did you mean: user_params
2014 Mar 25
0
Looking for some glue between Strong Parameters and CanCan
Hello Rails World, does anybody know a good solution for Strong Parameters in a Rails app authorized by Cancan (or a similar authorization gem)? def user_params if current_user.admin? params.require(:user).permit! else params.require(:user).permit(:password, :password_confirmation) end end Now I want to do this the "Cancan way". My first idea looks strange to me: def user_params if can? :edit_all_attributes, User params.req...
2014 Jun 08
0
Re-render partial inside a modal
...sers/form', :controller=>"users", :action =>"new" %> <a class="close-reveal-modal">&#215;</a> </div> *In my Users.controller.rb, I am rendering new sign up page if user inputs incorrect information! * def create @user = User.new(user_params) if @user.save # session[:remember_token] = @user.id # @current_user = @user # session[:remember_token] = @user.id.to_s flash.now[:success] = "You have succesfully signed up!" redirect_to users_path else render 'new' end end *What I actually want to accomplish is...
2016 Mar 10
4
[PATCH mesa 3/3] nouveau: Add support for clover / OpenCL kernel input parameters
On 04:27 PM - Mar 10 2016, Samuel Pitoiset wrote: > > > On 03/10/2016 04:23 PM, Ilia Mirkin wrote: > >On Thu, Mar 10, 2016 at 10:14 AM, Hans de Goede <hdegoede at redhat.com> wrote: > >>Add support for clover / OpenCL kernel input parameters. > >> > >>Signed-off-by: Hans de Goede <hdegoede at redhat.com> > >>--- > >>