title: Default ngModel in angular directive not being set
body: <p>I have this custom directive in angular that looks like this: (removed most of the code for brevity).</p>
  
  <pre><code>angular.module("SharedModule")
      .directive('singleSelect', ['$ionicModal', singleSelect]);
  
  function singleSelect($ionicModal) {
      return {
          restrict: 'E',
          require: 'ngModel',
          replace:true,
          template: [
              '&lt;div class="item item-icon-right" ng-click="showItems($event)" &gt;',
              '{{text || headerText}}',
              '&lt;i class="icon ion-ios-arrow-right"&gt;&lt;/i&gt;',
              '&lt;/div&gt;'
          ].join("")
          ,
          scope: {
              items: "=",
              headerText: "@"
          },
          link: function (scope, element, attrs, ngModelController) {
  
              if (ngModelController.$modelValue){ // i even tried $viewValue here
                  scope.selectedItemId = ngModelController.$modelValue.id;
                  scope.text = ngModelController.$modelValue.text;
              }
              scope.change = function (item) {
                  ngModelController.$setViewValue(item);
                  scope.text = ngModelController.$viewValue.text;
                  scope.close();
              };
          }
      }
  }
  </code></pre>
  
  <p>I set the default for the ng-model as:</p>
  
  <pre><code>&lt;single-select ng-model='defaultValue' header-text='text when no default present'&gt;
  </code></pre>
  
  <p>and setting the value for <code>defaultValue</code> to <code>{id:"1",label:"foo"}</code> in the scope. </p>
  
  <p>I expect that my template shows a <code>foo</code> when rendering my directive template but it does not. Debugging shows that my ngModel values are set to NaN. I am sure i am missing something trivial here. What could it be?</p>
  
  <p>Also, how could i display my ngModel's <code>label</code> value in the template without an intermediate scope property like the <code>text</code> i have used.</p>
  
  <p>UDPATE: i have created a sample <a href="http://jsfiddle.net/asadpalekar/PdCCE/7/" rel="nofollow">jsfiddle</a> to explain the problem well.
  I expect my div to display <code>foo</code> in the jsfiddle and not the default text.  </p>