Updating detail template for times output.
authorSteve Sutton <steve@gaslightmedia.com>
Thu, 26 Oct 2017 12:30:26 +0000 (08:30 -0400)
committerSteve Sutton <steve@gaslightmedia.com>
Thu, 26 Oct 2017 12:36:49 +0000 (08:36 -0400)
If there's no time to output then don't display the glm-event-times div.
Re-arranging some of the markup to keep the expired and name part out of
that if statement for the all_day.

index.php
readme.txt
views/front/events/detail.html

index 8e3b6df..5b0206e 100644 (file)
--- a/index.php
+++ b/index.php
@@ -4,7 +4,7 @@
  * Plugin URI: http://www.gaslightmedia.com/
  * Description: Gaslight Media Members Database.
 
- * Version: 1.6.69
+ * Version: 1.6.70
 
  * Author: Chuck Scott
  * Author URI: http://www.gaslightmedia.com/
@@ -22,7 +22,7 @@
  * @author Chuck Scott <cscott@gaslightmedia.com>
  * @license http://www.gaslightmedia.com Gaslightmedia
 
- * @version 1.6.69
+ * @version 1.6.70
 
  */
 
@@ -47,7 +47,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.69');
+define('GLM_MEMBERS_EVENTS_PLUGIN_VERSION', '1.6.70');
 define('GLM_MEMBERS_EVENTS_PLUGIN_DB_VERSION', '0.1.4');
 
 // This is the minimum version of the GLM Members DB plugin require for this plugin.
index bd88b2e..2cfd84f 100644 (file)
@@ -25,6 +25,10 @@ e.g.
 1. Activate the plugin through the 'Plugins' menu in WordPress
 
 == Changelog ==
+= 1.6.70 =
+* Fix time output for events with no time. Doesn't display the glm-event-times
+  div.
+
 = 1.6.69 =
 * Fix event detail page description output.
 * Fix output if more than one time schedule. Show's date only once if it
index 5c9d822..ce3474d 100644 (file)
 
                                     </div>
                                 {/if}
-                                <div class="glm-event-times">
-
-                                    <span class="time-tag"></span>
-
-                                    <span>
-                                    {if !$event.all_day}
-
+                                {if !$event.all_day}
+                                    <div class="glm-event-times">
+                                        <span class="time-tag"></span>
+                                        <span>
                                             {if $rec.start_time.time == $rec.end_time.time || $rec.start_time_only.value}
                                                 {$rec.start_time.time|strtotime|date_format:"%l:%M %P"}
                                             {else}
                                                 {$rec.start_time.time|strtotime|date_format:"%l:%M %P"} - {$rec.end_time.time|strtotime|date_format:"%l:%M %P"}
                                             {/if}
-                                    {/if}
-                                    </span>
+                                            {if $rec.name && $rec.name != 'Imported' && $rec.name != 'Imported Event Schedule' }
+                                                {$rec.name}
+                                            {/if}
+                                            {if $expired} <span style="color:red;"> (Expired) </span> {/if}
+                                        </span>
+                                    </div>
+                                {else}
                                     {if $rec.name && $rec.name != 'Imported' && $rec.name != 'Imported Event Schedule' }
                                         {$rec.name}
                                     {/if}
 
-
-
-
-
                                     {if $expired} <span style="color:red;"> (Expired) </span> {/if}
-                                </div>
+                                {/if}
                             {/foreach}
                             </div>
                             {if $event.hide_address.name == 'No'}