diff --git a/controllers/admin/AdminCustomerThreadsController.php b/controllers/admin/AdminCustomerThreadsController.php index 64779bbe7..83740cf38 100644 --- a/controllers/admin/AdminCustomerThreadsController.php +++ b/controllers/admin/AdminCustomerThreadsController.php @@ -349,6 +349,7 @@ class AdminCustomerThreadsControllerCore extends AdminController $current_employee->firstname.' '.$current_employee->lastname, null, null, _PS_MAIL_DIR_, true)) { + $cm->private = 1; $cm->message = $this->l('Message forwarded to').' '.$employee->firstname.' '.$employee->lastname."\n".$this->l('Comment:').' '.$_POST['message_forward']; $cm->add(); } diff --git a/themes/default/js/history.js b/themes/default/js/history.js index d86ac639e..6c8f88cbc 100644 --- a/themes/default/js/history.js +++ b/themes/default/js/history.js @@ -100,15 +100,16 @@ function updateOrderLineDisplay(domCheckbox) } //send a message in relation to the order with ajax -function sendOrderMessage () +function sendOrderMessage() { paramString = "ajax=true"; $('form#sendOrderMessage').find('input, textarea').each(function(){ paramString += '&' + $(this).attr('name') + '=' + encodeURI($(this).val()); }); + $.ajax({ type: "POST", - url: baseUri + "index.php?controller=order-detail", + url: $('form#sendOrderMessage').attr("action"), data: paramString, success: function (msg){ $('#block-order-detail').fadeOut('slow', function() {