Reputation: 41
Currently, I am using refile for my users to upload photos in their profile. I am trying to be able to add photos to their profile for them through active admin. For some reason, I can't get it to work. Does anyone have an example of working code? This is where I am at.
This is what I have in my user.rb file in active admin
f.inputs "Images Files" do
f.has_many :images do |item|
# item.input :image, :as => :file, :hint => f.attachment_field :images_files, multiple: true, presigned: true, direct: true
item.file_field :images_files, multiple: true, presigned: true, direct: true
end
end
permit_params images: [:created_at, :updated_at, :ambassador_id, :file_id]
Upvotes: 1
Views: 118