Created
February 19, 2011 18:52
-
-
Save jrmoran/835272 to your computer and use it in GitHub Desktop.
This file contains 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 PortfolioBuilder = function() { | |
var $context = ""; | |
var symbols = []; | |
var that = this; | |
return{ | |
init: function(context) { | |
$context = $(context); | |
this.initSymbols(); | |
this.updateButtons(); | |
}, | |
addCompany: foo(), | |
removeCompany: foo(), | |
update: foo(), | |
show: foo(), | |
hide:foo(), | |
hasCompany: foo(), | |
// build portfolio and send the results to Portfolio Object | |
evaluate: function() { | |
$.ajax({ | |
type: "POST", | |
url:base + "build_portfolio", | |
beforeSend:function() { | |
// show loader | |
$context.find('.loader').show(); | |
}, | |
success: function(JSONdata) { | |
$context.find('.loader').hide(); | |
Portfolio.build2(JSONdata); | |
} | |
}); | |
} | |
} | |
}(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment