0

I've a datasource item on my rendering that contains child items. In those items I want to edit them using Html.Glas().BeginEditFrame. The problem I'm having is that I cannot click the frame, the only click I can get is from the entire rendering. This is part of my code:

    <div class="row">
            <div class="l-video-highlights large-11 medium-11 column push-1">
                <div class="large-11 medium-11 small-12 columns page-intro">
                    <div class="title">
                        <h1>@Html.Glass().Editable(m => m.Title)</h1>
                    </div>
                    <div class="title-copy">@Html.Glass().Editable(m => m.Description)</div>
                </div>
                @foreach (IVideoHighlight highlight in Model.Highlights)
                {
                    if (Html.Glass().IsInEditingMode)
                    {
                        <div class="large-11 medium-11 small-12 columns page-intro">
                            @using (Html.Glass().BeginEditFrame(highlight, "Edit Highlight"))
                            {

                                <div data-alert class="alert-box alert info margin margin_bottom-0" role="alert">
                                    Click here to edit the Highlight
                                </div>

                            }
                        </div>
                    }
....
  • Is the "Editable" field true on your Rendering Item? And does it work for @Html.Glass().Editable(m => m.Title)? – Tamás Tárnok May 5 '17 at 15:47
  • Have you added an edit fame configuration called Edit Highlight at the core database? You should add this by the follwoing path: /sitecore/content/Applications/WebEdit/Edit Frame Buttons – Artsem Prashkovich May 6 '17 at 8:48
1

I have figured out what was happening. The problem was that I've missed the third parameter that corresponds to the fields that should be editable by the editor. So the method should be like this:

Html.Glass().BeginEditFrame(highlight, "Edit Highlight", m=>m.Title, m=>m.Description,etc,etc)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.