コード例 #1
0
ファイル: ContactImportHelper.php プロジェクト: dairdr/crm
 /**
  * @param ContactAddress $contactAddress
  */
 public function prepareAddress(ContactAddress $contactAddress)
 {
     // at this point imported address region have code equal to region_id in magento db field
     $mageRegionId = $contactAddress->getRegion() ? $contactAddress->getRegion()->getCode() : null;
     $contactAddress->setId(null);
     $this->addressImportHelper->updateAddressCountryRegion($contactAddress, $mageRegionId);
     $this->addressImportHelper->updateAddressTypes($contactAddress);
 }
コード例 #2
0
ファイル: BaseStrategy.php プロジェクト: dairdr/crm
 /**
  * @param AbstractAddress $address
  * @param int             $mageRegionId
  *
  * @return $this
  */
 protected function updateAddressCountryRegion(AbstractAddress $address, $mageRegionId)
 {
     $this->addressHelper->updateAddressCountryRegion($address, $mageRegionId);
     return $this;
 }