Download the PHP package it-blaster/fixtures-bundle without Composer
On this page you can find all versions of the php package it-blaster/fixtures-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download it-blaster/fixtures-bundle
More information about it-blaster/fixtures-bundle
Files in it-blaster/fixtures-bundle
Package fixtures-bundle
Short Description Symfony2 bundle for propel fixtures
License MIT
Homepage https://github.com/it-blaster/fixtures-bundle
Informations about the package fixtures-bundle
FixturesBundle
Symfony2 bundle for propel fixtures.
Т.к. обычный таск propel:fixtures:load
выдаёт ошибку Attempted to call method "getPeerClassname" on class "Propel\Runtime\Map\TableMap".
, чтобы его поправить пришлось переопределить таск и файлы папки DataFixtures/Loader
.
Всё это вынесено в отдельный бандл FixturesBundle.
Installation
Добавьте ItBlasterFixturesBundle в composer.json
:
Теперь запустите композер, чтобы скачать бандл командой:
Композер установит бандл в папку проекта vendor/it-blaster/fixtures-bundle
.
Далее подключите бандл в ядре AppKernel.php
:
Dump - Создание фикстур
Таск создания fixtures запускается командой php app/console it-blaster:fixtures:dump
. Файл с фикстурами будет создан в app/propel/fixtures
.
Load - Загрузка из фикстур в базу
Таск загрузки fixtures запускается командой php app/console it-blaster:fixtures:load @AppMainBundle
, где @AppMainBundle имя бандла, где у вас лежат файлы-fixtures. По умолчанию файлы-fixtures будут браться из папки app/propel/fixtures
.
Credits
It-Blaster [email protected]
All versions of fixtures-bundle with dependencies
propel/propel Version ~2.0@dev
propel/propel-bundle Version >=1.4
propel/propel1 Version ~1.6