28 lines
1.1 KiB
Plaintext
28 lines
1.1 KiB
Plaintext
= semantic_form_for [:admin, @home_block], :remote => true do |form|
|
|
|
|
.form1
|
|
= form.inputs do
|
|
= form.input :title, :label => "Title :"
|
|
= form.input :description,:as => :text , :label => "Description :"
|
|
|
|
|
|
|
|
|
|
#select_cible_type_bar.bar.dark_blue
|
|
-CibleType.all.each do |cible_type|
|
|
=link_to cible_type.name, new_admin_cible_path(:cible_type => cible_type.slug, :resource_type => "HomeBlock" ), :onclick => "$('#link_content_cible_form').load($(this).attr('href')+' #link_content_cible_form_content');$('#select_cible_type_bar .active').removeClass('active');$(this).addClass('active');return false;",:class => ("active" if cible_type.slug == @home_block.cible_type).to_s
|
|
|
|
|
|
|
|
#link_content_cible_form.form2
|
|
#link_content_cible_form_content
|
|
= form.inputs do
|
|
= form.input :cible_type,:as => :hidden
|
|
= form.input :cible_id,:as => :hidden
|
|
=render :partial => "portlet/link_contents/"+@home_block.cible_type.tableize.singularize.to_s+"_form", :locals => {:form => form} if @home_block.cible
|
|
|
|
= form.buttons do
|
|
= form.commit_button "Sauvegarder"
|
|
|
|
|