Symfony bundle for 99designs/money-php.
Adds exchange rate entity and a service for conversion.
"require": {
"astina/money-bundle":"dev-master",
}
Enable the bundle in the kernel:
<?php
// app/AppKernel.php
public function registerBundles()
{
$bundles = array(
// ...
new Astina\Bundle\MoneyBundle\AstinaMoneyBundle(),
);
}
##Usage
Note*: CurrencyExchangeRate entities need to be created for the exchanges you need.
$moneyChf = new Money\Money(190, 'CHF');
$moneyConverter = $container->get('astina_money.money_converter');
$moneyEur = $moneyConverter->convert($money, 'EUR');
How can I help you explore Laravel packages today?