[eGroupWare-svn] r55831 - /trunk/calendar/js/app.js

[email protected]
Newsgroups gmane.comp.web.egroupware.cvs
Message-ID <[email protected]>
Author: nathangray
Date: Mon Apr 25 17:56:23 2016
New Revision: 55831

URL: http://svn.stylite.de/viewvc/egroupware?rev=55831&view=rev
Log:
When calendar list view is switched to custom date range, set range to current state

Modified:
    trunk/calendar/js/app.js

Modified: trunk/calendar/js/app.js
URL: http://svn.stylite.de/viewvc/egroupware/trunk/calendar/js/app.js?rev=55831&r1=55830&r2=55831&view=diff
==============================================================================
--- trunk/calendar/js/app.js (original)
+++ trunk/calendar/js/app.js Mon Apr 25 17:56:23 2016
@@ -1234,8 +1234,15 @@
 		if (filter && dates)
 		{
 			dates.set_disabled(filter.value !== "custom");
-			if (filter.value == "custom")
-			{
+			if (filter.value == "custom" && !this.state_update_in_progress)
+			{
+				// Copy state dates over, without causing [another] state update
+				var actual = this.state_update_in_progress;
+				this.state_update_in_progress = true;
+				view.getWidgetById('startdate').set_value(app.calendar.state.first);
+				view.getWidgetById('enddate').set_value(app.calendar.state.last);
+				this.state_update_in_progress = actual;
+
 				jQuery(view.getWidgetById('startdate').getDOMNode()).find('input').focus();
 			}
 		}


------------------------------------------------------------------------------
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.