


= semantic_form_for [:admin,@menu_item], :remote => true do |form| 
  .content
    %h3 Ajouter un élément de menu
    .form1=render :partial => "form", :locals => {:form => form}



    #select_menu_item_content_type_bar.bar.dark_blue
      -MenuItem::ContentTypes.each do |menu_item_content_type|
        =link_to menu_item_content_type[:name], new_admin_menu_item_path(:menu_id => @menu_item.menu_id, :parent_id =>@menu_item.parent_id, :menu_item_content_type => menu_item_content_type[:slug] ), :onclick => "$('#menu_item_content_form').load($(this).attr('href')+' #menu_item_content_form');$('#select_menu_item_content_type_bar .btn-primary').removeClass('btn-primary');$(this).addClass('btn-primary');return false;",:class => "btn btn-default "+("btn-primary" if menu_item_content_type[:slug] == @menu_item.menu_content_type).to_s
    #menu_item_content_form.form2
      = form.inputs do 
        = form.input :menu_content_type,:as => :hidden
      =render :partial => "admin/"+@menu_item.menu_content_type.tableize.to_s+"/form", :locals => {:form => form}



  .actions
    = form.submit "Sauvegarder", :class => "btn btn-primary"



