protected function updateCurrencyRates(Currency $currency)
    {
        $baseExchangeRate = $this->table[$currency->getCode()];

        foreach ($this->table as $currencySymbol => $exchangeRate) {
            $rate = $this->calculateExchangeRate($baseExchangeRate, $currencySymbol);
            $this->addUpdateExchangeRate($currency->getCode(), $currencySymbol, $rate);
        }

        $this->helper->getEntityManager()->flush();
    }
protected function updateCurrencyRates(Currency $currency)
    {
        $baseExchangeRate = $this->table[$currency->getCode()];

        foreach ($this->table as $currencySymbol => $exchangeRate) {
            $rate = $this->calculateExchangeRate($baseExchangeRate, $currencySymbol);
            $this->addUpdateExchangeRate($currency->getCode(), $currencySymbol, $rate);
        }

        $this->helper->getEntityManager()->flush();
    }
protected function updateCurrencyRates ( Currency $ currency ) { $ baseExchangeRate = $ this -> table [ $ currency -> getCode ( ) ] ; foreach ( $ this -> table as $ currencySymbol => $ exchangeRate ) { $ rate = $ this -> calculateExchangeRate ( $ baseExchangeRate , $ currencySymbol ) ; $ this -> addUpdateExchangeRate ( $ currency -> getCode ( ) , $ currencySymbol , $ rate ) ; } $ this -> helper -> getEntityManager ( ) -> flush ( ) ; }
Updates managed currency with exchange rates

@param Currency $currency
Updates managed currency with exchange rates