Mage_GoogleBase_Block_Adminhtml_Types_Grid Class Reference

Inheritance diagram for Mage_GoogleBase_Block_Adminhtml_Types_Grid:

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 ()
 getRowUrl ($row)
 getGridUrl ()

Protected Member Functions

 _prepareCollection ()
 _prepareColumns ()


Detailed Description

Definition at line 34 of file Grid.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 Grid.php.

00037     {
00038         parent::__construct();
00039         $this->setId('types_grid');
00040         $this->setSaveParametersInSession(true);
00041         $this->setUseAjax(true);
00042     }


Member Function Documentation

_prepareCollection (  )  [protected]

Prepare grid collection object

Returns:
this

Reimplemented from Mage_Adminhtml_Block_Widget_Grid.

Definition at line 44 of file Grid.php.

00045     {
00046         $collection = Mage::getResourceModel('googlebase/type_collection')->addItemsCount();
00047         $this->setCollection($collection);
00048         parent::_prepareCollection();
00049         return $this;
00050     }

_prepareColumns (  )  [protected]

Reimplemented from Mage_Adminhtml_Block_Widget_Grid.

Definition at line 52 of file Grid.php.

00053     {
00054         $this->addColumn('attribute_set_name',
00055             array(
00056                 'header'    => $this->__('Attributes Set'),
00057                 'width'     => '150px',
00058                 'index'     => 'attribute_set_name',
00059         ));
00060 
00061         $this->addColumn('gbase_itemtype',
00062             array(
00063                 'header'    => $this->__('Google Base Item type'),
00064                 'width'     => '150px',
00065                 'index'     => 'gbase_itemtype',
00066         ));
00067 
00068         $this->addColumn('target_country',
00069             array(
00070                 'header'    => $this->__('Target Country'),
00071                 'width'     => '150px',
00072                 'index'     => 'target_country',
00073                 'renderer'  => 'googlebase/adminhtml_types_renderer_country',
00074                 'filter'    => false
00075         ));
00076 
00077         $this->addColumn('items_total',
00078             array(
00079                 'header'    => Mage::helper('catalog')->__('Total Qty Base Items'),
00080                 'width'     => '150px',
00081                 'index'     => 'items_total',
00082                 'filter'    => false
00083         ));
00084 
00085         return parent::_prepareColumns();
00086     }

getGridUrl (  ) 

Reimplemented from Mage_Adminhtml_Block_Widget_Grid.

Definition at line 93 of file Grid.php.

00094     {
00095         return $this->getUrl('*/*/grid', array('_current'=>true));
00096     }

getRowUrl ( row  ) 

Definition at line 88 of file Grid.php.

00089     {
00090         return $this->getUrl('*/*/edit', array('id'=>$row->getId(), '_current'=>true));
00091     }


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

Generated on Sat Jul 4 17:24:14 2009 for Magento by  doxygen 1.5.8