Fixing some examples

This commit is contained in:
David
2025-05-03 01:57:26 -04:00
parent 9f12bc28d0
commit d64e9c00be
13 changed files with 132 additions and 29 deletions

View File

@@ -0,0 +1,26 @@
<?php
namespace App\Tables;
use App\Models\SubDepartment;
use Mmt\GenericTable\Components\Column;
use Mmt\GenericTable\Components\ColumnCollection;
use Mmt\GenericTable\Interfaces\IDragDropReordering;
use Mmt\GenericTable\Interfaces\IGenericTable;
use Mmt\GenericTable\Support\GenericTableSettings;
class SubDepartmentsTable implements IGenericTable
{
public GenericTableSettings $tableSettings;
public function __construct()
{
$columns = new ColumnCollection();
$columns->add(new Column("Id", 'id as uid'));
$columns->add(new Column("Sub Department Name", 'name'));
$columns->add(new Column("Status"));
$columns->add(new Column("Department Name", 'department.name'));
$this->tableSettings = new GenericTableSettings(new SubDepartment(), $columns);
}
}