Skip to content

Commit 06b6072

Browse files
fix
1 parent f6ca34d commit 06b6072

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

packages/devextreme/js/__internal/grids/grid_core/filter/m_filter_row.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -769,6 +769,13 @@ const columnHeadersView = (Base: ModuleType<ColumnHeadersView>) => class ColumnH
769769
|| !equalByValue(editorDataSource.__dataGridSourceFilter || null, filter);
770770

771771
if (shouldUpdateFilter) {
772+
const selectedItem = editor.option('selectedItem');
773+
const items = editor.option('items') ?? [];
774+
const hasSelectedItem = items.some((item) => equalByValue(item, selectedItem));
775+
if (!hasSelectedItem) {
776+
editor.option('items', [...items, selectedItem]);
777+
}
778+
772779
const lookupDataSource = gridCoreUtils.getWrappedLookupDataSource(column, dataSource, filter);
773780
editor.option('dataSource', lookupDataSource);
774781
}

0 commit comments

Comments
 (0)