Commit 5a1f2908291290df5067ffc2f79013cbfebfedfe
1 parent
e579c815
Exists in
master
and in
29 other branches
Added datepicker on steps
(ActionItem2837)
Showing
3 changed files
with
14 additions
and
2 deletions
Show diff stats
604 Bytes
plugins/community_track/public/style.css
@@ -193,3 +193,9 @@ | @@ -193,3 +193,9 @@ | ||
193 | .community-track textarea { | 193 | .community-track textarea { |
194 | width: 100%; | 194 | width: 100%; |
195 | } | 195 | } |
196 | + | ||
197 | +.formfield input#datepicker-from-date, | ||
198 | +.formfield input#datepicker-to-date { | ||
199 | + width: 115px; | ||
200 | + background: url(/plugins/community_track/icons/calendar.png) right center no-repeat; | ||
201 | +} |
plugins/community_track/views/cms/community_track_plugin/_step.rhtml
@@ -4,8 +4,14 @@ | @@ -4,8 +4,14 @@ | ||
4 | 4 | ||
5 | <div> | 5 | <div> |
6 | <%= required f.text_field('name', :size => '64', :maxlength => 150) %> | 6 | <%= required f.text_field('name', :size => '64', :maxlength => 150) %> |
7 | - <%= labelled_form_field(_('Start date'), pick_date(:article, :start_date)) %> | ||
8 | - <%= labelled_form_field(_('End date'), pick_date(:article, :end_date)) %> | 7 | + <%= labelled_form_field(_('Period'), ( |
8 | + date_range_field('article[start_date]', 'article[end_date]', @article.start_date, @article.end_date, | ||
9 | + '%Y-%m-%d', | ||
10 | + { :change_month => true, :change_year => true, | ||
11 | + :date_format => 'yy-mm-dd' }, | ||
12 | + { :size => 14 }) | ||
13 | + )) %> | ||
14 | + | ||
9 | </div> | 15 | </div> |
10 | 16 | ||
11 | <%= labelled_form_field check_box(:article, :hidden) + _('Hidden Step'), '' %> | 17 | <%= labelled_form_field check_box(:article, :hidden) + _('Hidden Step'), '' %> |