priceCurrency = $priceCurrency; } /** * Convert and format price value for current application store * * @param float $value * @param bool $format * @param bool $includeContainer * @return float|string */ public function currency($value, $format = true, $includeContainer = true) { return $format ? $this->priceCurrency->convertAndFormat($value, $includeContainer) : $this->priceCurrency->convert($value); } /** * Convert and format price value for specified store * * @param float $value * @param int|\Magento\Store\Model\Store $store * @param bool $format * @param bool $includeContainer * @return float|string */ public function currencyByStore($value, $store = null, $format = true, $includeContainer = true) { if ($format) { $value = $this->priceCurrency->convertAndFormat( $value, $includeContainer, PriceCurrencyInterface::DEFAULT_PRECISION, $store ); } else { $value = $this->priceCurrency->convert($value, $store); } return $value; } }