public
Description: Simple Flex and Rails integration.
Homepage:
Clone URL: git://github.com/lancecarlson/flails.git
flails /
name age message
file .gitignore Tue Mar 24 18:53:57 -0700 2009 Ignore mongrel pid file and create and destroy ... [lancecarlson]
file LICENSE Fri Feb 20 04:00:44 -0800 2009 Added LICENSE [lancecarlson]
file README Loading commit data...
file Rakefile
file Test.mxml
file build_swc.xml
file manifest.xml
directory rails/
directory src/
directory swc/
directory test/
README
Installation:
1) Download the swc file in the pkg folder.
2) Include the swc file into your library path
3) Setup your rails app to respond to json requests (TODO: Provide examples)
4) Profit!

Example usage:

const Comment:Model = new Model(["post", "comment"])
var request:Request = Comment.findAll();

const Post:Model = new Model("post");
var request:Request = Post.findAll();

request.onComplete(function(posts:*):void {
  posts.forEach(function(post:*, index:int, array:Array):void {
    Alert.show(post.subject);
    post.comments.forEach(function(comment:*, index:int, array:Array):void {
      Alert.show(comment.body);
    })
  });
});

request.onProgress(function():void {
  Alert.show("Progressing!");
})

request.onError(function():void {
  Alert("Darn");
})