<%= ts("Edit Series") %>

<%= render "series/series_navigation" %>
<%= form_for(@series) do |f| %> <%= error_messages_for @series %>

<%= ts("* Required information") %>

<%= ts('Meta') %>
<%= f.label :title, ts("Series Title*"), :class => "required" %>
<%= f.text_field :title, :class => "observe_textlength text" %> <%= live_validation_for_field('series_title', :maximum_length => ArchiveConfig.TITLE_MAX, :minimum_length => ArchiveConfig.TITLE_MIN, :failureMessage => ts("We need a title! (At least %{min_length} characters long, please.)", :min_length => ArchiveConfig.TITLE_MIN.to_s)) %> <%= generate_countdown_html("series_title", ArchiveConfig.TITLE_MAX) %>
<%= render 'pseuds/byline', form: f, object: @series %>
<%= f.label :summary, ts("Series Description", :max => ArchiveConfig.SUMMARY_MAX.to_s) %>
<%= allowed_html_instructions %> <%= f.text_area :summary, :class => "observe_textlength" %> <%= live_validation_for_field('series_summary', :presence => false, :maximum_length => ArchiveConfig.SUMMARY_MAX) %> <%= generate_countdown_html("series_summary", ArchiveConfig.SUMMARY_MAX) %>
<%= f.label :series_notes, ts("Series Notes") %>
<%= allowed_html_instructions %> <%= f.text_area :series_notes, :class => "observe_textlength" %> <%= live_validation_for_field('series_notes', :presence => false, :maximum_length => ArchiveConfig.NOTES_MAX) %> <%= generate_countdown_html("series_notes", ArchiveConfig.NOTES_MAX) %>
<%= f.check_box :complete %>
<%= f.label :complete, ts("This series is complete") %>
<%= ts('Post') %>

<%= f.submit ts("Update") %> <%= link_to ts("Cancel"), series_path %>

<% end %>
<%= content_for :footer_js do %> <%= javascript_tag do %> $j(document).ready(function(){ $j(".toggle_formfield").click(function() { var targetId = $j(this).attr("id").replace("-show", ""); toggleFormField(targetId); }); }) <% end %> <% end %>