From 8f597194e019b992b8608c10c83392401a4b58a8 Mon Sep 17 00:00:00 2001 From: nathangray Date: Mon, 13 Mar 2017 08:38:45 -0600 Subject: [PATCH] Fix Planner sitemanager module no longer navigated. Due to missing state variables mostly --- calendar/js/app.js | 3 ++- calendar/sitemgr/class.module_calendar_planner.inc.php | 5 ++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/calendar/js/app.js b/calendar/js/app.js index de09a1337c..e7940e4092 100644 --- a/calendar/js/app.js +++ b/calendar/js/app.js @@ -4047,6 +4047,7 @@ jQuery.extend(app.classes.calendar,{ return app.classes.calendar.views[app.calendar.state.planner_view].scroll.call(this,delta); } var d = new Date(app.calendar.state.date); + var days = 1; // Yearly view, grouped by month - scroll 1 month if(app.calendar.state.sortby === 'month') @@ -4062,7 +4063,7 @@ jQuery.extend(app.classes.calendar,{ if(app.calendar.state.first && app.calendar.state.last) { var diff = new Date(app.calendar.state.last) - new Date(app.calendar.state.first); - var days = Math.round(diff / (1000*3600*24)); + days = Math.round(diff / (1000*3600*24)); } d.setUTCDate(d.getUTCDate() + (days*delta)); if(days > 8) diff --git a/calendar/sitemgr/class.module_calendar_planner.inc.php b/calendar/sitemgr/class.module_calendar_planner.inc.php index 61a1482bf5..74f2ce3a51 100644 --- a/calendar/sitemgr/class.module_calendar_planner.inc.php +++ b/calendar/sitemgr/class.module_calendar_planner.inc.php @@ -338,7 +338,10 @@ class module_calendar_planner extends Module $html .= '