Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html ng-app="someApp">
<head>
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.2.14/angular.min.js"></script>
  <meta charset="utf-8">
  <title>JS Bin</title>
</head>
<body>
  <div ng-controller="peopleList">
    
    <h5>Invited</h5>
    
    <div ng-repeat="person in people">
      <a href="" ng-click="isAttending()">
        {{person.first_name}}{{person.last_name}} - {{person.attending}}
      </a>
    </div>
    
    <h5>Attending</h5>
    <div ng-repeat="person in people">
      
    </div>
    
  </div>
</body>
</html>
 
var someApp = angular.module('someApp', []);
someApp.controller('peopleList', ['$scope', function($scope) {
    $scope.people = 
    [
        {
        "personID": 1,
        "first_name": "Sam",
        "last_name": "Stimpson",
        "attending": false
        },
        {
        "personID": 2,
        "first_name": "Alison",
        "last_name": "van Schoor",
        "attending": true
        },
        {
        "personID": 3,
        "first_name": "Lindsay",
        "last_name": "van Schoor",
        "attending": false
        },
        {
        "personID": 3,
        "first_name": "Lindsay",
        "last_name": "van Schoor",
        "attending": false
        }
    ];
    $scope.isAttending = function() {
       alert("is attending");
    };
}]);
 
Output

This bin was created anonymously and its free preview time has expired (learn why). — Get a free unrestricted account

Dismiss x
public
Bin info
anonymouspro
0viewers