Mage_Tag_Block_Customer_Recent Class Reference

Inheritance diagram for Mage_Tag_Block_Customer_Recent:

Mage_Core_Block_Template Mage_Core_Block_Abstract Varien_Object

List of all members.

Public Member Functions

 count ()
 getCollection ()
 dateFormat ($date)
 getAllTagsUrl ()

Protected Member Functions

 _construct ()
 _getCollection ()
 _toHtml ()

Protected Attributes

 $_collection


Detailed Description

Definition at line 35 of file Recent.php.


Member Function Documentation

_construct (  )  [protected]

Internal constructor, that is called from real constructor

Please override this one instead of overriding real __construct constructor

Please override this one instead of overriding real __construct constructor

Reimplemented from Mage_Core_Block_Abstract.

Definition at line 39 of file Recent.php.

00040     {
00041         parent::_construct();
00042 
00043         $this->_collection = Mage::getModel('tag/tag')->getEntityCollection()
00044             ->addStoreFilter(Mage::app()->getStore()->getId())
00045             ->addCustomerFilter(Mage::getSingleton('customer/session')->getCustomerId())
00046             ->setDescOrder()
00047             ->setPageSize(5)
00048             ->setActiveFilter()
00049             ->load()
00050             ->addProductTags();
00051     }

_getCollection (  )  [protected]

Definition at line 58 of file Recent.php.

00059     {
00060         return $this->_collection;
00061     }

_toHtml (  )  [protected]

Render block HTML

Returns:
string

Reimplemented from Mage_Core_Block_Template.

Definition at line 78 of file Recent.php.

00079     {
00080         if ($this->_collection->getSize() > 0) {
00081             return parent::_toHtml();
00082         }
00083         return '';
00084     }

count (  ) 

Definition at line 53 of file Recent.php.

00054     {
00055         return $this->_collection->getSize();
00056     }

dateFormat ( date  ) 

Definition at line 68 of file Recent.php.

00069     {
00070         return $this->formatDate($date, Mage_Core_Model_Locale::FORMAT_TYPE_SHORT);
00071     }

getAllTagsUrl (  ) 

Definition at line 73 of file Recent.php.

00074     {
00075         return Mage::getUrl('tag/customer');
00076     }

getCollection (  ) 

Definition at line 63 of file Recent.php.

00064     {
00065         return $this->_getCollection();
00066     }


Member Data Documentation

$_collection [protected]

Definition at line 37 of file Recent.php.


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

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