Skip to content

Commit 1e8bcdf

Browse files
author
Dmytro Voskoboinikov
committed
MAGETWO-35620: Implement Observer
1 parent 2724def commit 1e8bcdf

File tree

3 files changed

+6
-3
lines changed
  • app/code/Magento

3 files changed

+6
-3
lines changed

app/code/Magento/Sales/Controller/Adminhtml/Order/Creditmemo/Save.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,9 +95,10 @@ public function execute()
9595
isset($data['comment_customer_notify']),
9696
isset($data['is_visible_on_front'])
9797
);
98+
99+
$creditmemo->setCustomerNote($data['comment_text']);
98100
}
99101

100-
$creditmemo->setCustomerNote($data['comment_text']);
101102
$creditmemo->setCustomerNoteNotify(isset($data['comment_customer_notify']));
102103

103104
if (isset($data['do_refund'])) {

app/code/Magento/Sales/Controller/Adminhtml/Order/Invoice/Save.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,9 +158,10 @@ public function execute()
158158
isset($data['comment_customer_notify']),
159159
isset($data['is_visible_on_front'])
160160
);
161+
162+
$invoice->setCustomerNote($data['comment_text']);
161163
}
162164

163-
$invoice->setCustomerNote($data['comment_text']);
164165
$invoice->setCustomerNoteNotify(isset($data['comment_customer_notify']));
165166

166167
$invoice->register();

app/code/Magento/Shipping/Controller/Adminhtml/Order/Shipment/Save.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,9 +106,10 @@ public function execute()
106106
isset($data['comment_customer_notify']),
107107
isset($data['is_visible_on_front'])
108108
);
109+
110+
$shipment->setCustomerNote($data['comment_text']);
109111
}
110112

111-
$shipment->setCustomerNote($data['comment_text']);
112113
$shipment->setCustomerNoteNotify(isset($data['comment_customer_notify']));
113114

114115
$shipment->register();

0 commit comments

Comments
 (0)