[rt-users] RTIR 3.2 and RT 4.4 compatibility

2016-05-16 Thread Peter Viskup
Dear all,
would like to ask you whether the RT 4.4 and RTIT 3.2 are compatible.
The download page [1] says the RTIR 3.2 is built for RT 4.2 only.

[1] https://bestpractical.com/download-page

-- 
Peter Viskup
-
RT 4.4 and RTIR Training Sessions https://bestpractical.com/training
* Washington DC - May 23 & 24, 2016


[rt-users] Problems with status changing scrip

2016-05-16 Thread Zoey Schutt
Hello,


I am working on a scrip to auto-change the status of a ticket if it is set to 
"customer" status. However, I do not want the ticket to change status if the 
user who is replying to the ticket is the owner. I managed to get the status 
changing properly, but as soon as I try to setup the condition it no longer 
works. Could someone look this over for me and tell me where I'm messing up?


Condition: On Correspond

Action: User Defined

Template: Blank


Custom action preparation code:

return 1;

Custom action commit code:

# Abort if actor is owner of ticket
return 1 unless $self->TicketObj->Owner != $actor->id;

# Change status to "open" if status is "customer"
if ($self->TicketObj->Status() eq 'customer' ) {
$self->TicketObj->SetStatus('open');
$RT::Logger->info("Customer replied to ticket awaiting reply. Status set to 
open.");
return 1;
}
return undef;


RT Information:


RT 4.2.12

Perl v5.14.2 built for x86_64-linux-gnu-thread-multi

Apache 2.2.22

PHP 5.5.33-1~dotdeb+7.1

MySQL Ver 14.14 Distrib 5.5.49


Thanks,


Zoey Schutt

Braincoral Technology, LLC
-
RT 4.4 and RTIR Training Sessions https://bestpractical.com/training
* Washington DC - May 23 & 24, 2016


Re: [rt-users] Stalled tickets - Open on comment/reply?

2016-05-16 Thread Zoey Schutt
Hi Joel,


There is indeed a scrip that auto-changes the status of inactive tickets back 
to active when a customer replies. However, stalled is not considered an 
inactive status in the default life cycle. Feel free to correct me if I'm 
wrong, but due to this the built-in scrip will not change the status to open 
when a ticket gets updated while in stalled status.


Below is a portion of the default lifecycle, anything in inactive will cause 
the ticket's status to be updated.


default => {
initial => [qw(new)], # loc_qw
active  => [qw(open stalled)], # loc_qw
inactive=> [qw(resolved rejected deleted)], # loc_qw

Regards,


Zoey Schutt

Braincoral Technology, LLC


From: rt-users  on behalf of Joel 
Bergmark 
Sent: Thursday, May 12, 2016 2:30:01 PM
To: rt-users@lists.bestpractical.com
Subject: [rt-users] Stalled tickets - Open on comment/reply?

Perhaps this is not a bug, but stalled tickets that gets updated via email from 
external parties, didn't this previously change the status of the ticket to 
Open?

In RT 4.4 it seems not to work, and cant seem to make it work with custom scrip 
either (due to lack of perl skills).

Is this a bug or supposed to work in this way?

Regards
-
RT 4.4 and RTIR Training Sessions https://bestpractical.com/training
* Washington DC - May 23 & 24, 2016


Re: [rt-users] RT4 Install on Centos7+Internal Server Error

2016-05-16 Thread Bill Cole

On 9 May 2016, at 12:11, Brad wrote:


Hi Yanni,

Yes it is still the same error as back in February that I posted to 
the Best Pratical Bug and also brought up in this mail group.


Here is what I was getting with specific errors in the require.pm and 
RT.pm:


Just an FYI that I have never gotten it to load past the 500 error... 
and the RT bug webpage seems to have been taken down...



Hi Matt,

For configuring fcgid I do not see a configure web-handler choice for 
fcgid in configure --help.


That's because from RT's position, mod_fcgid and mod_fastcgi present the 
identical fastcgi interface.


It has fastcgi (default) modperl1 modperl2 and standalone. What is the 
correct configure to use with fcgid?


You should run the configure script in the RT4 source tree with 
"--with-web-handler=fastcgi" or no "--with-web-handler" argument at all, 
since fastcgi is the default.


Note that the configure script configures the RT source code for the 
ensuing build process, i.e. the 'make' commands. It DOES NOT configure 
Apache for you.



Currently I am using fastcgi which has produced the below errors.

Thanks,
Brad

On 02/21/2016 01:59 PM, Matt Zagrabelny wrote:
On Sun, Feb 21, 2016 at 11:20 AM, Brad  
wrote:

Hi All,

Set it up as Piotr pointed out but now getting an Internal error:

[Sun Feb 21 16:51:48.198523 2016] [mpm_prefork:notice] [pid 32464]
AH00163: Apache/2.4.6 (CentOS) OpenSSL/1.0.1e-fips mod_fcgid/2.3.9
PHP/5.4.16 mod_perl/2.0.9dev Perl/v5.16.3 configured -- resuming 
normal

operations


Can't locate UNIVERSAL/require.pm in @INC (@INC contains:
/opt/rt4/sbin/../local/lib /opt/rt4/sbin/../lib 
/usr/local/lib64/perl5

/usr/local/share/perl5 /usr/lib64/perl5/vendor_perl
/usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at
/opt/rt4/sbin/../lib/RT.pm line 60.
BEGIN failed--compilation aborted at /opt/rt4/sbin/../lib/RT.pm line 
60.
Compilation failed in require at /opt/rt4/sbin/rt-server.fcgi line 
86.


That's an indication that you do not have the UNIVERSAL::require Perl 
module installed in a proper location. The most likely cause of that on 
CentOS7 is using CPAN (particularly as a non-root user) to install Perl 
modules, as "make fixdeps" does. If done blindly, that is likely to 
result in a ~/perl/ directory with your CPAN-installed modules which 
won't be visible to RT.


You are better off enabling the EPEL repository and using yum to install 
the needed packages of Perl modules needed for RT. You can probably make 
"make fixdeps" do the right thing (once you've enabled the EPEL repo) by 
passing it a suitable alternative installation command in the 
RT_FIX_DEPS_CMD environment variable like this:


RT_FIX_DEPS_CMD='/bin/yum install -y perl-%s' make fixdeps

And of course, that must be run as root to be able to install the 
dependencies in the system-wide Perl library tree.


-
RT 4.4 and RTIR Training Sessions https://bestpractical.com/training
* Washington DC - May 23 & 24, 2016


[rt-users] Need to "edit" a ticket via javascript and Angular.js $http.post

2016-05-16 Thread Keith Creasy
Hello all.


I'm using RT 4.2.7.


I have my RT progress page working. I solved my previous problem of RT altering 
attribute values that were needed by Angular by redirecting so that the actual 
report page lives outside RT. One can now to to the URL, log into RT, and view 
the project progress report.


Now I want to update RT with some calculated values on certain, what we are 
calling "epic", tickets. The documentation is pretty vague and so far I haven't 
found just the right way to make it work. Does anyone have a good, working 
example of a call to edit an RT ticket via Javascript, or even better 
Angular.js? Here is my function as it currently stands. There is a lot of 
variable declarations that I probably don't need but was trying to rule out 
what might have been my own mistakes.


// We want to set the actual values in RT to match our calclulations on Epics.
this.setTimeData = function ( row) {
var number = row.id;
var url = baseURL+"ticket/"+row.id+"/edit";
var timeWorked = row.TimeWorked*60;
var timeLeft = row.TimeLeft*60;
var data = [];
data['content'] = 'TimeWorked: '+timeWorked+'\nTimeLeft: '+timeLeft;
if( number == 3683) {
console.log( url+": "+data.content+".");
$http.post( url, data)
.then( function (response) {
console.log(response.data);
})
.catch( function (e) {
console.log(e);
});
}
}



The response I get just has the ticket details in the response data... No 
errors but the ticket doesn't get updated either.


Thank yu for any assistance.


Keith


-
RT 4.4 and RTIR Training Sessions https://bestpractical.com/training
* Washington DC - May 23 & 24, 2016


[rt-users] Re: Problems with status changing scrip

2016-05-16 Thread Zoey Schutt
I ended up fixing the problem myself. The functioning scrip is below for anyone 
that would like to use it.


Scrip Name: Set ticket to active upon customer reply

Condition: On Correspond

Action: User Defined

Template: Blank


Custom action preparation code:

return 1;

Custom action commit code:


my $Actor = $self->TransactionObj->Creator;

my $Owner = $self->TicketObj->Owner;

# Change status to "open" if status is "customer"

if( $Owner != $Actor ) {

if ($self->TicketObj->Status() eq 'customer' ) {

$self->TicketObj->SetStatus('open');

$RT::Logger->info("Customer replied to ticket awaiting reply. Status set to 
open.");

return 1;

}

return undef;

}

return undef;


RT Information:


RT 4.2.12

Perl v5.14.2 built for x86_64-linux-gnu-thread-multi

Apache 2.2.22

PHP 5.5.33-1~dotdeb+7.1

MySQL Ver 14.14 Distrib 5.5.49




Zoey Schutt

Braincoral Technology, LLC



From: rt-users  on behalf of Zoey 
Schutt 
Sent: Monday, May 16, 2016 8:36 AM
To: rt-users@lists.bestpractical.com
Subject: [rt-users] Problems with status changing scrip


Hello,


I am working on a scrip to auto-change the status of a ticket if it is set to 
"customer" status. However, I do not want the ticket to change status if the 
user who is replying to the ticket is the owner. I managed to get the status 
changing properly, but as soon as I try to setup the condition it no longer 
works. Could someone look this over for me and tell me where I'm messing up?


Condition: On Correspond

Action: User Defined

Template: Blank


Custom action preparation code:

return 1;

Custom action commit code:

# Abort if actor is owner of ticket
return 1 unless $self->TicketObj->Owner != $actor->id;

# Change status to "open" if status is "customer"
if ($self->TicketObj->Status() eq 'customer' ) {
$self->TicketObj->SetStatus('open');
$RT::Logger->info("Customer replied to ticket awaiting reply. Status set to 
open.");
return 1;
}
return undef;


RT Information:


RT 4.2.12

Perl v5.14.2 built for x86_64-linux-gnu-thread-multi

Apache 2.2.22

PHP 5.5.33-1~dotdeb+7.1

MySQL Ver 14.14 Distrib 5.5.49


Thanks,


Zoey Schutt

Braincoral Technology, LLC
-
RT 4.4 and RTIR Training Sessions https://bestpractical.com/training
* Washington DC - May 23 & 24, 2016