-@new_i_task = @new_i_task || ITask.new(:admin_id => current_admin.id, :i_task_project_id => (@i_taks_project.id if @i_taks_project))

-new_var = new_var || false


.task_form_wrapper

  =semantic_form_for [:admin, (new_var ? @new_i_task : @i_task)], :remote => true do |f|

    .content.task_form
      %table{:style => "width:100%;"}
        =f.inputs do
          %tr
            %td{:style => "width:120px;"}= f.input :admin_id, :label => false, :collection => Admin.all, :as => :select, :include_blank => true, :member_label => :show_name
            %td{:style => "width:200px;"}= f.input :i_task_project_id, :label => false, :placeholder => "Projet :", :collection => ITaskProject.all, :as => :select, :include_blank => true
            %td= f.input :name, :label => false, :placeholder => "Libélé" 
            %td{:style => "width:100px;"}= f.input :minutes, :label => false, :placeholder => "Temps estimé (min)" , :as => :string
            %td{:style => "width:120px;"}= f.input :end_at, :label => false, :placeholder => "Echéance", :as => :date
            %td{:style => "width:20px;"}=f.submit "OK !", :class => "btn btn-primary"
          
    :scss
      #qi_pane_hover{
        table, tr, td, tbody{
          display:block !important;
          width:auto !important;
        }
        td{
          padding-bottom:10px !important;
        }
      
      }
    
    
      #new_i_task_form{
        .task_form_wrapper{
          position:fixed;
          bottom:0;
          left:100px;
          right:0;
          background:white;
          padding:20px 20px;
          box-shadow:0 0 5px rgba(0,0,0,0.5);
          z-index:1;
        
        
        }
        
      }
      .task_form{
        input{
          margin:0;
        }
        td{
          padding:0;
        }
        .form-group{
          padding:0;
          margin:0;
        }
      }
      
      
      
  