Created
May 9, 2012 19:04
-
-
Save sdepold/2648051 to your computer and use it in GitHub Desktop.
private/public in js
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
Layout.ScrumBoard = (function() { | |
"use strict" | |
var ScrumBoard = function() { | |
} | |
ScrumBoard.prototype.render = function() { | |
getActivities.call(this, function(data) { | |
console.log(data) | |
}) | |
} | |
var getActivities = function(callback) { | |
console.log(callback) | |
$.getJSON('/activities', { | |
sprintStart: Application.Index.SprintStart.getValue() | |
}).success(function(data) { | |
callback && callback(data) | |
}).error(function(err) { | |
console.log(err) | |
}) | |
} | |
return ScrumBoard | |
})() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment