title: How can I set my field to $dirty inside my custom directive?
body: <p>I have a dropdown/select directive that I used to replace the select boxes inside my form. I have few buttons that I set to disable as long as the form is pristine.</p>
  
  <pre><code>app.directive('dropdown', function ($timeout) {
      return {
          restrict: 'E',
          template: '&lt;div class="btn-group" dropdown&gt;' +
               '&lt;button id="dropdownDirective" class="btn dropdown-toggle" dropdown-toggle&gt;' + 
                  '{{ items[ngModel].name }}' +
                  '&lt;span class="caret"&gt;&lt;/span&gt;' +
              '&lt;/button&gt;' +
              '&lt;ul class="dropdown-menu" role ="menu" aria-label="dLabel"&gt;' +
                  '&lt;li ng-repeat="item in items"&gt;'+
                      '&lt;a href="#" ng-bind="item.name" ng-click = "select(item)" &gt;&lt; / a &gt;' +
                  '&lt;/li&gt;'+
              '&lt;/ul&gt;'+
              '&lt;/div&gt;',
          scope: {
              ngModel: '=', // selected option
              items: '=',   // options
          },
          link: function (scope, element, attrs) {
              scope.select = function (item) {
                  scope.ngModel = item.id;
              };           
          }
      };
  }); 
  </code></pre>
  
  <p>In HTML: </p>
  
  <pre><code>&lt;dropdown id="modalSelect"
      ng-model="ahs.modal.modalId"
      items="es.modal.data"&gt;
      &lt;/dropdown&gt;
  </code></pre>
  
  <p>With my directive, the $pristine is not being triggered. Can someone point to me what I'm doing wrong?</p>