class ViewProductDetails extends Page implements Tables\Contracts\HasTable
{
use Tables\Concerns\InteractsWithTable;
protected static ?string $navigationIcon = 'heroicon-o-document-text';
protected static ?string $title = 'View Product Details ';
protected static string $view = 'filament.pages.view-product-details';
protected function getTableQuery(): Builder
{
$productId = request()->route('product');
return Tradingprofile::where('product_id', $productId);
}
protected function getTableColumns(): array
{
return [
TextColumn::make('customer.name')->label('Customer Name')->searchable(),
];
}
protected static function shouldRegisterNavigation(): bool
{
return false;
}
class ViewProductDetails extends Page implements Tables\Contracts\HasTable
{
use Tables\Concerns\InteractsWithTable;
protected static ?string $navigationIcon = 'heroicon-o-document-text';
protected static ?string $title = 'View Product Details ';
protected static string $view = 'filament.pages.view-product-details';
protected function getTableQuery(): Builder
{
$productId = request()->route('product');
return Tradingprofile::where('product_id', $productId);
}
protected function getTableColumns(): array
{
return [
TextColumn::make('customer.name')->label('Customer Name')->searchable(),
];
}
protected static function shouldRegisterNavigation(): bool
{
return false;
}