Giter VIP home page Giter VIP logo

voyager-bread-generator's Introduction

Voyager BREAD generator

There is a common issue when we try to deploy local projects to a different environment. Currently, we need to export the database or so, in order to keep all the new BREADs structure across all the environments.

The only way to do that without having to create a database import each time is by creating the migrations, seeds, etc. for each bread.

This allows the developers to create new BREADs from the command line using Artisan.

How to use:

create a new bread

php artisan voyager:bread books

You can also generate the model and migration files

php artisan voyager:bread books --migration --model

Configure the bread

This command will create a new BooksBreadSeeder file with the basic configuration for a new bread-seed, there you can add/edit all the bread fields. See DataRowsTableSeeder

Once the seeder is done you need to run:

php artisan db:seed --class=BooksBreadSeeder

Optionally you need to re-generate the permissions from the command line

php artisan db:seed --class=PermissionRoleTableSeeder

You can also do this manually from the admin panel

Don't forget to run the new migration

php artisan migrate

voyager-bread-generator's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

voyager-bread-generator's Issues

Call to undefined function VoyagerBread\Commands\studly_case()

I need create migration and seeder for my bread, when I run:

bash-5.0# php artisan voyager:bread my_bread --migration

I have this error

Making BREAD

   Symfony\Component\Debug\Exception\FatalThrowableError  : Call to undefined function VoyagerBread\Commands\studly_case()

  at /var/www/html/vendor/voyager-bread-generator/src/Commands/BreadGenerator.php:104
    100|      * @return string
    101|      */
    102|     protected function getNameInput()
    103|     {
  > 104|         return trim(studly_case($this->argument('name')));
    105|     }
    106| 
    107|     /**
    108|      * Create a migration file for the model.

  Exception trace:

  1   VoyagerBread\Commands\BreadGenerator::getNameInput()
      /var/www/html/vendor/laravel/framework/src/Illuminate/Console/GeneratorCommand.php:54

  2   Illuminate\Console\GeneratorCommand::handle()
      /var/www/html/vendor/voyager-bread-generator/src/Commands/BreadGenerator.php:35

  Please use the argument -v to see more details.

Package installation

php artisan hook:install voyager-bread-generator show me error: Could not find package voyager-bread-generator at any version for your minimum-stability (stable) . Check the package spelling or your minimum-stability.

How to use this hook

Hi Guys,

Can someone explain how to use these generator in steps ?

I have my website on my local machine with Voyager admin and everything works fine. What i need to do before i deploy the project ?

Thank you very much in advance

Relationship seeder

I did not find so maybe you can give example how I need to create relationship in my seedee? Also, it will be good if you add documentation for all people.

Cannot install

I can't seem to be able to install this hook. I tried this way:

php artisan hook:install voyager-bread-generator

But I get this nasty error message:

  [InvalidArgumentException]
  Could not find package voyager-bread-generator at any version for your minimum-stability (stable). Check the package spelling or your minimum-stability

I'm running Laravel 5.5 and Voyager 1.0.6 on PHP 7.1

Help?

Not able to run artisan command to create bread

When I run:

php artisan voyager:bread books

I get the following error:

[Symfony\Component\Debug\Exception\FatalThrowableError]
Call to undefined method Illuminate\Console\GeneratorCommand::handle()

Laravel: 5.4
Voyager: 1.0.5

php artisan hook:install voyager-bread-generator error

Hi Guys while installing Voyager-bread-generator, i am getting error can anyone help me please ?

php artisan hook:install voyager-bread-generator

In InitCommand.php line 710:

Could not find package voyager-bread-generator.

Did you mean this?
voyager-bread-generator

`

5.6 Version Bump

Any chance you could bump the required Laravel version to 5.6.*?

how to install this package?

i try "php artisan hook:install voyager-bread-generator" and i got an error "There are no commands defined in the "hook" namespace."

Can't install Bread Generator

When trying to install Voyager Bread Generator using:

php artisan hook:install voyager-bread-generator

I get the following error:

[InvalidArgumentException]
Could not find package voyager-bread-generator at any version for your minimum-stability (stable). Check the package spelling or your minimum-stability

Laravel: 5.5.18
Voyager: 1.0.5

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.