Merge branch 'development' of https://github.com/PrestaShop/PrestaShop into bootstrap
Conflicts: admin-dev/themes/default/template/controllers/customers/helpers/view/view.tpl admin-dev/themes/default/template/controllers/modules_positions/form.tpl admin-dev/themes/default/template/controllers/orders/helpers/view/view.tpl admin-dev/themes/default/template/controllers/products/input_text_lang.tpl admin-dev/themes/default/template/controllers/products/shipping.tpl admin-dev/themes/default/template/controllers/shipping/content.tpl admin-dev/themes/default/template/helpers/form/form.tpl admin-dev/themes/default/template/helpers/list/list_header.tpl admin-dev/themes/default/template/toolbar.tpl classes/helper/HelperList.php controllers/admin/AdminCategoriesController.php controllers/admin/AdminManufacturersController.php controllers/admin/AdminModulesPositionsController.php controllers/admin/AdminPerformanceController.php controllers/admin/AdminStockInstantStateController.php css/admin.css js/admin-products.js js/admin.js
This commit is contained in:
@@ -117,43 +117,22 @@ class AdminManufacturersControllerCore extends AdminController
|
||||
|
||||
$this->content .= parent::renderList();
|
||||
}
|
||||
|
||||
public function initListManufacturerAddresses()
|
||||
|
||||
protected function getAddressFieldsList()
|
||||
{
|
||||
$this->toolbar_title = $this->l('Addresses');
|
||||
// reset actions and query vars
|
||||
$this->actions = array();
|
||||
unset($this->fields_list, $this->_select, $this->_join, $this->_group, $this->_filterHaving, $this->_filter);
|
||||
|
||||
$this->table = 'address';
|
||||
$this->identifier = 'id_address';
|
||||
$this->deleted = true;
|
||||
$this->_orderBy = null;
|
||||
|
||||
$this->addRowAction('editaddresses');
|
||||
$this->addRowAction('delete');
|
||||
|
||||
// test if a filter is applied for this list
|
||||
if (Tools::isSubmit('submitFilter'.$this->table) || $this->context->cookie->{'submitFilter'.$this->table} !== false)
|
||||
$this->filter = true;
|
||||
|
||||
// test if a filter reset request is required for this list
|
||||
if (isset($_POST['submitReset'.$this->table]))
|
||||
$this->action = 'reset_filters';
|
||||
else
|
||||
$this->action = '';
|
||||
|
||||
// Sub tab addresses
|
||||
$countries = Country::getCountries($this->context->language->id);
|
||||
foreach ($countries as $country)
|
||||
$this->countries_array[$country['id_country']] = $country['name'];
|
||||
|
||||
$this->fields_list = array(
|
||||
return array(
|
||||
'id_address' => array(
|
||||
'title' => $this->l('ID')
|
||||
),
|
||||
'manufacturer_name' => array(
|
||||
'title' => $this->l('Manufacturer')
|
||||
'title' => $this->l('Manufacturer'),
|
||||
'width' => 'auto',
|
||||
'filter_key' => 'm!name'
|
||||
),
|
||||
'firstname' => array(
|
||||
'title' => $this->l('First name')
|
||||
@@ -176,6 +155,32 @@ class AdminManufacturersControllerCore extends AdminController
|
||||
'filter_key' => 'cl!id_country'
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
public function initListManufacturerAddresses()
|
||||
{
|
||||
$this->toolbar_title = $this->l('Addresses');
|
||||
// reset actions and query vars
|
||||
$this->actions = array();
|
||||
unset($this->fields_list, $this->_select, $this->_join, $this->_group, $this->_filterHaving, $this->_filter);
|
||||
|
||||
$this->table = 'address';
|
||||
$this->list_id = 'address';
|
||||
$this->identifier = 'id_address';
|
||||
$this->deleted = true;
|
||||
$this->_orderBy = null;
|
||||
|
||||
$this->addRowAction('editaddresses');
|
||||
$this->addRowAction('delete');
|
||||
|
||||
// test if a filter is applied for this list
|
||||
if (Tools::isSubmit('submitFilter'.$this->table) || $this->context->cookie->{'submitFilter'.$this->table} !== false)
|
||||
$this->filter = true;
|
||||
|
||||
// test if a filter reset request is required for this list
|
||||
$this->action = (isset($_POST['submitReset'.$this->table]) ? 'reset_filters' : '');
|
||||
|
||||
$this->fields_list = $this->getAddressFieldsList();
|
||||
|
||||
$this->_select = 'cl.`name` as country, m.`name` AS manufacturer_name';
|
||||
$this->_join = '
|
||||
@@ -671,12 +676,13 @@ class AdminManufacturersControllerCore extends AdminController
|
||||
|
||||
public function initProcess()
|
||||
{
|
||||
if (Tools::getValue('submitAddaddress') || Tools::isSubmit('deleteaddress') || Tools::isSubmit('submitBulkdeleteaddress'))
|
||||
if (Tools::getValue('submitAddaddress') || Tools::isSubmit('deleteaddress') || Tools::isSubmit('submitBulkdeleteaddress') || Tools::isSubmit('exportaddress'))
|
||||
{
|
||||
$this->table = 'address';
|
||||
$this->className = 'Address';
|
||||
$this->identifier = 'id_address';
|
||||
$this->deleted = true;
|
||||
$this->fields_list = $this->getAddressFieldsList();
|
||||
}
|
||||
parent::initProcess();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user