Macro within macro stopped displaying in RTE after upgrade
Umb 7.13.1 upgraded from 7.5.4
Could someone please tell me what has changed between 7.5.4 and 7.13.1 to prevent the following macro from displaying in an RTE? Error is indicated in the code:-
@inherits Umbraco.Web.Macros.PartialViewMacroPage
@using ContentModels = Umbraco.Web.PublishedContentModels;
@{
var assetId = Model.MacroParameters["asset"];
dynamic asset = Umbraco.TypedContent(assetId);
}
@(RenderAsset(asset))
@helper RenderAsset(ContentModels.MacroAccordion macroAccordion)
{
var accordions = macroAccordion.Accordion.Select(x => new ContentModels.Accordion(x));
foreach (var accordion in accordions)
{
<div class="accordion">
<header><h3>@(accordion.Title)</h3><span class="icon-icon-small-arrow-up"></span></header>
<div class="accordion-content">
@(accordion.Content) <<<< Error : 'Cannot render a macro when there is no current PublishedContentRequest.'
</div>
</div>
}
}
accordion.Content "can" contain another macro (not the same macro) and displays perfectly on the original site when it does.
Any clues how to make this work again would be appreciated.
Quite a lot has changed under the hood with all the minor versions from 7.5 to 7.13 so I guess it can be a bit hard to pinpoint the exact issue - Does the log file review some additional details about this or is it just showing the same error?
Macro within macro stopped displaying in RTE after upgrade
Umb 7.13.1 upgraded from 7.5.4
Could someone please tell me what has changed between 7.5.4 and 7.13.1 to prevent the following macro from displaying in an RTE? Error is indicated in the code:-
accordion.Content "can" contain another macro (not the same macro) and displays perfectly on the original site when it does.
Any clues how to make this work again would be appreciated.
Many thanks.
Craig
Hi Craig
I'm not quite sure what might be the cause of this but I'm wondering if you have consulted the version specific upgrade documentation to see if anything could be causing this? https://our.umbraco.com/documentation/Getting-Started/Setup/Upgrading/version-specific
Quite a lot has changed under the hood with all the minor versions from 7.5 to 7.13 so I guess it can be a bit hard to pinpoint the exact issue - Does the log file review some additional details about this or is it just showing the same error?
/Jan
is working on a reply...