[freeside-commits]
freeside/FS/FS/TicketSystem RT_External.pm, 1.17, 1.18
Ivan,,,
ivan at wavetail.420.am
Fri Nov 18 01:44:28 PST 2005
Update of /home/cvs/cvsroot/freeside/FS/FS/TicketSystem
In directory wavetail:/tmp/cvs-serv9088
Modified Files:
RT_External.pm
Log Message:
update custom priorioty field BS for RT 3.4.4
Index: RT_External.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/TicketSystem/RT_External.pm,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -d -r1.17 -r1.18
--- RT_External.pm 15 Oct 2005 13:48:08 -0000 1.17
+++ RT_External.pm 18 Nov 2005 09:44:26 -0000 1.18
@@ -56,7 +56,7 @@
my( $from_sql, @param) = $self->_from_customer( $custnum, $priority );
my $sql = "select tickets.*, queues.name".
- ( length($priority) ? ", ticketcustomfieldvalues.content" : '' ).
+ ( length($priority) ? ", objectcustomfieldvalues.content" : '' ).
" $from_sql order by priority desc limit $limit";
my $sth = $dbh->prepare($sql) or die $dbh->errstr. "preparing $sql";
$sth->execute(@param) or die $sth->errstr. "executing $sql";
@@ -91,10 +91,11 @@
#";
push @param, $priority;
- $join = "join TicketCustomFieldValues
- on ( tickets.id = TicketCustomFieldValues.ticket )";
+ $join = "join ObjectCustomFieldValues
+ on ( tickets.id = ObjectCustomFieldValues.ObjectId )";
- $where = "and content = ?
+ $where = "and ObjectType = 'RT::Ticket'
+ and content = ?
and customfield = ( select id from customfields
where name = ?
and ( $queue_sql )
@@ -102,8 +103,9 @@
";
} else {
$where =
- "and 0 = ( select count(*) from TicketCustomFieldValues
- where ticket = tickets.id
+ "and 0 = ( select count(*) from ObjectCustomFieldValues
+ where ObjectId = tickets.id
+ and ObjectType = 'RT::Ticket'
and customfield = ( select id from customfields
where name = ?
and ( $queue_sql )
More information about the freeside-commits
mailing list