gitlabhq/app/views/snippets/_form.html.haml
Dmitriy Zaporozhets c1c64d985e css refactor
2011-11-12 14:45:32 +02:00

27 lines
705 B
Plaintext

%div
= form_for [@project, @snippet] do |f|
-if @snippet.errors.any?
%ul
- @snippet.errors.full_messages.each do |msg|
%li= msg
%table.round-borders
%tr
%td= f.label :title
%td= f.text_field :title, :placeholder => "Example Snippet"
%tr
%td= f.label :file_name
%td= f.text_field :file_name, :placeholder => "example.rb"
%tr
%td= f.label "Lifetime"
%td= f.select :expires_at, lifetime_select_options
%tr
%td{:colspan => 2}
= f.label :content, "Code"
%br
%br
= f.text_area :content
.actions.prepend-top
= f.submit 'Save', :class => "button"