Skip to content

Commit

Permalink
Make Product name and SKU searchable (#1986)
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanmitchell authored Oct 28, 2024
1 parent 5266054 commit d01de0d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
use Filament\Tables;
use Filament\Tables\Table;
use Lunar\Admin\Filament\Resources\OrderResource;
use Lunar\Admin\Support\RelationManagers\BaseRelationManager;
use Lunar\Admin\Filament\Resources\OrderResource\Pages\ManageOrder;
use Lunar\Admin\Support\RelationManagers\BaseRelationManager;
use Lunar\Models\Order;

class OrdersRelationManager extends BaseRelationManager
Expand Down
6 changes: 4 additions & 2 deletions packages/admin/src/Filament/Resources/ProductResource.php
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,8 @@ public static function getNameTableColumn(): Tables\Columns\Column
->attributeData()
->limitedTooltip()
->limit(50)
->label(__('lunarpanel::product.table.name.label'));
->label(__('lunarpanel::product.table.name.label'))
->searchable();
}

public static function getSkuTableColumn(): Tables\Columns\Column
Expand All @@ -323,7 +324,8 @@ public static function getSkuTableColumn(): Tables\Columns\Column
})
->listWithLineBreaks()
->limitList(1)
->toggleable();
->toggleable()
->searchable();
}

public static function getDefaultRelations(): array
Expand Down

0 comments on commit d01de0d

Please sign in to comment.