Автозамены регионов
This commit is contained in:
@@ -16,7 +16,7 @@ class ControllerCommonFooter extends Controller {
|
||||
}
|
||||
}
|
||||
|
||||
$data['contact'] = $this->url->link('information/contact');
|
||||
$data['contact'] = $this->url->link('information/contact', '', true);
|
||||
$data['return'] = $this->url->link('account/return/add', '', true);
|
||||
$data['sitemap'] = $this->url->link('information/sitemap');
|
||||
$data['tracking'] = $this->url->link('information/tracking');
|
||||
@@ -28,6 +28,7 @@ class ControllerCommonFooter extends Controller {
|
||||
$data['order'] = $this->url->link('account/order', '', true);
|
||||
$data['wishlist'] = $this->url->link('account/wishlist', '', true);
|
||||
$data['newsletter'] = $this->url->link('account/newsletter', '', true);
|
||||
$data['text_contacts'] = $this->language->get('text_contacts');
|
||||
|
||||
$data['powered'] = sprintf($this->language->get('text_powered'), $this->config->get('config_name'), date('Y', time()));
|
||||
|
||||
@@ -60,6 +61,12 @@ foreach(['name','email','telephone','address','open', 'comment'] as $item){
|
||||
$data['config_' . $item] = $this->config->get('config_' . $item);
|
||||
}
|
||||
|
||||
$this->load->model('localisation/zone');
|
||||
|
||||
foreach ($this->model_localisation_zone->getContacts() as $field => $value) {
|
||||
$data['config_' . $field] = $value;
|
||||
}
|
||||
|
||||
$data['scripts'] = $this->document->getScripts('footer');
|
||||
$data['styles'] = $this->document->getStyles('footer');
|
||||
|
||||
|
||||
@@ -109,6 +109,13 @@ foreach(['name','email','telephone','address','open', 'comment'] as $item){
|
||||
$zones = $this->model_localisation_zone->getZonesByCountryId($country_id);
|
||||
|
||||
$current_zone_id = isset($this->session->data['city_id']) ? (int)$this->session->data['city_id'] : (int)$this->config->get('config_zone_id');
|
||||
$contacts = $this->model_localisation_zone->getContacts($current_zone_id);
|
||||
|
||||
foreach ($contacts as $field => $value) {
|
||||
$data['config_' . $field] = $value;
|
||||
}
|
||||
|
||||
$data['telephone'] = $contacts['telephone'];
|
||||
|
||||
$data['current_city_name'] = '';
|
||||
foreach ($zones as $zone) {
|
||||
|
||||
Reference in New Issue
Block a user