X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Fmodules%2Forder.php;h=fda6bbc7d1612270e661fd8949c485dc1879d19a;hp=8df46153fc3307a7d9aea2c5b4d63e04d9ba9b85;hb=e8ca54fe91872ab95a6ffdc4f1268bf18889021d;hpb=89c00e43d2ce1dd1afe11c2c8485307342805f97 diff --git a/inc/modules/order.php b/inc/modules/order.php index 8df46153fc..fda6bbc7d1 100644 --- a/inc/modules/order.php +++ b/inc/modules/order.php @@ -1,7 +1,7 @@ getConfig('max_send'), - 'subject' => $DATA[0], - 'text' => $DATA[1], - 'payment' => GET_PAYMENT($DATA[3]), - 'category' => GET_CATEGORY($DATA[6]), - 'url' => $DATA[5] - ); + $add = ''; + if (getConfig('order_max_full') == 'ORDER') $add = ', mail_orders=mail_orders+1'; + subtractPoints('order', getMemberId(), $usedPoints); // Send an email to the user - $msg_mem = LOAD_EMAIL_TEMPLATE("order-member", $content, $GLOBALS['userid']); - SEND_EMAIL($email, MEMBER_NEW_QUEUE, $msg_mem); + $message_mem = loadEmailTemplate('order-member', $content, getMemberId()); + sendEmail(getMemberId(), '{--MEMBER_NEW_QUEUE--}', $message_mem); // Notify admins about this - SEND_ADMIN_NOTIFICATION(ADMIN_NEW_QUEUE, "order-admin", $content, $GLOBALS['userid']); + sendAdminNotification('{--ADMIN_NEW_QUEUE--}', 'order-admin', $content, getMemberId()); + + // Create new task (we ignore the task id here) + createNewTask( + '{--ADMIN_NEW_QUEUE--}', + '
'.loadEmailTemplate('order-admin', $content, getMemberId()).'
', + 'MEMBER_ORDER', + getMemberId(), + 0, + false + ); // Output back bottom - LOAD_TEMPLATE("member_order-back", false); + loadTemplate('member_order-back'); } else { - // Matching line not found or already "placed" in send queue - LOAD_URL(URL."/modules.php?module=login"); + // Matching line not found or already 'placed' in send queue + redirectToUrl('modules.php?module=login'); } } else { // Redirect... - LOAD_URL($URL); + redirectToUrl($url); } -// + +// [EOF] ?>