ok, the plural got me beyond an error message, but i cant see the uploaded multiuploaded files. singles files work.
controller code:
@folder_attachment = FolderAttachment.new(folder_attachment_params) @folder_attachment.company_id = current_user.cid @folder_attachment.user_id = current_user.id
@folder = Folder.find_by_id(params[:folder_attachment][:folder_id])
respond_to do |format|
if @folder_attachment.save
format.html { redirect_to @folder , notice: 'Attachment was successfully created.' }
# format.json { render :show, status: :created, location: @folder_attachment }
else
format.html { render :new }
# format.json { render json: @folder_attachment.errors, status: :unprocessable_entity }
end
end
def folder_attachment_params params.require(:folder_attachment).permit(:company_id, :folder_id, :singlefile, :comment,:tags, {files: }) end