Browse Source

Merchant model : ajout d'une méthode permettant de récupérer une config donnée.

reduction
Guillaume 4 years ago
parent
commit
3cb1d30767
1 changed files with 13 additions and 0 deletions
  1. +13
    -0
      ShopBundle/Model/Merchant.php

+ 13
- 0
ShopBundle/Model/Merchant.php View File

return $this; return $this;
} }


public function getMerchantConfig($name)
{
if($this->getMerchantConfigs()) {
foreach($this->getMerchantConfigs() as $merchantConfig) {
if($merchantConfig->getName() == $name) {
return $merchantConfig->getValue() ;
}
}
}

return false ;
}

public function getAddress(): ?Address public function getAddress(): ?Address
{ {
return $this->address; return $this->address;

Loading…
Cancel
Save