def belongs_to(*parents)
      options = parents.extract_options!
      @parents = parents.map(&:to_s)
      if options[:shallow]
        options[:shallow] = options[:shallow].to_s
        raise ArgumentError, ":shallow needs the name of a parent resource" unless @parents.include? options[:shallow]
        @shallow_parent = options[:shallow]
      end
    end
def belongs_to(*parents)
      options = parents.extract_options!
      @parents = parents.map(&:to_s)
      if options[:shallow]
        options[:shallow] = options[:shallow].to_s
        raise ArgumentError, ":shallow needs the name of a parent resource" unless @parents.include? options[:shallow]
        @shallow_parent = options[:shallow]
      end
    end
Specifies parent resources for the current resource.
 Each of these parents will be loaded automatically
 if the proper id parameter is given.
 For example,

   # cake_controller.rb
   belongs_to :baker, :customer

 Then on GET /bakers/12/cakes,

   params[:baker_id] #=> 12
   parent?           #=> true
   parent_name       #=> "baker"
   parent_model      #=> Baker
   parent_object     #=> Baker.find(12)
   current_objects   #=> Baker.find(12).cakes