title: AngularJS ng-click linking to a model
body: <p>I am building a small rss reader using Express(ie Jade) and Angular. I have a dropdown menu, where the menu items are populated by a list of items in a model.
  Whatever the user chooses as an item, there is a rss url attached to it and it should trigger a factory.
  This is the jade part:</p>
  
  <pre><code>div.btn-group
      button.btn.btn-info(type='button') {{loadButtonText}}
      button.btn.btn-info.dropdown-toggle(data-toggle='dropdown')
          span.caret
          span.sr-only Toggle Dropdown
      ul.dropdown-menu(role='menu')
          li(ng-repeat='rss in RSSList')
              a(href='#', ng-click="feedSrc='{{rss.url}}';loadFeed($event);") {{rss.Title}}
          input.form-control(type='text', autocomplete='off', placeholder="This is where your feed's url will appear" data-ng-model='feedSrc')
  </code></pre>
  
  <p>This is my angular controller:</p>
  
  <pre><code>var News = angular.module('myApp', []);
  News.controller('FeedCtrl', ['$scope','FeedService', function($scope, Feed){
      $scope.loadButtonText = 'Choose News Feed';
      $scope.RSSList = [
          {Title: "CNN", url: 'http://rss.cnn.com/rss/cnn_topstories.rss'},
          {Title: "Reuters", url: 'http://feeds.reuters.com/news/usmarkets'}
      ];
      $scope.loadFeed = function (e) {
          Feed.parseFeed($scope.feedSrc).then(function (res) {
              $scope.loadButtonText=angular.element(e.target).text();
              $scope.feeds = res.data.responseData.feed.entries;
              }); }}]);
  News.factory('FeedService', ['$http', function($http){
      return {parseFeed: function (url){
          return $http.jsonp('//ajax.googleapis.com/ajax/services/feed/load?v=1.0&amp;num=50&amp;callback=JSON_CALLBACK&amp;q='+encodeURIComponent(url));}}
  }]);
  </code></pre>
  
  <p>It seems feedSrc in ng-click doesn't capture rss.url and can not be passed as argument to the parseFeed function.
  I tried to pass rss.url directly into loadFeed, like this <code>ng-click="loadFeed({{rss.url}});"</code> and even <code>ng-click="loadFeed('{{rss.url}}');" I didn't work either.</code></p>