leantony / laravel-grid

A grid view for laravel, inspired by the yii2 grid widget
https://leantony.github.io/laravel-grid/
MIT License
91 stars 39 forks source link

laravel 5.7 sort don't work #90

Open alexeydg opened 5 years ago

alexeydg commented 5 years ago

subj

alexeydg commented 5 years ago

+bug

php artisan vendor:publish --provider="Leantony\Grid\Providers\GridServiceProvider" --tag="views" These will be copied to resources/views/vendor/leantony/grid. From there, you can change what you want and laravel will automatically use that, instead of the one from the package.

don't work. i changed files resources/views/vendor/leantony/grid, but laravel use /vendor/leantony/laravel-grid/src/resources/views]

sorting and filtering don't working

Nuranto commented 5 years ago

+1 @alexeydg did you find the source of the sort/filter problem ? I will have a look when I get some time.

alexeydg commented 5 years ago

I found a mistake. I renamed $name with Russian letters, in this case nothing works, in Grid.php you need to make changes to the init () method: Str :: singular (Str :: camel (Str::slug($ this-> name))). '-'. 'grid';

dayota commented 5 years ago

@alexeydg if you want to change only rendered title with russian letter you can just overwrite the renderTitle method of RendersGrid trait in your grid class. I'm not sure it's the best way, i made this to only change rendered title without other change.