Tickets on add to badge screen now show the time at the events timezone

This commit is contained in:
Kaleb Murphy 2008-09-12 18:15:04 +00:00
parent c56221f6da
commit 993391a620
2 changed files with 5 additions and 3 deletions

View file

@ -37,7 +37,7 @@
- fixed: Using a password recovery token a second time informs the user of the reuse instead of having a style inside a style with a login form. - fixed: Using a password recovery token a second time informs the user of the reuse instead of having a style inside a style with a login form.
- fixed: Thingy Things can now have no fields and still be functional. - fixed: Thingy Things can now have no fields and still be functional.
- fixed: Can no longer buy badges from receipt or direct link page if quantity is empty - fixed: Can no longer buy badges from receipt or direct link page if quantity is empty
- fixed: Tickets on add to badge screen now show the time at the event's timezone
7.5.22 7.5.22
- fixed: Layout template now gets prepared correctly - fixed: Layout template now gets prepared correctly
- fixed: When user does not have permissions to search/edit a thing a proper error is shown. - fixed: When user does not have permissions to search/edit a thing a proper error is shown.

View file

@ -857,11 +857,12 @@ sub www_getRegistrantAsJson {
my $existingTickets = $db->read("select ticketAssetId from EMSRegistrantTicket where badgeId=? and purchaseComplete=1",[$badgeId]); my $existingTickets = $db->read("select ticketAssetId from EMSRegistrantTicket where badgeId=? and purchaseComplete=1",[$badgeId]);
while (my ($id) = $existingTickets->array) { while (my ($id) = $existingTickets->array) {
my $ticket = WebGUI::Asset::Sku::EMSTicket->new($session, $id); my $ticket = WebGUI::Asset::Sku::EMSTicket->new($session, $id);
my $startTime = WebGUI::DateTime->new($ticket->get('startDate'))->set_time_zone($self->get('timezone'));
push(@tickets, { push(@tickets, {
title => $ticket->getTitle, title => $ticket->getTitle,
eventNumber => $ticket->get('eventNumber'), eventNumber => $ticket->get('eventNumber'),
hasPurchased => 1, hasPurchased => 1,
startDate => $ticket->get('startDate'), startDate => $startTime->toMysqlTime,
endDate => $ticket->get('endDate'), endDate => $ticket->get('endDate'),
location => $ticket->get('location'), location => $ticket->get('location'),
assetId => $ticket->getId, assetId => $ticket->getId,
@ -903,11 +904,12 @@ sub www_getRegistrantAsJson {
my $sku = $item->getSku; my $sku = $item->getSku;
# it's a ticket # it's a ticket
if ($sku->isa('WebGUI::Asset::Sku::EMSTicket')) { if ($sku->isa('WebGUI::Asset::Sku::EMSTicket')) {
my $startTime = WebGUI::DateTime->new($sku->get('startDate'))->set_time_zone($self->get('timezone'));
push(@tickets, { push(@tickets, {
title => $sku->getTitle, title => $sku->getTitle,
eventNumber => $sku->get('eventNumber'), eventNumber => $sku->get('eventNumber'),
itemId => $item->getId, itemId => $item->getId,
startDate => $sku->get('startDate'), startDate => $startTime->toMysqlTime,
endDate => $sku->get('endDate'), endDate => $sku->get('endDate'),
location => $sku->get('location'), location => $sku->get('location'),
assetId => $sku->getId, assetId => $sku->getId,