ruby on rails - ActiveAdmin page not displaying form_tag form alongside other content -


i have activeadmin page want use upload variety of files various controllers:

activeadmin.register_page "import"     content         columns              column                 panel "overview"                     para "this admin import page."                 end             end             column                 panel "update/import matters"                     para "this info form should take."                     form_tag import_matters_path, multipart: true                         file_field_tag :file                         submit_tag "import"                     end                 end             end         end     end end 

the page displays, right hand column displays panel text "this info..." when comment out line, import button no way upload file. when comment out submit_tag , para line, 'choose file' button select file import, nothing else.

the panel seems unable concatenate html form properly, i'm not clear how myself.

i ended using partial seemed fix issue. ended panel looking this:

panel "update/import matters"     para "some info form."     render 'matters_form' end 

and /app/views/admin/import/_matters_form.html.erb:

<%= form_tag import_matters_path, multipart: true %>     <%= file_field_tag :file %>     <%= submit_tag "import" %> <% end %> 

this might not way, partials worked in situation.


Comments

Popular posts from this blog

html - Firefox flex bug applied to buttons? -

html - Missing border-right in select on Firefox -

c# - two queries in same method -