Help Desk Software & Beyond
May 17, 2012, 03:49:31 AM *
Welcome, Guest. Please login or register.
To post messages you need to register. We apologize for inconvenience, but this is to prevent spam.
Registration is instant (no email verification) and we do not ask for any personal information.

Login with username, password and session length
News: Welcome to Help Desk Software forum!
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: [INFO] Transfer Ticket Notifications  (Read 984 times)
vicky
Newbie
*

Karma: 0
Posts: 21


View Profile
« on: July 17, 2009, 11:04:29 PM »

Hello,

 Can any one show me how, Transfer ticket option select the email addresses of operators. I think below is the code used.May be wrong.
If possible can any one explain the below code.
 

Code:
sub transfernotice {
  my $cfg = $_[0]->{cfg};
  my $ticket = $_[0]->{ticket};
  my $o = $cfg->get('_USER');
  return if $o eq undef;
  my $u = TTXUser->new($ticket->{oper});
  return if $u eq undef || $u->{email} eq undef;
  my $quicklink;
  if ($cfg->get('quicklink')) {
    $quicklink = '&o='.$ticket->{oper};
    my $salt = $ticket->{id} % 100;
    $salt = "0$salt" if $salt < 10;
    my $p = crypt($u->{passwd}.$ticket->{id}, $salt);
    $p =~ s/^\d\d//;
    $quicklink .= "&p=$p";
  }
  TTXMail::sendmail(
   {
     to => $u->{email},
     from => "\"".company($cfg, $ticket)."\" <".$cfg->get('email').">",
     subject => TTXDictionary::translate('Ticket transfer notice'),
     msg => '[b]'.TTXDictionary::translate('Ticket ID').':[/b] '.$ticket->{id}."\n".
            '[b]'.TTXDictionary::translate('Subject').':[/b] '.$ticket->{subject}."\n".
            '[b]'.TTXDictionary::translate('Transferred by').':[/b] '.$o->{fname}.' '.$o->{lname}.' ('.$o->{login}.") \n".
            '[b]'.TTXDictionary::translate('Access link').':[/b] '.
            '[url http://'.$ENV{HTTP_HOST}.$ENV{SCRIPT_NAME}.'?cmd=helpdesk&tk='.$ticket->{key}.$quicklink.']'.
            TTXDictionary::translate('Ticket').' '.$ticket->{id}.'[/url]'."\n\n"
   }
  );
}
« Last Edit: July 17, 2009, 11:14:02 PM by Sparky » Logged
Sparky
Moderator
Hero Member
*****

Karma: 83
Posts: 2,228


stop pushing all those buttons


View Profile
« Reply #1 on: July 17, 2009, 11:13:52 PM »

If you're looking for line by line explanations of TTX, here's a good place to start...

http://www.perltutorial.org/
Logged

Did you update the paths in ttxcfg.cgi after moving TTX to your new location?   Undecided
To those seeking help.... please report back when you figure it out.  Cheesy
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1 RC3 | SMF © 2001-2006, Lewis Media Valid XHTML 1.0! Valid CSS!
Page created in 0.02 seconds with 18 queries.