[rt-users] Adding Element to provide easy custom field searches

2013-06-25 Thread Chad Osmond
Hi,

We have a non-technical group who need to search RT for custom fields, and 
putting customfield1:5 in the top search box is too much for them.
We'd like to add a new element on the At A Glance page to have something like:

CustomField1 [...] [Search]
CustomField2 [...] [Search]

The Search buttons would direct to a search where the custom field was = the 
input value.

I'm just not sure where to start adding a new element.
Anyone have an example or pointers?

Chad Osmond
chad.osm...@compfitness.commailto:chad.osm...@compfitness.com
Technical Support
Compfitness - Keeping your Computer Systems in Shape!
905-443-3171 work - 905-447-6485 mobile



Re: [rt-users] '--' in request cuts off history when replying?

2013-06-25 Thread candidochris
Still having this problem, even with all modifications removed. 

The only changes made were local file overrides on MessageBox changing the
original signature -- 

from: $signature = -- \n. $text;

to:  $signature = \n\n\n-- \n. $text . \n\n;


And the order of elements in the textarea -- 

from: % $Default || '' %% $message %% $signature %/textarea

to: % $Default || '' %% $signature %% $message %/textarea






--
View this message in context: 
http://requesttracker.8502.n7.nabble.com/in-request-cuts-off-history-when-replying-tp54420p54428.html
Sent from the Request Tracker - User mailing list archive at Nabble.com.


[rt-users] Possible to lock tickets ?

2013-06-25 Thread Jean-Christophe Boggio

Hello,

We wish to lock tickets so that they can not be reopen by email once 
we have decided they are resolved and locked (manually).


I think we can't prevent the reopening with a scrip but can we do this 
via lifecycles ?


Thanks,

JC


Re: [rt-users] Organisation/User Links

2013-06-25 Thread Kevin Falcone
On Tue, Jun 25, 2013 at 11:16:56AM +1000, Adam Thick wrote:
 I work in an organisation using Request Tracker extensively for client
 and internal communication. We currently have a custom field on our
 queues which allow linking of tickets to client/organisations but I
 cannot apply this custom field to the users entity as well… I'd like
 one datasource for client information and would like to be able to
 link to this custom field from both users and tickets.
 
 I have a few questions relating to this, 
 
 has anyone come up with a way to apply a custom field to both tickets and 
 users?

At this time, you cannot apply the same custom field to Users and
Tickets.  In the past, I've seen this done a number of way.
The user contains the definitive list in a CF and the Ticket has a
simple enter-one CF that copies the value from the User using a Scrip.
Alternatively, both CFs are External Custom Fields backed from the
same master customer list:
http://bestpractical.com/rt/docs/latest/extending/external_custom_fields.html

-kevin


pgpx6WvXyzAm4.pgp
Description: PGP signature


Re: [rt-users] Adding Element to provide easy custom field searches

2013-06-25 Thread Kevin Falcone
On Tue, Jun 25, 2013 at 10:02:38AM -0400, Chad Osmond wrote:
We have a non-technical group who need to search RT for custom fields, and 
 putting
customfield1:5 in the top search box is too much for them.
 
We'd like to add a new element on the At A Glance page to have something 
 like:
 
CustomField1 [...] [Search]
 
CustomField2 [...] [Search]
 
The Search buttons would direct to a search where the custom field was = 
 the input value.
 
I'm just not sure where to start adding a new element.

You can use a shorter word than customfield1: if that helps (but
it may not).  The simple search code in 4.0 is quite extensible.

You start making a portlet for the homepage by copying something like
the share/html/Elements/QuickCreate mason component to
local/html/Elements/CustomSearch, hacking it to render the Custom
Fields you want and then making it available to users to put on their
homepages using the HomepageComponents configuration:
http://bestpractical.com/rt/docs/latest/RT_Config.html#HomepageComponents

-kevin


pgpHhs_5oL3Ff.pgp
Description: PGP signature


Re: [rt-users] Changing the lifecycles __maps__

2013-06-25 Thread Kevin Falcone
On Mon, Jun 24, 2013 at 01:59:19PM -0700, Landon wrote:
Would this be acceptable as a new configuration?
Set(%Lifecycles
__maps__ = {
'from SC-ABUS - to Incident Reports' = {
'open' = 'open',
'resolved' = 'resolved',
'new' = 'new',
'stalled' = 'stalled',
'deleted' = 'rejected'
} );
 

Ignoring the fact that you're missing a comma and a closing }, it's
quite easy to add your sample to an RT_SiteConfig.pm and then go to 
https://you.rt.server/Admin/Tools/Configuration.html to see what RT
parsed as your lifecycle config.

In general, top level keys do not need to be copied (so if you're not
changing general you don't have to copy it) but if you're changing
something inside general, you *do* have to copy it.

-kevin


pgpV1aLc5D1rq.pgp
Description: PGP signature


Re: [rt-users] Changing the lifecycles __maps__

2013-06-25 Thread Landon
On 25 June 2013 09:29, Kevin Falcone falc...@bestpractical.com wrote:

 Ignoring the fact that you're missing a comma and a closing }, it's
 quite easy to add your sample to an RT_SiteConfig.pm and then go to
 https://you.rt.server/Admin/Tools/Configuration.html to see what RT
 parsed as your lifecycle config.


 In general, top level keys do not need to be copied (so if you're not
 changing general you don't have to copy it) but if you're changing
 something inside general, you *do* have to copy it.


I was unaware of that URL until now.  Thank you and looking back the
closing } and comma are pretty obvious to me LOL  Thank you.


-- 
Landon Stewart landonstew...@gmail.com


Re: [rt-users] Possible to lock tickets ?

2013-06-25 Thread Kevin Falcone
On Tue, Jun 25, 2013 at 05:29:39PM +0200, Jean-Christophe Boggio wrote:
 We wish to lock tickets so that they can not be reopen by email
 once we have decided they are resolved and locked (manually).
 
 I think we can't prevent the reopening with a scrip but can we do
 this via lifecycles ?

You can turn off re-opening entirely by disabling the On Correspond
open Tickets Scrip that RT ships.

There is an extension to this in a time-based manner:
https://metacpan.org/module/RT::Extension::RepliesToResolved

You could also use it to say that once a ticket moves manually to the
'really closed' status, never allow the ticket to be reopened using
that extension.
https://metacpan.org/source/FALCONE/RT-Extension-RepliesToResolved-0.02/etc/RepliesToResolved_Config.pm

Technically you could define a lifecycle status that has no transition
to an active status, but that means you'll never be able to re-open
the ticket even manually.

-kevin


pgprZLljLldkm.pgp
Description: PGP signature


[rt-users] External Authentication

2013-06-25 Thread bba...@copesan.com
Has anyone configures RT to authenticate against MSSQL using SHA1 or SHA256? 
If so, can someone post some sample configs?

Thanks in advance for the help.




--
View this message in context: 
http://requesttracker.8502.n7.nabble.com/External-Authentication-tp54436.html
Sent from the Request Tracker - User mailing list archive at Nabble.com.


[rt-users] Alter From field in template

2013-06-25 Thread Giuseppe Sollazzo
Hi there,we currently have several queues each responding to a different e-mail 
address.
However, all replies come via the generic support e-mail address.


I tried editing the template to do this. In the template the first part 
changes, successfully, the Subject of a message according to the queue. 

What happens is:
- if I only leave the part of the script for Subject, this works as expected
- if I add the part of the script to change the From field, both don't work.


Any idea?
The structure of my script follows.


Many thanks,
Giuseppe


Subject: { if ($Ticket-QueueObj-Name eq 'Z')
{ Z Support Job Logged:  . $Ticket-Subject . 


Thank you for contacting Z.


-
Initial request details:
 . $Transaction-Content . 


;}
elsif ($Ticket-QueueObj-Name eq 'W')

{...}


From: { if ($Ticket-QueueObj-Name eq 'Z')
{ z...@sgul.ac.uk;}
elsif ($Ticket-QueueObj-Name eq 'W')
{ w...@sgul.ac.uk;}
else
{ supp...@sgul.ac.uk;
}



--
Giuseppe Sollazzo
Senior Systems Analyst
Computing Services
Information Services
St. George's, University Of London
Cranmer Terrace
London SW17 0RE

Email: gsoll...@sgul.ac.uk
Direct Dial: +44 20 8725 5160
Fax: +44 20 8725 3583


Re: [rt-users] Possible to lock tickets ?

2013-06-25 Thread Jean-Christophe Boggio

You can turn off re-opening entirely by disabling the On Correspond
open Tickets Scrip that RT ships.


Looks nice and simple.


There is an extension to this in a time-based manner:



You could also use it to say that once a ticket moves manually to the
'really closed' status, never allow the ticket to be reopened using
that extension.


So many options. Thanks a lot for your help.


Re: [rt-users] Alter From field in template

2013-06-25 Thread Kevin Falcone
On Tue, Jun 25, 2013 at 06:45:14PM +0100, Giuseppe Sollazzo wrote:
Hi there,
we currently have several queues each responding to a different e-mail 
 address.
However, all replies come via the generic support e-mail address.
I tried editing the template to do this. In the template the first part 
 changes, successfully,
the Subject of a message according to the queue.
What happens is:
- if I only leave the part of the script for Subject, this works as 
 expected
- if I add the part of the script to change the From field, both don't 
 work.
The structure of my script follows.

I'm assuming everywhere you say Script you mean Template.

If you want to change headers, they have to go at the top.  Look at
your code, it inserts a newline and $Transaction-Content.

I'm betting the mail goes out with a trailing From: at the bottom.

Put your From: first.  Templates are like emails, Headers, blank line,
body.

Subject: { if ($Ticket-QueueObj-Name eq 'Z')
{ Z Support Job Logged:  . $Ticket-Subject . 
Thank you for contacting Z.
-
Initial request details:
 . $Transaction-Content . 
;}
elsif ($Ticket-QueueObj-Name eq 'W')
{...}
From: { if ($Ticket-QueueObj-Name eq 'Z')
{ z...@sgul.ac.uk;}
elsif ($Ticket-QueueObj-Name eq 'W')
{ w...@sgul.ac.uk;}
else
{ supp...@sgul.ac.uk;
}


pgpE0LwyP5Vva.pgp
Description: PGP signature


Re: [rt-users] CustomField Transactions Options?

2013-06-25 Thread Kai Storbeck
Hi mloughran,

On 6/24/13 5:58 PM, Emmanuel Lacour wrote:
 On Mon, Jun 24, 2013 at 08:26:53AM -0700, namespace wrote:
 I have a custom field entry that when selected, I want to automatically add a
 watcher to the ticket in question.  As it stands,  this CustomField called
 *'Service Type'* has an entry for PO's that when selected should add
 'purchas...@fibermedia.net' as a watcher without having the operator
 manually add the entry.  I don't see anywhere in the customfield options to
 add a watcher, only to notify existing individuals associated with the
 ticket.  Anyone got any input on this?

I ran into a quite similar case just a few months ago.

 You have to do this with a scrip.

Our Custom Condition Code checks if the customfield 'Severity' is changed:

 return 0 unless $self-TransactionObj-Type eq 'CustomField';
 my $cf = RT::CustomField-new( $self-CurrentUser );
 $cf-SetContextObject( $self-TransactionObj );
 $cf-Load( $self-TransactionObj-Field );
 return 1 if $cf-Name() eq 'Severity';

 return 0;

And for our custom action prepare (or cleanup, I never know which to pick):

 for ($self-TransactionObj-NewValue) {
 if (m/^Major$/) {
 $self-TicketObj-AddWatcher(Type = 'Requestor', Email = 
 'major-incident@name.local');
 }
 elsif (m/^Critical$/) {
 $self-TicketObj-AddWatcher(Type = 'Requestor', Email = 
 'critical-incident@name.local');
 }
 }
 
 for ($self-TransactionObj-OldValue) {
 if ( m/^Critical$/ ) {
  $self-TicketObj-DeleteWatcher(Type = 'Requestor', Email = 
 'critical-incident@name.local');
 }
 elsif ( m/^Major$/ ) {
  $self-TicketObj-DeleteWatcher(Type = 'Requestor', Email = 
 'major-incident@name.local');
 }
 }
 
 return 1;

The added (or removed) watcher addresses expand to SMS in this case.


Regards,
Kai



signature.asc
Description: OpenPGP digital signature


Re: [rt-users] External Authentication

2013-06-25 Thread bba...@copesan.com
Here is an update

Config being used.
#Testing SQL Connection
'Connect_MSSQL'   =  {  ## GENERIC SECTION
   'type'  =  'db',
   'server'=  '192.168.***.***,
   'database'  =  'TheDataBase',
   'table' =  'TheTable',
   'user'  =  'UserWithReadAccess',
   'pass'  =  'PasswordToAboveUser',
   'port'  =  'MSSQLDefaultPort',
   'dbi_driver'=  'DBI_ODBC',
   'u_field'   =  'Email',
   'p_field'   =  'password',
   'p_enc_pkg' =  'Digest::SHA1',
   'p_enc_sub' =  'password',
   'd_field'   =  'disabled',
   'd_values'  =  ['0'],
   'attr_match_list'   =  [   'Gecos'
   ],
'attr_map' =  {   'Name' = 'Firstname',
   'EmailAddress' = 'Email',
 'ExternalAuthId' = 'Email',
  'Gecos' = 'Email'
}
  },

Getting following error

[Tue Jun 25 20:32:34 2013] [debug]: Attempting to use external auth service:
Connect__MSSQL
(/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:186)
[Tue Jun 25 20:32:34 2013] [debug]: Calling UserExists with $username
(bba...@copesan.com) and $service (Connect__MSSQL)
(/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:227)
[Tue Jun 25 20:32:34 2013] [debug]: Invalid service type for UserExists:
Connect__MSSQL
(/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:490)

Thanks in advance for the help



--
View this message in context: 
http://requesttracker.8502.n7.nabble.com/External-Authentication-tp54436p54441.html
Sent from the Request Tracker - User mailing list archive at Nabble.com.


Re: [rt-users] CustomField Transactions Options?

2013-06-25 Thread Thomas Sibley
On 06/25/2013 01:22 PM, Kai Storbeck wrote:
 And for our custom action prepare (or cleanup, I never know which to pick):

Prepare should be used to do any work needed to do the action's
business, or to check some further conditions (depends on the action).

No changes should ever be made in prepare since it may be called more
than once.  All changes should happen in cleanup (which is renamed to
commit in 4.2).


Re: [rt-users] External Authentication

2013-06-25 Thread Thomas Sibley
On 06/25/2013 01:39 PM, bba...@copesan.com wrote:
 'Connect_MSSQL'   =  {  ## GENERIC SECTION

Typo.  Compare above to message below.

 [Tue Jun 25 20:32:34 2013] [debug]: Invalid service type for UserExists:
 Connect__MSSQL
 (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:490)



Re: [rt-users] External Authentication

2013-06-25 Thread Thomas Sibley
On 06/25/2013 01:45 PM, Bryon Baker wrote:
 Not a typo
 
 I am trying to us a Microsoft SQL database not MySQL.

Please keep replies on the list.

And look more closely at what you typed.  One has a single underscore,
the other two.  I know you're using MSSQL not MySQL.



Re: [rt-users] External Authentication

2013-06-25 Thread Bryon Baker
Sorry I screwed on both. 

Made change and now I get the following messages.  LDAP works by the way.

[Tue Jun 25 20:58:13 2013] [debug]: Attempting to use external auth service: 
Connect_MSSQL (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:186)
[Tue Jun 25 20:58:13 2013] [debug]: SSO Failed and no user to test with. 
Nexting (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:214)
[Tue Jun 25 20:58:13 2013] [debug]: Attempting to use external auth service: 
Connect_LDAP (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:186)
[Tue Jun 25 20:58:13 2013] [debug]: SSO Failed and no user to test with. 
Nexting (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:214)
[Tue Jun 25 20:58:13 2013] [debug]: Autohandler called ExternalAuth. Response: 
(0, No User) 
(/usr/share/request-tracker/local/plugins/RT-Authen-ExternalAuth/html/Elements/DoAuth:11)

Thanks
Bryon Baker
Network Operations Manager
Copesan - Specialists in Pest Solutions
800-267-3726  •  262-783-6261 ext. 2296
bba...@copesan.com
www.copesan.com
Servicing North America with Local Care


-Original Message-
From: rt-users-boun...@lists.bestpractical.com 
[mailto:rt-users-boun...@lists.bestpractical.com] On Behalf Of Thomas Sibley
Sent: Tuesday, June 25, 2013 3:48 PM
To: RT Users
Subject: Re: [rt-users] External Authentication

On 06/25/2013 01:45 PM, Bryon Baker wrote:
 Not a typo
 
 I am trying to us a Microsoft SQL database not MySQL.

Please keep replies on the list.

And look more closely at what you typed.  One has a single underscore, the 
other two.  I know you're using MSSQL not MySQL.




[rt-users] Unprivileged/Self-Serve users unable to view Custom Fields

2013-06-25 Thread Duncan Napier
Hi,

I want everyone so see custom fields, including Self-Serve requesters.

I'm running RT 4.0.8 on CentOS 6.2/Apache2.2.24/Postfix-2.2.6. I have 
everything set up and have implelented some custom fields through the Custom 
Fields menu. Administrators can see custom fields fine. But unpriviliged users 
(externally authenticated users in CAS created at their first login cannot. I 
have Globalm Everyone and Unpriviliged General Rights -  SeeCustomField , 
Custom Fields-Everyone/Unprivileged still no luck. 

Strangely enough only one user who used to be priviliged/administrator but now 
is unpriviliged can see custom fields. 

-- 

 Regards,

 Duncan.

---
Duncan Napier
duncan_nap...@sfu.ca
http://www.sfu.ca/~dgnapier/
IT  Instrumentation Consultant
Dept of Molecular Biology and Biochemistry
Simon Fraser University

It takes ten years to become good at being a kid. Then another ten years
to become good at not being a kid - Larry Wall.



Re: [rt-users] External Authentication

2013-06-25 Thread Thomas Sibley
On 06/25/2013 02:05 PM, Bryon Baker wrote:
 Sorry I screwed on both. 
 
 Made change and now I get the following messages.  LDAP works by the way.
 
 [Tue Jun 25 20:58:13 2013] [debug]: Attempting to use external auth service: 
 Connect_MSSQL 
 (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:186)
 [Tue Jun 25 20:58:13 2013] [debug]: SSO Failed and no user to test with. 
 Nexting (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:214)
 [Tue Jun 25 20:58:13 2013] [debug]: Attempting to use external auth service: 
 Connect_LDAP (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:186)
 [Tue Jun 25 20:58:13 2013] [debug]: SSO Failed and no user to test with. 
 Nexting (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:214)
 [Tue Jun 25 20:58:13 2013] [debug]: Autohandler called ExternalAuth. 
 Response: (0, No User) 
 (/usr/share/request-tracker/local/plugins/RT-Authen-ExternalAuth/html/Elements/DoAuth:11)

This means that your MSSQL auth source didn't find a user, so it moved
on to your LDAP source where it also didn't find a user (presumably
because some users are in MSSQL and others are in LDAP).


Re: [rt-users] External Authentication

2013-06-25 Thread Bryon Baker
I change the dbi_Driver option to ODBC.  Now I get the following error

[Tue Jun 25 21:21:29 2013] [error]: DBI 
connect('database=RapidTrax6a;host=192.168.250.29;port=1433','HelpDeskOTRS',...)
 failed: [unixODBC][Driver Manager]Data source name not found, and no default 
driver specified (SQL-IM002) at 
/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth/DBI.pm line 446.

Odbc Information
linux-jrlt:~ #   perl -MDBD::ODBC -e 'print $DBD::ODBC::VERSION;'
1.33

linux-jrlt:~ # perl -MDBI -e 'DBI-installed_versions;'
  Perl: 5.016002(x86_64-linux-thread-multi)
  OS  : linux   (3.4.6-2.10-xen)
  DBI : 1.627
  DBD::mysql  : 4.021
  DBD::Sponge : 12.010002
  DBD::Proxy  : 0.2004
  DBD::ODBC   : 1.33
  DBD::Gofer  : 0.015326
  DBD::File   : 0.41
  DBD::ExampleP   : 12.014310
  DBD::DBM: 0.08

Still don't know what I am missing.

Thanks
Bryon Baker
Network Operations Manager
Copesan - Specialists in Pest Solutions
800-267-3726  •  262-783-6261 ext. 2296
bba...@copesan.com
www.copesan.com
Servicing North America with Local Care


-Original Message-
From: rt-users-boun...@lists.bestpractical.com 
[mailto:rt-users-boun...@lists.bestpractical.com] On Behalf Of Thomas Sibley
Sent: Tuesday, June 25, 2013 4:12 PM
To: rt-users@lists.bestpractical.com
Subject: Re: [rt-users] External Authentication

On 06/25/2013 02:05 PM, Bryon Baker wrote:
 Sorry I screwed on both. 
 
 Made change and now I get the following messages.  LDAP works by the way.
 
 [Tue Jun 25 20:58:13 2013] [debug]: Attempting to use external auth 
 service: Connect_MSSQL 
 (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:186)
 [Tue Jun 25 20:58:13 2013] [debug]: SSO Failed and no user to test 
 with. Nexting 
 (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:214)
 [Tue Jun 25 20:58:13 2013] [debug]: Attempting to use external auth 
 service: Connect_LDAP 
 (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:186)
 [Tue Jun 25 20:58:13 2013] [debug]: SSO Failed and no user to test 
 with. Nexting 
 (/usr/lib/perl5/vendor_perl/5.16.2/RT/Authen/ExternalAuth.pm:214)
 [Tue Jun 25 20:58:13 2013] [debug]: Autohandler called ExternalAuth. 
 Response: (0, No User) 
 (/usr/share/request-tracker/local/plugins/RT-Authen-ExternalAuth/html/
 Elements/DoAuth:11)

This means that your MSSQL auth source didn't find a user, so it moved on to 
your LDAP source where it also didn't find a user (presumably because some 
users are in MSSQL and others are in LDAP).