6
0
Fork 0
jiqu-library-server/app/Admin/Renderable/ProductSkuTable.php

23 lines
536 B
PHP

<?php
namespace App\Admin\Renderable;
use App\Models\ProductSku;
use Dcat\Admin\Grid;
use Dcat\Admin\Grid\LazyRenderable;
class ProductSkuTable extends LazyRenderable
{
public function grid(): Grid
{
$id = $this->id;
// $builder = ProductSku::where('id', $id);
return Grid::make(new ProductSku(), function (Grid $grid) {
$grid->disableRowSelector(false);
$grid->column('name');
$grid->quickSearch(['name']);
$grid->disableActions();
});
}
}