[Rt-commit] rt branch, update-action, updated. 187daaaf258962089d9b5959a4300f93a1ec5ef9
sartak at bestpractical.com
sartak at bestpractical.com
Tue Dec 15 14:05:43 EST 2009
The branch, update-action has been updated
via 187daaaf258962089d9b5959a4300f93a1ec5ef9 (commit)
from 3944bb7344f659d7c8c0d1a8bee6210f2c591f81 (commit)
Summary of changes:
lib/RT/Dispatcher.pm | 4 +---
lib/RT/View/Ticket/Update.pm | 4 +++-
2 files changed, 4 insertions(+), 4 deletions(-)
- Log -----------------------------------------------------------------
commit 187daaaf258962089d9b5959a4300f93a1ec5ef9
Author: Shawn M Moore <sartak at bestpractical.com>
Date: Tue Dec 15 14:05:32 2009 -0500
Don't load the ticket in the dispatcher, load it in the template
diff --git a/lib/RT/Dispatcher.pm b/lib/RT/Dispatcher.pm
index cbdd903..6a38504 100644
--- a/lib/RT/Dispatcher.pm
+++ b/lib/RT/Dispatcher.pm
@@ -754,9 +754,7 @@ on '/ticket/modify' => run {
die "no ticket selected";
}
else {
- my $ticket = RT::Model::Ticket->new;
- $ticket->load($id);
- set(ticket => $ticket);
+ set(id => $id);
show '/ticket/modify';
}
};
diff --git a/lib/RT/View/Ticket/Update.pm b/lib/RT/View/Ticket/Update.pm
index 928658f..dbda010 100644
--- a/lib/RT/View/Ticket/Update.pm
+++ b/lib/RT/View/Ticket/Update.pm
@@ -54,7 +54,9 @@ use Jifty::View::Declare -base;
__PACKAGE__->use_mason_wrapper;
template 'modify' => page { title => _('Modify a ticket') } content {
- my $ticket = get('ticket');
+ my $id = get('id');
+ my $ticket = RT::Model::Ticket->new;
+ $ticket->load($id);
my $update = new_action(
class => 'UpdateTicket',
-----------------------------------------------------------------------
More information about the Rt-commit
mailing list