}
if ($this->postAddLocations) {
$r['locations'] = array();
- if ($r['use_member_location'] ) {
+ if ($r['use_member_location']['value'] ) {
include_once GLM_MEMBERS_PLUGIN_CLASS_PATH . '/data/dataMemberInfo.php';
$memberData = new GlmDataMemberInfo( $this->wpdb, $this->config );
$member = $memberData->getActiveInfoForMember((int)$r['ref_dest_id']);
if ( isset($event['locations']) && !empty($event['locations']) && $event['hide_address']['name'] == 'No' ) {
$address = array();
$address[] = $event['locations']['name'];
- $address[] = $event['locations']['address'];
- $address[] = $event['locations']['city']['name'];
- $address[] = $event['locations']['state']['name'];
- $address[] = $event['locations']['zip'];
+ if ( $event['locations']['address'] ) {
+ $address[] = $event['locations']['address'];
+ $address[] = $event['locations']['city']['name'];
+ $address[] = $event['locations']['state']['name'];
+ $address[] = $event['locations']['zip'];
+ }
$location = new SetaPDF_Core_Text_Block( $font, self::PDF_FONT_SIZE );
$location->setText(implode(', ', $address));
$event['starting_date'] = $eventTime['start_time']['timestamp'];
$event['ending_date'] = $eventTime['end_time']['timestamp'];
//$eventsByDate[$eventDateTime][$eventTime['start_time']['timestamp']][] = $event;
- $eventsByDate[$eventDateTime][][$event['starting_date'] . '-' . $event['id']] = $event;
+ if ( $event['all_day'] ) {
+ $eventsByDate[$eventDateTime][][$eventDateTime . '-' . $event['id']] = $event;
+ } else {
+ $eventsByDate[$eventDateTime][][$event['starting_date'] . '-' . $event['id']] = $event;
+ }
// if there's a name search stop for the first occurrence of that event
if ( $action == 'event-list-name' ) {
break;
{/if}
{/if}
</div>
- {if $event.hide_address.name == 'No' }
+ {if $event.hide_address.name == 'No'}
<div class="small-12 column">
- {if !$event.use_member_location.value}
+ {if !$event.use_member_location.value && $event.locations}
{if $event.locations.name}{$event.locations.name}<br>{/if}
- {$event.locations.address}<br>
- {$event.locations.city.name}, {$event.locations.state.value} {$event.locations.zip}
+ {if $event.locations.address}
+ {$event.locations.address}<br>
+ {$event.locations.city.name}, {$event.locations.state.value} {$event.locations.zip}
+ {/if}
{else}
{$event.member.member}<br>
{$event.member.addr1}<br>