Skip to content

🎧 Your Personal Streaming Service

Add filter by name to Playlist list

Deluana734a1aaa35d
diff --git a/ui/src/playlist/PlaylistList.js b/ui/src/playlist/PlaylistList.js
index 31defa481..25979cfd9 100644
--- a/ui/src/playlist/PlaylistList.js
+++ b/ui/src/playlist/PlaylistList.js
@@ -5,11 +5,19 @@ import {
BooleanField,
NumberField,
DateField,
+ Filter,
+ SearchInput,
} from 'react-admin'
import { DurationField, List } from '../common'
+const PlaylistFilter = (props) => (
+ <Filter {...props}>
+ <SearchInput source="name" alwaysOn />
+ </Filter>
+)
+
const PlaylistList = (props) => (
- <List {...props} exporter={false}>
+ <List {...props} exporter={false} filters={<PlaylistFilter />}>
<Datagrid rowClick="show">
<TextField source="name" />
<TextField source="owner" />