Production release
This commit is contained in:
11
webhook.php
11
webhook.php
@@ -6,6 +6,7 @@ define('interface', true);
|
||||
// Includes
|
||||
//+++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
include './custom/settings/config.php';
|
||||
include './custom/settings/translations_mapping.php';
|
||||
include './functions.php';
|
||||
|
||||
//+++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
@@ -76,7 +77,15 @@ try {
|
||||
//++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
//Send the invoice when status is Paid
|
||||
//++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
$invoice_language = strtoupper($invoice_cust['customer']['language']!= '' ? $invoice_cust['customer']['language'] : $responses['language']);
|
||||
|
||||
// Determine invoice language
|
||||
if (!empty($invoice_cust['customer']['language'])) {
|
||||
$invoice_language = strtoupper($invoice_cust['customer']['language']);
|
||||
} elseif (!empty($invoice_cust['customer']['country']) && isset($available_languages[strtoupper($invoice_cust['customer']['country'])])) {
|
||||
$invoice_language = $available_languages[strtoupper($invoice_cust['customer']['country'])];
|
||||
} else {
|
||||
$invoice_language = 'US'; // Default fallback
|
||||
}
|
||||
|
||||
list($data,$customer_email,$order_id) = generateInvoice($invoice_cust,$orderId,$invoice_language);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user