/**
  * (non-PHPdoc)
  * @see Mage_Core_Model_Abstract::_afterLoad()
  */
 public function _afterLoad()
 {
     if ($this->getData('customer_type') == 'vendor') {
         $this->vendorModel = Mage::getModel('smvendors/vendor')->loadByCustomerId($this->getId());
         if ($this->vendorModel->getCustomerId() == $this->getId()) {
             $this->getVendorData();
         }
     } else {
         $this->vendorModel = Mage::getModel('smvendors/vendor');
     }
     return parent::_afterLoad();
 }
Esempio n. 2
0
 /**
  *
  * (override from an abstract parent)
  */
 protected function _afterLoad()
 {
     $this->loadCollections();
     return parent::_afterLoad();
 }