Created
September 7, 2012 20:38
-
-
Save george/3669415 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
SocialRoi.Report = DS.Model.extend | |
name: DS.attr('string') | |
configuration_state: DS.attr('string') | |
enterprise_guid: DS.attr('string') | |
enterprise_name: DS.attr('string') | |
enterprise_guid: DS.attr('string') | |
site_name: DS.attr('string') | |
site_id: DS.attr('number') | |
program_name: DS.attr('string') | |
program_id: DS.attr('number') | |
enterprises: (-> | |
ents = SocialRoi.Enterprise.find() | |
console.log ents.get('length') | |
ents | |
).property() | |
enterprisesLoaded: (-> | |
ents = @get('enterprises') | |
console.log 'enterprises.length: ', ents.get('length') | |
).observes('@each.enterprises') // <= doesn't work | |
//).observes('enterprises') // <= also doesn't work | |
// I'm trying to hook the call to SocialRoi.Enterprise.find() so when it returns data | |
// I can look at the length of the array. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment