Uploaded image for project: 'Mongoid'
  1. Mongoid
  2. MONGOID-3171

Association extension proxy owner

    • Type: Icon: Task Task
    • Resolution: Done
    • 3.1.5
    • Affects Version/s: None
    • Component/s: None
    • None

      I'm struggling how to get an extended association owner. AFAIK it's proxy_association.owner in ActiveRecord. Does this exist in Mongoid? Or is there another way? Example:

      class Something
      field :some_field

      has_many :whatevers, extend: ExtraStuff
      end

      module ExtraStuff
      def recent

      1. I need "some_field" here, but there's no "proxy_association"
        end
        end

            Assignee:
            Unassigned Unassigned
            Reporter:
            stanley90 stanley90
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: