appworldbr/voyager-bread-extractor

Extract Voyager BREAD from database to Seeder file.

1.1.4 2020-07-22 19:32 UTC

README

Extract Voyager BREAD from database to Seeder File.

Getting Started

Prerequisites

  • Laravel
  • Voyager

Installing

composer require appworldbr/voyager-bread-extractor

Usage

After create the BREAD manually, run php artisan voyager:extract ModelWithNamespace

ex.


php artisan voyager:extract App/Models/Products/Product

Them a file in database/seeds will be created with data_types, data_row, menu_item, permissions and BREAD translation seeds.

After that, if you want to migrate with this seed, first you will need run composer dump-autoload (read more) and them run php artisan db:seed --class=CLASSNAME (read more).

php artisan db:seed --class=ProductsBREADTableSeeder

or you can add the Seeder file in DatabaseSeeder.php file (read more)

and them run php artisan db:seed (read more)

Authors

  • Marcelo Araujo Jr - Initial work - AppWorld

License

This project is licensed under the MIT License - see the LICENSE.md file for details