Public Member Functions | |
__construct () | |
getRowUrl ($row) | |
Protected Member Functions | |
_prepareCollection () | |
_prepareColumns () |
Definition at line 34 of file Grid.php.
__construct | ( | ) |
Constructor
By default is looking for first argument as array and assignes it as object attributes This behaviour may change in child classes
Reimplemented from Varien_Object.
Definition at line 37 of file Grid.php.
00038 { 00039 parent::__construct(); 00040 $this->setId('ratingsGrid'); 00041 $this->setDefaultSort('rating_code'); 00042 $this->setDefaultDir('ASC'); 00043 $this->setSaveParametersInSession(true); 00044 }
_prepareCollection | ( | ) | [protected] |
Prepare grid collection object
Reimplemented from Mage_Adminhtml_Block_Widget_Grid.
Definition at line 46 of file Grid.php.
00047 { 00048 $collection = Mage::getModel('rating/rating') 00049 ->getResourceCollection() 00050 ->addEntityFilter(Mage::registry('entityId')); 00051 $this->setCollection($collection); 00052 return parent::_prepareCollection(); 00053 }
_prepareColumns | ( | ) | [protected] |
Reimplemented from Mage_Adminhtml_Block_Widget_Grid.
Definition at line 55 of file Grid.php.
00056 { 00057 $this->addColumn('rating_id', array( 00058 'header' => Mage::helper('rating')->__('ID'), 00059 'align' =>'right', 00060 'width' => '50px', 00061 'index' => 'rating_id', 00062 )); 00063 00064 $this->addColumn('rating_code', array( 00065 'header' => Mage::helper('rating')->__('Rating Name'), 00066 'align' =>'left', 00067 'index' => 'rating_code', 00068 )); 00069 00070 return parent::_prepareColumns(); 00071 }
getRowUrl | ( | $ | row | ) |