add JasonTable class

This commit is contained in:
2024-08-02 15:40:13 +03:00
parent 67a3f5770e
commit f53346610e
5 changed files with 80 additions and 103 deletions

View File

@ -7,7 +7,8 @@ use Itguild\Tables\ListJsonTable;
$json = file_get_contents('simple.json');
$table = new ListJsonTable($json);
$table->columns([
//$table->columns([
$table->setBeforePrintCell([
'status' => function ($ceil) {
return getStatusLabel()[$ceil];
},

View File

@ -7,7 +7,8 @@ use Itguild\Tables\ViewJsonTable;
$json = file_get_contents('view.json');
$table = new ViewJsonTable($json);
$table->rows([
//$table->rows([
$table->setBeforePrintCell([
'username' => function ($ceil) {
return "<span style='color: aqua'>$ceil</span>";
},