Skip to content
This repository has been archived by the owner on Aug 29, 2023. It is now read-only.

Commit

Permalink
fix(autocomplete): selecting a value will now flag the form/input as …
Browse files Browse the repository at this point in the history
…`$dirty`

Closes #2753
  • Loading branch information
Robert Messerle committed Jun 4, 2015
1 parent ce72cb2 commit 217cae1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/components/autocomplete/js/autocompleteController.js
Expand Up @@ -297,6 +297,8 @@ function MdAutocompleteCtrl ($scope, $element, $mdUtil, $mdConstant, $timeout, $
self.hidden = true;
self.index = 0;
self.matches = [];
//-- force form to update state for validation
elements.$.input.controller('ngModel').$setViewValue($scope.searchText);
}

function clearValue () {
Expand Down

0 comments on commit 217cae1

Please sign in to comment.