Re: [rt-users] RT 4.4.1 - Change owner on corrospond Scrip - Strange issue

2017-02-23 Thread Alex Hall
Thank you! This seems to be doing the right thing, while still not
notifying the user of the change. It's exactly what I was hoping for. It
felt great to close the ticket my boss made on this issue back in November!

On Thu, Feb 23, 2017 at 12:06 PM, Shawn M Moore <sh...@bestpractical.com>
wrote:

> Hey Robert, Alex,
>
> Is this just a display bug or are we not using the proper method to change
> the owner of the Ticket?
>
>
> You're not using the proper method.
>
> # do the actual 'status update'
> my ($status, $msg) = $self->TicketObj->_Set(Field => 'Owner', Value =>
> $Actor, RecordTransaction => 0);
>
>
> Should instead be:
>
> my ($status, $msg) = $self->TicketObj->SetOwner($Actor);
>
> What works: When user is first to correspond, Scrip executes and in Ticket
> view the Owner is set as expected.
>
>
> What doesn’t work: If we go into the queue and list all the open tickets,
> the owner will be listed as “nobody” in this view, but if you open the
> ticket, there is an owner. If you change the owner to someone else and
> change it back, then it seems to fix this issue.
>
>
> The reason you need to use SetOwner is that the owner of a ticket is
> represented in two different database tables. The first is in the
> GroupMembers table, alongside Requestors, Ccs, and AdminCcs, and custom
> roles. This is what provides features like permissions. It's also what's
> used when you display the "Owner" column in search results. Tickets _also_
> store their owner denormalized in the tickets table. This is used in, among
> other places, displaying the owner on ticket display, and in email
> notifications.
>
> ->Set(Field => 'Owner') only updates the latter. ->SetOwner updates both.
>
> This explains the inconsistencies you're seeing. Please try switching your
> scrip to ->SetOwner and seeing if it helps for tickets going forward. For
> existing tickets with this problem, you'll need to address the consistency
> issue.
>
> It turns out that, for different reasons entirely (
> https://issues.bestpractical.com/Ticket/Display.html?id=32381 ), RT 4.4.2
> adds an upgrade step and an rt-validator rule that detects and fixes such
> inconsistencies. You can find them here:
>
> https://github.com/bestpractical/rt/commit/58bacce6ada754657c7f56fd91f20c
> 573108c1ab
> https://github.com/bestpractical/rt/commit/20d8daf6855e3c53ee8a79d6827194
> 1d4cdca159
>
> Best,
> Shawn
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] RT 4.4.1 - Change owner on corrospond Scrip - Strange issue

2017-02-23 Thread Alex Hall
> On Feb 23, 2017, at 09:19, Kenneth Marshall <k...@rice.edu> wrote:
> Hi Alex and Robert,
> 
> What happens if you set RecordTransaction to 1/true? I have not checked the 
> code,
> but I would imagine that if you do not record the transaction, the cache 
> infrastructure
> would not invalidate the old entry and would continue to serve stale data. 
> Something
> to try perhaps.
I've tried both, and neither made a difference as far as I remember.
> On Feb 23, 2017, at 09:19, Kenneth Marshall <k...@rice.edu> wrote:
> 
> On Thu, Feb 23, 2017 at 08:51:29AM -0500, Alex Hall wrote:
>> I'm going to send the email I normally hate to receive. If you ever figure 
>> this out, please share it with the list!
>> 
>> I have a script to assign the ticket creator as the owner on creation, which 
>> works perfectly. Like you, though, the owner fails to display properly in 
>> ticket lists but works if you open a ticket. This has annoyed all our staff 
>> for months, but when I asked about on this list, we couldn't work out what 
>> the problem was.
>> 
>> Sorry you're running into this, but at the same time, I'm glad to know it's 
>> not just me. :) 
>>> On Feb 23, 2017, at 08:13, Robert Blayzor <rblayzor.b...@inoc.net> wrote:
>>> 
>>> Running RT 4.4.1 - running fine for years and probably never noticed this 
>>> before. We have a Scrip that runs that probably carried over from the 
>>> pre-RT4 days.
>>> 
>>> 
>>> Pretty common function is to change the Owner of the ticket from “Nobody” 
>>> to the first person to correspond if they are a privileged user in RT. The 
>>> Scrip is below and it does work. (kind of).
>>> 
>>> 
>>> What works: When user is first to correspond, Scrip executes and in Ticket 
>>> view the Owner is set as expected.
>>> 
>>> 
>>> What doesn’t work: If we go into the queue and list all the open tickets, 
>>> the owner will be listed as “nobody” in this view, but if you open the 
>>> ticket, there is an owner. If you change the owner to someone else and 
>>> change it back, then it seems to fix this issue.
>>> 
>>> 
>>> Is this just a display bug or are we not using the proper method to change 
>>> the owner of the Ticket?
>>> 
>>> 
>>> 
>>> Here is the Scrip we’ve been using:
>>> 
>>> # Condition: On correspond
>>> # Action: User Defined
>>> # Template: blank
>>> 
>>> my $Actor = $self->TransactionObj->Creator;
>>> my $Queue = $self->TicketObj->QueueObj;
>>> 
>>> # if actor is RT_SystemUser then get out of here
>>> return 1 if $Actor == $RT::SystemUser->id;
>>> 
>>> # get out unless ticket owner is nobody
>>> return 1 unless $self->TicketObj->Owner == $RT::Nobody->id;
>>> 
>>> # get out unless $Actor is not part of AdminCc watchers
>>> return 1 unless $Queue->IsWatcher(Type => 'AdminCc', PrincipalId => $Actor);
>>> 
>>> # do the actual 'status update'
>>> my ($status, $msg) = $self->TicketObj->_Set(Field => 'Owner', Value => 
>>> $Actor, RecordTransaction => 0);
>>> unless( $status ) {
>>> $RT::Logger->warning( "Can't set ticket owner to $Actor: $msg" );
>>> return undef;
>>> }
>>> return 1;
>>> 
> 
> 
> Hi Alex and Robert,
> 
> What happens if you set RecordTransaction to 1/true? I have not checked the 
> code,
> but I would imagine that if you do not record the transaction, the cache 
> infrastructure
> would not invalidate the old entry and would continue to serve stale data. 
> Something
> to try perhaps.
> 
> Regards,
> Ken



Re: [rt-users] RT 4.4.1 - Change owner on corrospond Scrip - Strange issue

2017-02-23 Thread Alex Hall
I'm going to send the email I normally hate to receive. If you ever figure this 
out, please share it with the list!

I have a script to assign the ticket creator as the owner on creation, which 
works perfectly. Like you, though, the owner fails to display properly in 
ticket lists but works if you open a ticket. This has annoyed all our staff for 
months, but when I asked about on this list, we couldn't work out what the 
problem was.

Sorry you're running into this, but at the same time, I'm glad to know it's not 
just me. :) 
> On Feb 23, 2017, at 08:13, Robert Blayzor  wrote:
> 
> Running RT 4.4.1 - running fine for years and probably never noticed this 
> before. We have a Scrip that runs that probably carried over from the pre-RT4 
> days.
> 
> 
> Pretty common function is to change the Owner of the ticket from “Nobody” to 
> the first person to correspond if they are a privileged user in RT. The Scrip 
> is below and it does work. (kind of).
> 
> 
> What works: When user is first to correspond, Scrip executes and in Ticket 
> view the Owner is set as expected.
> 
> 
> What doesn’t work: If we go into the queue and list all the open tickets, the 
> owner will be listed as “nobody” in this view, but if you open the ticket, 
> there is an owner. If you change the owner to someone else and change it 
> back, then it seems to fix this issue.
> 
> 
> Is this just a display bug or are we not using the proper method to change 
> the owner of the Ticket?
> 
> 
> 
> Here is the Scrip we’ve been using:
> 
> # Condition: On correspond
> # Action: User Defined
> # Template: blank
> 
> my $Actor = $self->TransactionObj->Creator;
> my $Queue = $self->TicketObj->QueueObj;
> 
> # if actor is RT_SystemUser then get out of here
> return 1 if $Actor == $RT::SystemUser->id;
> 
> # get out unless ticket owner is nobody
> return 1 unless $self->TicketObj->Owner == $RT::Nobody->id;
> 
> # get out unless $Actor is not part of AdminCc watchers
> return 1 unless $Queue->IsWatcher(Type => 'AdminCc', PrincipalId => $Actor);
> 
> # do the actual 'status update'
> my ($status, $msg) = $self->TicketObj->_Set(Field => 'Owner', Value => 
> $Actor, RecordTransaction => 0);
> unless( $status ) {
>  $RT::Logger->warning( "Can't set ticket owner to $Actor: $msg" );
>  return undef;
> }
> return 1;
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 



[rt-users] excluding queue in RT SQL

2017-02-09 Thread Alex Hall
Hi all,
Just a quick question, and one I feel like I should know. In RT's
implementation of SQL, how do I specify a queue; name or ID?

We have a cron job that runs, using SQL to search for tickets. I'm being
asked to exclude a specific queue from this search. Do I need to use "queue
<> 'queue name'" or "queue <> 7"? Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] Search question: after a specific date

2017-02-01 Thread Alex Hall
On Wed, Feb 1, 2017 at 11:24 AM, Barrett, Brian <
brian_barr...@urmc.rochester.edu> wrote:

> Dear RT,
>
> I have a question regarding the searching for “after” a specific date on 2
> consecutive months.  The results for the current month include tickets from
> the previous.  See below
>
> When I do a search for
>
> Status = ‘resolved’
>
> AND Owner = “user’
>
> AND Resolved > ‘2016-12-31’
>
> I get a specific total of 38
>
> When I do a search for
>
> Status = ‘resolved’
>
> AND Owner = “user’
>
> AND Resolved > ‘201-01-31’
>
Assuming this is 2017, not just 201

I get a specific total of 6
>
> The 6 tickets showing for Feb are also in the report for Jan?  Why?
>
Because you spcified > 2016-12-31, which encompasses everything up to
today. Essentially, your two searches are identical, but one starts earlier
than the other. You'd need to limit your date with something like
Resolved < 2017-02-01
to eliminate anything past Jan 31. At least that's how I'm reading it;
sorry if I'm mistaken.

> I’m using RT v4.1.11
>
>
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] Changing default format of ticket list in queue?

2017-01-30 Thread Alex Hall
Sorry I wasn't clear. I'm talking about the results when you view all
tickets for a certain queue. For instance, open a ticket in the Customer
Service queue, and somewhere on that page is the queue name as a link.
Clicking that link takes you to a page listing all active tickets in that
queue. That list of tickets is what I want to modify.

I didn't realize until just now that the list is simply an automatic
search. I don't know how to modify the results page for this search without
changing the results for *any* search. At least I have a place to start
now. I was thinking that queues had special pages listing their active
tickets, so I was looking for that template.

On Mon, Jan 30, 2017 at 12:27 PM, Matt Zagrabelny <mzagr...@d.umn.edu>
wrote:

> Hi Alex,
>
> On Mon, Jan 30, 2017 at 11:18 AM, Alex Hall <ah...@autodist.com> wrote:
> > Hi all,
> > Where would I go to change the default format for the list of tickets
> shown
> > when you click a queue name?
>
> I presume you are talking about the Queue List?
>
>  Can this be done on a queue-by-queue basis, or
> > only as a modification to some template in share/html?
>
> I don't think there is anything out of the box that will do what you
> want. That being said, we use a callback to tweak the output for just
> a single queue.
>
> Note: the path may be different for the callback file location due to
> us running 4.2.
>
> # cat /opt/rt4/local/plugins/RT-Site-UMN-Duluth-QueueListTweaks/html/
> Callbacks/RT-Site-UMN-Duluth-QueueListTweaks/Elements/
> QueueSummaryByLifecycle/LinkBuilders
> <%INIT>
> my $umd_link_all = sub {
> my ($queue, $all_statuses) = @_;
> my @escaped = @{$all_statuses};
>
> # People want to see resolved tickets in the calendar view
> # of their QueueList - that is, for the Computer Management (CM) queue.
> # Aside from this "if" statement, this sub routine was lifted from
> # upstream's version.
> if ($queue->{Name} eq 'CM') {
> push @escaped, 'resolved';
> }
>
> s{(['\\])}{\\$1}g for @escaped; #'# help out the syntax highlighting
>
> my $search = ${$build_search_link}->(
> $queue->{Name},
> "(".join(" OR ", map "Status = '$_'", @escaped).")",
> );
>
> if ($queue->{Name} eq 'CM') {
> my @fields = map
> { "'__${_}__'" }
> (
> 'Created',
> 'Due',
> 'Resolved',
> 'Started',
> 'Starts',
> 'LastUpdated',
> )
> ;
>
> my $format = $m->interp->apply_escapes(
> join(',', @fields),
> 'u',
> );
> $search .= '='.$format;
> }
>
> return $search;
> };
>
> ${$link_all} = $umd_link_all;
> 
> <%ARGS>
> $build_search_link
> $link_all
> $link_status
> 
>
> Enjoy,
>
> -m
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] Changing default format of ticket list in queue?

2017-01-30 Thread Alex Hall
Hi all,
Where would I go to change the default format for the list of tickets shown
when you click a queue name? Can this be done on a queue-by-queue basis, or
only as a modification to some template in share/html? I'd like to make
some global changes, but for a few queues, have the value of a
queue-specific CF in the list. Thanks for any suggestions.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] Hiding menu options for particular user groups

2017-01-25 Thread Alex Hall
You're on Apache, so I doubt you're also using an FCGI server like Enginx
users have to? If you happen to be, you'll need to restart that separately,
and not worry about Apache. At least, I just restart the FCGI server and
not Nginx and it works. My only other idea is to reverse the order: clear
the cache, *then* restart Apache. I can't think of anything else you should
have to do. If it still doesn't work, check the names of your modified
files in local/html/Elements. If the file(s) you worked on there don't
match the names in share/html/Elements precisely, RT won't find and load
your versions.

On Wed, Jan 25, 2017 at 4:03 PM, Matthew Coons <coo...@umich.edu> wrote:

> Is there anything besides restarting apache and clearing the Mason cache
> that I need to do for my changes to take effect?
>
> I found the callbacks that reference the "logout" button in the "Tabs"
> file and I commented them out.
>
> I restarted apache and cleared the mason cache, but I still see the logout
> option present. Even if I start a new session from a private webpage.
>
> Any ideas what I may be doing wrong?
>
> Thanks.
>
> Matt Coons
> Incident Responder and Threat Analyst
> Information & Infrastructure Assurance (IIA)
> University of Michigan
>
> 734-764-4105 <(734)%20764-4105>
> coo...@umich.edu
>
> On Wed, Jan 25, 2017 at 3:03 PM, Matthew Coons <coo...@umich.edu> wrote:
>
>> Thanks Alex and Matt, this is really helpful!
>>
>>
>> Matt Coons
>> Incident Responder and Threat Analyst
>> Information & Infrastructure Assurance (IIA)
>> University of Michigan
>>
>> 734-764-4105 <(734)%20764-4105>
>> coo...@umich.edu
>>
>> On Wed, Jan 25, 2017 at 2:48 PM, Matt Zagrabelny <mzagr...@d.umn.edu>
>> wrote:
>>
>>> https://docs.bestpractical.com/rt/4.4.1/writing_extensions.h
>>> tml#Adding-and-Modifying-Menus
>>>
>>> On Wed, Jan 25, 2017 at 11:57 AM, Matthew Coons <coo...@umich.edu>
>>> wrote:
>>> > Hello RT users,
>>> >
>>> > I wanted to know if anybody had a working example or was already
>>> hiding RT
>>> > menu options from logged in users?
>>> >
>>> > The first item I want to hide is the "Logout" button for all users.
>>> We're
>>> > using SSO so it's not required to be present.
>>> >
>>> > The second item I would like to hide (for a specific user group) is
>>> the RTIR
>>> > menu option.
>>> >
>>> > Any help or suggestions would be much appreciated,
>>> >
>>> > Thank you!
>>> >
>>> > Matt Coons
>>> >
>>>
>>
>>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] Hiding menu options for particular user groups

2017-01-25 Thread Alex Hall
I don't have a specific example, but you can hide the Logout option with an
overlay.

cp [RT path]/share/html/Elements/Tabs [RT path]/local/html/Elements

Now open the copy you just made, find the Logout option, and wrap it in a
conditional, or add to the conditions already present. You can check the
group membership of the current user, for instance. Once done, don't forget
to clear your Mason cache and restart RT:

find [RT path]/var/mason_data/obj -mindepth 1 -delete
/etc/init.d/[RT script name] restart

If you need more detailed instructions, let the list know.

On Wed, Jan 25, 2017 at 12:57 PM, Matthew Coons <coo...@umich.edu> wrote:

> Hello RT users,
>
> I wanted to know if anybody had a working example or was already hiding RT
> menu options from logged in users?
>
> The first item I want to hide is the "Logout" button for all users. We're
> using SSO so it's not required to be present.
>
> The second item I would like to hide (for a specific user group) is the
> RTIR menu option.
>
> Any help or suggestions would be much appreciated,
>
> Thank you!
>
> Matt Coons
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] Limiting rt-crontool notifications to every n days?

2017-01-17 Thread Alex Hall
Thank you, that looks like it'll work. Did your JSON-like syntax for
updating fields ever make it into core for 4.4.1? I found the attachment in
your linked message, but it's a bin file and I'm not sure what to do with
it.

On Tue, Jan 17, 2017 at 11:17 AM, Matt Zagrabelny <mzagr...@d.umn.edu>
wrote:

> Hey Alex,
>
> On Mon, Jan 16, 2017 at 8:18 AM, Alex Hall <ah...@autodist.com> wrote:
> > Hi all,
> > RT is sending out notifications for old tickets just like we want it to.
> If
> > a ticket hasn't been updated in seven days and the status is open or new,
> > the owner gets an email every weekday until the ticket is updated. What
> I'd
> > like to do, though, is have a way of changing that "every weekday" bit
> for
> > stalled tickets.
> >
> > Instead of warning users every weekday about tickets that are stalled and
> > haven't been touched in a while, I'd like to warn them once or twice a
> week.
> > I can't run the cron job that seldom, though, or a ticket could go days
> > longer than it should without being picked up. Is there any way to only
> send
> > an email to a user if the system has not emailed them in N days? I could
> add
> > a column to the Tickets table for this, or add a new table, but I always
> > like to stay clear of database schema modifications if I can. Besides, I
> > don't know how to interface with a custom table using RT SQL.
>
> I wouldn't alter the schema.
>
> > Is there any way of doing this?
>
> You could use a custom field. Something like "Last Email Notification
> Sent At" or something equally verbose. ;)
>
> Then add that CF to your query about which tickets need to get email
> notifications.
>
> We do essentially what you are asking about. We leverage two things:
>
> 1. rt-crontool can take multiple --action arguments
> 2. A custom (but it could be "cored") scrip action. The scrip action
> is ModifyCustomField. Here is a link to it:
>
> http://lists.bestpractical.com/pipermail/rt-devel/2016-
> December/012601.html
>
> Here is one of our cron jobs that keeps track of when it sent an email
> and also sends the email:
>
> 0 12 * * * /opt/rt4/bin/rt-crontool --log=warning --search
> RT::Search::FromSQL --search-arg ' Queue = "Access Requests" AND
> Status = "activated" AND ( ( "CF.{Renewal Verified At}" IS NULL AND
> Created <= "1 year ago" ) OR ( "CF.{Renewal Verified At}" IS NOT NULL
> AND "CF.{Renewal Verified At}" <= "1 year ago" ) ) AND ( "CF.{Renewal
> Verification Sent At}" IS NULL OR "CF.{Renewal Verification Sent At}"
> <= "20 days ago" ) ' --transaction-type Create --transaction last
> --template "Access Request Renewal Verification" --action
> RT::Action::MailRequestors --action-arg "" --action
> RT::Action::ModifyCustomField --action-arg '{ "name": "Renewal
> Verification Sent At", "operation": "set", "value": "now" }'
>
> -m
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] When replying to a new ticket a new ticket get created

2017-01-16 Thread Alex Hall
That looks fine to me, though I'm no expert. I definitely don't see
anything that would cause email replies to turn into new tickets. My only
other idea is a rights problem, but I don't know RT well enough to know if
it's even possible.

My thought is that the users emailing replies don't have permission to
comment or correspond on the tickets in question, so RT is making new
tickets instead. But again, I don't know RT enough to say whether it would
do that or not. It's just a thought. Still, it might be worth checking the
rights, unless and until someone with more experience can help.

On Mon, Jan 16, 2017 at 9:25 AM, Martin Petersson <mar...@uanet.se> wrote:

> Yes here it is:
> I have no files in RT_SiteConfig.d/
>
> #
> # To include a directive here, just copy the equivalent statement
> # from RT_Config.pm and change the value. We've included a single
> # sample value below.
> #
> # If this file includes non-ASCII characters, it must be encoded in
> # UTF-8.
> #
> # This file is actually a perl module, so you can include valid
> # perl code, as well.
> #
> # The converse is also true, if this file isn't valid perl, you're
> # going to run into trouble. To check your SiteConfig file, use
> # this command:
> #
> #   perl -c /path/to/your/etc/RT_SiteConfig.pm
> #
> # You must restart your webserver after making changes to this file.
> #
>
> # You may also split settings into separate files under the
> etc/RT_SiteConfig.d/
> # directory.  All files ending in ".pm" will be parsed, in alphabetical
> order,
> # after this file is loaded.
>
> Set( $rtname, 'uanet.se');
> Set( $Organization, 'uanet.se');
> Set( $Timezone, 'Europe/Stockholm');
> Set( $WebDomain, 'help.uanet.se');
> Set( $WebPort, 443);
> Set( $WebPath, '');
> Set( $DatabasePassword, ’secret');
> Set($CorrespondAddress , ’supp...@uanet.se');
> Set($CommentAddress , 'support-comm...@uanet.se');
> Set(@ReferrerWhitelist, qw(helpdesk.uanet.se:443  helpdesk.uanet.se:80));
> # You must install Plugins on your own, this is only an example
> # of the correct syntax to use when activating them:
> # Plugin( "RT::Authen::ExternalAuth" );
> #Plugin('RT::Extension::SLA');
> #Plugin('RT::Extension::CommandByMail');
> #Set(@MailPlugins, qw(Auth::MailFrom Action::CommandByMail));
> 1;
>
>
>
> *Martin Petersson*
> *IT-Konsult*
>
> *+46 (0)522 980 28*, mar...@uanet.se, www.uanet.se
> Gustaf Mattssons Väg 2, 451 50 Uddevalla, Orgnr: 556702-4095
>
>
> <http://www.uanet.se/>
> <http://www.uanet.se/>
>
> 16 jan. 2017 kl. 15:19 skrev Alex Hall <ah...@autodist.com>:
>
> Yes, the regexp would be in there if you've modified it. Can you just post
> your entire RT_SiteConfig.pm file (or files if you're using files inside
> RT_SiteConfig.d)? That might be the best way for us to see what you're
> working with.
>
> On Mon, Jan 16, 2017 at 9:14 AM, Martin Petersson <mar...@uanet.se> wrote:
>
>> Hello,
>>
>> Thank you for your answer.
>> Should $EmailSubjectTagRegex be in RT_SiteConfig.pm?
>>
>> I have renamed the RT site, could that cause anything?
>>
>>
>> *Martin Petersson*
>> *IT-Konsult*
>>
>> *+46 (0)522 980 28*, mar...@uanet.se, www.uanet.se
>> Gustaf Mattssons Väg 2, 451 50 Uddevalla, Orgnr: 556702-4095
>>
>> 
>> <http://www.uanet.se/>
>> <http://www.uanet.se/>
>>
>> 16 jan. 2017 kl. 15:00 skrev Alex Hall <ah...@autodist.com>:
>>
>> My first thought is that you've modified your $EmailSubjectTagRegex
>> setting. If you have, there may be a mistake in that which is causing a
>> problem. If you have changed it, can you give us its current value? Or
>> disable the change and see if replies start working correctly, then debug
>> the regexp?
>>
>> On Sat, Jan 14, 2017 at 5:10 PM, Martin Petersson <mar...@uanet.se>
>> wrote:
>>
>>> Hello,
>>>
>>> Somehow i get the auto reply ticket that the customer receive.
>>> And then when i reply to the ticket it creates a new ticket, whats wrong?
>>>
>>> I have Ubuntu latest OS and RT 4.4.1
>>>
>>>
>>>
>>>
>>> *Martin Petersson*
>>> *IT-Konsult*
>>>
>>> *+46 (0)522 980 28*, mar...@uanet.se, www.uanet.se
>>> Gustaf Mattssons Väg 2, 451 50 Uddevalla, Orgnr: 556702-4095
>>>
>>> 
>>> <http://www.uanet.se/>
>>> <http://www.uanet.se/>
>>>
>>>
>>
>>
>> --
>> Alex Hall
>> Automatic Distributors, IT department
>> ah...@autodist.com
>>
>>
>>
>
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] When replying to a new ticket a new ticket get created

2017-01-16 Thread Alex Hall
Yes, the regexp would be in there if you've modified it. Can you just post
your entire RT_SiteConfig.pm file (or files if you're using files inside
RT_SiteConfig.d)? That might be the best way for us to see what you're
working with.

On Mon, Jan 16, 2017 at 9:14 AM, Martin Petersson <mar...@uanet.se> wrote:

> Hello,
>
> Thank you for your answer.
> Should $EmailSubjectTagRegex be in RT_SiteConfig.pm?
>
> I have renamed the RT site, could that cause anything?
>
>
> *Martin Petersson*
> *IT-Konsult*
>
> *+46 (0)522 980 28*, mar...@uanet.se, www.uanet.se
> Gustaf Mattssons Väg 2, 451 50 Uddevalla, Orgnr: 556702-4095
>
>
> <http://www.uanet.se/>
> <http://www.uanet.se/>
>
> 16 jan. 2017 kl. 15:00 skrev Alex Hall <ah...@autodist.com>:
>
> My first thought is that you've modified your $EmailSubjectTagRegex
> setting. If you have, there may be a mistake in that which is causing a
> problem. If you have changed it, can you give us its current value? Or
> disable the change and see if replies start working correctly, then debug
> the regexp?
>
> On Sat, Jan 14, 2017 at 5:10 PM, Martin Petersson <mar...@uanet.se> wrote:
>
>> Hello,
>>
>> Somehow i get the auto reply ticket that the customer receive.
>> And then when i reply to the ticket it creates a new ticket, whats wrong?
>>
>> I have Ubuntu latest OS and RT 4.4.1
>>
>>
>>
>>
>> *Martin Petersson*
>> *IT-Konsult*
>>
>> *+46 (0)522 980 28*, mar...@uanet.se, www.uanet.se
>> Gustaf Mattssons Väg 2, 451 50 Uddevalla, Orgnr: 556702-4095
>>
>> 
>> <http://www.uanet.se/>
>> <http://www.uanet.se/>
>>
>>
>
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] Limiting rt-crontool notifications to every n days?

2017-01-16 Thread Alex Hall
Hi all,
RT is sending out notifications for old tickets just like we want it to. If
a ticket hasn't been updated in seven days and the status is open or new,
the owner gets an email every weekday until the ticket is updated. What I'd
like to do, though, is have a way of changing that "every weekday" bit for
stalled tickets.

Instead of warning users every weekday about tickets that are stalled and
haven't been touched in a while, I'd like to warn them once or twice a
week. I can't run the cron job that seldom, though, or a ticket could go
days longer than it should without being picked up. Is there any way to
only send an email to a user if the system has not emailed them in N days?
I could add a column to the Tickets table for this, or add a new table, but
I always like to stay clear of database schema modifications if I can.
Besides, I don't know how to interface with a custom table using RT SQL.

Is there any way of doing this? I wouldn't mind lowering active ticket
warnings to every other day as well, if I could, so this would help
multiple places. Thanks for any thoughts.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] When replying to a new ticket a new ticket get created

2017-01-16 Thread Alex Hall
My first thought is that you've modified your $EmailSubjectTagRegex
setting. If you have, there may be a mistake in that which is causing a
problem. If you have changed it, can you give us its current value? Or
disable the change and see if replies start working correctly, then debug
the regexp?

On Sat, Jan 14, 2017 at 5:10 PM, Martin Petersson <mar...@uanet.se> wrote:

> Hello,
>
> Somehow i get the auto reply ticket that the customer receive.
> And then when i reply to the ticket it creates a new ticket, whats wrong?
>
> I have Ubuntu latest OS and RT 4.4.1
>
>
>
>
> *Martin Petersson*
> *IT-Konsult*
>
> *+46 (0)522 980 28*, mar...@uanet.se, www.uanet.se
> Gustaf Mattssons Väg 2, 451 50 Uddevalla, Orgnr: 556702-4095
>
>
> <http://www.uanet.se/>
> <http://www.uanet.se/>
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] Warning users before creating new ticket?

2017-01-11 Thread Alex Hall
Hi all,
Someone just asked me if I could add a feature to our RT installation, but
I don't know how to go about it.

In our customer service queue, we have a custom field for the order number
to which the ticket refers. Sometimes, two different reps will start
working on the same order without realizing it, thus making the CF the same
order number for two tickets. The feature I'm being asked about is a check
for other tickets that have that same order number; if any exist, the user
gets a warning and can cancel their ticket. They are also told who owns the
original ticket.

I can see two pieces to this, and how to do them both. The lookup happens
in a script tied to ticket creation, and the warning is custom JavaScript
that simply pops up a confirm prompt. But how to put these two together is
where I'm stuck. How would the results of the script's search get back to
Javascript, and how would OK/Cancel in the JS confirm box get back to the
script? Alternatively, does something like this already exist that I just
don't know about? Thanks for any ideas on this.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] Owner not showing in search results?

2017-01-05 Thread Alex Hall
Never mind the SQL logging question, I got it. Something really weird: in
the ticket insertion, I see no owner value at all. Here it is:

INSERT INTO Tickets
(Resolved, Priority, Starts, Creator, InitialPriority, SLA, Created,
LastUpdatedBy, Type, Queue, LastUpdated, Started, Due, Subject,
FinalPriority, Status)
VALUES ('1970-01-01 00:00:00', '1', '1970-01-01 00:00:00', '28', '1', NULL,
'2017-01-05 22:51:29', '28', 'ticket', '5', '2017-01-05 22:51:29',
'1970-01-01 00:00:00', '2017-01-07 22:51:29', 'Test', '50', 'new')

Of course, I see nothing for the custom field I set either. Still, why
would owner not be set in the initial ticket insertion? Later, I see this
insertion, for some reason:

INSERT INTO Groups
(Instance, LastUpdated, Name, Created, LastUpdatedBy, Domain, Description,
id, Creator)
VALUES ('1164', '2017-01-05 22:51:29', 'Owner', '2017-01-05 22:51:29',
'28', 'RT::Ticket-Role', NULL, '4856', '28')

I have no idea what that's about. I have to run, so there may be more in
the log file I'll get to tomorrow. But what's going on here, and could this
explain why owners don't show in search results but they do in ticket
displays? Thanks.



On Thu, Jan 5, 2017 at 1:40 PM, Alex Hall <ah...@autodist.com> wrote:

>
>
> On Mon, Nov 28, 2016 at 11:41 AM, Kenneth Marshall <k...@rice.edu> wrote:
>
>> On Mon, Nov 28, 2016 at 11:32:36AM -0500, Alex Hall wrote:
>> > Thanks, I didn't know that would happen. I did that to suppress the
>> email notification; we want users notified if their tickets change owners,
>> but only if that change is NOT from "nobody" to themselves.
>> >
>> > I just updated the script to record the transaction. It worked, because
>> I got the email I wanted suppressed, and the owner still changed. Oddly,
>> "nobody" is still the owner when I search for my ticket, though. Should I
>> flush a cache or something? Mason cache wouldn't have anything to do with
>> this, would it?
>>
>> Hi Alex,
>>
>> Well, that is not what I would have expected to happen. I do not know
>> enough
>> about the DB queries that are being run to generate the search results.
>> Probably,
>> my next step would be to look at the actual query and see where the
>> incorrect
>> results are being produced. I am not much help because we use PostgreSQL
>> as
>> the DB and not MySQL. Sorry, I cannot be of more assistance.
>>
>
> How do I view the actual query being used? Is there a way to get RT to
> store it, or some other trick? Thanks.
>
>>
>> Regards,
>> Ken
>>
>
>
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] Owner not showing in search results?

2017-01-05 Thread Alex Hall
On Mon, Nov 28, 2016 at 11:41 AM, Kenneth Marshall <k...@rice.edu> wrote:

> On Mon, Nov 28, 2016 at 11:32:36AM -0500, Alex Hall wrote:
> > Thanks, I didn't know that would happen. I did that to suppress the
> email notification; we want users notified if their tickets change owners,
> but only if that change is NOT from "nobody" to themselves.
> >
> > I just updated the script to record the transaction. It worked, because
> I got the email I wanted suppressed, and the owner still changed. Oddly,
> "nobody" is still the owner when I search for my ticket, though. Should I
> flush a cache or something? Mason cache wouldn't have anything to do with
> this, would it?
>
> Hi Alex,
>
> Well, that is not what I would have expected to happen. I do not know
> enough
> about the DB queries that are being run to generate the search results.
> Probably,
> my next step would be to look at the actual query and see where the
> incorrect
> results are being produced. I am not much help because we use PostgreSQL as
> the DB and not MySQL. Sorry, I cannot be of more assistance.
>

How do I view the actual query being used? Is there a way to get RT to
store it, or some other trick? Thanks.

>
> Regards,
> Ken
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] __active__ including stalled tickets?

2017-01-05 Thread Alex Hall
Okay, I can see that. I was thinking of active/inactive as now, as in a
stalled ticket is inactive until someone un-stalls it. But from RT's
perspective, it does make sense that a ticket not deleted or resolved is
still, in some way, active. I'll have to adjust my crontool script too, or
people will get warnings about stalled tickets when I promised they
wouldn't. Glad I checked!

On Thu, Jan 5, 2017 at 11:12 AM, Matt Zagrabelny <mzagr...@d.umn.edu> wrote:

> ...and I see that Shawn has answered, too. Here is what I had to say:
>
> "stalled" is an active status. I know the word feels "inactive", but
> according to the default lifecycle, it is active.
>
> https://github.com/bestpractical/rt/blob/stable/etc/RT_Config.pm.in#L3034
>
> On Thu, Jan 5, 2017 at 10:07 AM, Alex Hall <ah...@autodist.com> wrote:
> >
> >
> > On Thu, Jan 5, 2017 at 11:01 AM, Matt Zagrabelny <mzagr...@d.umn.edu>
> wrote:
> >>
> >> __Active__ is case sensitive, I believe.
> >
> >  I should have said that I tried capital and lowercase A in my searches,
> > along with making the word all caps. I keep getting the same result.
> >
> >>
> >> -m
> >>
> >> On Thu, Jan 5, 2017 at 9:56 AM, Alex Hall <ah...@autodist.com> wrote:
> >> > Hey all,
> >> > I just did a search:
> >> > Priority > 9 and Status = '__active__'
> >> > Five of the resulting tickets are stalled, but I thought __active__
> >> > ignored
> >> > stalled tickets. Any idea why they're appearing? Did I miss a setting
> or
> >> > something, or is this intended behavior? Thanks.
> >> > --
> >> > Alex Hall
> >> > Automatic Distributors, IT department
> >> > ah...@autodist.com
> >
> >
> >
> >
> > --
> > Alex Hall
> > Automatic Distributors, IT department
> > ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] __active__ including stalled tickets?

2017-01-05 Thread Alex Hall
On Thu, Jan 5, 2017 at 11:01 AM, Matt Zagrabelny <mzagr...@d.umn.edu> wrote:

> __Active__ is case sensitive, I believe.
>
 I should have said that I tried capital and lowercase A in my searches,
along with making the word all caps. I keep getting the same result.


> -m
>
> On Thu, Jan 5, 2017 at 9:56 AM, Alex Hall <ah...@autodist.com> wrote:
> > Hey all,
> > I just did a search:
> > Priority > 9 and Status = '__active__'
> > Five of the resulting tickets are stalled, but I thought __active__
> ignored
> > stalled tickets. Any idea why they're appearing? Did I miss a setting or
> > something, or is this intended behavior? Thanks.
> > --
> > Alex Hall
> > Automatic Distributors, IT department
> > ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] __active__ including stalled tickets?

2017-01-05 Thread Alex Hall
Hey all,
I just did a search:
Priority > 9 and Status = '__active__'
Five of the resulting tickets are stalled, but I thought __active__ ignored
stalled tickets. Any idea why they're appearing? Did I miss a setting or
something, or is this intended behavior? Thanks.
-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] How unprivileged users could see all tickets in their queue?

2017-01-05 Thread Alex Hall
Ah, got it. If you want to restrict users from seeing the user search
option, and from searching tickets, it seems like both Martin's and my
emails will do it. The only potential problem I see with mine is that one
could still type in a username, though queue/group restrictions should
still stop tickets involving that user from appearing.

On Thu, Jan 5, 2017 at 9:26 AM, Felix Defrance <fe...@d2france.fr> wrote:

>
>
> Le 05/01/2017 à 12:22, Alex Hall a écrit :
> > Martin's suggestion makes sense, but I thought Felix was trying to
> restrict user search, not ticket search? That is, he doesn't want users to
> be able to search (and thus view the names of) all users? It's quite early
> here, so my brain may still be muttled and I could be wrong.
> Alex, after I see it was possible to display any tickets via the search
> module, I want to restrict this too.
>
> >
> > Sent from my iPhone
> >
> >> On Jan 5, 2017, at 06:08, Martin Wheldon <martin.wheldon@greenhills-it.
> co.uk> wrote:
> >>
> >> Hi Félix,
> >>
> >> I've just tried to configure this on a RT 4.4.1 install using a custom
> role and it seems to work fine.
> >> Here is the process I carried out.
> >>
> >> I've got 2 unprivileged users with a single queue, each being the owner
> of multiple tickets in that queue.
> >> I created a new custom role, then assigned it to the queue. Next I
> added the users to the custom role. (Done on the queue, watchers tab)
> >> The I added the SeeQueue and ShowTickets permissions to the custom role
> on the queue.
> >>
> >> Now when I login as either of the users I see all the tickets in that
> queue owner by those users.
> In this case, unprivileged users via (SelfService of course), just see
> their own tickets. For me, I have just 2 menus: "Tickets" and "Logged in
> foobar".
>
> In Tickets, I just see "Open tickets" and "Closed Tickets". In both
> pages, I just see tickets that users declarated as requestor.
>
> The custom role not provide an access to see all ticket in the queue (as
> elacour told to us).
>
> Now I understand the goal of the roles, maybe it's possible to
> automaticaly add custom role as a watcher to the right queue on all
> existing tickets and  the futur new ticket.
>
> Do you think it's possible ?
>
> Thx
>
> >>
> >> Hope that helps
> >>
> >> Best Regards
> >>
> >> Martin
> >>
> >>> On 2017-01-04 08:45, Emmanuel Lacour wrote:
> >>>> Le 03/01/2017 à 18:27, Felix Defrance a écrit :
> >>>> Hi all,
> >>>> I don't find how I could add ShowTickets or QueueList in
> >>>> SelfService.
> >>>> I want to allow my unprivileged users, grouped by company name, to
> >>>> see all tickets in their queue.
> >>>> The group rights on the queue is correctly defined and users could
> >>>> access to the tickets by entring the ticket number in the "goto
> >>>> Ticket" field (top right in SelfService).
> >>>> I have tried to play with CustomRole but it's not working for me. So
> >>>> anybody known how I can do it?
> >>> SelfService filters ticket list to tickets the user is watcher on
> >>> (requestor or Cc). This is hard coded in
> >>> share/html/SelfService/Elements/MyRequests:
> >>> my $id = $session{'CurrentUser'}->id;
> >>> my $Query = "( Watcher.id = $id )";
> >>> if ($status) {
> >>>$status =~ s/(['\\])/\\$1/g;
> >>>$Query .= " AND Status = '$status'";
> >>> }
> >>> so if you wan't to relax this to all tickets users have ShowTicket
> >>> rights, you have to modify this query ;)
> >>> But I strongly discourage (unless really needed) to setup an RT
> >>> instance with one queue per customer, best to think queues per
> >>> internal support team and play with customroles/groups or customfields
> >>> to set the customer.
>
> --
> Félix Defrance
> PGP: 0x0F04DC57
>
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] How unprivileged users could see all tickets in their queue?

2017-01-05 Thread Alex Hall
Martin's suggestion makes sense, but I thought Felix was trying to restrict 
user search, not ticket search? That is, he doesn't want users to be able to 
search (and thus view the names of) all users? It's quite early here, so my 
brain may still be muttled and I could be wrong. 

Sent from my iPhone

> On Jan 5, 2017, at 06:08, Martin Wheldon  
> wrote:
> 
> Hi Félix,
> 
> I've just tried to configure this on a RT 4.4.1 install using a custom role 
> and it seems to work fine.
> Here is the process I carried out.
> 
> I've got 2 unprivileged users with a single queue, each being the owner of 
> multiple tickets in that queue.
> I created a new custom role, then assigned it to the queue. Next I added the 
> users to the custom role. (Done on the queue, watchers tab)
> The I added the SeeQueue and ShowTickets permissions to the custom role on 
> the queue.
> 
> Now when I login as either of the users I see all the tickets in that queue 
> owner by those users.
> 
> Hope that helps
> 
> Best Regards
> 
> Martin
> 
>> On 2017-01-04 08:45, Emmanuel Lacour wrote:
>>> Le 03/01/2017 à 18:27, Felix Defrance a écrit :
>>> Hi all,
>>> I don't find how I could add ShowTickets or QueueList in
>>> SelfService.
>>> I want to allow my unprivileged users, grouped by company name, to
>>> see all tickets in their queue.
>>> The group rights on the queue is correctly defined and users could
>>> access to the tickets by entring the ticket number in the "goto
>>> Ticket" field (top right in SelfService).
>>> I have tried to play with CustomRole but it's not working for me. So
>>> anybody known how I can do it?
>> SelfService filters ticket list to tickets the user is watcher on
>> (requestor or Cc). This is hard coded in
>> share/html/SelfService/Elements/MyRequests:
>> my $id = $session{'CurrentUser'}->id;
>> my $Query = "( Watcher.id = $id )";
>> if ($status) {
>>$status =~ s/(['\\])/\\$1/g;
>>$Query .= " AND Status = '$status'";
>> }
>> so if you wan't to relax this to all tickets users have ShowTicket
>> rights, you have to modify this query ;)
>> But I strongly discourage (unless really needed) to setup an RT
>> instance with one queue per customer, best to think queues per
>> internal support team and play with customroles/groups or customfields
>> to set the customer.


Re: [rt-users] Where to put crontool scripts?

2017-01-05 Thread Alex Hall
Thanks for the thoughts, everyone. I think we'll keep them under local, in 
their own folder. Good to know upgrading won't touch anything. 

Sent from my iPhone

> On Jan 5, 2017, at 00:54, Alex Vandiver <a...@chmrr.net> wrote:
> 
> On Wed, 4 Jan 2017 11:13:38 -0500
> Alex Hall <ah...@autodist.com> wrote:
>> I'm considering putting them in /opt/rt4/etc, maybe in a "crontool-scripts"
>> folder, but I don't know what RT upgrades might do to that.
> 
> RT upgrades won't remove any extra files you have lying around.
> - Alex


Re: [rt-users] Ticket owner in database set to "no owner shown in search results"

2017-01-04 Thread Alex Hall
While this is still a mystery, please disregard the below email. I was
reading the columns wrong and mistook the subject for the owner. The owner
is actually set properly, yet this and another ticket come up if you search
for tickets whose owner is 'nobody'. Odd, but not quite as odd as I had in
the below message.

On Wed, Jan 4, 2017 at 12:18 PM, Alex Hall <ah...@autodist.com> wrote:

> Hi all,
> A while ago I was asking why owners don't always show in search results. I
> just had a look at one such ticket in the database:
>
> select * from Tickets where id = 527;
>
> The "Owner" column is set to the value "no owner shown in search results".
> I don't know how it got that way, or what it means. More puzzling still, if
> I open the ticket in the web UI, the owner is correct. Yet, this ticket
> shows up if I search for tickets in the UI with "Owner='nobody'". Somehow,
> RT knows the owner, but in the Tickets table has it set to this odd value
> I've never seen. What would cause this and, more importantly, how do I stop
> it from happening?
>
> We have a script set up to make the requestor the owner automatically, but
> that's working (I got it straight from the Wiki). This means that users
> aren't manually adding themselves as owners, they're relying on the script
> to do it for them when the ticket is created. Yet, sometimes, we get a
> ticket like the one described above--no owner in the database or searches,
> but an owner when you view the actual ticket. Any thoughts as to how to fix
> this, and how RT knows the owner? Is it substituting the creator somehow?
> I'm very confused! Thanks for any suggestions.
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] How unprivileged users could see all tickets in their queue?

2017-01-04 Thread Alex Hall
I'm honestly not sure which file you want, but my guess is
share/html/Elements/Tabs. In that file is a line that goes something like:

$search->child( users ...

If you wrap that bit in a conditional, checking that the active user is not
a member of the group as I said in a previous message, that should do the
job.

On Wed, Jan 4, 2017 at 12:21 PM, Felix Defrance <fe...@d2france.fr> wrote:

>
>
> Le 04/01/2017 à 15:47, Alex Hall a écrit :
>
>
>
> On Wed, Jan 4, 2017 at 9:35 AM, Felix Defrance <fe...@d2france.fr> wrote:
>
>>
>> Le 04/01/2017 à 15:10, Alex Hall a écrit :
>>
>> Okay, searching users is the problem? I'm not sure, but what about an
>> overlay that conditionally shows that part of page templates? You could
>> create a group to which you'd assign any user you don't want viewing other
>> users, then find the element that displays the user search and add a
>> condition to return nothing if the user belongs to that group?
>>
>> Yes, this is a part of the problem. The second, but not important, it's
>> just for the look, the ability to custom "Rt at a glance" by user
>> groups.
>>
>> For the first, I don't known how I can do " then find the element that
>> displays the user search and add a condition to return nothing if the user
>> belongs to that group"
>>
>> In one template, I was able to find this snippet to get the user object:
> my $user = $session{'CurrentUser'}->UserObj;
>
> From there, I imagine you could check if the user is a member of a certain
> group. Then "return 0" or something like that to stop the element from
> loading. My Perl skills aren't worthy of being called skills in any way,
> and I've never tried something quite like this, but it's my first thought.
> Sorry I can't help more; hopefully a more experienced user has a much
> simpler solution for you. :)
>
>
> Do you know if the menu search come from : rt/share/html/Dashboards/Elements/*
> ? Or from another file ?
>
> I don't find documentation about these files and what are they doing :(
>
> Thanks
>
>
>>
>> On Wed, Jan 4, 2017 at 8:57 AM, Felix Defrance <fe...@d2france.fr> wrote:
>>
>>>
>>> Le 04/01/2017 à 14:02, Alex Hall a écrit :
>>>
>>> Can you describe your setup more? I'm not sure why unprivileged users
>>> would need access to all queue tickets, or why each user would have their
>>> own queue? As I understand it, unprivileged users are end users (i.e.
>>> customers, those who don't work for your organization). Thus, they
>>> shouldn't be able to access an entire queue, only tickets they open. Make
>>> them privileged, and restrict their rights by adding them to a certain
>>> group, and your life may be a lot easier.
>>>
>>> Yes! In the begining, that's what I tried to do. Restrict privilieged
>>> users. But I didn't find how restrict the access to the SearchUser.
>>>
>>> A member of a queue can search and view all users.
>>>
>>> In my setup, a queue and group, are dedicated to a customer.
>>>
>>> A customer should not be able to fetch other informations that are not
>>> inside of their queue. Thus, not be able to search all user in RT database..
>>>
>>> Maybe, it's possible to limit the search function to their queue or
>>> desactivate the access to the menu search. Do you know about that ?
>>>
>>> Thanks,
>>>
>>>
>>> For example, you might have a group called "basic users" to which you'd
>>> add the users you currently consider unprivileged. That group would have
>>> only a few rights, but since its members would be privileged, you wouldn't
>>> run into RT's built-in restrictions.
>>>
>>> As to one queue per user, that would quickly get hard to manage. Queues
>>> are for organizing tickets and users. Sure, a queue may have just one user,
>>> but each user shouldn't have their own queue. Trying to keep track of the
>>> rights of such a setup would be a nightmare, assuming you have a good
>>> amount of users. As an example, we have queues for technology, warehouse,
>>> customer service, and other divisions within the company. Some queues have
>>> a lot of people, some have a few, butthey are all logical groupings of
>>> tasks. If I made a new queue for every user, I'd have dozens of them, and
>>> tickets would be all over the place! Plus, there's email to consider; if
>>> you want to accept incoming emails for ticket replies, you have to make a
>>> new Fetchmail or Postfi

[rt-users] Ticket owner in database set to "no owner shown in search results"

2017-01-04 Thread Alex Hall
Hi all,
A while ago I was asking why owners don't always show in search results. I
just had a look at one such ticket in the database:

select * from Tickets where id = 527;

The "Owner" column is set to the value "no owner shown in search results".
I don't know how it got that way, or what it means. More puzzling still, if
I open the ticket in the web UI, the owner is correct. Yet, this ticket
shows up if I search for tickets in the UI with "Owner='nobody'". Somehow,
RT knows the owner, but in the Tickets table has it set to this odd value
I've never seen. What would cause this and, more importantly, how do I stop
it from happening?

We have a script set up to make the requestor the owner automatically, but
that's working (I got it straight from the Wiki). This means that users
aren't manually adding themselves as owners, they're relying on the script
to do it for them when the ticket is created. Yet, sometimes, we get a
ticket like the one described above--no owner in the database or searches,
but an owner when you view the actual ticket. Any thoughts as to how to fix
this, and how RT knows the owner? Is it substituting the creator somehow?
I'm very confused! Thanks for any suggestions.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] Where to put crontool scripts?

2017-01-04 Thread Alex Hall
Hi all,
I'm just wondering if there's a conventional place to store scripts that
run crontool jobs? I've got one to notify people of old tickets, but I'll
be making more, now that this one is working. Thanks again for all the help
with that script, by the way.

I'm considering putting them in /opt/rt4/etc, maybe in a "crontool-scripts"
folder, but I don't know what RT upgrades might do to that. Is it best to
just put them somewhere completely separate, like ~/rt-crontool-scripts, or
can I keep them somewhere in the RT directory tree? Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] How unprivileged users could see all tickets in their queue?

2017-01-04 Thread Alex Hall
On Wed, Jan 4, 2017 at 9:35 AM, Felix Defrance <fe...@d2france.fr> wrote:

>
> Le 04/01/2017 à 15:10, Alex Hall a écrit :
>
> Okay, searching users is the problem? I'm not sure, but what about an
> overlay that conditionally shows that part of page templates? You could
> create a group to which you'd assign any user you don't want viewing other
> users, then find the element that displays the user search and add a
> condition to return nothing if the user belongs to that group?
>
> Yes, this is a part of the problem. The second, but not important, it's
> just for the look, the ability to custom "Rt at a glance" by user
> groups.
>
> For the first, I don't known how I can do " then find the element that
> displays the user search and add a condition to return nothing if the user
> belongs to that group"
>
> In one template, I was able to find this snippet to get the user object:
my $user = $session{'CurrentUser'}->UserObj;

>From there, I imagine you could check if the user is a member of a certain
group. Then "return 0" or something like that to stop the element from
loading. My Perl skills aren't worthy of being called skills in any way,
and I've never tried something quite like this, but it's my first thought.
Sorry I can't help more; hopefully a more experienced user has a much
simpler solution for you. :)

>
>
> On Wed, Jan 4, 2017 at 8:57 AM, Felix Defrance <fe...@d2france.fr> wrote:
>
>>
>> Le 04/01/2017 à 14:02, Alex Hall a écrit :
>>
>> Can you describe your setup more? I'm not sure why unprivileged users
>> would need access to all queue tickets, or why each user would have their
>> own queue? As I understand it, unprivileged users are end users (i.e.
>> customers, those who don't work for your organization). Thus, they
>> shouldn't be able to access an entire queue, only tickets they open. Make
>> them privileged, and restrict their rights by adding them to a certain
>> group, and your life may be a lot easier.
>>
>> Yes! In the begining, that's what I tried to do. Restrict privilieged
>> users. But I didn't find how restrict the access to the SearchUser.
>>
>> A member of a queue can search and view all users.
>>
>> In my setup, a queue and group, are dedicated to a customer.
>>
>> A customer should not be able to fetch other informations that are not
>> inside of their queue. Thus, not be able to search all user in RT database..
>>
>> Maybe, it's possible to limit the search function to their queue or
>> desactivate the access to the menu search. Do you know about that ?
>>
>> Thanks,
>>
>>
>> For example, you might have a group called "basic users" to which you'd
>> add the users you currently consider unprivileged. That group would have
>> only a few rights, but since its members would be privileged, you wouldn't
>> run into RT's built-in restrictions.
>>
>> As to one queue per user, that would quickly get hard to manage. Queues
>> are for organizing tickets and users. Sure, a queue may have just one user,
>> but each user shouldn't have their own queue. Trying to keep track of the
>> rights of such a setup would be a nightmare, assuming you have a good
>> amount of users. As an example, we have queues for technology, warehouse,
>> customer service, and other divisions within the company. Some queues have
>> a lot of people, some have a few, butthey are all logical groupings of
>> tasks. If I made a new queue for every user, I'd have dozens of them, and
>> tickets would be all over the place! Plus, there's email to consider; if
>> you want to accept incoming emails for ticket replies, you have to make a
>> new Fetchmail or Postfix entry for every single user/queue you have.
>>
>> I hope this makes some sense. As I said, a lot of this depends on your
>> usage pattern and setup concept. If you can explain that to us more, we
>> might be able to help better.
>>
>> On Wed, Jan 4, 2017 at 3:57 AM, Felix Defrance <fe...@d2france.fr> wrote:
>>
>>> Hello,
>>>
>>> You right, this rights isn't checked.
>>>
>>> But I can't view all tickets in selfservice anymore.
>>>
>>> I verify the same rights in :
>>>
>>>  Admin > Queue, "select the queue name" and  Group Rights, select and
>>> grant "unprivileged users" to Seequeue & Showtickets
>>>
>>> In the same section:
>>>
>>>  grant group "compagny name" to Seequeue & Showtickets
>>>
>>>
>>> But no effect.
>>>
>>> I try to add a 

Re: [rt-users] How unprivileged users could see all tickets in their queue?

2017-01-04 Thread Alex Hall
Okay, searching users is the problem? I'm not sure, but what about an
overlay that conditionally shows that part of page templates? You could
create a group to which you'd assign any user you don't want viewing other
users, then find the element that displays the user search and add a
condition to return nothing if the user belongs to that group?

On Wed, Jan 4, 2017 at 8:57 AM, Felix Defrance <fe...@d2france.fr> wrote:

>
> Le 04/01/2017 à 14:02, Alex Hall a écrit :
>
> Can you describe your setup more? I'm not sure why unprivileged users
> would need access to all queue tickets, or why each user would have their
> own queue? As I understand it, unprivileged users are end users (i.e.
> customers, those who don't work for your organization). Thus, they
> shouldn't be able to access an entire queue, only tickets they open. Make
> them privileged, and restrict their rights by adding them to a certain
> group, and your life may be a lot easier.
>
> Yes! In the begining, that's what I tried to do. Restrict privilieged
> users. But I didn't find how restrict the access to the SearchUser.
>
> A member of a queue can search and view all users.
>
> In my setup, a queue and group, are dedicated to a customer.
>
> A customer should not be able to fetch other informations that are not
> inside of their queue. Thus, not be able to search all user in RT database..
>
> Maybe, it's possible to limit the search function to their queue or
> desactivate the access to the menu search. Do you know about that ?
>
> Thanks,
>
>
> For example, you might have a group called "basic users" to which you'd
> add the users you currently consider unprivileged. That group would have
> only a few rights, but since its members would be privileged, you wouldn't
> run into RT's built-in restrictions.
>
> As to one queue per user, that would quickly get hard to manage. Queues
> are for organizing tickets and users. Sure, a queue may have just one user,
> but each user shouldn't have their own queue. Trying to keep track of the
> rights of such a setup would be a nightmare, assuming you have a good
> amount of users. As an example, we have queues for technology, warehouse,
> customer service, and other divisions within the company. Some queues have
> a lot of people, some have a few, butthey are all logical groupings of
> tasks. If I made a new queue for every user, I'd have dozens of them, and
> tickets would be all over the place! Plus, there's email to consider; if
> you want to accept incoming emails for ticket replies, you have to make a
> new Fetchmail or Postfix entry for every single user/queue you have.
>
> I hope this makes some sense. As I said, a lot of this depends on your
> usage pattern and setup concept. If you can explain that to us more, we
> might be able to help better.
>
> On Wed, Jan 4, 2017 at 3:57 AM, Felix Defrance <fe...@d2france.fr> wrote:
>
>> Hello,
>>
>> You right, this rights isn't checked.
>>
>> But I can't view all tickets in selfservice anymore.
>>
>> I verify the same rights in :
>>
>>  Admin > Queue, "select the queue name" and  Group Rights, select and
>> grant "unprivileged users" to Seequeue & Showtickets
>>
>> In the same section:
>>
>>  grant group "compagny name" to Seequeue & Showtickets
>>
>>
>> But no effect.
>>
>> I try to add a user to watchers 'CC', and grant watchers 'CC' to Seequeue
>> & Showtickets but no effect too :(
>>
>> Another ideas ?
>>
>> Thanks,
>>
>> Félix.
>> Le 03/01/2017 à 18:39, Alex Hall a écrit :
>>
>> Have you granted the rights? In Admin > Global > Group Rights, select the
>> "unprivileged users" tab, then grant "view queue". That should help, though
>> our setup is quite different so I can't verify it.
>>
>> On Tue, Jan 3, 2017 at 12:27 PM, Felix Defrance <fe...@d2france.fr>
>> wrote:
>>
>>> Hi all,
>>>
>>> I don't find how I could add ShowTickets or QueueList in SelfService.
>>>
>>> I want to allow my unprivileged users, grouped by company name, to see
>>> all tickets in their queue.
>>>
>>> The group rights on the queue is correctly defined and users could
>>> access to the tickets by entring the ticket number in the "goto Ticket"
>>> field (top right in SelfService).
>>>
>>> I have tried to play with CustomRole but it's not working for me. So
>>> anybody known how I can do it?
>>> Thank you,
>>>
>>> --
>>> Félix Defrance
>>> PGP: 0x0F04DC57
>>>
>>>
>>
>>
>> --
>> Alex Hall
>> Automatic Distributors, IT department
>> ah...@autodist.com
>>
>>
>> --
>> Félix Defrance
>> PGP: 0x0F04DC57
>>
>>
>
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>
>
> --
> Félix Defrance
> PGP: 0x0F04DC57
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] How unprivileged users could see all tickets in their queue?

2017-01-04 Thread Alex Hall
Can you describe your setup more? I'm not sure why unprivileged users would
need access to all queue tickets, or why each user would have their own
queue? As I understand it, unprivileged users are end users (i.e.
customers, those who don't work for your organization). Thus, they
shouldn't be able to access an entire queue, only tickets they open. Make
them privileged, and restrict their rights by adding them to a certain
group, and your life may be a lot easier.

For example, you might have a group called "basic users" to which you'd add
the users you currently consider unprivileged. That group would have only a
few rights, but since its members would be privileged, you wouldn't run
into RT's built-in restrictions.

As to one queue per user, that would quickly get hard to manage. Queues are
for organizing tickets and users. Sure, a queue may have just one user, but
each user shouldn't have their own queue. Trying to keep track of the
rights of such a setup would be a nightmare, assuming you have a good
amount of users. As an example, we have queues for technology, warehouse,
customer service, and other divisions within the company. Some queues have
a lot of people, some have a few, butthey are all logical groupings of
tasks. If I made a new queue for every user, I'd have dozens of them, and
tickets would be all over the place! Plus, there's email to consider; if
you want to accept incoming emails for ticket replies, you have to make a
new Fetchmail or Postfix entry for every single user/queue you have.

I hope this makes some sense. As I said, a lot of this depends on your
usage pattern and setup concept. If you can explain that to us more, we
might be able to help better.

On Wed, Jan 4, 2017 at 3:57 AM, Felix Defrance <fe...@d2france.fr> wrote:

> Hello,
>
> You right, this rights isn't checked.
>
> But I can't view all tickets in selfservice anymore.
>
> I verify the same rights in :
>
>  Admin > Queue, "select the queue name" and  Group Rights, select and
> grant "unprivileged users" to Seequeue & Showtickets
>
> In the same section:
>
>  grant group "compagny name" to Seequeue & Showtickets
>
>
> But no effect.
>
> I try to add a user to watchers 'CC', and grant watchers 'CC' to Seequeue
> & Showtickets but no effect too :(
>
> Another ideas ?
>
> Thanks,
>
> Félix.
> Le 03/01/2017 à 18:39, Alex Hall a écrit :
>
> Have you granted the rights? In Admin > Global > Group Rights, select the
> "unprivileged users" tab, then grant "view queue". That should help, though
> our setup is quite different so I can't verify it.
>
> On Tue, Jan 3, 2017 at 12:27 PM, Felix Defrance <fe...@d2france.fr> wrote:
>
>> Hi all,
>>
>> I don't find how I could add ShowTickets or QueueList in SelfService.
>>
>> I want to allow my unprivileged users, grouped by company name, to see
>> all tickets in their queue.
>>
>> The group rights on the queue is correctly defined and users could access
>> to the tickets by entring the ticket number in the "goto Ticket" field (top
>> right in SelfService).
>>
>> I have tried to play with CustomRole but it's not working for me. So
>> anybody known how I can do it?
>> Thank you,
>>
>> --
>> Félix Defrance
>> PGP: 0x0F04DC57
>>
>>
>
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>
>
> --
> Félix Defrance
> PGP: 0x0F04DC57
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] How unprivileged users could see all tickets in their queue?

2017-01-03 Thread Alex Hall
Have you granted the rights? In Admin > Global > Group Rights, select the
"unprivileged users" tab, then grant "view queue". That should help, though
our setup is quite different so I can't verify it.

On Tue, Jan 3, 2017 at 12:27 PM, Felix Defrance <fe...@d2france.fr> wrote:

> Hi all,
>
> I don't find how I could add ShowTickets or QueueList in SelfService.
>
> I want to allow my unprivileged users, grouped by company name, to see all
> tickets in their queue.
>
> The group rights on the queue is correctly defined and users could access
> to the tickets by entring the ticket number in the "goto Ticket" field (top
> right in SelfService).
>
> I have tried to play with CustomRole but it's not working for me. So
> anybody known how I can do it?
> Thank you,
>
> --
> Félix Defrance
> PGP: 0x0F04DC57
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] Ticket SQL for dates?

2016-12-31 Thread Alex Hall
Hello list,
In a thread a week or two ago, I was asking about the syntax for finding
tickets by relative dates, like "3 days ago". It wasn't working, and at
least one other list member was able to confirm that it wasn't. I really
need this, or something like it, but no workaround I try does anything.

First, I took the straight MySQL route, doing advanced searches with
queries like

Owner = 'ahall'
and Status = '__active__'
and LastUpdated <= DATE_SUB(CURDATE(), INTERVAL 3 day)

But I got an error saying that a value was expected for CURDATE(). I tried
DATEDIFF, and a simple "LastUpdated <= (now() - INTERVAL 3 DAYS)", all with
similar errors.

Hoping it was just something odd in the search interface, I tried this in
the cron tool, but I'm getting no tickets at all. Using the RT-recommended
syntax of "3 days ago" is convenient, but doesn't work at all. It's like it
gets ignored completely--tickets are found with the right status, owner,
etc, but never any date considerations whatsoever.

Is there anything else I can try in order to get tickets last updated N
days ago? I've tried UntouchedInHours, but it relies on this same "N hours
ago" syntax and so also fails. I find it hard to believe that 4.4.1 would
have been out for so long with such a critical bug, but last time I asked
about this, someone else on the list did say they could confirm the
problem. Thanks for any answers!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] rt-crontool returns "No recipients found. Not sending."

2016-12-30 Thread Alex Hall
I just wondered if anyone had any ideas on this. I haven't gotten further
than what's in the below message, and I don't know why that isn't working.
I see similar addresses to the below in the mail logs all the time, so this
has to be some kind of address that RT understands. It just won't send
mail. Needless to say, my boss really wants stale ticket alerts to work,
and as far as I know, it's this one last problem that is stopping me from
doing that.

On Thu, Dec 22, 2016 at 4:17 PM, Alex Hall <ah...@autodist.com> wrote:

> Hi all,
> Further to my rt-crontool question about notifying ticket owners of
> untouched tickets, I've made a bit of progress in that I'm getting a new
> error. I tried adding
> --transaction first
> to the crontool call, and that seemed to do something. Now, I'm getting an
> error similar to:
>
> [17710] [Thu Dec 22 21:04:01 2016] [info]:  776.656-...@example.com> No recipients found. Not sending.
> (/opt/rt4/bin/../lib/RT/Interface/Email.pm:806)
>
> My actions are:
>
> --action RT::Action::Notify
> --action-arg RT::Action::NotifyOwnerOrAdminCc
> (also tried)
> --action-arg owner
>
> I don't know where this address is coming from, or what it means, but
> clearly some address is being found. Why would it say there are no
> recipients found, then? The ticket requestor is the same as the owner,
> because we have our RT set up to make that happen on ticket creation, if
> that will be a problem. What might I be missing? I'm so close to having
> this working! RT4.4.1, Debian 8. Thanks!
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] Wiki conventions?

2016-12-30 Thread Alex Hall
Hi all,
I've finally created an account on the RT wiki. This has been a really
great resource for me, but there are a lot of pages I've read in the last
few months with formatting mistakes, grammar problems, outdated information
that's not marked as not working under 4.x, and so on. I don't know how
much time I'll have to edit things, but I hope to try to contribute where I
can by fixing mistakes when I find them. I might add my own pages
eventually, but for now I'll stick to edits.

What are the conventions by which Best Practical likes people to operate?
For instance, if a page is understandable but could do with better grammar,
is it considered polite to correct it, or should it be left alone? What
other rules and conventions exist that I should keep in mind? Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] Putting CF values in email templates?

2016-12-30 Thread Alex Hall
Hi all,
I'm trying to get CF values to conditionally appear in tickets, but when I
do, the template breaks and no emails get sent to anyone. I've seen a few
ways of doing this in the Wiki, each a bit different and many for different
RT versions. Here's my attempt. What did I do wrong?

{
if(my $orderNumber = $Ticket->CustomFieldValues["Order Number"]) {
"Testing printing the order number: " . $orderNumber . ""
}
}

Thank you for any information.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] Using DBI for DB2 connection in scripts?

2016-12-27 Thread Alex Hall
Hello list,
I've just gotten a DSN to our iSeries working on the same server that hosts
RT. Next, I'll be making a script to auto-set a custom field with a value
pulled from that iSeries based on another field. This way, for instance,
you can make a ticket with the order number in a CF, and the customer rep
gets added to the ticket. The rep comes from the iSeries.

What I'm wondering is whether the DBI module in RT can already do this? Can
I give it a DSN and some SQL, then get the results? Or do I need to install
a separate database Perl module and use that? I know next to nothing about
Perl, let alone how to use it to talk to databases, so this may be a stupid
question. Still, I thought it worth asking; if the DB module that RT
already uses can do this, there's no need to install another one. Side
note: if anyone has ever dealt with DB2 from Perl in RT before, any other
suggestions or warnings you can offer will be appreciated. Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] rt-crontool returns "No recipients found. Not sending."

2016-12-22 Thread Alex Hall
Hi all,
Further to my rt-crontool question about notifying ticket owners of
untouched tickets, I've made a bit of progress in that I'm getting a new
error. I tried adding
--transaction first
to the crontool call, and that seemed to do something. Now, I'm getting an
error similar to:

[17710] [Thu Dec 22 21:04:01 2016] [info]: <
rt-4.4.1-17710-1482440641-776.656-...@example.com> No recipients found. Not
sending. (/opt/rt4/bin/../lib/RT/Interface/Email.pm:806)

My actions are:

--action RT::Action::Notify
--action-arg RT::Action::NotifyOwnerOrAdminCc
(also tried)
--action-arg owner

I don't know where this address is coming from, or what it means, but
clearly some address is being found. Why would it say there are no
recipients found, then? The ticket requestor is the same as the owner,
because we have our RT set up to make that happen on ticket creation, if
that will be a problem. What might I be missing? I'm so close to having
this working! RT4.4.1, Debian 8. Thanks!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] Emailing with NotifyOwnerOrAdminCc action?

2016-12-20 Thread Alex Hall
In my previous message, the "new" error was because I didn't include
--template. Now that I have, I'm back to the original error, in my first
message. I've also tried using

--action RT::Action::Notify \
--action-arg RT::Action::NotifyOwnerOrAdminCc

but I still get the same error (can't call method "message" on an undefined
value). I've looked this up online, but only found a few threads, one of
which said to use RT::Action::Notify. I don't know what else to try, or why
this refuses to work.

On Tue, Dec 20, 2016 at 7:48 AM, Alex Hall <ah...@autodist.com> wrote:

> I'm still working on this, and it still hates me. :) I thought of
> something this morning and it gave me a different result; I wanted to see
> if I was on the right track, at least. Any thoughts?
>
> After my search and search-arg items, I'm now trying this:
>
> --action RT::Action::SendEmail \
> --action-arg RT::Action::NotifyOwnerOrAdminCc
>
> I also tried
>
> --action-arg 'owner'
>
> In both cases, I got the error:
>
> Can't call method "MIMEObj" on an undefined value at
> /opt/rt4/bin/../lib/RT/Action/SendEmail.pm line 139
>
> This is at least a slightly different error. As I said yesterday, I can't
> give a hard-coded email address, as this job will have to email whoever is
> the owner of the ticket being worked on. I have to be missing something
> obvious about this process!
>
> On Mon, Dec 19, 2016 at 4:51 PM, Alex Hall <ah...@autodist.com> wrote:
>
>> Hi all,
>> Now that I'm getting the tickets I want, I'm trying to email the owners
>> of those tickets. After my search and search-arg parameters for
>> rt-crontool, I'm doing this:
>>
>> --action RT::Action::NotifyOwnerOrAdminCc \
>> --template "untouched ticket"
>>
>> I'm missing --action-arg, but I don't know what to put for that since
>> NotifyOwnerOrAdminCc will, I presume, take care of it. However, I'm getting
>> an error:
>>
>> can't call method "Message" on an undefined value at
>> /opt/rt4/bin/../lib/RT/Action/SendEmail.pm on line 1118
>>
>> I'm assuming this is what I mentioned--my missing action-arg--but I don't
>> know what to put in there. Right now, the search is limited to just my own
>> tickets, but eventually it'll run with no owner restriction so it can
>> notify all users. Thus, the email address to use is whatever the owner's
>> address is, and I can't hard-code it. What's the trick to getting this to
>> work correctly? Thanks!
>>
>> --
>> Alex Hall
>> Automatic Distributors, IT department
>> ah...@autodist.com
>>
>
>
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] Emailing with NotifyOwnerOrAdminCc action?

2016-12-20 Thread Alex Hall
I'm still working on this, and it still hates me. :) I thought of something
this morning and it gave me a different result; I wanted to see if I was on
the right track, at least. Any thoughts?

After my search and search-arg items, I'm now trying this:

--action RT::Action::SendEmail \
--action-arg RT::Action::NotifyOwnerOrAdminCc

I also tried

--action-arg 'owner'

In both cases, I got the error:

Can't call method "MIMEObj" on an undefined value at
/opt/rt4/bin/../lib/RT/Action/SendEmail.pm line 139

This is at least a slightly different error. As I said yesterday, I can't
give a hard-coded email address, as this job will have to email whoever is
the owner of the ticket being worked on. I have to be missing something
obvious about this process!

On Mon, Dec 19, 2016 at 4:51 PM, Alex Hall <ah...@autodist.com> wrote:

> Hi all,
> Now that I'm getting the tickets I want, I'm trying to email the owners of
> those tickets. After my search and search-arg parameters for rt-crontool,
> I'm doing this:
>
> --action RT::Action::NotifyOwnerOrAdminCc \
> --template "untouched ticket"
>
> I'm missing --action-arg, but I don't know what to put for that since
> NotifyOwnerOrAdminCc will, I presume, take care of it. However, I'm getting
> an error:
>
> can't call method "Message" on an undefined value at
> /opt/rt4/bin/../lib/RT/Action/SendEmail.pm on line 1118
>
> I'm assuming this is what I mentioned--my missing action-arg--but I don't
> know what to put in there. Right now, the search is limited to just my own
> tickets, but eventually it'll run with no owner restriction so it can
> notify all users. Thus, the email address to use is whatever the owner's
> address is, and I can't hard-code it. What's the trick to getting this to
> work correctly? Thanks!
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] Emailing with NotifyOwnerOrAdminCc action?

2016-12-19 Thread Alex Hall
Hi all,
Now that I'm getting the tickets I want, I'm trying to email the owners of
those tickets. After my search and search-arg parameters for rt-crontool,
I'm doing this:

--action RT::Action::NotifyOwnerOrAdminCc \
--template "untouched ticket"

I'm missing --action-arg, but I don't know what to put for that since
NotifyOwnerOrAdminCc will, I presume, take care of it. However, I'm getting
an error:

can't call method "Message" on an undefined value at
/opt/rt4/bin/../lib/RT/Action/SendEmail.pm on line 1118

I'm assuming this is what I mentioned--my missing action-arg--but I don't
know what to put in there. Right now, the search is limited to just my own
tickets, but eventually it'll run with no owner restriction so it can
notify all users. Thus, the email address to use is whatever the owner's
address is, and I can't hard-code it. What's the trick to getting this to
work correctly? Thanks!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] LastUpdated for tickets not working?

2016-12-19 Thread Alex Hall
Well, I found something that works. It's not UntouchedInHours, but this
query seems to return what I want:

select id
from Tickets
where LastUpdated <= (now() - INTERVAL 10 DAYS);

I still have to work out how to email ticket owners, but at least I can get
the right tickets now. Odd that the other way doesn't work. How exactly
does this "10 days ago" syntax get interpreted? Or is it no longer
supported?

On Mon, Dec 19, 2016 at 2:48 PM, Alex Hall <ah...@autodist.com> wrote:

> I'm using the Crontool, yes, but I've also been doing searches on the web
> interface to see if I could get this to work. My Crontool syntax is
> something like:
>
> /opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
> --search-arg "status != 'resolved' and LastUpdated <= '3 days ago'" \
> --action RT::Action \
> --verbose
>
> Or:
>
> /opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
> --search-arg "status != 'resolved'" \
> --condition RT::Condition::UntouchedInHours \
> --arg-condition 72 \
> --verbose
>
> This shouldn't be modifying tickets, yet I'm seeing tickets created hours
> or minutes ago appearing in the results. Same for my RT web searches for
> similar SQL to what's above.
>
> I'm in the database now, looking at the Tickets table and messing with
> queries. I just tried this, but got an empty set:
>
> select id, LastUpdated
> from Tickets
> where LastUpdated <= '3 days ago'
> order by LastUpdated DESC
> limit 10;
>
> I'm not surprised I got nothing, as I imagine the '3 days ago' syntax is
> something RT interprets before giving the query to the database engine.
> Still, it was worth a shot. I'm now refreshing my knowledge of date math in
> MySQL so I can query exactly what I want, but I hoped UntouchedInHours
> would do all that for me. Oh, and yes, LastUpdated does seem to have normal
> values in it. They're in GMT time, but they seem to be correct.
>
> On Mon, Dec 19, 2016 at 2:37 PM, Matt Zagrabelny <mzagr...@d.umn.edu>
> wrote:
>
>> Hi Alex,
>>
>> On Mon, Dec 19, 2016 at 12:54 PM, Alex Hall <ah...@autodist.com> wrote:
>> > Hello all,
>> > I'm trying to get stale ticket alerts working, so am using the
>> > UntouchedInHours condition. I've also tried, in SQL:
>> > LastUpdated <= '2 days ago'
>> > and similar searches. Yet, I always get the same number of tickets as I
>> get
>> > when I leave the date restriction off completely, and UntouchedInHours
>> is
>> > always giving me tickets opened today.
>>
>> I assume you are using rtcrontool. Correct?
>>
>> How are you alerting?
>>
>> Is the alerting actually "touching" the tickets thus affecting the query?
>>
>> You can query the tickets table directly and see the lastupdated
>> field. See if that field changes how you would expect when you "touch"
>> or "update" a ticket.
>>
>> -m
>>
>
>
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] LastUpdated for tickets not working?

2016-12-19 Thread Alex Hall
I'm using the Crontool, yes, but I've also been doing searches on the web
interface to see if I could get this to work. My Crontool syntax is
something like:

/opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
--search-arg "status != 'resolved' and LastUpdated <= '3 days ago'" \
--action RT::Action \
--verbose

Or:

/opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
--search-arg "status != 'resolved'" \
--condition RT::Condition::UntouchedInHours \
--arg-condition 72 \
--verbose

This shouldn't be modifying tickets, yet I'm seeing tickets created hours
or minutes ago appearing in the results. Same for my RT web searches for
similar SQL to what's above.

I'm in the database now, looking at the Tickets table and messing with
queries. I just tried this, but got an empty set:

select id, LastUpdated
from Tickets
where LastUpdated <= '3 days ago'
order by LastUpdated DESC
limit 10;

I'm not surprised I got nothing, as I imagine the '3 days ago' syntax is
something RT interprets before giving the query to the database engine.
Still, it was worth a shot. I'm now refreshing my knowledge of date math in
MySQL so I can query exactly what I want, but I hoped UntouchedInHours
would do all that for me. Oh, and yes, LastUpdated does seem to have normal
values in it. They're in GMT time, but they seem to be correct.

On Mon, Dec 19, 2016 at 2:37 PM, Matt Zagrabelny <mzagr...@d.umn.edu> wrote:

> Hi Alex,
>
> On Mon, Dec 19, 2016 at 12:54 PM, Alex Hall <ah...@autodist.com> wrote:
> > Hello all,
> > I'm trying to get stale ticket alerts working, so am using the
> > UntouchedInHours condition. I've also tried, in SQL:
> > LastUpdated <= '2 days ago'
> > and similar searches. Yet, I always get the same number of tickets as I
> get
> > when I leave the date restriction off completely, and UntouchedInHours is
> > always giving me tickets opened today.
>
> I assume you are using rtcrontool. Correct?
>
> How are you alerting?
>
> Is the alerting actually "touching" the tickets thus affecting the query?
>
> You can query the tickets table directly and see the lastupdated
> field. See if that field changes how you would expect when you "touch"
> or "update" a ticket.
>
> -m
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] LastUpdated for tickets not working?

2016-12-19 Thread Alex Hall
Hello all,
I'm trying to get stale ticket alerts working, so am using the
UntouchedInHours condition. I've also tried, in SQL:
LastUpdated <= '2 days ago'
and similar searches. Yet, I always get the same number of tickets as I get
when I leave the date restriction off completely, and UntouchedInHours is
always giving me tickets opened today.

Because the condition and my own query both rely on LastUpdated, I'm
starting to suspect that this field may not be working correctly. Is this a
know problem in 4.4.1, or--more probably--am I doing something wrong? I'm
not getting any errors anywhere, now that UntouchedInHours has been fixed
to use RT::Condition and not RT::Condition::Generic, but neither am I
getting the tickets I should be. Thanks for any ideas!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] constantly seeing error after RT::Extension::Announce

2016-12-19 Thread Alex Hall
I'm almost positive I ran that, and the page says I could end up with data
duplication if I run it again. Is there a query I could run in the database
to check, so I can know for sure? Thanks.

On Fri, Dec 16, 2016 at 8:53 PM, Todd Wade <waveri...@gmail.com> wrote:

> On 12/16/16 3:57 PM, Alex Hall wrote:
>
>> Ever since I installed the RT::Extension::Announce plugin, I've seen an
>> error repeated over and over in the log (hundreds of times). It's always
>> the same:
>>
>> couldn't load custom field by 'announcement groups' identifier
>>
>
> Hi Alex,
>
> This sounds like you missed the 'make initdb' step that creates the custom
> field:
>
> https://metacpan.org/pod/RT::Extension::Announce#INSTALLATION
>
> https://st.aticpan.org/source/BPS/RT-Extension-Announce-1.01
> /etc/initialdata
>
> Regards,
>
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] Where to put Crontool conditions?

2016-12-19 Thread Alex Hall
Thanks, I now have a Condition folder alongside the Interface folder.
Sorry; in my previous message, I mistyped the directory quite badly. That's
what I get for going from memory.

On Mon, Dec 19, 2016 at 11:26 AM, Emmanuel Lacour <elac...@easter-eggs.com>
wrote:

> Le 19/12/2016 à 17:07, Alex Hall a écrit :
> > Hi list,
> > Where do I put custom conditions for rt-crontool? I'm trying to get
> > UntouchedInHours to work. Its page says to place it in
> > local/RT/bin/... But I have no bin inside local/RT. I'm assuming that,
> > like so many Wiki pages, this is simply not updated for the newer RT
> > versions? What's the right path to use under 4.4.1? Thanks. Oh, the
> > page I'm using:
> > https://rt-wiki.bestpractical.com/wiki/UntouchedInHours
>
>
> like any custom RT scrip condition: local/lib/RT/Condition/ (you need to
> create this directory if not yet done).
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] Where to put Crontool conditions?

2016-12-19 Thread Alex Hall
Hi list,
Where do I put custom conditions for rt-crontool? I'm trying to get
UntouchedInHours to work. Its page says to place it in local/RT/bin/... But
I have no bin inside local/RT. I'm assuming that, like so many Wiki pages,
this is simply not updated for the newer RT versions? What's the right path
to use under 4.4.1? Thanks. Oh, the page I'm using:
https://rt-wiki.bestpractical.com/wiki/UntouchedInHours

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] constantly seeing error after RT::Extension::Announce

2016-12-16 Thread Alex Hall
Hi all,
Ever since I installed the RT::Extension::Announce plugin, I've seen an
error repeated over and over in the log (hundreds of times). It's always
the same:

couldn't load custom field by 'announcement groups' identifier

I have no idea what it means or what the cause is. I've done some
modifications to the display and CSS of the plugin, but nothing about
"announcement groups". What could cause this error, should I worry, and can
I fix or hide it? I'm worried it will hide other errors or warnings, given
how often it repeats itself. Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Transaction appears to have no content

2016-12-15 Thread Alex Hall
My immediate thought is a rights problem. If you go to Admin > Global >
Group Rights, click the Requestors group, and find the rights for the
transactions you're sending, are they enabled? Same for the group(s) to
which the requestor belongs. That is, can the requestor, at some level,
view comments, view ticket, etc? I don't know how rights interact with
email notifications, but it's worth checking. Of course, if you've modified
that script, you may want to revert to the original one just to see if
yours has a bug.

On Thu, Dec 15, 2016 at 3:44 PM, Claude EDUMA <clauded...@gmail.com> wrote:

> Hello,
>
> I'm using correspondence template and  "On Correspond Notify Requestors and
> Ccs" scrip for notify requestors when incident is resolved. but requestor
> receive only :
>
> Transaction appears to have no content.
>
> when i send comment all is fine. This issue occurre only when i send
> message to requestor.
>
> some ideas ?
>
> -
> RT 4.4 and RTIR training sessions, and a new workshop day!
> https://bestpractical.com/training
> * Los Angeles - January 9-11 2017
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] All users can comment despite that right being revoked

2016-12-15 Thread Alex Hall
I've just discovered that "modify tickets" includes--for some strange
reason--the comment right. Thus, if we want users to be able to modify
other aspects of tickets, they automatically get granted the right to
comment as well. This seems like an odd decision, but at least I think I've
found the problem.

Back to removing the option from the Actions menu, then. I've been
searching, but I don't know where this action gets added. I've found a few
places where some actions are added to @Actions, but never "comment".

You mentioned a rights debugger in 4.6. Is 4.6 out for testing? Rights
debugging sounds very useful!

On Thu, Dec 15, 2016 at 11:56 AM, Matt Zagrabelny <mzagr...@d.umn.edu>
wrote:

> Hi Alex,
>
> On Thu, Dec 15, 2016 at 8:28 AM, Alex Hall <ah...@autodist.com> wrote:
> > Hi all,
> > We've just discovered something odd. It seems that all users can comment
> on
> > tickets, even though we've removed the "comment on tickets" right
> everywhere
> > we've found it--all groups, privileged users, everyone, etc. I could
> simply
> > remove the comment action from the actions list, but I'd rather find out
> why
> > the right revoking isn't doing what I thought.
> >
> > Is there a way to search the RT database to see where this right is
> enabled,
> > to check that none of us (admins) missed it somewhere? Is there a second
> > right that might cause this action to appear, that isn't called "comment
> on
> > tickets"? Maybe we've just overlooked something seemingly not important
> but
> > that actually causes commenting to be granted?
> >
> > To clarify my "search the database" question: I know SQL and how to query
> > the RT database. I just don't know which tables or columns to include, or
> > what value to look for. Thanks.
>
> Have you checked your global rights?
>
> Admin -> Global -> Groups
>
> PS. There might be a rights debugger in 4.6.
>
> -m
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] All users can comment despite that right being revoked

2016-12-15 Thread Alex Hall
Hi all,
We've just discovered something odd. It seems that all users can comment on
tickets, even though we've removed the "comment on tickets" right
everywhere we've found it--all groups, privileged users, everyone, etc. I
could simply remove the comment action from the actions list, but I'd
rather find out why the right revoking isn't doing what I thought.

Is there a way to search the RT database to see where this right is
enabled, to check that none of us (admins) missed it somewhere? Is there a
second right that might cause this action to appear, that isn't called
"comment on tickets"? Maybe we've just overlooked something seemingly not
important but that actually causes commenting to be granted?

To clarify my "search the database" question: I know SQL and how to query
the RT database. I just don't know which tables or columns to include, or
what value to look for. Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] supplying database credentials to rt-fulltext-indexer

2016-12-12 Thread Alex Hall
Neither. For the moment, root runs everything (yes, I know that's enough to
get me slapped). 4.4.1 is the only version ever installed from source, thus
/opt/rt4/sbin/rt-fulltext-indexer has to be new. The only other version on
the server is indeed from 4.2, but is from a Debian package and thus lives
in some other sbin folder on the system and not this one.

On Mon, Dec 12, 2016 at 1:12 PM, Jeff Voskamp <javosk...@uwaterloo.ca>
wrote:

> On 12/12/16 10:42 AM, Alex Hall wrote:
>
>> Hi all,
>> I think I can say definitely that this is a bug. I added the DB
>> credentials to RT_SiteConfig.pm and, suddenly, the indexer started working
>> perfectly. Yet RT itself pulls the exact same credentials from
>> RT_SiteConfig.d/03-DBInfo.pm with no trouble. I have all my settings in
>> multiple files under RT_SiteConfig.d, and they all work. It's just
>> rt-fulltext-indexer that seems to have trouble accessing them. This
>> explains a lot, and hopefully gets fixed in the next release. Thanks for
>> everyone's suggestions and help.
>>
> Permissions on RT_SiteConfig.d/03-DBInfo.pm are such that the user running
> rt-fulltext-indexer can read them? Alternately you're not running
> rt-fulltext-indexer from an earlier release (4.2.x) that didn't support
> RT_SiteConfig.d?
>
> Jeff
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] supplying database credentials to rt-fulltext-indexer

2016-12-12 Thread Alex Hall
Hi all,
I think I can say definitely that this is a bug. I added the DB credentials
to RT_SiteConfig.pm and, suddenly, the indexer started working perfectly.
Yet RT itself pulls the exact same credentials from
RT_SiteConfig.d/03-DBInfo.pm with no trouble. I have all my settings in
multiple files under RT_SiteConfig.d, and they all work. It's just
rt-fulltext-indexer that seems to have trouble accessing them. This
explains a lot, and hopefully gets fixed in the next release. Thanks for
everyone's suggestions and help.

On Sat, Dec 10, 2016 at 5:56 AM, Alex Hall <ah...@autodist.com> wrote:

> I thought it would, but it doesn't seem to be. My db credentials must be
> correct, because RT isn't complaining of any db problems, and is working
> fine. Is it possible that there's a bug in 4.4.1 that causes this indexer
> to get confused by the use of the RT_SiteConfig.d/* files? I use those
> instead of a single .pm file. I'll have to try putting my database
> credentials in the actual PM file later today, once I'm awake, to see if
> that helps.
>
> Sent from my iPhone
>
> > On Dec 10, 2016, at 03:47, Alex Vandiver <a...@chmrr.net> wrote:
> >
> > On Fri, 9 Dec 2016 17:30:31 -0500
> > Alex Hall <ah...@autodist.com> wrote:
> >> What this file never says is how to tell the indexer tool how to
> connect to
> >> the database. It clearly isn't pulling from the RT configuration, nor
> from
> >> /home/www-data/rtrc.
> >
> > The indexer reads and uses the database configuration from
> > your /opt/rt4/etc/RT_Config.pm and /opt/rt4/tec/RT_SiteConfig.pm
> > files.  rtrc files are _only_ used by the "bin/rt" tool, which is meant
> > to be run from other machines than your RT host.
> >
> > The rt-setup-fulltext-indexer wants to know your DBA username and
> > password because it needs to create new tables and indexes, which the
> > standard RT database user does not have permissions to do.  Once the
> > index is set up, updates to the index are done as RT's standard
> > database user.
> >
> > - Alex
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] supplying database credentials to rt-fulltext-indexer

2016-12-10 Thread Alex Hall
I thought it would, but it doesn't seem to be. My db credentials must be 
correct, because RT isn't complaining of any db problems, and is working fine. 
Is it possible that there's a bug in 4.4.1 that causes this indexer to get 
confused by the use of the RT_SiteConfig.d/* files? I use those instead of a 
single .pm file. I'll have to try putting my database credentials in the actual 
PM file later today, once I'm awake, to see if that helps.

Sent from my iPhone

> On Dec 10, 2016, at 03:47, Alex Vandiver <a...@chmrr.net> wrote:
> 
> On Fri, 9 Dec 2016 17:30:31 -0500
> Alex Hall <ah...@autodist.com> wrote:
>> What this file never says is how to tell the indexer tool how to connect to
>> the database. It clearly isn't pulling from the RT configuration, nor from
>> /home/www-data/rtrc.
> 
> The indexer reads and uses the database configuration from
> your /opt/rt4/etc/RT_Config.pm and /opt/rt4/tec/RT_SiteConfig.pm
> files.  rtrc files are _only_ used by the "bin/rt" tool, which is meant
> to be run from other machines than your RT host.
> 
> The rt-setup-fulltext-indexer wants to know your DBA username and
> password because it needs to create new tables and indexes, which the
> standard RT database user does not have permissions to do.  Once the
> index is set up, updates to the index are done as RT's standard
> database user.
> 
> - Alex
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017


Re: [rt-users] supplying database credentials to rt-fulltext-indexer

2016-12-09 Thread Alex Hall
FTS is enabled and working, but it seems to be working only on tickets that
were set up when the setup tool was run. According to the docs
(rt4/docs/full_text_indexing.pod):

To keep the index up-to-date, you will need to run:

/opt/rt4/sbin/rt-fulltext-indexer

...at regular intervals.  By default, this will only tokenize up to 200
tickets at a time; you can adjust this upwards by passing C<--limit
500>.  Larger batch sizes will take longer and consume more memory.


What this file never says is how to tell the indexer tool how to connect to
the database. It clearly isn't pulling from the RT configuration, nor from
/home/www-data/rtrc.

On Fri, Dec 9, 2016 at 5:12 PM, Landon Stewart <lstew...@internap.com>
wrote:

> On Dec 9, 2016, at 2:06 PM, Alex Hall <ah...@autodist.com> wrote:
>
>
> I thought the tool I had to run periodically was 
> /opt/rt4/sbin/rt-fulltext-indexer.
> That's the one guides tell me to run; the setup tool seems to be the
> initial database adjustment tool, but once it runs once, I thought I had to
> run the indexer every so often. The indexer is the tool that refuses
> database credentials. Unless the guides on this are wrong, and the setup
> one is the one I have to run with cron?
>
>
> I haven't enabled Full Text searching in RT before but I have set it up in
> MySQL for other uses.  From my experiences with MySQL I believe you setup
> the indexes once only with the setup tool for RT and once they are setup
> there's no need to 're-index' anything regularly with any crontab or
> anything.
>
> Above all though - do this on a copy of your RT installation/database and
> make sure it works before you potentially interrupt the flow of business in
> production.
>
> --
> Landon Stewart
> Lead Analyst - Abuse and Security Management
> INTERNAP ®
>  lstew...@internap.com
>  www.internap.com
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] supplying database credentials to rt-fulltext-indexer

2016-12-09 Thread Alex Hall
I thought the tool I had to run periodically was
/opt/rt4/sbin/rt-fulltext-indexer. That's the one guides tell me to run;
the setup tool seems to be the initial database adjustment tool, but once
it runs once, I thought I had to run the indexer every so often. The
indexer is the tool that refuses database credentials. Unless the guides on
this are wrong, and the setup one is the one I have to run with cron?

On Fri, Dec 9, 2016 at 4:40 PM, Landon Stewart <lstew...@internap.com>
wrote:

> On Dec 9, 2016, at 1:33 PM, Alex Hall <ah...@autodist.com> wrote:
>
>
> I still don't have this working, so any input would be great. I just
> wanted to add that, since my last email on the topic, I've tried putting an
> rtrc file in /root, since I'm running this as root for the moment. It
> didn't help. I've also looked through the actual file, trying to find where
> it gets its credentials from, but all I saw was some kind of database
> handler function which I'll have to try to track down. I'm really hoping
> someone knows an easier way. After all, I can't be the first to use my own
> database name, username, and password who needs this tool to run.
>
>
> /opt/rt4/sbin/rt-setup-fulltext-index --dba root --dba-password secret
>
> Source: https://docs.bestpractical.com/rt/4.2.12/full_text_indexing.html
>
> --
> Landon Stewart
> Lead Analyst - Abuse and Security Management
> INTERNAP ®
>  lstew...@internap.com
>  www.internap.com
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] supplying database credentials to rt-fulltext-indexer

2016-12-09 Thread Alex Hall
I still don't have this working, so any input would be great. I just wanted
to add that, since my last email on the topic, I've tried putting an rtrc
file in /root, since I'm running this as root for the moment. It didn't
help. I've also looked through the actual file, trying to find where it
gets its credentials from, but all I saw was some kind of database handler
function which I'll have to try to track down. I'm really hoping someone
knows an easier way. After all, I can't be the first to use my own database
name, username, and password who needs this tool to run.

On Thu, Dec 8, 2016 at 10:38 AM, Alex Hall <ah...@autodist.com> wrote:

> Hi all,
> I completely forgot to set up rt-fulltext-indexer as a cron job after
> initially enabling FTS. When I run it now, it complains that the database
> credentials are wrong, and yes, they definitely are. How do I give it the
> right ones? I hoped it would pick them up from rtrc, which I made for
> rt-email-dashboards, but it doesn't seem to be doing so. I know I've done
> this once before, I just don't remember (and can't find) how I did it.
> Thanks.
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] missing callbacks in 4.4.1 CSS?

2016-12-09 Thread Alex Hall
Thanks. By "lib", I assume you just mean to make a folder somewhere, then
use "@import myNewLib/myFile.css"? Should I make a replacement for the css
file in local/html/NoAut/something that I'm replacing? I actually don't see
a static folder around this CSS folder, so I'm not quite sure what should
go where.h

On Fri, Dec 9, 2016 at 10:35 AM, Matt Zagrabelny <mzagr...@d.umn.edu> wrote:

> Hi Alex,
>
> No need for a callback. Just include your CSS files in a lib. There is a
> function call you can make to include a CSS file in /static/css/. This is
> the proper way in, at least, 4.2.
>
> -m
>
> On Dec 9, 2016 9:55 AM, "Alex Hall" <ah...@autodist.com> wrote:
>
>> Hey all,
>> I'm trying to add a background image to a div, so went looking for the
>> callback the wiki describes. The wiki uses 3.8, and I'm on 4.4.1, but I
>> didn't think that mattered. Yet, I can't find any callbacks by looking in
>> main.css or base.css, and the wiki's big list of 4.2 callbacks has no css
>> at all. I tried
>> cd /opt/rt4/share
>> find /static/css | xargs grep 'callback'
>>
>> as well as
>>
>> find /static/css -name '*.css' | xargs grep 'callback'
>>
>> but got no results either way. What's the trick to callbacks in 4.4 for
>> CSS? Or do I make a copy of one of the CSS files in /opt/rt4/local and
>> modify it? Thanks.
>>
>> --
>> Alex Hall
>> Automatic Distributors, IT department
>> ah...@autodist.com
>>
>> -
>> RT 4.4 and RTIR training sessions, and a new workshop day!
>> https://bestpractical.com/training
>> * Los Angeles - January 9-11 2017
>>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] missing callbacks in 4.4.1 CSS?

2016-12-09 Thread Alex Hall
Hey all,
I'm trying to add a background image to a div, so went looking for the
callback the wiki describes. The wiki uses 3.8, and I'm on 4.4.1, but I
didn't think that mattered. Yet, I can't find any callbacks by looking in
main.css or base.css, and the wiki's big list of 4.2 callbacks has no css
at all. I tried
cd /opt/rt4/share
find /static/css | xargs grep 'callback'

as well as

find /static/css -name '*.css' | xargs grep 'callback'

but got no results either way. What's the trick to callbacks in 4.4 for
CSS? Or do I make a copy of one of the CSS files in /opt/rt4/local and
modify it? Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] error during RT::Extension::Announce initdb

2016-12-08 Thread Alex Hall
Hi all,
I was installing RT::Extension::Announce just now. Running
perl Makefile.PL
told me to run
make initdb
for first-time installations, so I did. In the course of that, I got the
following error:
[23258] [Thu Dec  8 17:39:31 2016] [error]: Invalid Custom Field values
source (/opt/rt4/sbin/../lib/RT/Handle.pm:1145)
Done inserting data.
Done.

Is this anything I need to worry about for the extension to work properly,
or, in fact, do I need to worry about it for *any* reason? Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] supplying database credentials to rt-fulltext-indexer

2016-12-08 Thread Alex Hall
Hi all,
I completely forgot to set up rt-fulltext-indexer as a cron job after
initially enabling FTS. When I run it now, it complains that the database
credentials are wrong, and yes, they definitely are. How do I give it the
right ones? I hoped it would pick them up from rtrc, which I made for
rt-email-dashboards, but it doesn't seem to be doing so. I know I've done
this once before, I just don't remember (and can't find) how I did it.
Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] which scripts fire when

2016-12-07 Thread Alex Hall
Hi all,
In my last email, I asked about duplicate messages being sent out and was
told to check the RT workflow and enabled scripts. In doing so, I realized
I don't quite get how different scripts fire or are ignored.

For instance, we have a global script that notifies owner and CCs on ticket
correspond. Some queues have the same script, using the same template,
because we thought for a while we might need to set different templates on
different queues. But we don't, so the global and queue-specific scripts do
the same thing. My first thought is that this is causing some of our
duplication problems, but it can't be, because people sometimes get just
one email, and sometimes three or four.

Ideally, I'd like a way to generate a transaction and find out exactly what
scripts did what, and what email was sent to whom as a result of each one.
Is that kind of monitoring possible? I suspect a debug log would be far
more verbose than I need or not provide the kind of detail I'm after, but
if that's the only way, that's the only way. Still, if a different option
exists, I'd love to know about it.

I guess that's it for now. I'd like a way to watch the different scripts do
their thing for a single transaction, and I need to better understand how
the different scripts decide when to fire and when to stay quiet. Thanks as
always!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Preventing duplicate emails

2016-12-07 Thread Alex Hall
Hello list,
Is there an example of a script to prevent duplicate emails? We often have
users adding an owner as a CC, or adding someone as a CC and a one-time CC,
or for other reasons adding someone to a ticket multiple times. I've
accepted that user training won't solve this completely, so is there an
example of a script that will? Some way to prevent identical emails going
to one person more than once? Or, given that this would be one script and
thus couldn't access the details of other scripts when a transaction
happens, is this simply not possible? Thanks for any ideas.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] simple search not finding words in subjects?

2016-11-30 Thread Alex Hall
Hi all,
My boss said he couldn't find a ticket that he thought he should be able to
find. He was searching a customer name, let's say Custname. I thought at
first the problem was that the ticket was resolved, but I was wrong.

The problem appears to be that simple search is looking for "content like
"searchTerm"". When I changed it to "subject like "searchTerm"", the ticket
in question came right up.

I guess I need to set simple search to look for "content like "searchTerm"
OR subject like "searchTerm"". But I see no way to customize the simple
search query in the configuration options. Is this possible? If so, what's
the recommended way? In case it matters, we do have full text indexing on.
RT4.4.1 on Debian 8. Thanks!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Custom fields in saved searches

2016-11-30 Thread Alex Hall
Hi all,
We have one global custom field, 'type', and several other custom fields
that only apply to one queue. When we make a saved search for our sales
reps so they can see tickets that apply to the customers they manage, we
can't include any custom fields in the criteria or display except 'type'. I
know this is because the other fields aren't global, but how do we get RT
to include these fields? These reps all have access to the queue to which
the fields belong, so I'm not sure why they (the fields) won't show up
anywhere in the search builder interface. I can't even write them in,
although given how many different ways there seem to be to write in a CF, I
could just be doing it wrong. Thanks for any suggestions.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Owner not showing in search results?

2016-11-28 Thread Alex Hall
Thanks, I didn't know that would happen. I did that to suppress the email 
notification; we want users notified if their tickets change owners, but only 
if that change is NOT from "nobody" to themselves.

I just updated the script to record the transaction. It worked, because I got 
the email I wanted suppressed, and the owner still changed. Oddly, "nobody" is 
still the owner when I search for my ticket, though. Should I flush a cache or 
something? Mason cache wouldn't have anything to do with this, would it?
> On Nov 28, 2016, at 11:18, Kenneth Marshall <k...@rice.edu> wrote:
> 
> Hi Alex,
> 
> You do not record your transaction in your scrip. That means that the
> system does not know that a change has been made and to invalidate the
> caches. You will either need to record it or live with the result.
> 
> Regards,
> Ken
> 
> On Mon, Nov 28, 2016 at 11:12:00AM -0500, Alex Hall wrote:
>>>> my ($status, $msg) = $self->TicketObj->_Set(Field => 'Owner', Value =>
>>>> $Actor, RecordTransaction => 0);
> 
> This should be 1, not 0 to record the transaction and that should flush
> the cached info.
> 

-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017


Re: [rt-users] Owner not showing in search results?

2016-11-28 Thread Alex Hall
I just wondered if anyone had any more thoughts on this problem. We just
set up email dashboards, and they're doing the same thing search results
do; owners are often set to 'nobody', but if you go into the ticket, the
real owner is shown. Since dashboards and searches use the same display, or
seem to, I'm not surprised. But seeing that reminded me that this is still
a problem we'd like to get fixed if possible. As I mentioned before, I've
made no changes to the search results pages, and the problem appears to be
when the owner is set via our script to auto-assign the requestor as the
owner. The owner is set correctly if you view the ticket, but not if that
ticket appears in a search results page. Thanks.

On Fri, Nov 18, 2016 at 9:18 AM, Alex Hall <ah...@autodist.com> wrote:

> We always leave it at the default. I did a search for "queue:technology",
> and here's the format it uses:
>
>'__id__
> /TITLE:#',
>'__
> Subject__/TITLE:Subject',
>Status,
>QueueName,
>Owner,
>Priority,
>'__NEWLINE__',
>'__NBSP__',
>'__Requestors__',
>'__CreatedRelative__',
>'__ToldRelative__',
>'__LastUpdatedRelative__',
>'__TimeLeft__'
>
> On Fri, Nov 18, 2016 at 9:03 AM, Sinapius, Vinzenz <
> vinzenz.sinap...@tracetronic.de> wrote:
>
>> Hi Alex,
>>
>>
>>
>> What is the Format-String of your search? (It’s under the advanced tab,
>> when you edit the search)
>>
>>
>>
>> The scrip looks fine.
>>
>>
>>
>> Cheers,
>>
>> Vinzenz
>>
>> Vinzenz Sinapius
>> Information Technology | Informationstechnik
>>
>> *trace**tronic* GmbH
>> Stuttgarter Str. 3
>> 01189 DRESDEN
>> GERMANY
>>
>> Phone: +49 351 205768-167
>> Fax: +49 351 205768-999
>> E-mail: vinzenz.sinap...@tracetronic.de
>>
>> Head Office | Hauptsitz: Stuttgarter Str. 3, 01189 DRESDEN, GERMANY
>> Managing Directors | Geschäftsführer: Dr.-Ing. Rocco Deutschmann,
>> Dr.-Ing. Peter Strähle
>> Registration Court | Registergericht: Amtsgericht Dresden, HRB 23 086
>>
>>
>>
>> *Von:* rt-users [mailto:rt-users-boun...@lists.bestpractical.com] *Im
>> Auftrag von *Alex Hall
>> *Gesendet:* Freitag, 18. November 2016 14:29
>> *An:* rt-users <rt-users@lists.bestpractical.com>
>> *Betreff:* [rt-users] Owner not showing in search results?
>>
>>
>>
>> Hi all,
>>
>> We have an odd problem. I've put a script in place that sets the
>> requestor of a ticket to be its owner, and that works perfectly when
>> viewing a ticket--the owner is shown as the requestor. The problem is that
>> search results show most tickets as being owned by nobody, but if you click
>> a ticket, you see the owner has actually been set as expected. It's just
>> search results that don't want to show the owner.
>>
>> I found this script on the Wiki, and don't know enough about RT's
>> internals to say if it does everything it should. Does anyone see any
>> possible problems with it that would cause the issue with search results?
>>
>>
>> # get actor ID
>> my $Actor = $self->TransactionObj->Creator;
>> #if actor is RT_SystemUser then get out of here
>> return 1 if $Actor == $RT::SystemUser->id;
>> #prevents a ticket being assigned to an unprivileged user, comment out if
>> you want this
>> return 1 unless $self->TransactionObj->CreatorObj->Privileged;
>> #get out unless ticket owner is nobody
>> return 1 unless $self->TicketObj->Owner == $RT::Nobody->id;
>> #try to change owner
>> $RT::Logger->info("Auto assign ticket #". $self->TicketObj->id ." to user
>> #". $Actor );
>> my ($status, $msg) = $self->TicketObj->_Set(Field => 'Owner', Value =>
>> $Actor, RecordTransaction => 0);
>> unless( $status ) {
>> $RT::Logger->error( "Impossible to assign the ticket to $Actor: $msg"
>> );
>> return undef;
>> }
>>
>> return 1;
>>
>>
>> --
>>
>> Alex Hall
>>
>> Automatic Distributors, IT department
>>
>> ah...@autodist.com
>>
>> -
>> RT 4.4 and RTIR training sessions, and a new workshop day!
>> https://bestpractical.com/training
>> * Los Angeles - January 9-11 2017
>>
>
>
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] how to supply db credentials to rt-email-dashboards?

2016-11-25 Thread Alex Hall
Hi list,
I'm trying to run /opt/rt4/sbin/rt-email-dashboards, but am getting an
error that the database credentials are not correct. They aren't, but why?
If they get picked up from the configuration, they should be correct, since
RT itself is running just fine. If they aren't gotten from the
configuration files, where do they come from and how can I supply them? The
tool's help text didn't list any DB settings as possible flags. Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Automatically allow CCs access to tickets out of their queues?

2016-11-25 Thread Alex Hall
Please disregard the below email. The Graphics guy had been one-time CC-ed,
not permanently CC-ed, and no one realized it until just now. Sorry for the
pointless message. I do need to find a way to turn one-time CC into
permanent, for just this reason.

On Fri, Nov 25, 2016 at 3:45 PM, Alex Hall <ah...@autodist.com> wrote:

> Hi all,
> We just ran into a situation I expect to happen somewhat frequently. A
> graphics worker was CC-ed on a customer service ticket. Graphics would be
> overwhelmed with useless information if we gave them access to the Customer
> Service queue, and CS people don't care about graphics. But sometimes,
> queues do need to cross like this. Of course, Mr. Graphics couldn't view
> the ticket because it was a CS ticket, even though he'd been CC-ed and even
> gotten an email about it.
>
> What I'd like to do is grant ticket viewing rights to anyone CC-ed into a
> ticket, regardless of group membership. Is that possible to do? I know we
> could make teams or temporary groups, but I'd prefer an automated solution
> that doesn't require even more work from a staff who are only grudgingly
> using the new ticket system to begin with. :) Thanks for any help.
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Automatically allow CCs access to tickets out of their queues?

2016-11-25 Thread Alex Hall
Hi all,
We just ran into a situation I expect to happen somewhat frequently. A
graphics worker was CC-ed on a customer service ticket. Graphics would be
overwhelmed with useless information if we gave them access to the Customer
Service queue, and CS people don't care about graphics. But sometimes,
queues do need to cross like this. Of course, Mr. Graphics couldn't view
the ticket because it was a CS ticket, even though he'd been CC-ed and even
gotten an email about it.

What I'd like to do is grant ticket viewing rights to anyone CC-ed into a
ticket, regardless of group membership. Is that possible to do? I know we
could make teams or temporary groups, but I'd prefer an automated solution
that doesn't require even more work from a staff who are only grudgingly
using the new ticket system to begin with. :) Thanks for any help.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Emailing dashboards?

2016-11-23 Thread Alex Hall
Hi all,
I know RT can automatically email dashboards to specific users. I've just
not sure how to set this up. I found one list of dashboards where a
"subscription" column was present in the table, but it only listed a
single, global dashboard and not those for a given user. I've been through
users and settings, but didn't find it. This must be obvious, but where
would I tell users to go to set up subscriptions to their custom
dashboards? I just want certain users to get emails once a day with the
content of a specific saved search. Thanks!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Greetings to recent adopters of RT and invitation for group study

2016-11-22 Thread Alex Hall
I'm still pretty new to RT, so would like to join such a session. Thanks.

Sent from my iPhone

> On Nov 22, 2016, at 08:25, Reza  wrote:
> 
> Greetings new and recent adopters to RT!
> 
> I recently joined the community and though I have RT running in a production 
> environment, I have it running in the most basic of installations.
> 
> The best way I learn is through interaction of other newbies and advanced 
> users.
> 
> Unfortunately I do not have the time and resources to join an RT training 
> conference as much as I would love to in a heart beat.
> 
> Wondering how many here would be interested to learn / chat / video 
> conference online - as an international collective, for further knowledge 
> acquisition through group efforts.
> 
> If you are interested, please reply to this post and I will try to work on 
> getting a conference line free of charge, or perhaps have a group chat / talk 
> on Skype or other chat mediums.
> 
> Thanks in advance!
> Reza.
> 
> -
> RT 4.4 and RTIR training sessions, and a new workshop day! 
> https://bestpractical.com/training
> * Los Angeles - January 9-11 2017
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017


Re: [rt-users] Timezone set to GMT?

2016-11-21 Thread Alex Hall
I'm using the RT default, which appears to pull the information from
/etc/timezone:

my $zone = "UTC";
$zone=`/bin/cat /etc/timezone`
if -f "/etc/timezone";
chomp $zone;
Set($Timezone, $zone);

And /etc/timezone exists and is set correctly. I can just set the actual
value in this file, but I'm still not sure why this doesn't work.


On Sat, Nov 19, 2016 at 1:17 AM, Landon Stewart <lstew...@internap.com>
wrote:

> On Nov 18, 2016, at 11:40 AM, Alex Hall <ah...@autodist.com> wrote:
>
> Hi all,
> I have the timezone set in SiteConfig how it came by default, and
> /etc/timezone on my server is correct. Yet, I've just noticed that times in
> RT are GMT, not Eastern like they should be. I only just noticed this, but
> I'm told it has been an ongoing problem. That means I don't know what I
> might have changed, or when.
>
> Is there more to the timezone than letting RT pick it up from
> /etc/timezone? Do I need to worry about setting MySQL somehow? The file is
> 644, so is readable by everyone. Thanks.
>
>
> This is probably already set in the shipped configuration in
> etc/RT_Config.pm as follows but you can override it in etc/RT_SiteConfig.pm
>
>$Timezone
>$Timezone is the default timezone, used to convert times
> entered by users into GMT, as they are stored in the database, and back
> again;
>users can override this.  It should be set to a timezone
> recognized by your server.
>
> eg:
> Set($Timezone, "US/Eastern");
>
> --
> Landon Stewart
> Lead Analyst - Abuse and Security Management
> INTERNAP ®
>  lstew...@internap.com
>  www.internap.com
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Timezone set to GMT?

2016-11-18 Thread Alex Hall
Hi all,
I have the timezone set in SiteConfig how it came by default, and
/etc/timezone on my server is correct. Yet, I've just noticed that times in
RT are GMT, not Eastern like they should be. I only just noticed this, but
I'm told it has been an ongoing problem. That means I don't know what I
might have changed, or when.

Is there more to the timezone than letting RT pick it up from
/etc/timezone? Do I need to worry about setting MySQL somehow? The file is
644, so is readable by everyone. Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Owner not showing in search results?

2016-11-18 Thread Alex Hall
We always leave it at the default. I did a search for "queue:technology",
and here's the format it uses:

   '__id__/TITLE:#',
   '__Subject__/TITLE:Subject',
   Status,
   QueueName,
   Owner,
   Priority,
   '__NEWLINE__',
   '__NBSP__',
   '__Requestors__',
   '__CreatedRelative__',
   '__ToldRelative__',
   '__LastUpdatedRelative__',
   '__TimeLeft__'

On Fri, Nov 18, 2016 at 9:03 AM, Sinapius, Vinzenz <
vinzenz.sinap...@tracetronic.de> wrote:

> Hi Alex,
>
>
>
> What is the Format-String of your search? (It’s under the advanced tab,
> when you edit the search)
>
>
>
> The scrip looks fine.
>
>
>
> Cheers,
>
> Vinzenz
>
> Vinzenz Sinapius
> Information Technology | Informationstechnik
>
> *trace**tronic* GmbH
> Stuttgarter Str. 3
> 01189 DRESDEN
> GERMANY
>
> Phone: +49 351 205768-167
> Fax: +49 351 205768-999
> E-mail: vinzenz.sinap...@tracetronic.de
>
> Head Office | Hauptsitz: Stuttgarter Str. 3, 01189 DRESDEN, GERMANY
> Managing Directors | Geschäftsführer: Dr.-Ing. Rocco Deutschmann, Dr.-Ing.
> Peter Strähle
> Registration Court | Registergericht: Amtsgericht Dresden, HRB 23 086
>
>
>
> *Von:* rt-users [mailto:rt-users-boun...@lists.bestpractical.com] *Im
> Auftrag von *Alex Hall
> *Gesendet:* Freitag, 18. November 2016 14:29
> *An:* rt-users <rt-users@lists.bestpractical.com>
> *Betreff:* [rt-users] Owner not showing in search results?
>
>
>
> Hi all,
>
> We have an odd problem. I've put a script in place that sets the requestor
> of a ticket to be its owner, and that works perfectly when viewing a
> ticket--the owner is shown as the requestor. The problem is that search
> results show most tickets as being owned by nobody, but if you click a
> ticket, you see the owner has actually been set as expected. It's just
> search results that don't want to show the owner.
>
> I found this script on the Wiki, and don't know enough about RT's
> internals to say if it does everything it should. Does anyone see any
> possible problems with it that would cause the issue with search results?
>
>
> # get actor ID
> my $Actor = $self->TransactionObj->Creator;
> #if actor is RT_SystemUser then get out of here
> return 1 if $Actor == $RT::SystemUser->id;
> #prevents a ticket being assigned to an unprivileged user, comment out if
> you want this
> return 1 unless $self->TransactionObj->CreatorObj->Privileged;
> #get out unless ticket owner is nobody
> return 1 unless $self->TicketObj->Owner == $RT::Nobody->id;
> #try to change owner
> $RT::Logger->info("Auto assign ticket #". $self->TicketObj->id ." to user
> #". $Actor );
> my ($status, $msg) = $self->TicketObj->_Set(Field => 'Owner', Value =>
> $Actor, RecordTransaction => 0);
> unless( $status ) {
> $RT::Logger->error( "Impossible to assign the ticket to $Actor: $msg"
> );
> return undef;
> }
>
> return 1;
>
>
> --
>
> Alex Hall
>
> Automatic Distributors, IT department
>
> ah...@autodist.com
>
> -
> RT 4.4 and RTIR training sessions, and a new workshop day!
> https://bestpractical.com/training
> * Los Angeles - January 9-11 2017
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Owner not showing in search results?

2016-11-18 Thread Alex Hall
Hi all,
We have an odd problem. I've put a script in place that sets the requestor
of a ticket to be its owner, and that works perfectly when viewing a
ticket--the owner is shown as the requestor. The problem is that search
results show most tickets as being owned by nobody, but if you click a
ticket, you see the owner has actually been set as expected. It's just
search results that don't want to show the owner.

I found this script on the Wiki, and don't know enough about RT's internals
to say if it does everything it should. Does anyone see any possible
problems with it that would cause the issue with search results?


# get actor ID
my $Actor = $self->TransactionObj->Creator;
#if actor is RT_SystemUser then get out of here
return 1 if $Actor == $RT::SystemUser->id;
#prevents a ticket being assigned to an unprivileged user, comment out if
you want this
return 1 unless $self->TransactionObj->CreatorObj->Privileged;
#get out unless ticket owner is nobody
return 1 unless $self->TicketObj->Owner == $RT::Nobody->id;
#try to change owner
$RT::Logger->info("Auto assign ticket #". $self->TicketObj->id ." to user
#". $Actor );
my ($status, $msg) = $self->TicketObj->_Set(Field => 'Owner', Value =>
$Actor, RecordTransaction => 0);
unless( $status ) {
$RT::Logger->error( "Impossible to assign the ticket to $Actor: $msg" );
return undef;
}

return 1;

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] questions about crontool user setup

2016-11-17 Thread Alex Hall
Hi list,
I'm looking into email alerts for untouched tickets, and I thought of the
crontool right away. In reading its Wiki page, I'm a little confused about
setting up the user to run it. RT 4.4.1, Debian 8. Link I've been reading:
https://rt-wiki.bestpractical.com/wiki/UseRtCrontool

The page says to make an RT user *and* a Unix user. If the tool runs on the
server, though, where does the RT user come into it? If I do need both a
Unix and RT user, what do I enter into RT as the user's Unix login value?
Can I just make my RT user part of the admin group, or should I *only*
grant it the two rights the Wiki page mentions (view/modify tickets in all
queues)? That is, do I need to grant specific user rights, because of
security concerns surrounding making this user a full admin, or can I just
make it an admin? Thanks for any explanations.
-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] FTS enabled in SiteConfig, but not being enabled

2016-11-15 Thread Alex Hall
Hi all,
I found the problem. I've seen "Table" and "TableName" both used in sample
configurations, but apparently only one is correct. As soon as I switched
to "Table" in my config file, FTS enabled itself.

On Tue, Nov 15, 2016 at 11:09 AM, Matt Zagrabelny <mzagr...@d.umn.edu>
wrote:

> On Tue, Nov 15, 2016 at 9:56 AM, Alex Hall <ah...@autodist.com> wrote:
> > Good thought, but that doesn't seem to have helped. It still says that
> > Enable and Indexed are 0 in the system configuration page.
> >
> > On Tue, Nov 15, 2016 at 10:49 AM, Martin Wheldon
> > <martin.whel...@greenhills-it.co.uk> wrote:
> >>
> >> Hi Alex,
> >>
> >> Sounds like you may need to clear the mason cache.
>
> Clearing the mason cache only affects mason components that have been
> updated on disk.
>
> Changing configuration parameters wouldn't effect any mason components.
>
> -m
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] FTS enabled in SiteConfig, but not being enabled

2016-11-15 Thread Alex Hall
Good thought, but that doesn't seem to have helped. It still says that
Enable and Indexed are 0 in the system configuration page.

On Tue, Nov 15, 2016 at 10:49 AM, Martin Wheldon <
martin.whel...@greenhills-it.co.uk> wrote:

> Hi Alex,
>
> Sounds like you may need to clear the mason cache.
>
> Best Regards
>
> Martin
>
>
> On 2016-11-15 15:34, Alex Hall wrote:
>
>> Hi all,
>> I've enabled FTS on the database, and restarted the server just to be
>> sure. I have this line in one of my config files:
>>
>> Set( %FullTextSearch,
>> Enable => 1,
>> Indexed => 1,
>> Table => 'AttachmentsIndex');
>>
>> And yet, in global > system config, I see that Enable is set to 0, not
>> 1. I've looked at the loaded config files, and they include the one
>> where I enabled this. After a lot of work yesterday, I did get the
>> index program to run without any warnings, so I know that worked. I
>> see no errors in the log when RT starts, at least not related to FTS.
>>
>> I'm on RT 4.4.1, MySQL 5.7, Debian 8. What's the trick to getting FTS
>> to work? Thanks!
>>
>> --
>>
>> Alex Hall
>> Automatic Distributors, IT department
>> ah...@autodist.com
>>
>> -
>> RT 4.4 and RTIR training sessions, and a new workshop day!
>> https://bestpractical.com/training
>> * Los Angeles - January 9-11 2017
>>
> -
> RT 4.4 and RTIR training sessions, and a new workshop day!
> https://bestpractical.com/training
> * Los Angeles - January 9-11 2017
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] FTS enabled in SiteConfig, but not being enabled

2016-11-15 Thread Alex Hall
Hi all,
I've enabled FTS on the database, and restarted the server just to be sure.
I have this line in one of my config files:


Set( %FullTextSearch,
Enable => 1,
Indexed => 1,
Table => 'AttachmentsIndex');

And yet, in global > system config, I see that Enable is set to 0, not 1.
I've looked at the loaded config files, and they include the one where I
enabled this. After a lot of work yesterday, I did get the index program to
run without any warnings, so I know that worked. I see no errors in the log
when RT starts, at least not related to FTS.

I'm on RT 4.4.1, MySQL 5.7, Debian 8. What's the trick to getting FTS to
work? Thanks!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Enabling full text index, getting "MySQL server has gone away"

2016-11-14 Thread Alex Hall
For future readers, my own solution was--thankfully--much simpler. Nowhere
that I found in the docs I was reading did it say you had to add the
max_allowed_packet setting under a section called [mysqld] in my.cnf. As
soon as I did that, my setting took effect, and the full text setup ran
perfectly.

On Mon, Nov 14, 2016 at 12:10 PM, James Zuelow <james.zue...@juneau.org>
wrote:

> I had success by using Debian’s snapshot server and downgrading MySQL
> 5.6.27-2 and then running rt-setup-fulltext-index.  That worked perfectly.
>
>
>
> You can safely “upgrade” back to your current version after the setup
> script runs – the fulltext index maintenance script will run fine.
>
>
>
> If downgrading worked, please update my Debian bug report with the version
> that did not work for you:  http://bugs.debian.org/cgi-
> bin/bugreport.cgi?bug=840780
>
>
>
>
>
> James
>
>
>
> *From:* rt-users [mailto:rt-users-boun...@lists.bestpractical.com] *On
> Behalf Of *Alex Hall
> *Sent:* Monday, November 14, 2016 7:57 AM
> *To:* martin.whel...@greenhills-it.co.uk
> *Cc:* rt-users
> *Subject:* Re: [rt-users] Enabling full text index, getting "MySQL server
> has gone away"
>
>
>
> Thanks for the correction. I hate to say it, but this didn't change the
> results I'm seeing at all. I just updated /etc/mysql/conf.d/mysql.cnf,
> restarted MySQL, and ran the full-text index command again. I got the exact
> same errors as before.
>
>
>
> On Mon, Nov 14, 2016 at 11:50 AM, Martin Wheldon <
> martin.whel...@greenhills-it.co.uk> wrote:
>
> Hi Alex,
>
> I think the mysql configuration be "max_allowed_packet" rather than
> "max_packet_size".
>
> Best Regards
>
> Martin
>
>
>
> On 2016-11-14 13:54, Alex Hall wrote:
>
> I should also say that I've already tried setting my MySQL
> max_packet_size. 500M didn't do it, so I upped it to 5000M, restarting
> the service both times. That hasn't changed the warnings I'm getting,
> and I really don't think any attachments are over 5GB. Plus, the first
> few warnings are that "st execute failed", not about attachments not
> being indexed.
>
> On Mon, Nov 14, 2016 at 7:46 AM, Alex Hall <ah...@autodist.com> wrote:
>
> Hi all,
> As the subject says, I'm trying to enable full text indexing. I've
> updated MySQL to 5.7 (on Debian 8) and ran
>
> /opt/rt4/sbin/rt-setup-fulltext-index --dba root --dba-password pwd
>
> However, I get a bunch of warnings about executing the SQL
> statements and, after that, that attachments can't be indexed. In
> all cases, the main problem is the same: "the MySQL server has gone
> away". The initial connection was successful, so I'm not sure what
> the problem is. I also tested the root login after the 5.7 update,
> just to be sure it worked, and it was fine. Has anyone ever seen
> this happen? Any suggestions on what to do about it? Thanks!
>
> --
>
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>
>
> --
>
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>
> -
> RT 4.4 and RTIR training sessions, and a new workshop day!
> https://bestpractical.com/training
> * Los Angeles - January 9-11 2017
>
> -
> RT 4.4 and RTIR training sessions, and a new workshop day!
> https://bestpractical.com/training
> * Los Angeles - January 9-11 2017
>
>
>
>
> --
>
> Alex Hall
>
> Automatic Distributors, IT department
>
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Unable to create tickets after MySQL update?

2016-11-14 Thread Alex Hall
Hi all,
Ticket creation is working, now that I've finally gotten it out of strict
mode. You'd think it would check its own cnf file for errors on startup,
but nope, it doesn't notice until you try to log in using the 'mysql -u'
command. Not even an error in the log file. Anyway...

Priority is still not sticking, which doesn't surprise me. If RT is
inserting a string into an int, MySQL would put a 0 in that field. What did
surprise me is that disabling the PriorityAsString extension didn't help. I
set the priority to be 15, and when I created the cicket, it was still 0.
Yet the log shows none of the messages I've been seeing, as though it
thought it worked. Very odd stuff.

As to testing, yes, I normally do. I got to work very early today--a
Monday--with my mind set on updating MySQL and enabling full text search
before people got here and started using the system. Because of the hour,
or maybe because the tutorials I'd read made updating sound so easy, I
completely forgot to run all this on the test server first. Not a good move
on my part.

On Mon, Nov 14, 2016 at 4:24 PM, Matt Zagrabelny <mzagr...@d.umn.edu> wrote:

> Hi Alex,
>
> On Mon, Nov 14, 2016 at 10:37 AM, Alex Hall <ah...@autodist.com> wrote:
> > Hello again all,
> > I just discovered I have a more serious problem than full-text indexing
> not
> > working. I'm getting an error when anyone tries to make a ticket, and the
> > ticket is never created. Here's the message:
> >
> > Nov 14 11:31:03 server24 RT: [2522] DBD::mysql::st execute failed:
> Incorrect
> > integer value: 'ARRAY(0x18325928)' for column 'Priority' at row 1 at
> > /usr/share/perl5/DBIx/SearchBuilder/Handle.pm line 586.
> >
> > I have the PriorityAsString extension installed, but that's been working
> > perfectly for weeks. I've also modified some files so that the user can
> > select a priority on the main ticket creation page instead of going to
> the
> > details view, but that's also been working smoothly. The only major
> change
> > is the MySQL 5.5 upgrade to 5.7, but why that would be the cause, given
> the
> > error message, I'm not sure. If RT were trying to insert a string like
> that
> > before, it should have never worked. Is there anything I can do to fix
> this?
> > I'd rather not revert to 5.5, because I still want that full-text
> indexing
> > at some point and would rather fix this problem so I can keep trying to
> do
> > that. Thanks!
>
> Some thoughts...
>
> What do your PriorityAsString configs look like?
>
> Try disabling PriorityAsString.
>
> I know it doesn't help where you're at right now, but are you testing
> your changes in a test environment before making these changes in
> production?
>
> -m
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Unable to create tickets after MySQL update?

2016-11-14 Thread Alex Hall
Update: still not working. I tried setting sql-mode to an empty string,
like it would have been in 5.5, and to all the 5.7 standard ones except
strict_trans_tables. Neither helped. Updating existing tickets, and all
data retrieval, seem to work fine. It's just that priority getting a string
(that looks like a variable pointer) instead of an integer that's causing
the problem. Until I fix this, no one can make tickets, so if anyone has
any suggestions, please share them. Thanks.

On Mon, Nov 14, 2016 at 11:37 AM, Alex Hall <ah...@autodist.com> wrote:

> Hello again all,
> I just discovered I have a more serious problem than full-text indexing
> not working. I'm getting an error when anyone tries to make a ticket, and
> the ticket is never created. Here's the message:
>
> Nov 14 11:31:03 server24 RT: [2522] DBD::mysql::st execute failed:
> Incorrect integer value: 'ARRAY(0x18325928)' for column 'Priority' at row 1
> at /usr/share/perl5/DBIx/SearchBuilder/Handle.pm line 586.
>
> I have the PriorityAsString extension installed, but that's been working
> perfectly for weeks. I've also modified some files so that the user can
> select a priority on the main ticket creation page instead of going to the
> details view, but that's also been working smoothly. The only major change
> is the MySQL 5.5 upgrade to 5.7, but why that would be the cause, given the
> error message, I'm not sure. If RT were trying to insert a string like that
> before, it should have never worked. Is there anything I can do to fix
> this? I'd rather not revert to 5.5, because I still want that full-text
> indexing at some point and would rather fix this problem so I can keep
> trying to do that. Thanks!
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Enabling full text index, getting "MySQL server has gone away"

2016-11-14 Thread Alex Hall
Thanks for the correction. I hate to say it, but this didn't change the
results I'm seeing at all. I just updated /etc/mysql/conf.d/mysql.cnf,
restarted MySQL, and ran the full-text index command again. I got the exact
same errors as before.


On Mon, Nov 14, 2016 at 11:50 AM, Martin Wheldon <
martin.whel...@greenhills-it.co.uk> wrote:

> Hi Alex,
>
> I think the mysql configuration be "max_allowed_packet" rather than
> "max_packet_size".
>
> Best Regards
>
> Martin
>
>
> On 2016-11-14 13:54, Alex Hall wrote:
>
>> I should also say that I've already tried setting my MySQL
>> max_packet_size. 500M didn't do it, so I upped it to 5000M, restarting
>> the service both times. That hasn't changed the warnings I'm getting,
>> and I really don't think any attachments are over 5GB. Plus, the first
>> few warnings are that "st execute failed", not about attachments not
>> being indexed.
>>
>> On Mon, Nov 14, 2016 at 7:46 AM, Alex Hall <ah...@autodist.com> wrote:
>>
>> Hi all,
>>> As the subject says, I'm trying to enable full text indexing. I've
>>> updated MySQL to 5.7 (on Debian 8) and ran
>>>
>>> /opt/rt4/sbin/rt-setup-fulltext-index --dba root --dba-password pwd
>>>
>>> However, I get a bunch of warnings about executing the SQL
>>> statements and, after that, that attachments can't be indexed. In
>>> all cases, the main problem is the same: "the MySQL server has gone
>>> away". The initial connection was successful, so I'm not sure what
>>> the problem is. I also tested the root login after the 5.7 update,
>>> just to be sure it worked, and it was fine. Has anyone ever seen
>>> this happen? Any suggestions on what to do about it? Thanks!
>>>
>>> --
>>>
>>> Alex Hall
>>> Automatic Distributors, IT department
>>> ah...@autodist.com
>>>
>>
>> --
>>
>> Alex Hall
>> Automatic Distributors, IT department
>> ah...@autodist.com
>>
>> -
>> RT 4.4 and RTIR training sessions, and a new workshop day!
>> https://bestpractical.com/training
>> * Los Angeles - January 9-11 2017
>>
> -
> RT 4.4 and RTIR training sessions, and a new workshop day!
> https://bestpractical.com/training
> * Los Angeles - January 9-11 2017
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Unable to create tickets after MySQL update?

2016-11-14 Thread Alex Hall
Hello again all,
I just discovered I have a more serious problem than full-text indexing not
working. I'm getting an error when anyone tries to make a ticket, and the
ticket is never created. Here's the message:

Nov 14 11:31:03 server24 RT: [2522] DBD::mysql::st execute failed:
Incorrect integer value: 'ARRAY(0x18325928)' for column 'Priority' at row 1
at /usr/share/perl5/DBIx/SearchBuilder/Handle.pm line 586.

I have the PriorityAsString extension installed, but that's been working
perfectly for weeks. I've also modified some files so that the user can
select a priority on the main ticket creation page instead of going to the
details view, but that's also been working smoothly. The only major change
is the MySQL 5.5 upgrade to 5.7, but why that would be the cause, given the
error message, I'm not sure. If RT were trying to insert a string like that
before, it should have never worked. Is there anything I can do to fix
this? I'd rather not revert to 5.5, because I still want that full-text
indexing at some point and would rather fix this problem so I can keep
trying to do that. Thanks!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Enabling full text index, getting "MySQL server has gone away"

2016-11-14 Thread Alex Hall
Hi all,
As the subject says, I'm trying to enable full text indexing. I've updated
MySQL to 5.7 (on Debian 8) and ran

/opt/rt4/sbin/rt-setup-fulltext-index --dba root --dba-password pwd

However, I get a bunch of warnings about executing the SQL statements and,
after that, that attachments can't be indexed. In all cases, the main
problem is the same: "the MySQL server has gone away". The initial
connection was successful, so I'm not sure what the problem is. I also
tested the root login after the 5.7 update, just to be sure it worked, and
it was fine. Has anyone ever seen this happen? Any suggestions on what to
do about it? Thanks!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Making one-time CC permanent CC on ticket creation?

2016-11-10 Thread Alex Hall
Hello list,
I really want to make one-time CC/admin CC people into permanent CCs. I've
been all through share/html/Tickets/Create.html, since that's where the
form for new tickets points, and I can't find where it actually makes the
tickets. I thought all I'd have to do is adjust a few arguments and rewirte
the text hints, but that isn't proving to be the case at all. Is there an
easier way of doing what I want? Did I miss the obvious in Create.html?
Thanks for any suggestions.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Safe to upgrade from MySQL5.5?

2016-11-10 Thread Alex Hall
Hello all,
I think I already know the answer, but I want to be sure. I'm running MySQL
5.5 on Debian 8, RT 4.4.1. I want to go to 5.6 or 5.7 to enable full text
search. Are there any potential problems in doing this? Does RT use any
aspect of MySQL that would be affected by any of the changes made in MySQL
between 5.5 and 5.7? Is there anything else, aside from backing up, I
should know or consider before upgrading? Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Mapping users of a particular LDAP database to a specific queue

2016-11-09 Thread Alex Hall
My first thought is to use group rights to limit ticket/queue access. That
is, let users log in as normal, but add them to a specific queue as a
group. That way, you don't need to worry about where they logged in from or
were authenticated from. Unless I've misunderstood your question, in which
case I'm sorry for the confusion.

On Wed, Nov 9, 2016 at 7:30 AM, Maneesh Kumar <manee...@cdac.in> wrote:

> Hello members,
>
> We have a requirement of mapping users of a particular LDAP database to a
> specific queue. This is required to enable users to have access to a
> specific queue rather than all queues. The access need to be enabled for
> creation of tickets and thereafter for listing his/her open and closed
> tickets.
>
> Please let me know if this is possible and steps to meet this requirement.
>
>
> Maneesh Kumar
>
>
> National PARAM Supercomputing Facility
>
> HPC Infrastructure and Ecosystem Group
> Centre for Development of Advanced Computing
>
> 
> ---
> [ C-DAC is on Social-Media too. Kindly follow us at:
> Facebook: https://www.facebook.com/CDACINDIA & Twitter: @cdacindia ]
>
> This e-mail is for the sole use of the intended recipient(s) and may
> contain confidential and privileged information. If you are not the
> intended recipient, please contact the sender by reply e-mail and destroy
> all copies and the original message. Any unauthorized review, use,
> disclosure, dissemination, forwarding, printing or copying of this email
> is strictly prohibited and appropriate legal action will be taken.
> 
> ---
>
> -
> RT 4.4 and RTIR training sessions, and a new workshop day!
> https://bestpractical.com/training
> * Los Angeles - January 9-11 2017
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Unable to drag files to attach them?

2016-11-08 Thread Alex Hall
Thanks for the clarification. After talking with more users, it looks like
some hadn't tried it since the 4.4.1 update but still assumed it was
broken, while others were dropping into the message field and not the drop
target. Still others were dragging images from websites, and thinking RT
wasn't working when the images failed to copy over. I think this one is
resolved, and sorry for the false alarm.

On Tue, Nov 8, 2016 at 4:10 PM, Shawn M Moore <sh...@bestpractical.com>
wrote:

> Hi Landon, Alex,
>
> On Nov 8, 2016, at 14:51, Landon Stewart <lstew...@internap.com> wrote:
> On Nov 8, 2016, at 10:39 AM, Alex Hall <ah...@autodist.com> wrote:
>
>
> Hi all,
> Users are complaining that they can't drag/drop files to attach them to
> tickets. I can't see the screen, so don't use a mouse, so can't test this
> first-hand. Are there browsers or other variables that are known to stop
> this functionality, or did I disable something I shouldn't have? Thanks.
>
>
> I can say that I've never dragged and dropped a file onto a ticket to
> attach it.  It sounds like users might just be used to sites like imgur and
> the like who let you do this because they have scripts that make it
> possible and they expect it to be possible for RT.  They'll have to click
> the "Choose File" button while updating a ticket and actually choose the
> file.
>
>
> In RT 4.4, we did add support for dragging and dropping attachments onto
> tickets. We have a quick demo of this feature in action at
> https://www.youtube.com/watch?v=aBwYK1a8W7U#t=1m23s and described on our
> blog at https://bestpractical.com/blog/2015/12/whats-new-in-44-
> improved-attachment-handling
>
> Unfortunately, Alex, it's not clear to me why it would be broken for your
> users. If you can provide any more information about what your users are
> experiencing as well as which browsers they're trying it in, we may be able
> to pinpoint a cause.
>
> Best,
> Shawn
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Unable to drag files to attach them?

2016-11-08 Thread Alex Hall
I'll pass this along, thanks. I think the confusion, then, is that the text
says "Drag files here or click to attach". Odd that it says to drag files
if there's no JS to support that feature. I'll see about changing the text
in the html so users don't expect this option.

On Tue, Nov 8, 2016 at 2:51 PM, Landon Stewart <lstew...@internap.com>
wrote:

> On Nov 8, 2016, at 10:39 AM, Alex Hall <ah...@autodist.com> wrote:
>
>
> Hi all,
> Users are complaining that they can't drag/drop files to attach them to
> tickets. I can't see the screen, so don't use a mouse, so can't test this
> first-hand. Are there browsers or other variables that are known to stop
> this functionality, or did I disable something I shouldn't have? Thanks.
>
>
> I can say that I've never dragged and dropped a file onto a ticket to
> attach it.  It sounds like users might just be used to sites like imgur and
> the like who let you do this because they have scripts that make it
> possible and they expect it to be possible for RT.  They'll have to click
> the "Choose File" button while updating a ticket and actually choose the
> file.
>
> With that said - On Sarfari for macOS you can drag a file to the "Choose
> File" button and it lights up while you do it but I don't know if that
> works on Windows and I don't know if it's the same in all browsers.
>
> --
> Landon Stewart
> Lead Analyst - Abuse and Security Management
> INTERNAP ®
>  lstew...@internap.com
>  www.internap.com
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] avoiding duplicate emails for transaction types

2016-11-08 Thread Alex Hall
Hi all,
I'm setting up some email notifications, and am wondering how RT handles
sub-types of transactions.

I'm making a template to be used when a ticket is created, and others for
when a ticket has its status or priority changed. Those three are all
transactions, but I also have a template that is used for all transactions,
to cover anything else. Will RT see that it already has a script assigned
to, say, creation and not trigger the general transaction one, or will it
run both? Am I better off making or modifying scripts for each transaction
type I want, or, like naming templates the same as global ones in queues,
will RT be able to handle multiple scripts for one event in a hierarchical
way?

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Unable to drag files to attach them?

2016-11-08 Thread Alex Hall
Hi all,
Users are complaining that they can't drag/drop files to attach them to
tickets. I can't see the screen, so don't use a mouse, so can't test this
first-hand. Are there browsers or other variables that are known to stop
this functionality, or did I disable something I shouldn't have? Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Ticket owners not always showing in search results

2016-11-07 Thread Alex Hall
Sorry for all the messages today.

My boss just pointed out something odd: our script to make a ticket
requestor into the owner works fine, in that viewing the ticket shows the
owner. However, a search that turns up multiple tickets will have many
owners listed as "nobody in particular". Clicking such a ticket reveals an
owner, though. Why would the search sometimes refuse to show the owner,
while the ticket page lists one? I haven't modified the results page at
all, and while I did modify the ticket display some, I never touched the
part that shows the owner. Here's the script (I didn't write it, I borrowed
it):


# get actor ID
my $Actor = $self->TransactionObj->Creator;
#if actor is RT_SystemUser then get out of here
return 1 if $Actor == $RT::SystemUser->id;
#prevents a ticket being assigned to an unprivileged user, comment out if
you want this
return 1 unless $self->TransactionObj->CreatorObj->Privileged;
#get out unless ticket owner is nobody
return 1 unless $self->TicketObj->Owner == $RT::Nobody->id;
#try to change owner
$RT::Logger->info("Auto assign ticket #". $self->TicketObj->id ." to user
#". $Actor );
my ($status, $msg) = $self->TicketObj->_Set(Field => 'Owner', Value =>
$Actor, RecordTransaction => 0);
unless( $status ) {
$RT::Logger->error( "Impossible to assign the ticket to $Actor: $msg" );
return undef;
}

return 1;

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] color-coding tickets by priority?

2016-11-07 Thread Alex Hall
Hi list,
Now that I have priority on the main ticket creation page rather than the
details page, people are using it more. I'm expecting the next question I
get to be about making tickets of certain priorities more visually striking
in results lists. For instance, if a color is 30-50 (our cap is 50), could
it be made a different color than the tickets that are 1-29, while tickets
at 0 are a third color? RT may already do this, I'm not sure, since I use a
screen reader. If it doesn't, can it be made to? At the least, do tickets
have a class I could use in CSS to do this? If not, it would be easy enough
to add that to the div in the HTML, but before I go making solutions, I
wanted to see what RT already had in place.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Searching ticket content?

2016-11-07 Thread Alex Hall
Hi all,
That 'subject' dropdown has content-type, but not just content. Is there a
setting I've missed?

On Mon, Nov 7, 2016 at 9:16 AM, Kenneth Marshall <k...@rice.edu> wrote:

> On Mon, Nov 07, 2016 at 08:57:32AM -0500, Alex Hall wrote:
> > Hello list,
> > Some users at work are wondering if they can search ticket contents?
> > There's no way in the search builder, but I know I can plug any SQL I
> want
> > to into the advanced search. Even if I knew the SQL to use, though,
> that's
> > only a saved search for that string. Could I somehow offer users a way to
> > search for a string they enter when they're ready to search? I don't want
> > to expose the actual SQL query, as there's too much chance of a misplaced
> > punctuation mark or mistyped character causing errors. Thanks.
> >
> > --
> > Alex Hall
> > Automatic Distributors, IT department
> > ah...@autodist.com
>
>
> Hi Alex,
>
> In advanced search, you select 'Content' and the the items to search
> for. Does that not work for you?
>
> Regards,
> Ken
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Searching ticket content?

2016-11-07 Thread Alex Hall
Hello list,
Some users at work are wondering if they can search ticket contents?
There's no way in the search builder, but I know I can plug any SQL I want
to into the advanced search. Even if I knew the SQL to use, though, that's
only a saved search for that string. Could I somehow offer users a way to
search for a string they enter when they're ready to search? I don't want
to expose the actual SQL query, as there's too much chance of a misplaced
punctuation mark or mistyped character causing errors. Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

[rt-users] Checking Mason template syntax?

2016-11-04 Thread Alex Hall
Hi all,
I know I can check configuration modules with perl -c, but is there a
similar way to check the syntax of Mason templates I'm modifying? They
aren't valid Perl, so I can't use that. I imagine RT uses some kind of
validation somewhere, though, and I wonder if I can access it directly to
confirm my syntax won't kill RT before making a template live?

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] modifying SelfService

2016-11-04 Thread Alex Hall
I'd also add that you may want to not touch the files in the share
directory. You may have a reason for doing it this way that I missed in
your message, but generally, RT likes you to copy these files and then
modify the copies. This is called an "overlay".
https://rt-wiki.bestpractical.com/wiki/CustomizingWithOverlays

You'll want to copy any files you want to change into
[rt_home]/local/html/[original path]. Modify those files, clear your Mason
cache, restart your server, and your changes will take effect. The
advantage is not only that you have the original file, but that you can
revert to it simply by renaming or erasing your modified version.

To change share/html/Tickets/Elements/ShowPriority, for instance, you'd do:

cd /opt/rt4/local
mkdir html
cd html
mkdir Tickets
cd Tickets
mkdir Elements
cd Elements
cp /opt/rt4/share/html/Tickets/Elements/ShowPriority .

You now have a copy of ShowPriority that you can modify as much as you want.

On Fri, Nov 4, 2016 at 9:46 AM, Matt Zagrabelny <mzagr...@d.umn.edu> wrote:

> Heya,
>
>
> On Fri, Nov 4, 2016 at 8:10 AM, Stehlík Tomáš <steh...@oaza-net.cz> wrote:
> > Hello,
> >
> >
> >
> > I have one stupid question – I am trying modify SelfService portal but i
> am
> > facing that changes into html files are not affecting on the pages.
> >
> >
> >
> > For example, modifying
> >
> >
> >
> > /opt/rt4/share/html/SelfService/Elements/MyRequests
> >
> >
> >
> > I tried to change
> >
> >
> >
> > my $Query = "( Watcher.id = $id )";
> >
> >
> >
> > to
> >
> >
> >
> > my $Query = "( Watcher.id = 2 )";
> >
> >
> >
> > (to just see what happens)
> >
> >
> >
> > And it’s still same (it shows me only my tickets). Even when I change
>
> You probably need to clear your mason cache:
>
> sudo find /opt/rt4/var/mason_data/obj -mindepth 1 -delete
> sudo service apache2 restart
>
> -m
> -
> RT 4.4 and RTIR training sessions, and a new workshop day!
> https://bestpractical.com/training
> * Los Angeles - January 9-11 2017
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - January 9-11 2017

Re: [rt-users] Finding queue priority in script?

2016-11-02 Thread Alex Hall
Thanks, I found it. I wonder if the lack of documentation is because this
is an option under DefaultValue()? It's not wrapped to make its own
function, so maybe the docs never picked it up under what I would think of
as an expected name?

On Wed, Nov 2, 2016 at 5:18 AM, Martin Wheldon <
martin.whel...@greenhills-it.co.uk> wrote:

> Sorry that should be DefaultValue, not SetDefaultValue.
> Should read the question more closely :(
>
> Martin
>
>
> On 2016-11-02 09:10, Martin Wheldon wrote:
>
>> Hi Alex,
>>
>> The file below contains a example of how to set the default values for a
>> queue.
>>
>> share/html/Admin/Queues/DefaultValues.html
>>
>> Looks like the SetDefaultValue method for Queues isn't documented or a
>> least I haven't found where, which seems odd
>> as I've always found RT to be very well documented.
>>
>> Best Regards
>>
>> Martin
>>
>> On 2016-11-01 21:50, Alex Hall wrote:
>>
>>> Hi all,
>>> It hit me the other day that instead of trying to move the priority
>>> field out of the details view, I could simply make a custom field for
>>> priority, then set it in a script on ticket creation.
>>>
>>> I see in the docs how to set a ticket's priority, but is there a way
>>> to get a queue's priority values (initial and maximum)? All our queues
>>> will likely share priority settings, so I'm not too worried about
>>> this, but I would prefer to base things off a given queue's settings
>>> if possible. The docs for Queue objects mention nothing about
>>> priority, which seems like an odd ommition. Thanks for any
>>> suggestions.
>>>
>>> --
>>>
>>> Alex Hall
>>> Automatic Distributors, IT department
>>> ah...@autodist.com
>>>
>>> -
>>> RT 4.4 and RTIR training sessions, and a new workshop day!
>>> https://bestpractical.com/training
>>> * Los Angeles - Q1 2017
>>>
>> -
>> RT 4.4 and RTIR training sessions, and a new workshop day!
>> https://bestpractical.com/training
>> * Los Angeles - Q1 2017
>>
> -
> RT 4.4 and RTIR training sessions, and a new workshop day!
> https://bestpractical.com/training
> * Los Angeles - Q1 2017
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - Q1 2017

[rt-users] Enable devel-mode on existing RT instance?

2016-11-02 Thread Alex Hall
Hi all,
I'm getting an error in an overlay, but nothing is logged. I know I can use
./configure --devel-mode
to help, though whether that will show additional information for errors
like this I'm not sure. Either way, how do I enable it on an existing
installation of RT? Do I go back to the unpacked source and re-run the
configure script, or is there more to it? Thanks.

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com
-
RT 4.4 and RTIR training sessions, and a new workshop day! 
https://bestpractical.com/training
* Los Angeles - Q1 2017

  1   2   3   >