Also fixed a front-end link for the reg events list page where a link went nowhere.
require_once GLM_MEMBERS_REGISTRATIONS_PLUGIN_CLASS_PATH.'/data/dataRegRequestRegistrant.php';
$RegRequestRegistrant = new GlmDataRegistrationsRequestRegistrant($this->wpdb, $this->config);
- $result_data['registrants'] = $RegRequestRegistrant-> getList('T.account = '.$result_data['id'], 'event_datetime');
+ $result_data['registrants'] = $RegRequestRegistrant->getList('T.account = '.$result_data['id'], 'event_datetime');
$result_data['numb_registrants'] = is_array($result_data['registrants']) * count($result_data['registrants']);
}
* @access public
*/
public $fields = false;
+ /**
+ * Get Registrants for the request flag
+ *
+ * If this is set then post-processing will include a list of the registrants
+ * for each request retrieved.
+ *
+ * This option is false by default and must be specifically set if it is desired.
+ *
+ * @var $getRegistrantslist
+ * @access public
+ */
+ public $getRegistrantslist = false;
/**
* Constructor
}
+ // If requested, get a list of the registrants
+ if (in_array($action, array('l', 'g')) && $this->getRegistrantslist) {
+
+ require_once GLM_MEMBERS_REGISTRATIONS_PLUGIN_CLASS_PATH.'/data/dataRegRequestRegistrant.php';
+ $RegRequestRegistrant = new GlmDataRegistrationsRequestRegistrant($this->wpdb, $this->config);
+ $result_data['registrants'] = $RegRequestRegistrant->getList('T.reg_request = '.$result_data['id'], 'lname, fname');
+ $result_data['numb_registrants'] = is_array($result_data['registrants']) * count($result_data['registrants']);
+
+ }
+
return $result_data;
}
// If we have a request ID
if ($requestID && $requestID > 0) {
- // Try to check and get the request (cart)
+ // Try to get the request (cart)
$cart = $regCartSupport->getRegistrationCart($requestID);
// If there's no valid cart
setcookie("glmMembersDatabaseRegistrationRequestID", $requestID, time()+86400);
}
- //echo "<pre>".print_r($requests,1)."</pre>";
+ // echo "<pre>".print_r($cart,1)."</pre>";
// Compile template data
$templateData = array(
<td style="padding-right: 1em;">{$terms.reg_term_event_cap}</td>
<td style="padding-right: 1em;">Level</td>
<td style="padding-right: 1em;">Rate</td>
- <td style="padding-right: 1em;">Requeest Status</td>
+ <td style="padding-right: 1em;">Request Status</td>
<td>Attending</td>
</tr>
{foreach $account.registrants as $registrant}
</div>
</div>
-
+
+ <div class="glm-admin-table-inner glm-admin-table">
+ <h1>Current List of {$terms.reg_term_attendee_plur_cap} for this Request</h1>
+ {assign var="i" value="0"}
+ <table class="glm-admin-table wp-list-table striped glm-nowrap">
+ <tr>
+ <td style="padding-right: 1em;">Name</td>
+ <td style="padding-right: 1em;">{$terms.reg_term_event_cap}</td>
+ <td style="padding-right: 1em;">Level</td>
+ <td style="padding-right: 1em;">Rate</td>
+ <td>Attending</td>
+ </tr>
+ {foreach $cart.events as $event}
+ {foreach $event.classes as $class}
+ {foreach $class.rates as $rate}
+ {foreach $rate.registrants as $registrant}
+ <tr>
+ <td>{$registrant.fname} {$registrant.lname}</td>
+ <td><a href="{$thisUrl}?page=glm-members-admin-menu-registrations-events&option=eventDashboard&option=registrants®EventID={$event.reg_event}">{$event.event_name}</a></td>
+ <td>{$class.class_name}</td>
+ <td>{$rate.rate_name}</td>
+ <td>{if $registrant.not_attending.value}No{else}Yes{/if}</td>
+ </tr>
+ {/foreach}
+ {/foreach}
+ {/foreach}
+ {/foreach}
+ </table>
+ </div>
+
<div class="glm-admin-table-inner glm-admin-table">
{if $cart.request.status.name != 'In Cart'}
{/if}
<div class="glm-small-12 glm-large-4 glm-columns">
- <a href="" class="glm-reg-list-add-btn">{$terms.reg_term_register_cap} for this {$terms.reg_term_event_cap}</a>
+ <a href="{$thisUrl}?page=registration&eventRegId={$event.id}" class="glm-reg-list-add-btn">{$terms.reg_term_register_cap} for this {$terms.reg_term_event_cap}</a>
</div>
</div>