Skip to content

Allow :parent and :model options to be specified together #186

@shaug

Description

@shaug

This is the same underlying problem as the #183, but I don't think the model can always reliably be inferred from scope, so I didn't want to vote it for fear it might be further dismissed, even if the underlying issue is valid and solvable.

It is possible to specify a has_many with a class_name on a parent class, which is necessary when the name of the resulting accessor does not automatically map to the correct class name for the model.

As such, it seems decent_exposure should allow parent and model to both be specified. When the above configuration is used with the current code, the parent short-cut cannot be used (even though it would seem natural), because the model method in behavior.rb fails to automatically determine the correct model name.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions