From dd1454804838c0d45c41625e7e877b3f33ec213d Mon Sep 17 00:00:00 2001 From: Quitta Date: Thu, 5 Sep 2013 04:29:47 +0200 Subject: [PATCH] some fixes for the real version --- .../tools/server/ryzom_ams/ams_lib/autoload/helpers.php | 2 +- .../server/ryzom_ams/ams_lib/autoload/mail_handler.php | 6 +++--- .../tools/server/ryzom_ams/ams_lib/autoload/ticket.php | 2 +- .../tools/server/ryzom_ams/ams_lib/autoload/ticket_log.php | 1 - 4 files changed, 5 insertions(+), 6 deletions(-) diff --git a/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/helpers.php b/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/helpers.php index cef808a92..18f34b1d1 100644 --- a/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/helpers.php +++ b/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/helpers.php @@ -81,7 +81,7 @@ class Helpers{ if ( !file_exists( $value ) ){ //echo $value; print($value); - drupal_mkdir($value); + mkdir($value); } } diff --git a/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/mail_handler.php b/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/mail_handler.php index 3a17412e4..4434c62db 100644 --- a/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/mail_handler.php +++ b/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/mail_handler.php @@ -13,11 +13,11 @@ class Mail_Handler{ public static function send_ticketing_mail($receiver, $ticketObj, $content, $type, $sender = 0) { - global $MAIL_LOG_PATH; - error_log("Receiver: {$receiver}, content: {$content}, type: {$type}, SendingId: {$sender} \n", 3, $MAIL_LOG_PATH); + global $TICKET_MAILING_SUPPORT; if($TICKET_MAILING_SUPPORT){ - + global $MAIL_LOG_PATH; + error_log("Receiver: {$receiver}, content: {$content}, type: {$type}, SendingId: {$sender} \n", 3, $MAIL_LOG_PATH); if($sender == 0){ //if it is not forwarded (==public == which returns 0) then make it NULL which is needed to be placed in the DB. $sender = NULL; diff --git a/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/ticket.php b/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/ticket.php index e263ff700..84cda6f0a 100644 --- a/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/ticket.php +++ b/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/ticket.php @@ -87,7 +87,7 @@ class Ticket{ //create the new ticket! $ticket = new Ticket(); - $values = array("Title" => $title, "Status"=> 1, "Queue"=> 0, "Ticket_Category" => $category, "Author" => $author, "Priority" => 0); + $values = array("Title" => $title, "Timestamp"=>0, "Status"=> 1, "Queue"=> 0, "Ticket_Category" => $category, "Author" => $author, "Priority" => 0); $ticket->set($values); $ticket->create(); $ticket_id = $ticket->getTId(); diff --git a/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/ticket_log.php b/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/ticket_log.php index d011049d7..ee6f6b9ef 100644 --- a/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/ticket_log.php +++ b/code/ryzom/tools/server/ryzom_ams/ams_lib/autoload/ticket_log.php @@ -42,7 +42,6 @@ class Ticket_Log{ $instanceLog->setAuthor($instanceAuthor); $instanceLog->setTicket($ticket_id); $instanceLog->setQuery($log['Query']); - $result[] = $instanceLog; } return $result;