Class: RemoteModelMigration

Inherits:
Migration
  • Object
show all
Defined in:
lib/migrations/site/02_remotes_page_model.rb

Class Method Summary collapse

Class Method Details

.down(site) ⇒ Object



8
9
10
# File 'lib/migrations/site/02_remotes_page_model.rb', line 8

def self.down(site)
  sites.remotes_pages.destroy
end

.up(site) ⇒ Object



2
3
4
5
6
# File 'lib/migrations/site/02_remotes_page_model.rb', line 2

def self.up(site)
  site.record_proxy_pages.create_model :remotes_page do |remotes_pages|
    remotes_pages.record_class_name = 'RemotesPage'
  end
end