Created
August 19, 2014 08:16
-
-
Save dgertych-monterail/abcef0835971eb04da15 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| console.log 'for in', "all: #{$scope.all}" | |
| for user in $scope.participants | |
| console.log user | |
| user.checked_out_events[$scope.id].selected = $scope.all | |
| console.log 'forEach', "all: #{$scope.all}" | |
| _.forEach $scope.participants, (user) -> | |
| console.log user | |
| user.checked_out_events[$scope.id].selected = $scope.all |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var user, _i, _len, _ref; | |
| console.log('for in', "all: " + $scope.all); | |
| _ref = $scope.participants; | |
| for (_i = 0, _len = _ref.length; _i < _len; _i++) { | |
| user = _ref[_i]; | |
| console.log(user); | |
| user.checked_out_events[$scope.id].selected = $scope.all; | |
| } | |
| console.log('forEach', "all: " + $scope.all); | |
| _.forEach($scope.participants, function(user) { | |
| console.log(user); | |
| return user.checked_out_events[$scope.id].selected = $scope.all; | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment