Download the PHP package padam87/money-bundle without Composer
On this page you can find all versions of the php package padam87/money-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download padam87/money-bundle
More information about padam87/money-bundle
Files in padam87/money-bundle
Download padam87/money-bundle
More information about padam87/money-bundle
Files in padam87/money-bundle
Vendor padam87
Package money-bundle
Short Description Symfony bundle for https://github.com/moneyphp/money
License MIT
Package money-bundle
Short Description Symfony bundle for https://github.com/moneyphp/money
License MIT
Please rate this library. Is it a good library?
Informations about the package money-bundle
MoneyBundle
Symfony bundle for https://github.com/moneyphp/money
As an opinionated bundle, this money bundle uses the following principles as it's main guide:
- Storage is just as important as calculation.
- Financial data should be held in SQL, so Doctrine ORM only implementation.
- Money objects are Embeddables.
- Amount should be stored in a human readable way in the database.
- ISO money scale (eg smallest amount is 1 cent for EUR) is not viable for complex applications.
To achieve these, the following restrictions apply:
- precision and scale are mandatory (but have default values)
- amounts are mapped as DECIMAL (changable, but not recommended to change)
- ext-bcmath is mandatory.
(DECIMAL database values are converted to string by PDO.
This bundle uses bcmath to multiple these values by ˙pow(10, $scale)˙, and pass integer values to the
Money
object. https://github.com/Padam87/MoneyBundle/blob/master/Doctrine/Type/MoneyAmountType.php#L45)
Installation
composer require padam87/money-bundle
Configuration (optional)
Usage
Doctrine
Formatting
The bundle adds 2 services.
padam87_money.number_formatter
- A simple \NumberFormatter
object, with the current request's locale, and currency style.
Money\Formatter\IntlMoneyFormatter
- Intl money formatter
All versions of money-bundle with dependencies
PHP Build Version
Package Version
Requires
php Version
^7.4 || ^8.0
ext-bcmath Version *
symfony/framework-bundle Version ^4.0 || ^5.0 || ^6.0
moneyphp/money Version ^3.1
doctrine/orm Version ^2.5
doctrine/doctrine-bundle Version ^1.5 || ^2.0
ext-bcmath Version *
symfony/framework-bundle Version ^4.0 || ^5.0 || ^6.0
moneyphp/money Version ^3.1
doctrine/orm Version ^2.5
doctrine/doctrine-bundle Version ^1.5 || ^2.0
The package padam87/money-bundle contains the following files
Loading the files please wait ....