GX-Bug #54286 » ShippingAndPaymentMatrixCountryNameFix.patch
| src/GXMainComponents/Controllers/HttpView/AdminAjax/ShippingPaymentMatrixAjaxController.inc.php (revision ) | ||
|---|---|---|
| 16 | 16 |
public function actionGetCountryList() |
| 17 | 17 |
{
|
| 18 | 18 |
$db = StaticGXCoreLoader::getDatabaseQueryBuilder(); |
| 19 | ||
| 20 |
$languageTextManager = MainFactory::create_object('LanguageTextManager', array('countries', $_SESSION['languages_id']));
|
|
| 21 | ||
| 19 | 22 |
$countriesData = $db->select() |
| 20 | 23 |
->from('countries')
|
| 21 | 24 |
->join('languages', 'countries.countries_iso_code_2 = languages.code', 'left')
|
| ... | ... | |
| 47 | 50 |
'id' => $country['countries_id'], |
| 48 | 51 |
'languageId' => $country['languages_id'], |
| 49 | 52 |
'code' => $country['countries_iso_code_2'], |
| 50 |
'name' => $country['countries_name'],
|
|
| 53 |
'name' => $languageTextManager->get_text($country['countries_iso_code_2']),
|
|
| 51 | 54 |
'active' => (int)$country['status'] === 1 || $active, |
| 52 | 55 |
'data' => count($oldData) > 0 ? $oldData : null |
| 53 | 56 |
]; |