Files
growstuff/app/views/crops/_form.html.haml
2013-05-02 12:13:28 +10:00

27 lines
1000 B
Plaintext

= form_for @crop, :html => {:class => 'form-horizontal'} do |f|
- if @crop.errors.any?
#error_explanation
%h3= "#{pluralize(@crop.errors.count, "error")} prohibited this crop from being saved:"
%ul
- @crop.errors.full_messages.each do |msg|
%li= msg
%p
%span.help-block
For detailed crop wrangling guidelines, please consult the
=link_to "crop wrangling guide", "http://wiki.growstuff.org/index.php/Crop_wrangling"
on the Growstuff wiki.
.control-group
= f.label :system_name, :class => 'control-label'
.controls
= f.text_field :system_name
%span.help-inline Name in US English; singular; capitalize proper nouns only.
.control-group
= f.label :en_wikipedia_url, 'Wikipedia URL', :class => 'control-label'
.controls
= f.text_field :en_wikipedia_url
%span.help-inline Link to this crop's page on the English language Wikipedia.
.form-actions
= f.submit 'Save', :class => 'btn btn-primary'