Your search did not match any results.



The Lookup is a UI component that allows an end user to search for an item in a collection shown in a drop-down menu. This demo shows how to create a simple and a grouped Lookup.

Backend API
Copy to CodePen
var DemoApp = angular.module('DemoApp', ['dx']); DemoApp.controller('DemoController', function DemoController($scope) { $scope.lookupOptions = { dropDownOptions: { showTitle: false }, items: employeesList, value: employeesList[0] }; $scope.lookupGroupedOptions = { dataSource: new{ store: employeesTasks, key: "ID", group: "Assigned" }), dropDownOptions: { closeOnOutsideClick: true, showTitle: false }, grouped: true, displayExpr: "Subject" }; });
<!DOCTYPE html> <html > <head> <title>DevExtreme Demo</title> <meta http-equiv="X-UA-Compatible" content="IE=edge" /> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0" /> <script src=""></script> <script>window.jQuery || document.write(decodeURIComponent('%3Cscript src="js/jquery.min.js"%3E%3C/script%3E'))</script> <link rel="stylesheet" type="text/css" href="" /> <link rel="stylesheet" type="text/css" href="" /> <script src=""></script> <script>window.angular || document.write(decodeURIComponent('%3Cscript src="js/angular.min.js"%3E%3C/script%3E'))</script> <script src=""></script> <script src="data.js"></script> <link rel="stylesheet" type="text/css" href="styles.css" /> <script src="index.js"></script> </head> <body class="dx-viewport"> <div class="demo-container" ng-app="DemoApp" ng-controller="DemoController"> <div class="dx-fieldset"> <div class="dx-fieldset-header">Simple lookup</div> <div class="dx-field"> <div dx-lookup="lookupOptions"></div> </div> </div> <div class="dx-fieldset"> <div class="dx-fieldset-header">Grouped lookup</div> <div class="dx-field"> <div dx-lookup="lookupGroupedOptions"></div> </div> </div> </div> </body> </html>
.dx-theme-generic .dx-fieldset, .dx-theme-material .dx-fieldset { width: 40%; float: left; } .dx-field > .dx-lookup { flex: 1; }
var employeesList = ["John Heart", "Samantha Bright", "Arthur Miller", "Robert Reagan", "Greta Sims", "Brett Wade", "Sandra Johnson", "Ed Holmes", "Barb Banks", "Kevin Carter", "Cindy Stanwick", "Sammy Hill", "Davey Jones", "Victor Norris", "Mary Stern", "Robin Cosworth", "Kelly Rodriguez", "James Anderson", "Antony Remmen", "Olivia Peyton", "Taylor Riley", "Amelia Harper", "Wally Hobbs", "Brad Jameson", "Karen Goodson", "Marcus Orbison", "Sandy Bright", "Morgan Kennedy", "Violet Bailey", "Ken Samuelson", "Nat Maguiree", "Bart Arnaz", "Leah Simpson", "Arnie Schwartz", "Billy Zimmer", "Samantha Piper", "Maggie Boxter", "Terry Bradley", "Gabe Jones", "Lucy Ball", "Jim Packard", "Hannah Brookly", "Harv Mudd", "Clark Morgan", "Todd Hoffman", "Jackie Garmin", "Lincoln Bartlett", "Brad Farkus", "Jenny Hobbs", "Dallas Lou", "Stu Pizaro"]; var employeesTasks = [{ "ID": 1, "Assigned": "Mr. John Heart", "Subject": "Choose between PPO and HMO Health Plan" }, { "ID": 2, "Assigned": "Mr. John Heart", "Subject": "Google AdWords Strategy" }, { "ID": 3, "Assigned": "Mr. John Heart", "Subject": "New Brochures" }, { "ID": 4, "Assigned": "Mr. John Heart", "Subject": "Update NDA Agreement" }, { "ID": 5, "Assigned": "Mr. John Heart", "Subject": "Review Product Recall Report by Engineering Team" }, { "ID": 6, "Assigned": "Mrs. Olivia Peyton", "Subject": "Update Personnel Files" }, { "ID": 7, "Assigned": "Mrs. Olivia Peyton", "Subject": "Review Health Insurance Options Under the Affordable Care Act" }, { "ID": 8, "Assigned": "Mrs. Olivia Peyton", "Subject": "Non-Compete Agreements" }, { "ID": 9, "Assigned": "Mrs. Olivia Peyton", "Subject": "Give Final Approval for Refunds" }, { "ID": 10, "Assigned": "Mr. Robert Reagan", "Subject": "Deliver R&D Plans for 2013" }, { "ID": 11, "Assigned": "Mr. Robert Reagan", "Subject": "Decide on Mobile Devices to Use in the Field" }, { "ID": 12, "Assigned": "Mr. Robert Reagan", "Subject": "Try New Touch-Enabled WinForms Apps" }, { "ID": 13, "Assigned": "Mr. Robert Reagan", "Subject": "Approval on Converting to New HDMI Specification" }, { "ID": 14, "Assigned": "Ms. Greta Sims", "Subject": "Approve Hiring of John Jeffers" }, { "ID": 15, "Assigned": "Ms. Greta Sims", "Subject": "Update Employee Files with New NDA" }, { "ID": 16, "Assigned": "Ms. Greta Sims", "Subject": "Provide New Health Insurance Docs" }];