Skip to content

Commit b57ba27

Browse files
committed
Update customer name fields in OrdersService and invoice settings
1 parent 581e9bd commit b57ba27

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

app/Services/OrdersService.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -2479,7 +2479,8 @@ public function orderTemplateMapping($option, Order $order)
24792479
'order_code' => $order->code,
24802480
'order_type' => $this->getTypeLabel($order->type),
24812481
'order_date' => ns()->date->getFormatted($order->created_at),
2482-
'customer_name' => $order->customer->name,
2482+
'customer_first_name' => $order->customer->first_name,
2483+
'customer_last_name' => $order->customer->last_name,
24832484
'customer_email' => $order->customer->email,
24842485
'shipping_' . 'first_name' => $order->shipping_address->first_name,
24852486
'shipping_' . 'last_name' => $order->shipping_address->last_name,

app/Settings/invoice-settings/receipts.php

+4-2
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,8 @@
6262
__('{order_code}: displays the order code.'), '<br>',
6363
__('{order_date}: displays the order date.'), '<br>',
6464
__('{order_type}: displays the order type.'), '<br>',
65-
__('{customer_name}: displays the customer name.'), '<br>',
65+
__('{customer_first_name}: displays the customer first name.'), '<br>',
66+
__('{customer_last_name}: displays the customer last name.'), '<br>',
6667
__('{customer_email}: displays the customer email.'), '<br>',
6768
__('{shipping_first_name}: displays the shipping first name.'), '<br>',
6869
__('{shipping_last_name}: displays the shipping last name.'), '<br>',
@@ -100,7 +101,8 @@
100101
__('{order_code}: displays the order code.') . '<br>',
101102
__('{order_date}: displays the order date.') . '<br>',
102103
__('{order_type}: displays the order type.'), '<br>',
103-
__('{customer_name}: displays the customer name.') . '<br>',
104+
__('{customer_first_name}: displays the customer first name.') . '<br>',
105+
__('{customer_last_name}: displays the customer last name.') . '<br>',
104106
__('{customer_email}: displays the customer email.') . '<br>',
105107
__('{shipping_first_name}: displays the shipping first name.') . '<br>',
106108
__('{shipping_last_name}: displays the shipping last name.') . '<br>',

0 commit comments

Comments
 (0)