Commit af45a1f88cf6c36b174af977ac79e56c1e1da04c
Committed by
Rodrigo Souto
1 parent
cfb21027
Exists in
master
and in
12 other branches
edit_article: edit publish date.
resolves #312 and close.
Showing
5 changed files
with
5 additions
and
1 deletions
Show diff stats
app/models/article.rb
... | ... | @@ -9,7 +9,7 @@ class Article < ActiveRecord::Base |
9 | 9 | :highlighted, :notify_comments, :display_hits, :slug, |
10 | 10 | :external_feed_builder, :display_versions, :external_link, |
11 | 11 | :image_builder, :show_to_followers, |
12 | - :author, :display_preview | |
12 | + :author, :display_preview, :published_at | |
13 | 13 | |
14 | 14 | acts_as_having_image |
15 | 15 | ... | ... |
app/views/cms/_raw_html_article.html.erb
... | ... | @@ -2,6 +2,7 @@ |
2 | 2 | |
3 | 3 | <%= required labelled_form_field(_('Title'), text_field(:article, 'name', :size => '64', :maxlength => 150)) %> |
4 | 4 | |
5 | +<%= render :partial => 'text_fields' %> | |
5 | 6 | <%= render :partial => 'general_fields' %> |
6 | 7 | <%= render :partial => 'translatable' %> |
7 | 8 | <%= render :partial => 'shared/lead_and_body' %> | ... | ... |
... | ... | @@ -0,0 +1 @@ |
1 | +<%= labelled_form_field(_('Publish date'), date_field('article[published_at]', DateTime.current, '%Y-%m-%d', {:max_date => '+0d', :date_format => 'yy-mm-dd'}, {:id => "article_published_at"})) %> | ... | ... |
app/views/cms/_textile_article.html.erb
... | ... | @@ -4,6 +4,7 @@ |
4 | 4 | |
5 | 5 | <%= required labelled_form_field(_('Title'), text_field(:article, 'name', :size => '72', :maxlength => 150)) %> |
6 | 6 | |
7 | +<%= render :partial => 'text_fields' %> | |
7 | 8 | <%= render :partial => 'general_fields' %> |
8 | 9 | <%= render :partial => 'translatable' %> |
9 | 10 | <%= render :partial => 'shared/lead_and_body' %> | ... | ... |
app/views/cms/_tiny_mce_article.html.erb
... | ... | @@ -5,6 +5,7 @@ |
5 | 5 | <div> |
6 | 6 | <%= required labelled_form_field(_('Title'), text_field(:article, 'name', :size => '64', :maxlength => 150)) %> |
7 | 7 | |
8 | + <%= render :partial => 'text_fields' %> | |
8 | 9 | <%= render :partial => 'general_fields' %> |
9 | 10 | <%= render :partial => 'translatable' %> |
10 | 11 | <%= render :partial => 'shared/lead_and_body', :locals => {:tiny_mce => true} %> | ... | ... |