backend/kernel/modules/module_shop_client/views/view.php
2024-10-29 14:53:52 +03:00

32 lines
897 B
PHP

<?php
/**
* @var array $data
*/
use kernel\IGTabel\btn\DangerBtn;
use kernel\IGTabel\btn\PrimaryBtn;
use kernel\IGTabel\btn\SuccessBtn;
$table_info = [
"meta" => [
"rows" => [
"name" => "Название",
"author" => "Автор",
"version" => "Версия",
"description" => "Описание",
"installations" => "Установки",
"views" => "Просмотры"
],
"params" => ["class" => "table table-bordered"],
"baseUrl" => "/admin/module_shop_client",
],
"data" => $data
];
$table = new \Itguild\Tables\ViewJsonTable(json_encode($table_info, JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE));
$table->beforePrint(function () {
$btn = PrimaryBtn::create("Список", "/admin/module_shop_client")->fetch();
return $btn;
});
$table->create();
$table->render();