Fix issue with getting incorrect end time for separate schedules.
authorSteve Sutton <steve@gaslightmedia.com>
Fri, 17 Aug 2018 12:55:51 +0000 (08:55 -0400)
committerSteve Sutton <steve@gaslightmedia.com>
Fri, 17 Aug 2018 12:55:51 +0000 (08:55 -0400)
Need to check the end and start times.

index.php
views/front/events/agenda.html

index c96393d..6a2c018 100644 (file)
--- a/index.php
+++ b/index.php
@@ -3,7 +3,7 @@
  * Plugin Name: GLM Members Database Events
  * Plugin URI: http://www.gaslightmedia.com/
  * Description: Gaslight Media Members Database.
- * Version: 1.6.93
+ * Version: 1.6.94
  * Author: Chuck Scott
  * Author URI: http://www.gaslightmedia.com/
  * License: GPL2
@@ -19,7 +19,7 @@
  * @package glmMembersDatabaseEventsAddOn
  * @author Chuck Scott <cscott@gaslightmedia.com>
  * @license http://www.gaslightmedia.com Gaslightmedia
- * @version 1.6.93
+ * @version 1.6.94
  */
 
 // Check that we're being called by WordPress.
@@ -43,7 +43,7 @@ if (!defined('ABSPATH')) {
  *  so that we're sure the other add-ons see an up to date
  *  version from this plugin.
  */
-define('GLM_MEMBERS_EVENTS_PLUGIN_VERSION', '1.6.93');
+define('GLM_MEMBERS_EVENTS_PLUGIN_VERSION', '1.6.94');
 define('GLM_MEMBERS_EVENTS_PLUGIN_DB_VERSION', '0.1.6');
 
 // This is the minimum version of the GLM Members DB plugin require for this plugin.
index d640f76..6b0b37c 100644 (file)
                                                     <div class='date-range-container'>
                                                         {if !$event.all_day}
                                                             {$showTime = false}
-                                                            {if $event.starting_date|date_format:"%l:%M %P" == $event.ending_date|date_format:"%l:%M %P"}
-                                                                {$event.starting_date|date_format:"%l:%M %P"}
+                                                            {$event_start_time = $event.starting_date|date_format:"%m/%d/%Y"}
+                                                            {$event_start_time = $event_start_time|cat:' '}
+                                                            {$event_start_time = $event_start_time|cat:$rec.start_time.time}
+                                                            {$event_end_time = $event.starting_date|date_format:"%m/%d/%Y"}
+                                                            {$event_end_time = $event_end_time|cat:' '}
+                                                            {$event_end_time = $event_end_time|cat:$rec.end_time.time}
+                                                            {if $event_start_time|date_format:"%l:%M %P" == $event_end_time|date_format:"%l:%M %P"}
+                                                                {$event_start_time|date_format:"%l:%M %P"}
                                                             {else}
-                                                                {$event.starting_date|date_format:"%l:%M %P"} - {$event.ending_date|date_format:"%l:%M %P"}
+                                                                {$event_start_time|date_format:"%l:%M %P"} - {$event_end_time|date_format:"%l:%M %P"}
                                                             {/if}
 
                                                         {/if}