def has_many_elements(element, target_model)
      element.class.reflect_on_all_associations(:has_many).each do |assoc|
        if assoc.name.to_s == target_model.downcase.pluralize
          model = Object.const_get(target_model.singularize.camelize)
          return element.send(target_model.downcase.pluralize).paginate(:per_page => 10, :page => 1)
        end
      end
      return []
    end
def has_many_elements(element, target_model)
      element.class.reflect_on_all_associations(:has_many).each do |assoc|
        if assoc.name.to_s == target_model.downcase.pluralize
          model = Object.const_get(target_model.singularize.camelize)
          return element.send(target_model.downcase.pluralize).paginate(:per_page => 10, :page => 1)
        end
      end
      return []
    end
get all elements that element has_many of (paginated)