We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a3d7804 + d236242 commit 448475bCopy full SHA for 448475b
README.md
@@ -41,23 +41,24 @@ use Rappasoft\LaravelLivewireTables\Views\Column;
41
42
class UsersTable extends DataTableComponent
43
{
44
-
45
protected $model = User::class;
46
+ public function configure(): void
47
+ {
48
+ $this->setPrimaryKey('id');
49
+ }
50
+
51
public function columns(): array
52
53
return [
54
+ Column::make('ID', 'id')
55
+ ->sortable(),
56
Column::make('Name')
- ->sortable()
- ->searchable(),
- Column::make('E-mail', 'email')
- Column::make('Verified', 'email_verified_at')
57
->sortable(),
58
];
59
}
60
61
62
```
63
64
### [See advanced example](https://rappasoft.com/docs/laravel-livewire-tables/v2/examples/advanced-example)
0 commit comments