kreta/KretaWeb/Views/Shared/EditorTemplates/PanelBarGeneric.cshtml
2024-03-13 00:33:46 +01:00

19 lines
No EOL
626 B
Text

@using Kreta.Web.Models.EditorTemplates
@model PanelBarBaseModel
@(Html.Kendo().PanelBar()
.Name(Model.PanelName)
.ExpandMode(Model.ExpandMode)
.Animation(animation => animation.Enable(Model.Animation))
.BindTo(Model.ChildModels, mapping =>
{
mapping.For<PanelBarChildModel>(binding => binding.ItemDataBound((panel, childModel) =>
{
panel.Text = childModel.PartialViewTitle;
panel.Template.InlineTemplate = @<text>
@Html.Partial(childModel.PartialViewName, childModel.GenericPanelBarModel)
</text>;
}));
})
)