kEpEx / laravel-crud-generator

php artisan command to generate fully working crud with grid paginated server side only by having database tables
MIT License
98 stars 44 forks source link

Using Custom Layout - No JavaScript on the footer to Populate the Read table #4

Closed chicagocomputerclasses closed 8 years ago

chicagocomputerclasses commented 8 years ago

First of all, great project!

Tried to extend the one of my own layouts using the command below

php artisan make:crud all --master-layout=layouts.mylayout

Seems to work great overall, adding records works, however, it's missing the JavaScript in the footer that populates from ajax request and fills the records list table.

Is there a particular section I need in my master layout file for this to work other than @yield('content')?

chicagocomputerclasses commented 8 years ago

OK, so it does seem to need @yield('scripts') in addition, but it still doesn't generate dataTables javascript includes, so it needs to be added to the layout manually.

It might be a better idea to include this in a separate file as an include to add in the layout I guess, but then it may interfere with other bootsrap includes above.

kEpEx commented 8 years ago

I'm glad you resolved, yeah probably at least I need to put some documentation to let know this. Sorry for the delay to answer :)

Still a lot of things could be improved, but at least I hope it save you some development time, and if you look for specific features let me know and maybe I implement it