rvdlee-salesupply / doctrine-data-fixture-module
A port for ZF3 of Hounddog's original data-fixture code.
0.0.9
2018-03-06 22:15 UTC
Requires
- php: ^7
- doctrine/data-fixtures: ^1.3
- doctrine/doctrine-orm-module: ^1.1
- php-coveralls/php-coveralls: ^2.0
Requires (Dev)
This package is not auto-updated.
Last update: 2024-04-19 02:07:46 UTC
README
Introduction
This is a port for ZF3 of Hounddog's orignal code to make fixtures supported in the form of a CLI command.
Installation
Installation of this module uses composer. For composer documentation, please refer to getcomposer.org.
$ composer require rvdlee-salesupply/doctrine-data-fixture-module
Then open config/application.config.php
and add DoctrineModule
, DoctrineORMModule
and
DoctrineDataFixtureModule
to your modules
Registering Fixtures
To register fixtures with Doctrine module add the fixtures in your configuration.
<?php return [ 'doctrine' => [ 'fixture' => [ __NAMESPACE__ . '_fixture' => __DIR__ . '/../src/' . __NAMESPACE__ . '/Fixture', ] ] ];
Usage
Command Line
Access the Doctrine command line as following from your project root:
$ ./vendor/bin/doctrine-module data-fixture:import