Skip to content

Commit 1cdb1a8

Browse files
ENGCOM-1035: [Foward-Port of #14156] Add website- and storeview-code in stores admin grid #14157
- Merge Pull Request #14157 from aschrammel/magento2:2.3-develop - Merged commits: 1. 6f73126 2. 1e5745d 3. 8004cc5
2 parents 81f7b73 + 8004cc5 commit 1cdb1a8

File tree

4 files changed

+8
-5
lines changed

4 files changed

+8
-5
lines changed

app/code/Magento/Backend/Block/System/Store/Grid/Render/Group.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ public function render(\Magento\Framework\DataObject $row)
2727
$this->getUrl('adminhtml/*/editGroup', ['group_id' => $row->getGroupId()]) .
2828
'">' .
2929
$this->escapeHtml($row->getData($this->getColumn()->getIndex())) .
30-
'</a>';
30+
'</a><br />'
31+
. '(' . __('Code') . ': ' . $row->getGroupCode() . ')';
3132
}
3233
}

app/code/Magento/Backend/Block/System/Store/Grid/Render/Store.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ public function render(\Magento\Framework\DataObject $row)
2727
$this->getUrl('adminhtml/*/editStore', ['store_id' => $row->getStoreId()]) .
2828
'">' .
2929
$this->escapeHtml($row->getData($this->getColumn()->getIndex())) .
30-
'</a>';
30+
'</a><br />' .
31+
'(' . __('Code') . ': ' . $row->getStoreCode() . ')';
3132
}
3233
}

app/code/Magento/Backend/Block/System/Store/Grid/Render/Website.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ public function render(\Magento\Framework\DataObject $row)
2424
$this->getUrl('adminhtml/*/editWebsite', ['website_id' => $row->getWebsiteId()]) .
2525
'">' .
2626
$this->escapeHtml($row->getData($this->getColumn()->getIndex())) .
27-
'</a>';
27+
'</a><br />' .
28+
'(' . __('Code') . ': ' . $row->getCode() . ')';
2829
}
2930
}

app/code/Magento/Store/Model/ResourceModel/Website/Collection.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,11 +138,11 @@ public function joinGroupAndStore()
138138
$this->getSelect()->joinLeft(
139139
['group_table' => $this->getTable('store_group')],
140140
'main_table.website_id = group_table.website_id',
141-
['group_id' => 'group_id', 'group_title' => 'name']
141+
['group_id' => 'group_id', 'group_title' => 'name', 'group_code' => 'code']
142142
)->joinLeft(
143143
['store_table' => $this->getTable('store')],
144144
'group_table.group_id = store_table.group_id',
145-
['store_id' => 'store_id', 'store_title' => 'name']
145+
['store_id' => 'store_id', 'store_title' => 'name', 'store_code' => 'code']
146146
);
147147
$this->addOrder('group_table.name', \Magento\Framework\DB\Select::SQL_ASC) // store name
148148
->addOrder(

0 commit comments

Comments
 (0)