Releases: Okipa/laravel-table
Releases · Okipa/laravel-table
1.2.6
1.2.5
- Fixed the translations publication and overriding as specified on the Laravel documentation : https://laravel.com/docs/packages#translations.
- Changed the command to publish the translations to :
php artisan vendor:publish --tag=laravel-table:translations
- Changed the command to publish the configuration to :
php artisan vendor:publish --tag=laravel-table:config
- Changed the command to publish the views to :
php artisan vendor:publish --tag=laravel-table:views
- Improved testing with Travis CI (added some tests with
--prefer-lowest
composer tag to check the package compatibility with the lowest dependencies versions).
1.2.4
1.2.3
- The model is now directly passed to the route during the table
show
,edit
anddestroy
routes generation instead of its id.
// assuming your declared your edit route like this :
(new Table)->model(User::class)->routes([
// ...
'edit' => ['name'=> 'user.edit', 'params' => ['foo' => 'bar']],
//...
])
// the route will be generated like this during the table instantiation :
route('user.edit, [$user, 'foo' => 'bar']);
// instead of this way
route('user.edit, [$user->id, 'foo' => 'bar']);
1.2.2
- Fixed params order when generating the table routes. The table model id was not positioned at first when declaring other parameters.
// with a route declared like this :
Route::get('user/edit/{user}/{foo}', 'UsersController@edit')->name('user.edit');
// and a table routes declaration like this :
(new Table)->model(User::class)->routes([
// ...
'edit' => ['name'=> 'user.edit', 'params' => ['bar']],
//...
])
// the route is now correctly generated and gives : /user/edit/1/bar instead of /user/edit/bar/1
1.2.1
- Fixed the
show
,edit
anddestroy
route generation, since Laravel 6 does handle differently the key given in theroute()
helper call :
// assuming your declared your edit route like this :
(new Table)->model(User::class)->routes([
// ...
'edit' => ['name'=> 'user.edit', 'params' => ['foo' => 'bar']],
//...
])
// the route will be generated like this during the table instantiation :
route('user.edit, [$user->id, 'foo' => 'bar']);
// instead of this way
route('user.edit, ['id' => $user->id, 'foo' => 'bar']);
1.2.0
1.1.0
- Added the possibility to add an identifier to a table with
->identifier('your identifier')
. This identifier will be used for several things :- It will be added as an id (formatted as a slug string) to the table itself.
- It will be used to automatically customize the following interaction fields sent to the table, in order to be able to interact with a specific table if you have several of them on a single view :
rows
,search
,sort_by
,sort_dir
.
⚠️ if you have published the views, you will have to re-publish them.