// MERGE with 1.4 r7770
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@7776 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -129,24 +129,32 @@ class AdminCustomerThreads extends AdminTab
|
||||
'{messages}' => $output,
|
||||
'{employee}' => $currentEmployee->firstname.' '.$currentEmployee->lastname,
|
||||
'{comment}' => stripslashes($_POST['message_forward']));
|
||||
Mail::Send($context->language->id, 'forward_msg', Mail::l('Fwd: Customer message'), $params,
|
||||
|
||||
if (Mail::Send($context->language->id, 'forward_msg', Mail::l('Fwd: Customer message'), $params,
|
||||
$employee->email, $employee->firstname.' '.$employee->lastname,
|
||||
$currentEmployee->email, $currentEmployee->firstname.' '.$currentEmployee->lastname);
|
||||
$currentEmployee->email, $currentEmployee->firstname.' '.$currentEmployee->lastname,
|
||||
NULL, NULL, _PS_MAIL_DIR_, true))
|
||||
{
|
||||
$cm->message = $this->l('Message forwarded to').' '.$employee->firstname.' '.$employee->lastname."\n".$this->l('Comment:').' '.$_POST['message_forward'];
|
||||
$cm->add();
|
||||
}
|
||||
}
|
||||
elseif (($email = Tools::getValue('email')) AND Validate::isEmail($email))
|
||||
{
|
||||
$params = array(
|
||||
'{messages}' => $output,
|
||||
'{employee}' => $currentEmployee->firstname.' '.$currentEmployee->lastname,
|
||||
'{comment}' => stripslashes($_POST['message_forward']));
|
||||
Mail::Send($context->language->id, 'forward_msg', Mail::l('Fwd: Customer message'), $params,
|
||||
|
||||
if (Mail::Send((int)($cookie->id_lang), 'forward_msg', Mail::l('Fwd: Customer message'), $params,
|
||||
$email, NULL,
|
||||
$currentEmployee->email, $currentEmployee->firstname.' '.$currentEmployee->lastname);
|
||||
$currentEmployee->email, $currentEmployee->firstname.' '.$currentEmployee->lastname,
|
||||
NULL, NULL, _PS_MAIL_DIR_, true))
|
||||
{
|
||||
$cm->message = $this->l('Message forwarded to').' '.$email."\n".$this->l('Comment:').' '.$_POST['message_forward'];
|
||||
$cm->add();
|
||||
}
|
||||
}
|
||||
else
|
||||
echo '<div class="alert error">'.Tools::displayError('Email invalid.').'</div>';
|
||||
}
|
||||
@@ -173,9 +181,13 @@ class AdminCustomerThreads extends AdminTab
|
||||
'{reply}' => Tools::nl2br(Tools::getValue('reply_message')),
|
||||
'{link}' => Tools::url($context->link->getPageLink('contact', true), 'id_customer_thread='.(int)($ct->id).'&token='.$ct->token),
|
||||
);
|
||||
Mail::Send($ct->id_lang, 'reply_msg', Mail::l('An answer to your message is available'), $params, Tools::getValue('msg_email'), NULL, NULL, NULL, $fileAttachment);
|
||||
$ct->status = 'closed';
|
||||
$ct->update();
|
||||
if (Mail::Send($ct->id_lang, 'reply_msg', Mail::l('An answer to your message is available'),
|
||||
$params, Tools::getValue('msg_email'), NULL, NULL, NULL, $fileAttachment, NULL,
|
||||
_PS_MAIL_DIR_, true))
|
||||
{
|
||||
$ct->status = 'closed';
|
||||
$ct->update();
|
||||
}
|
||||
Tools::redirectAdmin(self::$currentIndex.'&id_customer_thread='.(int)$id_customer_thread.'&viewcustomer_thread&token='.Tools::getValue('token'));
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user