[freeside-commits] freeside/FS/FS/TicketSystem RT_External.pm, 1.36.2.1, 1.36.2.2
Ivan,,,
ivan at wavetail.420.am
Wed Mar 10 19:27:40 PST 2010
Update of /home/cvs/cvsroot/freeside/FS/FS/TicketSystem
In directory wavetail.420.am:/tmp/cvs-serv24260/FS/FS/TicketSystem
Modified Files:
Tag: FREESIDE_1_9_BRANCH
RT_External.pm
Log Message:
add queue selection to customer ticket creation, RT#7656
Index: RT_External.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/TicketSystem/RT_External.pm,v
retrieving revision 1.36.2.1
retrieving revision 1.36.2.2
diff -u -w -d -r1.36.2.1 -r1.36.2.2
--- RT_External.pm 12 Feb 2010 01:37:53 -0000 1.36.2.1
+++ RT_External.pm 11 Mar 2010 03:27:38 -0000 1.36.2.2
@@ -247,7 +247,7 @@
}
-sub href_new_ticket {
+sub href_params_new_ticket {
my( $self, $custnum_or_cust_main, $requestors ) = @_;
my( $custnum, $cust_main );
@@ -258,14 +258,25 @@
$custnum = $custnum_or_cust_main;
$cust_main = qsearchs('cust_main', { 'custnum' => $custnum } );
}
- my $queueid = $cust_main->agent->ticketing_queueid || $default_queueid;
- $self->baseurl.
- 'Ticket/Create.html?'.
- "Queue=$queueid".
- "&new-MemberOf=freeside://freeside/cust_main/$custnum".
- ( $requestors ? '&Requestors='. uri_escape($requestors) : '' )
- ;
+ my %param = (
+ 'Queue' => ($cust_main->agent->ticketing_queueid || $default_queueid),
+ 'new-MemberOf'=> "freeside://freeside/cust_main/$custnum",
+ 'Requestors' => $requestors,
+ );
+
+ ( $self->baseurl.'Ticket/Create.html', %param );
+}
+
+sub href_new_ticket {
+ my $self = shift;
+
+ my( $base, %param ) = $self->href_params_new_ticket(@_);
+
+ my $uri = new URI $base;
+ $uri->query_form(%param);
+ $uri;
+
}
sub href_ticket {
More information about the freeside-commits
mailing list