Commit c59ac0a0da8ef57f8e817a94cabe6acd0534d7d4
1 parent
b004dee3
Exists in
staging
and in
27 other branches
Adds time to article's publish date
Signed-off-by: Gabriel Silva <gabriel93.silva@gmail.com> Signed-off-by: Marcos Ronaldo <marcos.rpj2@gmail.com>
Showing
2 changed files
with
14 additions
and
1 deletions
Show diff stats
app/views/cms/_text_fields.html.erb
1 | -<%= labelled_form_field(_('Publish date'), date_field('article[published_at]', @article.published_at || DateTime.current, {:max_date => '+0d', :date_format => 'yy-mm-dd'}, {:id => "article_published_at"})) %> | |
1 | +<%= labelled_form_field(_('Publish date'), date_field('article[published_at]', @article.published_at || DateTime.current, {:max_date => '+0d', :time => true}, {:id => "article_published_at"})) %> | ... | ... |
features/edit_article.feature
... | ... | @@ -281,3 +281,16 @@ Feature: edit article |
281 | 281 | And I press "Save" |
282 | 282 | Then I should not see "Language must be choosen" |
283 | 283 | And I should be on /joaosilva/article-in-portuguese |
284 | + | |
285 | + @selenium | |
286 | + Scenario: create an article with time | |
287 | + Given I am on joaosilva's control panel | |
288 | + And I follow "Manage Content" | |
289 | + And I follow "New content" | |
290 | + When I follow "Text article with visual editor" | |
291 | + And I fill in "Title" with "My time testing Article" | |
292 | + And I fill in "Publish date" with "1980-11-15 20:37" | |
293 | + And I press "Save" | |
294 | + And I go to /joaosilva/my-time-testing-article | |
295 | + Then I should see "November 15, 1980 20:37" | |
296 | + | ... | ... |