Skip to content

Feature: Allow the Details parameter type for DynamicContent to be different than the Controller name. #2403

@rhullah

Description

@rhullah

Currently according to the documentation, when implementing Master/Details views of a widget, if you want the details Action to accept a DynamicContent item, it must match the name of the Controller. This isn't always an acceptable solution and we end up doing workarounds.

I'm wondering if a new custom Attribute could be created and then could be applied to the parameter to specify the exact Dynamic Type. In which case it could look something like the following:

public ActionResult Details(
    [DynamicContentType("Telerik.Sitefinity.DynamicTypes.Model.MyModule.Item")]
    DynamicContent item
) {
    ...
}

The attribute could then be verified and if present the type could be resolved from the attribute instead of forcing the Controller name.

Any likelihood of this?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions