Skip to content

Instantly share code, notes, and snippets.

@robertsosinski
Created September 29, 2012 17:15
Show Gist options
  • Save robertsosinski/3804621 to your computer and use it in GitHub Desktop.
Save robertsosinski/3804621 to your computer and use it in GitHub Desktop.
Nesting ActiveRecord models into separate schemas
module Inventory
class Base < ActiveRecord::Base
self.abstract_class = true
self.table_name_prefix = 'inventory.'
end
end
class Ticket < Inventory::Base
belongs_to :venue
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment