Ejemplo n.º 1
0
 /**
  * Retrieve information about customer
  * Add last logged in datetime
  *
  * @throws Mage_Api2_Exception
  * @return array
  */
 protected function _retrieve()
 {
     /** @var $log Mage_Log_Model_Customer */
     $log = Mage::getModel('log/customer');
     $log->loadByCustomer($this->getRequest()->getParam('id'));
     $data = parent::_retrieve();
     $data['is_confirmed'] = (int) (!(isset($data['confirmation']) && $data['confirmation']));
     $lastLoginAt = $log->getLoginAt();
     if (null !== $lastLoginAt) {
         $data['last_logged_in'] = $lastLoginAt;
     }
     return $data;
 }
Ejemplo n.º 2
0
Archivo: V1.php Proyecto: quyip8818/Mag
 /**
  * Retrieve information about customer
  *
  * @throws Mage_Api2_Exception
  * @return array
  */
 protected function _retrieve()
 {
     if ($this->_isOwner($this->getRequest()->getParam('id'))) {
         return parent::_retrieve();
     }
 }