-@new_i_task = @new_i_task || ITask.new(:admin_id => current_admin.id, :i_website_id => (@i_website.id if @i_website), :end_at => (Date.today + 2.day)) -if @i_task_project -@new_i_task.i_website = @i_task_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_website_id, :label => false, :placeholder => "Projet :", :collection => IWebsite.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 -if f.object.id %td{:style => "width:100px;"}= f.input :minutes_done, :label => false, :placeholder => "Temps passé (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:10px 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; } }