HTML Editor Not Rendering in Designer

Posted by Community Admin on 04-Aug-2018 22:16

HTML Editor Not Rendering in Designer

All Replies

Posted by Community Admin on 21-Jun-2017 00:00

I'm building out a simple mvc widget that I'll add to later, but first I need to get the HTML editor to render in the designer view. Currently the designer pops up but the html editor is not there. Strange thing is, we have another widget nearly identical to this one and it renders fine. Anyone run across this before?
About to pull my hair out on this one.

 

Here's what I have so far:

Scripts\HMICAccordion\designerview-Simple.js:

(function ($)
    angular.module('designer').requires.push('ngSanitize');
)(jQuery);

 

Views\HMICAccordion\DesignerView.Simple.json:

 "priority": 1,
  "components": ["sf-html-field" ]

 

Views\HMICAccordion\DesignerView.Simple.cshtml:

<div class="row">
    <div class="col-xs-12">
        <div class="form-group">
            <label>Html For Accordion Control</label>
            <div>
                    <sf-html-field sf-model="properties.HTMLText.PropertyValue"></sf-html-field>
            </div>
 
          </div>
        </div>
</div>
 
    <div class="row">
        <div class="col-xs-12">
            * Instructions here
        </div>
    </div>

 

Views\HMICAccordion\Index.cshtml: 

@using Telerik.Sitefinity.Frontend.Mvc.Helpers;
@using Telerik.Sitefinity.UI.MVC;
@using SitefinityWebApp;
 
@Html.Script("/Mvc/Scripts/HMICAccordion/hmicaccordion.js", "bottom")
 
@Html.Raw(ViewBag.HTMLText)

 

my controller class:

namespace SitefinityWebApp.Mvc.Controllers
  
    [ControllerToolboxItem(Name = "HMIC Accordion Widget", Title = "Accordion Widget", SectionName = "HMIC")]
    public class HMICAccordionController : Controller
    
        public string HTMLText get; set;
        public ActionResult Index()
        
            ViewBag.HTMLText = HTMLText;
            return View();
        
    

 

This thread is closed