Introduce 'revisions' association on Web

This commit is contained in:
James Herdman 2009-08-29 14:47:11 -04:00
parent ed8e9cfbd8
commit c0cab0d0b7

View file

@ -1,7 +1,13 @@
class Web < ActiveRecord::Base
## Associations
has_many :pages, :dependent => :destroy
has_many :wiki_files, :dependent => :destroy
has_many :revisions, :through => :pages
## Methods
def wiki
Wiki.new
end