Skip to content

Commit

Permalink
https://github.com/jayelkaake/enhancedgrid/pull/69
Browse files Browse the repository at this point in the history
  • Loading branch information
rjocoleman committed Jan 10, 2021
1 parent 82dc67a commit 6c7c51c
Showing 1 changed file with 6 additions and 15 deletions.
21 changes: 6 additions & 15 deletions app/code/community/TBT/Enhancedgrid/Block/Catalog/Product/Grid.php
Original file line number Diff line number Diff line change
Expand Up @@ -266,12 +266,7 @@ protected function loadColumnOptions($attr_code)
protected function _getStore()
{
$storeId = (int) $this->getRequest()->getParam('store', 0);
$store = Mage::app()->getStore($storeId);
if ($store->getId() != $storeId) {
$store = Mage::app()->getStore(0);
}

return $store;
return Mage::app()->getStore($storeId);
}

protected function _addColumnFilterToCollection($column)
Expand Down Expand Up @@ -667,19 +662,15 @@ protected function _prepareMassaction()

public function getRowUrl($row)
{
//@nelkaake -m 16/11/10: Changed to use _getStore function
return $this->getUrl('adminhtml/catalog_product/edit',
array(
'store' => $this->_getStore(),
'id' => $row->getId(),
));
return $this->getUrl('*/*/edit', array(
'store'=>$this->getRequest()->getParam('store'),
'id'=>$row->getId())
);
}

public function getGridUrl()
{
return $this->getUrl('adminhtml/*/grid', array(
'_current' => true,
));
return $this->getUrl('*/*/grid', array('_current'=>true));
}

protected function getMADivider($dividerHeading = '-------')
Expand Down

0 comments on commit 6c7c51c

Please sign in to comment.