Method: Sequel::Plugins::ManyThroughMany::ClassMethods#one_through_many

Defined in:
lib/sequel/plugins/many_through_many.rb

#one_through_many(name, through, opts = OPTS, &block) ⇒ Object

Creates a one_through_many association. See many_through_many for arguments.



231
232
233
# File 'lib/sequel/plugins/many_through_many.rb', line 231

def one_through_many(name, through, opts=OPTS, &block)
  associate(:one_through_many, name, opts.merge(through.is_a?(Hash) ? through : {:through=>through}), &block)
end