_initContactFields(); $this->_initMemberFields(); $this->getElement('password')->setRequired(false); $this->getElement('confirmPassword')->setRequired(false); $this->getElement('password')->setDescription('Leave blank to keep current password unchanged'); $this->getElement('confirmPassword')->setDescription('Leave blank to keep current password unchanged'); $this->_initBillingShippingFields(); return $this; } protected function _prepareData($data = null) { $data = parent::_prepareData($data); $this->_initAddressData($data); return $data; } protected function _initAddressData(array &$data) { if (($sameAs = $data[AddressEntity::TYPE_SHIPPING]['sameAs'])) { $data[AddressEntity::TYPE_SHIPPING] = array_merge(compact('sameAs'), $data[$sameAs]); } return $this; } protected function _initMemberFields() { parent::_initMemberFields(); $this->getElement('securityAnswer') ->setRequired(false) ->setDescription('Leave blank to keep current answer unchanged'); return $this; } }