Created
          May 13, 2013 15:41 
        
      - 
      
- 
        Save Blackmist/5569268 to your computer and use it in GitHub Desktop. 
    Post model, create an instance of the adapter
  
        
  
    
      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 attr = Ember.attr; | |
| //define model | |
| App.Post = Ember.Model.extend({ | |
| id: attr('number'), | |
| title: attr('string'), | |
| author: attr('string'), | |
| body: attr('string'), | |
| posted: attr('date') | |
| }); | |
| //Point the adapter at the table you want to use. | |
| App.Post.adapter = Ember.WAMAdapter.create({ table: client.getTable('posts') }); | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment