Skip to content

DropDownBox: add Search in Embedded Components topic#8854

Merged
vladaskorohodova merged 13 commits into
DevExpress:26_1from
vladaskorohodova:ddb-grid-list26_1
Jun 19, 2026
Merged

DropDownBox: add Search in Embedded Components topic#8854
vladaskorohodova merged 13 commits into
DevExpress:26_1from
vladaskorohodova:ddb-grid-list26_1

Conversation

@vladaskorohodova

Copy link
Copy Markdown
Collaborator

No description provided.

@vladaskorohodova vladaskorohodova self-assigned this Jun 10, 2026
Copilot AI review requested due to automatic review settings June 10, 2026 07:31

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new “Search in Embedded Components” documentation section for DropDownBox, describing how to implement search when embedding DataGrid (flat data) or TreeList (lookup display-value search). It also modernizes parts of the existing “Synchronize with the Embedded Element” topic code samples.

Changes:

  • Added an overview article explaining shared configuration and the differences between DataGrid (searchValue/searchExpr) and TreeList (lookup-driven filter) search approaches.
  • Added two new how-to topics: one for embedded DataGrid search and one for embedded TreeList search (lookup scenario).
  • Updated the existing synchronization topic’s wording and refreshed Angular/Vue/React code samples.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 7 comments.

File Description
concepts/05 UI Components/DropDownBox/20 Search in Embedded Components/00 Search in Embedded Components.md New overview article comparing search approaches and shared configuration.
concepts/05 UI Components/DropDownBox/20 Search in Embedded Components/05 DataGrid.md New DataGrid-focused how-to with multi-framework code snippets.
concepts/05 UI Components/DropDownBox/20 Search in Embedded Components/10 TreeList.md New TreeList-focused how-to for lookup display-value search.
concepts/05 UI Components/DropDownBox/15 Synchronize with the Embedded Element.md Refined introductory text + updated framework code samples.

Comment thread concepts/05 UI Components/DropDownBox/15 Synchronize with the Embedded Element.md Outdated
@vladaskorohodova vladaskorohodova changed the title DropDownBox: add Search in Embedded Components topic (WIP) DropDownBox: add Search in Embedded Components topic Jun 10, 2026
@vladaskorohodova vladaskorohodova requested a review from Copilot June 10, 2026 14:35

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 13 comments.

Comment thread concepts/05 UI Components/DropDownBox/15 Synchronize with the Embedded Element.md Outdated
Copilot AI review requested due to automatic review settings June 10, 2026 15:01

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 9 comments.

@16adianay 16adianay self-requested a review June 11, 2026 08:38
Copilot AI review requested due to automatic review settings June 11, 2026 08:47

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 8 comments.

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 11, 2026 10:04

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 5 comments.

@Abadzhev Abadzhev left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Co-authored-by: Vladimir Abadzhev <vladimira@devexpress.com>
Copilot AI review requested due to automatic review settings June 15, 2026 10:34

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 9 comments.

Copilot AI review requested due to automatic review settings June 16, 2026 09:06

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 17, 2026 06:18

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 7 comments.

Comment thread concepts/05 UI Components/DropDownBox/15 Synchronize with the Embedded Element.md Outdated
Co-authored-by: Albert Totten <49917542+albertov05@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 18, 2026 05:46

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 10 comments.

Comment on lines +444 to +465
function applySearchFilter(text, lookupField, dataField, searchExprVal, lookupDataSource, dataSource) {
// Step 1: find employees whose Name contains the typed text
lookupDataSource.load({ filter: [lookupField, 'contains', text] }).done((items) => {
const filterParts = [];

// Step 2: optionally also search in a non-lookup field (for example, Task_Subject)
if (Array.isArray(searchExprVal)) {
filterParts.push([searchExprVal[1], 'contains', text]);
}

// Step 3: add an OR condition for each matched employee ID
items.forEach((item, index) => {
if (filterParts.length > 0 || index > 0) filterParts.push('or');
filterParts.push([dataField, '=', item.ID]);
});

// Step 4: apply the filter (use a "no-results" sentinel if nothing matched)
const filterExpr = filterParts.length > 0 ? filterParts : [dataField, '=', -1];
dataSource.filter(filterExpr);
dataSource.load();
});
}

See this example for more details: [DropDownBox with embedded TreeList](https://github.com/DevExpress-Examples/devextreme-dropdownbox-implement-search-for-treelist).

#####See Also#####

[note] This implementation supports single selection only. To implement multiple selection, use the [TagBox](/api-reference/10%20UI%20Components/dxTagBox '/Documentation/ApiReference/UI_Components/dxTagBox/') component instead.

#####See Also#####
- [DropDownBox with embedded DataGrid](https://github.com/DevExpress-Examples/devextreme-dropdownbox-filter-data-in-nested-widget) (search by regular field)
- [DropDownBox with embedded TreeList](https://github.com/DevExpress-Examples/devextreme-dropdownbox-implement-search-for-treelist) (search by lookup column display value)

#####See Also#####
Comment on lines +58 to +68
import { Component } from "@angular/core";
import { DxDropDownBoxComponent } from "devextreme-angular/ui/drop-down-box";
import { DxDataGridComponent } from "devextreme-angular/ui/data-grid";
import ArrayStore from "devextreme/data/array_store";
// ...

@Component({
selector: "app-root",
templateUrl: "./app.component.html",
standalone: true,
imports: [DxDropDownBoxComponent, DxDataGridComponent]
})
Comment on lines +211 to +220
import { Component } from "@angular/core";
import { DxDropDownBoxComponent } from "devextreme-angular/ui/drop-down-box";
import { DxDataGridComponent, DxoDataGridSelectionComponent } from "devextreme-angular/ui/data-grid";

@Component({
selector: "app-root",
templateUrl: "./app.component.html",
standalone: true,
imports: [DxDropDownBoxComponent, DxDataGridComponent, DxoDataGridSelectionComponent]
})
Comment on lines +103 to +107
const dropDownBoxData = [/* ... */];
const gridDataSource = new ArrayStore({
data: widgetData,
key: 'ID',
});
Comment on lines +120 to 124
const dropDownBoxData = [/* ... */];
const gridDataSource = new ArrayStore({
data: widgetData,
key: "ID"
key: 'ID',
});
Comment on lines +99 to +100
import DxDropDownBox from 'devextreme-vue/drop-down-box';
import { DxDataGrid } from 'devextreme-vue/data-grid';
Comment on lines +249 to +250
import DxDropDownBox from 'devextreme-vue/drop-down-box';
import { DxDataGrid, DxSelection } from 'devextreme-vue/data-grid';
@vladaskorohodova vladaskorohodova merged commit 771ceb2 into DevExpress:26_1 Jun 19, 2026
6 checks passed
@vladaskorohodova vladaskorohodova deleted the ddb-grid-list26_1 branch June 19, 2026 05:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants