8000 Establish `PermittedContentType` view model for content type references · Issue #50 · OnTopicCMS/OnTopic-Editor-AspNetCore · GitHub
[go: up one dir, main page]

Skip to content

Establish PermittedContentType view model for content type references #50

@JeremyCaney

Description

@JeremyCaney

Every ContentTypeDescriptorViewModel has a PermittedContentTypes property that references other ContentTypeDescriptors that are permitted to be created under it. These are exclusively needed for the ContentTypeList view component, which only needs the Key and Title property. And, yet, currently, the entire ContentTypeDescriptorViewModel is mapped, including those derived from the underlying EditingTopicViewModel and CoreTopicViewModel (excluding associations). That's a lot of overhead for every request just to render a dropdown menu.

To mitigate this, establish a new PermittedContentTypeViewModel which only includes the Key and Title needed by the ContentTypeList view component. This can then be explicitly mapped on the ContentTypeDescriptorViewModel using 5.1.0's [MapAs()] attribute.

< 5D27 /div>

Metadata

Metadata

Assignees

Labels

Area: InterfaceRelates to the overall user interface design and implementation.Priority: 1Severity 1: MinorStatus 5: CompleteTask is considered complete, and ready for deployment.Type: ImprovementImproves the functionality or interface of an existing feature.

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0