Mage_Adminhtml_Block_Permissions_Grid_Role Class Reference

Inheritance diagram for Mage_Adminhtml_Block_Permissions_Grid_Role:

Mage_Adminhtml_Block_Widget_Grid Mage_Adminhtml_Block_Widget Mage_Adminhtml_Block_Template Mage_Core_Block_Template Mage_Core_Block_Abstract Varien_Object

List of all members.

Public Member Functions

 __construct ()
 getGridUrl ()
 getRowUrl ($row)

Protected Member Functions

 _prepareCollection ()
 _prepareColumns ()


Detailed Description

Definition at line 34 of file Role.php.


Constructor & Destructor Documentation

__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 36 of file Role.php.

00037     {
00038         parent::__construct();
00039         $this->setId('roleGrid');
00040         $this->setSaveParametersInSession(true);
00041         $this->setDefaultSort('role_id');
00042         $this->setDefaultDir('asc');
00043         $this->setUseAjax(true);
00044     }


Member Function Documentation

_prepareCollection (  )  [protected]

Prepare grid collection object

Returns:
this

Reimplemented from Mage_Adminhtml_Block_Widget_Grid.

Definition at line 46 of file Role.php.

00047     {
00048         $collection =  Mage::getModel("admin/roles")->getCollection();
00049         $this->setCollection($collection);
00050 
00051         return parent::_prepareCollection();
00052     }

_prepareColumns (  )  [protected]

Reimplemented from Mage_Adminhtml_Block_Widget_Grid.

Definition at line 54 of file Role.php.

00055     {
00056 
00057         $this->addColumn('role_id', array(
00058             'header'    =>Mage::helper('adminhtml')->__('ID'),
00059             'index'     =>'role_id',
00060             'align'     => 'right',
00061             'width'    => '50px'
00062         ));
00063 
00064         $this->addColumn('role_name', array(
00065             'header'    =>Mage::helper('adminhtml')->__('Role Name'),
00066             'index'     =>'role_name'
00067         ));
00068 
00069         return parent::_prepareColumns();
00070     }

getGridUrl (  ) 

Reimplemented from Mage_Adminhtml_Block_Widget_Grid.

Definition at line 72 of file Role.php.

00073     {
00074         return $this->getUrl('*/*/roleGrid', array('_current'=>true));
00075     }

getRowUrl ( row  ) 

Definition at line 77 of file Role.php.

00078     {
00079         return $this->getUrl('*/*/editrole', array('rid' => $row->getRoleId()));
00080     }


The documentation for this class was generated from the following file:

Generated on Sat Jul 4 17:22:53 2009 for Magento by  doxygen 1.5.8