Help with query and display

Hi all,

I’m trying to get a custom query to display on the main page of RT. Here
is the contents of the file …

<&|/Elements/TitleBox,
title => loc(‘Pending Service Calls’),
title_href => “Search/Results.html”.$QueryString &>
<& /Elements/TicketList,
Format => “’<a
href=”$RT::WebPath/Ticket/Display.html?id=id">id/TITLE:#’,
’<a
href="$RT::WebPath/Ticket/Display.html?id=id">Subject/TITL
E:Subject’, ExtendedStatus, DueRelative, Owner",

    Query => $Query,
    OrderBy => 'id',
    Order => 'ASC',
    ShowNavigation => 0
    &>

</&>
<%init>

my $Query = " Status = ‘service’ ";

my $QueryString = ‘?’ . $m->comp(’/Elements/QueryString’,
Query => $Query,
Order => ‘ASC’,
OrderBy => ‘id’) if ($Query);

</%init>

––

All of the data displays except the Owner. I think I am just not
referencing it by the right name. Any help is greatly appreciated…

Also, is there anywhere that I can find all of the possibilities for
fields in a custom search?

Thanks,

Dave Kettmann
NetLogic
314-266-4000

Anyone? … Bueller? … This should be a simple fix I would think?

Dave-----Original Message-----
From: rt-users-bounces@lists.bestpractical.com
[mailto:rt-users-bounces@lists.bestpractical.com] On Behalf Of Dave
Kettmann
Sent: Wednesday, January 11, 2006 11:19 AM
To: rt-users@lists.bestpractical.com
Subject: [rt-users] Help with query and display

Hi all,

I’m trying to get a custom query to display on the main page of RT. Here
is the contents of the file …

<&|/Elements/TitleBox,
title => loc(‘Pending Service Calls’),
title_href => “Search/Results.html”.$QueryString &>
<& /Elements/TicketList,
Format => “’<a
href=”$RT::WebPath/Ticket/Display.html?id=id">id/TITLE:#’,
’<a
href="$RT::WebPath/Ticket/Display.html?id=id">Subject/TITL
E:Subject’, ExtendedStatus, DueRelative, Owner",

    Query => $Query,
    OrderBy => 'id',
    Order => 'ASC',
    ShowNavigation => 0
    &>

</&>
<%init>

my $Query = " Status = ‘service’ ";

my $QueryString = ‘?’ . $m->comp(’/Elements/QueryString’,
Query => $Query,
Order => ‘ASC’,
OrderBy => ‘id’) if ($Query);

</%init>

––

All of the data displays except the Owner. I think I am just not
referencing it by the right name. Any help is greatly appreciated…

Also, is there anywhere that I can find all of the possibilities for
fields in a custom search?

Thanks,

Dave Kettmann
NetLogic
314-266-4000

http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Be sure to check out the RT Wiki at http://wiki.bestpractical.com

Download a free sample chapter of RT Essentials from O’Reilly Media at
http://rtbook.bestpractical.com

WE’RE COMING TO YOUR TOWN SOON - RT Training in Amsterdam, Boston and
San Francisco - Find out more at
http://bestpractical.com/services/training.html

Looking at the code for MyTickets, it appears you are mixing user/client
syntax with application/server syntax. That is,

<& /Elements/TicketList,
Format => “’<a
href=”$RT::WebPath/Ticket/Display.html?id=id">idTITLE:#’,
’<a
href="$RT::WebPath/Ticket/Display.html?id=id">Subject/TITL
E:Subject’, ExtendedStatus, DueRelative, Owner",
Query => $Query,
OrderBy => ‘id’,
Order => ‘ASC’,
ShowNavigation => 0
&>

Should have ExtendedStatus rather than ExtendedStatus, Owner rather
than Owner, etc.

Are you trying to display the owner in your results? Just trying to
clarify. Also, where in the code are you pulling the Owner field? I
couldn’t find it.

Thanks,
Tim
972-980-4991-----Original Message-----
From: Dave Kettmann [mailto:dkettmann@netlogic.net]
Sent: Thursday, January 12, 2006 9:37 AM
To: Dave Kettmann; rt-users@lists.bestpractical.com
Subject: [rt-users] RE: Help with query and display

Anyone? … Bueller? … This should be a simple fix I would think?

Dave

-----Original Message-----
From: rt-users-bounces@lists.bestpractical.com
[mailto:rt-users-bounces@lists.bestpractical.com] On Behalf Of Dave Kettmann
Sent: Wednesday, January 11, 2006 11:19 AM
To: rt-users@lists.bestpractical.com
Subject: [rt-users] Help with query and display

Hi all,

I’m trying to get a custom query to display on the main page of RT. Here is
the contents of the file …

<&|/Elements/TitleBox,
title => loc(‘Pending Service Calls’),
title_href => “Search/Results.html”.$QueryString &> <&
/Elements/TicketList,
Format => “’<a
href=”$RT::WebPath/Ticket/Display.html?id=id">id/TITLE:#’,
’<a
href="$RT::WebPath/Ticket/Display.html?id=id">Subject/TITL
E:Subject’, ExtendedStatus, DueRelative, Owner",

    Query => $Query,
    OrderBy => 'id',
    Order => 'ASC',
    ShowNavigation => 0
    &>

</&>
<%init>

my $Query = " Status = ‘service’ ";

my $QueryString = ‘?’ . $m->comp(’/Elements/QueryString’,
Query => $Query,
Order => ‘ASC’,
OrderBy => ‘id’) if ($Query);

</%init>

––

All of the data displays except the Owner. I think I am just not referencing
it by the right name. Any help is greatly appreciated…

Also, is there anywhere that I can find all of the possibilities for fields
in a custom search?

Thanks,

Dave Kettmann
NetLogic
314-266-4000

http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Be sure to check out the RT Wiki at http://wiki.bestpractical.com

Download a free sample chapter of RT Essentials from O’Reilly Media at
http://rtbook.bestpractical.com

WE’RE COMING TO YOUR TOWN SOON - RT Training in Amsterdam, Boston and San
Francisco - Find out more at http://bestpractical.com/services/training.html

http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Be sure to check out the RT Wiki at http://wiki.bestpractical.com

Download a free sample chapter of RT Essentials from O’Reilly Media at
http://rtbook.bestpractical.com

WE’RE COMING TO YOUR TOWN SOON - RT Training in Amsterdam, Boston and San
Francisco - Find out more at http://bestpractical.com/services/training.html

This is probably the line of code you’re looking for.

%$Ticket->OwnerObj->Name%

This is what pulls the owner’s name in the MyRequests element. You might be
able to rewrite this element to only show the Service tickets.

Thanks
Tim Mahoney
Win Svr 2003 / RT 3.0.12 / Apache 1.33 / Perl 5.8.6 / MySQL 4.1.18-----Original Message-----
From: Dave Kettmann [mailto:dkettmann@netlogic.net]
Sent: Thursday, January 12, 2006 9:37 AM
To: Dave Kettmann; rt-users@lists.bestpractical.com
Subject: [rt-users] RE: Help with query and display

Anyone? … Bueller? … This should be a simple fix I would think?

Dave

-----Original Message-----
From: rt-users-bounces@lists.bestpractical.com
[mailto:rt-users-bounces@lists.bestpractical.com] On Behalf Of Dave Kettmann
Sent: Wednesday, January 11, 2006 11:19 AM
To: rt-users@lists.bestpractical.com
Subject: [rt-users] Help with query and display

Hi all,

I’m trying to get a custom query to display on the main page of RT. Here is
the contents of the file …

<&|/Elements/TitleBox,
title => loc(‘Pending Service Calls’),
title_href => “Search/Results.html”.$QueryString &> <&
/Elements/TicketList,
Format => “’<a
href=”$RT::WebPath/Ticket/Display.html?id=id">id/TITLE:#’,
’<a
href="$RT::WebPath/Ticket/Display.html?id=id">Subject/TITL
E:Subject’, ExtendedStatus, DueRelative, Owner",

    Query => $Query,
    OrderBy => 'id',
    Order => 'ASC',
    ShowNavigation => 0
    &>

</&>
<%init>

my $Query = " Status = ‘service’ ";

my $QueryString = ‘?’ . $m->comp(’/Elements/QueryString’,
Query => $Query,
Order => ‘ASC’,
OrderBy => ‘id’) if ($Query);

</%init>

––

All of the data displays except the Owner. I think I am just not referencing
it by the right name. Any help is greatly appreciated…

Also, is there anywhere that I can find all of the possibilities for fields
in a custom search?

Thanks,

Dave Kettmann
NetLogic
314-266-4000

http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Be sure to check out the RT Wiki at http://wiki.bestpractical.com

Download a free sample chapter of RT Essentials from O’Reilly Media at
http://rtbook.bestpractical.com

WE’RE COMING TO YOUR TOWN SOON - RT Training in Amsterdam, Boston and San
Francisco - Find out more at http://bestpractical.com/services/training.html

http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Be sure to check out the RT Wiki at http://wiki.bestpractical.com

Download a free sample chapter of RT Essentials from O’Reilly Media at
http://rtbook.bestpractical.com

WE’RE COMING TO YOUR TOWN SOON - RT Training in Amsterdam, Boston and San
Francisco - Find out more at http://bestpractical.com/services/training.html

Thanks everyone for the help… I am still tinkering with this and I
can’t quite get the syntax right. Is there anywhere with documentation
explaining how to use this so I don’t have to bug all of you? :slight_smile:

Dave Kettmann
NetLogic
314-266-4000-----Original Message-----
From: Mahoney, Tim [mailto:Tim.Mahoney@magicorp.com]
Sent: Thursday, January 12, 2006 10:06 AM
To: Dave Kettmann; rt-users@lists.bestpractical.com
Subject: RE: [rt-users] RE: Help with query and display

This is probably the line of code you’re looking for.

%$Ticket->OwnerObj->Name%

This is what pulls the owner’s name in the MyRequests element. You
might be
able to rewrite this element to only show the Service tickets.

Thanks
Tim Mahoney
Win Svr 2003 / RT 3.0.12 / Apache 1.33 / Perl 5.8.6 / MySQL 4.1.18

-----Original Message-----
From: Dave Kettmann [mailto:dkettmann@netlogic.net]
Sent: Thursday, January 12, 2006 9:37 AM
To: Dave Kettmann; rt-users@lists.bestpractical.com
Subject: [rt-users] RE: Help with query and display

Anyone? … Bueller? … This should be a simple fix I would think?

Dave

-----Original Message-----
From: rt-users-bounces@lists.bestpractical.com
[mailto:rt-users-bounces@lists.bestpractical.com] On Behalf Of Dave
Kettmann
Sent: Wednesday, January 11, 2006 11:19 AM
To: rt-users@lists.bestpractical.com
Subject: [rt-users] Help with query and display

Hi all,

I’m trying to get a custom query to display on the main page of RT. Here
is
the contents of the file …

<&|/Elements/TitleBox,
title => loc(‘Pending Service Calls’),
title_href => “Search/Results.html”.$QueryString &> <&
/Elements/TicketList,
Format => “’<a
href=”$RT::WebPath/Ticket/Display.html?id=id">id/TITLE:#’,
’<a
href="$RT::WebPath/Ticket/Display.html?id=id">Subject/TITL
E:Subject’, ExtendedStatus, DueRelative, Owner",

    Query => $Query,
    OrderBy => 'id',
    Order => 'ASC',
    ShowNavigation => 0
    &>

</&>
<%init>

my $Query = " Status = ‘service’ ";

my $QueryString = ‘?’ . $m->comp(’/Elements/QueryString’,
Query => $Query,
Order => ‘ASC’,
OrderBy => ‘id’) if ($Query);

</%init>

––

All of the data displays except the Owner. I think I am just not
referencing
it by the right name. Any help is greatly appreciated…

Also, is there anywhere that I can find all of the possibilities for
fields
in a custom search?

Thanks,

Dave Kettmann
NetLogic
314-266-4000

http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Be sure to check out the RT Wiki at http://wiki.bestpractical.com

Download a free sample chapter of RT Essentials from O’Reilly Media at
http://rtbook.bestpractical.com

WE’RE COMING TO YOUR TOWN SOON - RT Training in Amsterdam, Boston and
San
Francisco - Find out more at
http://bestpractical.com/services/training.html

http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users

Be sure to check out the RT Wiki at http://wiki.bestpractical.com

Download a free sample chapter of RT Essentials from O’Reilly Media at
http://rtbook.bestpractical.com

WE’RE COMING TO YOUR TOWN SOON - RT Training in Amsterdam, Boston and
San
Francisco - Find out more at
http://bestpractical.com/services/training.html