journalduhacker/app/views/stories/edit.html.erb

57 lines
1.8 KiB
Plaintext
Raw Normal View History

<div class="box" id="story_box">
<div class="legend">
Edit Story
</div>
<%= form_for @story, :url => story_path(@story.short_id),
2014-02-12 20:14:25 +01:00
:method => :put, :html => { :id => "edit_story" } do |f| %>
<%= render :partial => "stories/form", :locals => { :story => @story,
:f => f } %>
<% if @user.is_moderator? %>
<div class="box">
2014-04-09 00:51:12 +02:00
<div class="boxline">
<%= f.label :merge_story_short_id, "Merge Into:",
:class => "required" %>
<%= f.text_field :merge_story_short_id, :autocomplete => "off",
:placeholder => "Short id of story into which this story " <<
"be merged" %>
</div>
<div class="boxline">
<%= f.label :unavailable_at, "Unavailable:",
:class => "required" %>
<%= f.check_box :is_unavailable %>
<%= f.label :unavailable_at, "Source URL is unavailable, " <<
"enable display of cached text", :class => "normal" %>
</div>
<% if @story.user_id != @user.id %>
<div class="boxline">
<%= f.label :moderation_reason, "Mod Reason:",
:class => "required" %>
<%= f.text_field :moderation_reason, :autocomplete => "off" %>
</div>
<% end %>
</div>
<% end %>
<p></p>
2013-02-14 01:50:51 +01:00
<div class="box">
<div class="boxline markdown_help_toggler">
<div class="markdown_help_label">
2012-07-10 19:16:10 +02:00
Markdown formatting available
</div>
<%= submit_tag "Save" %>
&nbsp;or <a href="<%= story_path(@story.short_id) %>">cancel
2012-07-02 03:09:22 +02:00
editing</a>
<div style="clear: both;"></div>
<%= render :partial => "global/markdownhelp",
:locals => { :allow_images => true } %>
</div>
</div>
<% end %>
</div>