2007-10-25から1日間の記事一覧
アクセサメソッドを簡単定義するには,attr_accessor メソッドを使う. class foo @bar = 0 attr_accessor :bar def f = foo.new f.bar = 10 p f.bar #=> 10
なんとなくこんな感じ. user = User.find(1) user.books.find(:all, :include => [:associations])
rake tmp:cache:clear 更新されなくて悩んだorz.