1-888-365-2779
+1-888-365-2779
Try Now
More in this section

Forums / Developing with Sitefinity / How can I change BlogsList behavior on admin?

How can I change BlogsList behavior on admin?

4 posts, 1 answered
  1. Bruno Michels
    Bruno Michels avatar
    125 posts
    Registered:
    16 Apr 2010
    07 Jun 2010
    Link to this post
    I'm trying to map the blogs list to my own, but it's not working.
    <!-- ## Blogs ## -->
    <viewSettings hostType="Telerik.Blogs.WebControls.Admin.BlogsListView, Telerik.Blogs">
      <views>
        <remove name="BlogsListView" />
        <add name="BlogsListView" viewType="Sitefinity.Blog.Admin.BlogList, Sitefinity.Blog"></add>
      </views>
    </viewSettings>

    What's wrong? It never reaches my breakpoint on the first line of CreateChildControls().


    The same for the libraries works just normal.

    <viewSettings hostType="Telerik.Libraries.WebControls.Admin.LibrariesView, Telerik.Libraries">
      <views>
        <remove name="LibraryEdit`1" />
        <add name="LibraryEdit`1" viewType="...
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    07 Jun 2010
    Link to this post
    Hello Bruno Michels,

    The hostType should be Telerik.Blogs.WebControls.Admin.BlogsView, Telerik.Blogs

    All the best,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  3. Bruno Michels
    Bruno Michels avatar
    125 posts
    Registered:
    16 Apr 2010
    07 Jun 2010
    Link to this post
    <!-- ## Blogs ## -->
    <viewSettings hostType="Telerik.Blogs.WebControls.Admin.BlogsView, Telerik.Blogs">
      <views>
        <remove name="BlogsView" />
        <add name="BlogsView" viewType="Sitefinity.Blog.Admin.BlogList, Sitefinity.Blog"></add>
      </views>
    </viewSettings>

    It's still not working, it never reaches the breakpoint on

    public class BlogList : Telerik.Blogs.WebControls.Admin.BlogsView
    {
        protected override void CreateChildControls()
     -> {
            base.CreateChildControls();
        }
    }

    I compiled both the website and the class library.
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    07 Jun 2010
    Link to this post
    Hello Bruno Michels,

    Now you have change the mapping again and it is not correct. You only had to change the host type. Please consider the configuration and the code below

    MAPPING FOR BlogsListView

    <viewSettings hostType="Telerik.Blogs.WebControls.Admin.BlogsView, Telerik.Blogs">
        <views>
          <remove name="BlogsListView" />
          <add name="BlogsListView" viewType="BlogsListViewCustom, App_Code"></add>
        </views>
      </viewSettings>

    class file

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Web;
    using Telerik.Blogs.WebControls.Admin;
     
    /// <summary>
    /// Summary description for BlogsListViewCustom
    /// </summary>
    public class BlogsListViewCustom :  BlogsListView
    {
        public BlogsListViewCustom()
        {
            
        }
     
        protected override void CreateChildControls()
        {
            base.CreateChildControls();
        }
    }


    MAPPING FOR BlogsView

    <viewSettings hostType="Telerik.Blogs.WebControls.Admin.BlogsControlPanel, Telerik.Blogs">
         <views>
           <remove name="BlogsView" />
           <add name="BlogsView" viewType="BlogsViewCustom, App_Code"></add>
         </views>
       </viewSettings>

    class file

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Web;
    using Telerik.Blogs.WebControls.Admin;
     
    /// <summary>
    /// Summary description for BlogsListViewCustom
    /// </summary>
    public class BlogsViewCustom : BlogsView
    {
        public BlogsViewCustom ()
        {
            
        }
     
        protected override void CreateChildControls()
        {
            base.CreateChildControls();
        }
    }


    Regards,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
    Answered
Register for webinar
4 posts, 1 answered