Re: [rt-users] Scrip for adding to the custom field based on another CF

2015-01-21 Thread Landon Stewart
On Jan 21, 2015, at 7:07 AM, Kevin Squire gentg...@wikiak.org wrote:
 
 
 I have a scrip currently that checks for status change from X-- Y and if 
 true, adds an entry to the Custom Field RMA Num.  It adds our RMA number, 
 which is really just RMA-$RT_Ticket_Number
 
 They have asked me to change the number based on another CF RMA TYPE.  If 
 the RMA type = Student Withdrawl they want the RMA number to be appended 
 with WD
 
 
 My perl skills are limited to copy/paste and tweaking existing so I would 
 like a little bit of help with my If/Then statement.  The idea being:
 
 IF CustomField{RMA Type} = Student Withdrawl
 THEN $Append = -WD
 ELSE $Append = 
 
 Then in the current line (below)
  my $Value = RMA- . $Num ;
 
 would be changed to
   my $Value = RMA- . $Num . $Append ;

This can be done with one ternary operator:
my $value = $self-TicketObj-FirstCustomFieldValue('RMA Type') eq 'Student 
Withdrawl' ? RMA- . $Num : RMA- . $Num . $Append;

Some notes:
- The condition here is:  $self-TicketObj-FirstCustomFieldValue('RMA Type') 
eq 'Student Withdrawl'
- If the condition is true then $value will equal what's between the ? and the 
: (colon)
- If the condition is false then $value will equal what's between the : and the 
; (semi-colon)

Landon Stewart : lstew...@iweb.com
Lead Specialist, Abuse and Security Management
Spécialiste principal, gestion des abus et sécurité
http://iweb.com : +1 (888) 909-4932



signature.asc
Description: Message signed with OpenPGP using GPGMail


Re: [rt-users] T-Extension-CustomField-HideEmptyValues does not work with mobile theme

2015-01-21 Thread Alex Vandiver
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Wed, 21 Jan 2015 09:22:23 + Daniel Schwager
daniel.schwa...@dtnet.de wrote:
 your plugin (1) does not work with RT 4.2.9 and mobile theme (from my
 android). All fields will be shown.

The right place to report bugs in the extension, as the page you linked
explains, is via the rt.cpan.org queue.

Regardless, version 1.10 is on its way to CPAN now, which resolves the
issue.  Due to a bug in RT, the Custom Fields box may still be
displayed even if there are no CFs to display.  I expect 4.2.10 to
address that issue.
 - Alex
-BEGIN PGP SIGNATURE-
Version: GnuPG v2.0.22 (GNU/Linux)

iEYEARECAAYFAlS/9IsACgkQMflWJZZAbqCvLwCfZSCvW3MzS6Iq21CSV+8xHw4h
oTgAoI7zaUUzrcGV+uAiKuo5ou3/5h6M
=9d8s
-END PGP SIGNATURE-


Re: [rt-users] Assets - export or show list with custom fields

2015-01-21 Thread Alex Vandiver
On Wed, 21 Jan 2015 12:11:57 -0500 Ryan Whalen rwha...@advanceweb.com
wrote:
 Hello,
 
 Is there a way to export the assets in a catalog to a csv file?

Assets 1.01 added a CSV export.

 If not, is there a way to display specified custom fields in the
 search results? Or see a list of assets with more information than
 Name, Description, Status, and Owner?

http://bestpractical.com/docs/assets/latest/Assets_Config.html#AssetSearchFormat

 - Alex


[rt-users] Postfix can not send email

2015-01-21 Thread leandro.gs
Hey! I have seen a lot of questions about this, but none of the answers
helped me with this issue. Here's the problem, I have an external dedicated
email server and I'm using fetchmail to get this emails so RT can proccess
it. RT can send email notifications to the users and I'm trying to do so
using postfix. Here follows my main.cf file:



When I monitor the maillog, I can see that the notifications are sent from
the correct mail, but the destination keep going wrong
(r...@correio.incaper.es.gov.br) does anyone know how to sent the emails to
the requestors, Cc and AdminCc?



--
View this message in context: 
http://requesttracker.8502.n7.nabble.com/Postfix-can-not-send-email-tp59397.html
Sent from the Request Tracker - User mailing list archive at Nabble.com.


[rt-users] Assets - export or show list with custom fields

2015-01-21 Thread Ryan Whalen
Hello,

Is there a way to export the assets in a catalog to a csv file? If not, is
there a way to display specified custom fields in the search results? Or
see a list of assets with more information than Name, Description, Status,
and Owner?

I didn't see an assets-specific mailing list, please let me know if there
is a more appropriate place for this question.

Thanks,
Ryan


Re: [rt-users] Postfix can not send email

2015-01-21 Thread Alex Peters
What do RT's debug logs show when an email is generated?

On Thu, 22 Jan 2015 2:39 am leandro.gs leandrog...@gmail.com wrote:

 Hey! I have seen a lot of questions about this, but none of the answers
 helped me with this issue. Here's the problem, I have an external dedicated
 email server and I'm using fetchmail to get this emails so RT can proccess
 it. RT can send email notifications to the users and I'm trying to do so
 using postfix. Here follows my main.cf file:



 When I monitor the maillog, I can see that the notifications are sent from
 the correct mail, but the destination keep going wrong
 (r...@correio.incaper.es.gov.br) does anyone know how to sent the emails
 to
 the requestors, Cc and AdminCc?



 --
 View this message in context: http://requesttracker.8502.n7.
 nabble.com/Postfix-can-not-send-email-tp59397.html
 Sent from the Request Tracker - User mailing list archive at Nabble.com.



Re: [rt-users] Scrip for adding to the custom field based on another CF

2015-01-21 Thread Alex Peters
You should move your scrip code from the Prepare box to the Commit box.
Making changes to tickets in the Prepare stage of a transaction can cause
unintended side effects and is not recommended.

On Thu, 22 Jan 2015 2:07 am Kevin Squire gentg...@wikiak.org wrote:


 I have a scrip currently that checks for status change from X-- Y and if
 true, adds an entry to the Custom Field RMA Num.  It adds our RMA number,
 which is really just RMA-$RT_Ticket_Number

 They have asked me to change the number based on another CF RMA TYPE.
 If the RMA type = Student Withdrawl they want the RMA number to be
 appended with WD


 My perl skills are limited to copy/paste and tweaking existing so I
 would like a little bit of help with my If/Then statement.  The idea being:

 IF CustomField{RMA Type} = Student Withdrawl
 THEN $Append = -WD
 ELSE $Append = 

 Then in the current line (below)
  my $Value = RMA- . $Num ;

 would be changed to
   my $Value = RMA- . $Num . $Append ;





 *Custom action preparation code:*

 # Define the Custom Field to Act on
 my $CFName = RMA Num;

 #Get the RT Ticket Number
 my $Num = $self-TicketObj-id();

 # Define the desired value for the CF
 my $Value = RMA- . $Num ;

 $self-TicketObj-AddCustomFieldValue( Field = $CFName, Value = $Value );

 return 1;




 --
 http://www.wikiak.org

 #
  Associate yourself with men of good quality if you esteem
  your own reputation; for 'tis better to be alone then in bad
  company.- George Washington, Rules of Civility



Re: [rt-users] Scrip for adding to the custom field based on another CF

2015-01-21 Thread Kevin Squire
I was not aware of this.  

When you say Commit box, are you referring to the Custom action
cleanup code box?



On Wed, 21 Jan 2015 21:35:47 +
Alex Peters a...@peters.net wrote:

 You should move your scrip code from the Prepare box to the Commit
 box. Making changes to tickets in the Prepare stage of a transaction
 can cause unintended side effects and is not recommended.
 
-- 
http://www.wikiak.org

#
 Associate yourself with men of good quality if you esteem
 your own reputation; for 'tis better to be alone then in bad 
 company.- George Washington, Rules of Civility


Re: [rt-users] Scrip for adding to the custom field based on another CF

2015-01-21 Thread Alex Peters
Sorry, yes, that one.

There are some preview operations that run the prepare code on the
assumption that nothing will change.  In such circumstances, your custom
field would be set even before someone hits the Update button.  It's
always best not to have the Prepare code make any changes.

The cleanup box should probably be renamed, since everywhere else it
seems to be known as commit.  The distinction would be clearer.

The commit code won't run unless the prepare code returns a true value, so
in that box you could write 1; to ensure that the commit code always runs.

On Thu, 22 Jan 2015 9:16 am Kevin Squire gentg...@wikiak.org wrote:

 I was not aware of this.

 When you say Commit box, are you referring to the Custom action
 cleanup code box?



 On Wed, 21 Jan 2015 21:35:47 +
 Alex Peters a...@peters.net wrote:

  You should move your scrip code from the Prepare box to the Commit
  box. Making changes to tickets in the Prepare stage of a transaction
  can cause unintended side effects and is not recommended.
 
 --
 http://www.wikiak.org

 #
  Associate yourself with men of good quality if you esteem
  your own reputation; for 'tis better to be alone then in bad
  company.- George Washington, Rules of Civility



Re: [rt-users] Scrip for adding to the custom field based on another CF

2015-01-21 Thread Kevin Squire
Such an elegant solution - thank you.


 This can be done with one ternary operator:
 my $value = $self-TicketObj-FirstCustomFieldValue('RMA Type') eq
 'Student Withdrawl' ? RMA- . $Num : RMA- . $Num . $Append;

 Some notes:
 - The condition here is:  $self-TicketObj-FirstCustomFieldValue('RMA
 Type') eq 'Student Withdrawl'
 - If the condition is true then $value will equal what's between the ? and
 the : (colon)
 - If the condition is false then $value will equal what's between the :
 and the ; (semi-colon)




[rt-users] Migrating from MySql to Oracle

2015-01-21 Thread Hummer, Greg
Hi,

I work at a support desk currently using RT 4.0.6 on a MySQL server and we need 
to switch to RT 4.2.0 on a Oracle Server for fulltext search among other thing. 
The database administrators are not very familiar with RT, but they have 
successfully upgraded 4.0.6 MySQL to 4.2.0 MySQL on a test server.

My question, is there any step by step document, guidance, or video that I can 
provide to the DBA’s to assist them in the conversion to Oracle?

I was told that RT 4.2 includes utilities such as the RT-Validator, 
RT-Serializer, and RT-Impoter to assist in this process. I have read though the 
documentation provided on the BestPractical website, but still cannot verify 
what directions to give to the DBAs.

From what I read, this is what I think I know so far:

1. They should take the database for 4.2.0 on the MySQL server and use 
RT-Validatorhttps://www.bestpractical.com/docs/rt/4.2/rt-validator.html to 
ensure the database is self-consistent.
2. Next they should use 
RT-Serializerhttps://www.bestpractical.com/docs/rt/4.2/rt-serializer.html to 
write out the RT database to a disk. During the process of using RT-Serializer, 
the tech team needs to enable the Clone feature.
3. Finally, they need to use 
RT-Importerhttps://www.bestpractical.com/docs/rt/4.2/rt-importer.html to 
import the cloned, serialized database from the disk onto the Oracle Database 
with RT4.2 already installed.

Follow-up questions:
Are the utilities described above easily found and operated? I have never seen 
the back end of RT.
How long should the conversion take with a database containing 108,000 tickets?
Are there any errors or issues that I should keep an eye out for when the DBAs 
do the conversion?

I am sorry if this is a basic question, I am not knowledgeable about database 
administration and migrations.

I am looking for any assistance I can get.

Thanks you for your time.

Sincerely,
Greg


[rt-users] Scrip for adding to the custom field based on another CF

2015-01-21 Thread Kevin Squire
I have a scrip currently that checks for status change from X-- Y and if
true, adds an entry to the Custom Field RMA Num.  It adds our RMA number,
which is really just RMA-$RT_Ticket_Number

They have asked me to change the number based on another CF RMA TYPE.  If
the RMA type = Student Withdrawl they want the RMA number to be appended
with WD


My perl skills are limited to copy/paste and tweaking existing so I
would like a little bit of help with my If/Then statement.  The idea being:

IF CustomField{RMA Type} = Student Withdrawl
THEN $Append = -WD
ELSE $Append = 

Then in the current line (below)
 my $Value = RMA- . $Num ;

would be changed to
  my $Value = RMA- . $Num . $Append ;





*Custom action preparation code:*

# Define the Custom Field to Act on
my $CFName = RMA Num;

#Get the RT Ticket Number
my $Num = $self-TicketObj-id();

# Define the desired value for the CF
my $Value = RMA- . $Num ;

$self-TicketObj-AddCustomFieldValue( Field = $CFName, Value = $Value );

return 1;




-- 
http://www.wikiak.org

#
 Associate yourself with men of good quality if you esteem
 your own reputation; for 'tis better to be alone then in bad
 company.- George Washington, Rules of Civility