https://www.redmine.org/https://www.redmine.org/favicon.ico?16793021292013-02-26T02:49:08ZRedmineRedmine - Defect #13260: JQuery Datepicker popup is missing multiple month/year modifiershttps://www.redmine.org/issues/13260?journal_id=460792013-02-26T02:49:08ZMischa The Evil
<ul><li><strong>Subject</strong> changed from <i>Issues calendar popup missing year modifiers</i> to <i>JQuery Datepicker popup is missing multiple month/year modifiers</i></li><li><strong>Category</strong> changed from <i>Issues planning</i> to <i>UI</i></li><li><strong>Status</strong> changed from <i>New</i> to <i>Confirmed</i></li></ul><p>Zach La Celle wrote:</p>
<blockquote>
<p>We just upgraded from Redmine 1.4 to Redmine 2.2. Someone noticed that, when changing the "due date" for issues using the calendar pop-up, there is no longer a way to move directly between years: only to move between months. There used to be a second button to click on that would move you forward-backward by year.</p>
</blockquote>
<p>Indeed, you're right. That button, and the ability to quickly change month/year using a drop-down menu, was a specific feature provided by the third-party javascript datepicker script called "The DHTML Calendar" (<a class="source" href="https://www.redmine.org/projects/redmine/repository/svn/revisions/10068/entry/trunk/public/javascripts/calendar">source:trunk/public/javascripts/calendar@10068</a>). Thar script has been replaced with the JQuery Datepicker in <a class="changeset" title="Use JQuery Datepicker (#11445)." href="https://www.redmine.org/projects/redmine/repository/svn/revisions/10069">r10069</a>, which itself was part of the general switch from Prototype/Scriptaculous to JQuery done for <a class="issue tracker-2 status-5 priority-4 priority-default closed" title="Feature: Switch from Prototype to JQuery (Closed)" href="https://www.redmine.org/issues/11445">#11445</a> (Redmine <a class="version" href="https://www.redmine.org/versions/47">2.1.0</a>).</p>
<p>The JQuery datepicker however has a comparable feature (<a class="external" href="http://jqueryui.com/resources/demos/datepicker/dropdown-month-year.html">http://jqueryui.com/resources/demos/datepicker/dropdown-month-year.html</a>) which can be enabled by setting the <code>changeMonth</code> and <code>changeYear</code> booleans to <code>true</code> in <a class="source" href="https://www.redmine.org/projects/redmine/repository/svn/revisions/11486/entry/trunk/app/helpers/application_helper.rb">source:trunk/app/helpers/application_helper.rb@11486</a>:</p>
<pre><code class="diff syntaxhl"><span class="gh">Index: application_helper.rb
===================================================================
</span><span class="gd">--- application_helper.rb (revision 11486)
</span><span class="gi">+++ application_helper.rb (revision head)
</span><span class="p">@@ -1076,7 +1076,7 @@</span>
"var datepickerOptions={dateFormat: 'yy-mm-dd', firstDay: #{start_of_week}, " +
"showOn: 'button', buttonImageOnly: true, buttonImage: '" +
path_to_image('/images/calendar.png') +
<span class="gd">- "', showButtonPanel: true, showWeek: true, showOtherMonths: true, selectOtherMonths: true};")
</span><span class="gi">+ "', showButtonPanel: true, showWeek: true, showOtherMonths: true, selectOtherMonths: true, changeMonth: true, changeYear: true};")
</span> jquery_locale = l('jquery.locale', :default => current_language.to_s)
unless jquery_locale == 'en'
tags << javascript_include_tag("i18n/jquery.ui.datepicker-#{jquery_locale}.js")
</code></pre>
<p>This issue can be considered a regression in functionality IMHO. I'd suggest to enable those two options by default to complete (along with <a class="changeset" title="Small datepicker improvements (#13098). Patch by Daniel Felix." href="https://www.redmine.org/projects/redmine/repository/svn/revisions/11335">r11335</a> for <a class="issue tracker-3 status-5 priority-4 priority-default closed" title="Patch: Small datepicker improvements (Closed)" href="https://www.redmine.org/issues/13098">#13098</a>) the switch to the JQuery datepicker without losing any features.<br />Any feedback?</p> Redmine - Defect #13260: JQuery Datepicker popup is missing multiple month/year modifiershttps://www.redmine.org/issues/13260?journal_id=461032013-02-26T11:28:03ZEtienne Massip
<ul><li><strong>Target version</strong> set to <i>Candidate for next major release</i></li></ul> Redmine - Defect #13260: JQuery Datepicker popup is missing multiple month/year modifiershttps://www.redmine.org/issues/13260?journal_id=461202013-02-26T17:55:55ZJan Niggemann (redmine.org team member)jan.niggemann@redmine.org
<ul></ul><p>Mischa The Evil wrote:</p>
<blockquote>
<p>This issue can be considered a regression in functionality IMHO. I'd suggest to enable those two options by default<br />Any feedback?</p>
</blockquote>
<p>Yes: You're right :-)</p> Redmine - Defect #13260: JQuery Datepicker popup is missing multiple month/year modifiershttps://www.redmine.org/issues/13260?journal_id=467502013-03-17T11:54:30ZDaniel Felix
<ul><li><strong>Target version</strong> changed from <i>Candidate for next major release</i> to <i>2.4.0</i></li></ul><p>This is a smaller fix which is already given. <br />I set this to 2.4. :-)</p> Redmine - Defect #13260: JQuery Datepicker popup is missing multiple month/year modifiershttps://www.redmine.org/issues/13260?journal_id=471042013-03-19T21:53:50ZJean-Philippe Langjp_lang@yahoo.fr
<ul><li><strong>Status</strong> changed from <i>Confirmed</i> to <i>Closed</i></li><li><strong>Resolution</strong> set to <i>Fixed</i></li></ul><p>Added in <a class="changeset" title="JQuery Datepicker popup is missing multiple month/year modifiers (#13260)." href="https://www.redmine.org/projects/redmine/repository/svn/revisions/11663">r11663</a>.</p> Redmine - Defect #13260: JQuery Datepicker popup is missing multiple month/year modifiershttps://www.redmine.org/issues/13260?journal_id=541312014-01-05T22:55:17ZAdrian Harris
<ul></ul><p>Datepicker with every new version changes some options, be very attentive: [[<a class="external" href="http://basicuse.net/articles/pl/scripting_languages/javascript/jquery_ui_widgets_datepicker_calendar">http://basicuse.net/articles/pl/scripting_languages/javascript/jquery_ui_widgets_datepicker_calendar</a>]]</p>