Skip to content

How to add new attributes to permit? #990

@lun4i

Description

@lun4i

Currently the ApplicationController methods has been changed a bit. resource_params method returns output of permitted params for other class - YourControllerDashboard instead of Admin::YourController. So, permitted_attributes method no longer belongs to the ApplicationController class, and neither used in it.
Let me know if I am wrong at this point, and if I am not - what will be a new solution?
I am digging around trying to use this workaround:

private
def dashboard
  super.permitted_attributes << :image
end

Reopening previous issue:
#207

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions