-
-
Notifications
You must be signed in to change notification settings - Fork 853
Closed
yajra/laravel-datatables-html
#230Labels
Description
Summary of problem or feature request
Error
Declaration of Yajra\DataTables\Html\Column::data(array|string $value): static must be compatible with Illuminate\Support\Fluent::data($key = null, $default = null)
Code snippet of problem
File vendor/yajra/laravel-datatables-html/src/Html/Column.php, function data (line 305 - 310) was the reason:
public function data(array|string $value): static
{
$this->attributes['data'] = $value;
return $this;
}System details
- Operating System: Mac OS 15
- PHP Version: 8.3
- Laravel Version: laravel/framework ^11.34
- Laravel-Datatables Version: yajra/laravel-datatables ^11.0
Solution
File vendor/yajra/laravel-datatables-html/src/Html/Column.php, change function data (line 305 - 310) to:
public function data($key = null, $default = null): static
{
$this->attributes['data'] = $key;
return $this;
}FarhanSharesOzanKurtvipertecpro, alberto-morais-oliveira-f, baonguyen212002, goentur, OzanKurt and 1 more