simpod/doctrine-money

This package is abandoned and no longer maintained. No replacement package was suggested.

Doctrine mapping support for MoneyPHP

v0.1 2018-03-24 15:06 UTC

README

The project is abandoned. Avoid embeddables and use brick/money. No Doctrine types needed.

Doctrine Money

Build Status Quality Score Code Coverage GitHub Issues

Installation

composer require simpod/doctrine-money

Use

doctrine:
    orm:
        mappings:
            Money:
                dir: "%kernel.project_dir%/../vendor/simpod/doctrine-money/src/doctrine/orm"
                prefix: Money
                type: xml

Then in entity you can add property of type Money\Money:

/**
 * @var Money
 * @ORM\Embedded(class="Money\Money")
 */
private $money;