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

Forums / Developing with Sitefinity / approved and non approved roles

approved and non approved roles

6 posts, 0 answered
  1. tim
    tim avatar
    27 posts
    Registered:
    12 Oct 2010
    23 May 2011
    Link to this post
    hi

    is there a way to disallow an admin to set a user as approved and unapproved in the roles part of the user admin ? Seems obvious to me that you wouldnt do that but the client thinks its confusing, ie if one checkbox is ticked the other is not and if they check the other one it unchecks the previous one..

    tia
    tim
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    09 Dec 2016
    23 May 2011
    Link to this post
    Hello tim,

    It looks like that you have made some customizations to users section, because in 3.x there is no option to approve and reject users out of the box. Please check the users template you modified.

    Kind regards,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. tim
    tim avatar
    27 posts
    Registered:
    12 Oct 2010
    23 May 2011
    Link to this post
    hi

    its not something i changed its in the Roles section of the user admin, where it lists the roles, I just need a way of getting access to them when they are generated as part of :

    <cc2:CheckBoxOrderList runat="server" ID="RolesList"></cc2:CheckBoxOrderList>

    basically i just want to add an onclick event so i can check which is being checked/unchecked.

    hope that makes (some sort of) sense

    tim
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    09 Dec 2016
    23 May 2011
    Link to this post
    Hi tim,

    Open Sitefinity\Admin\CmsAdmin\Users.aspx
    and add the function below to the template


        <script type="text/javascript">
            function ChangeCheckBoxState(id, checkState) {
                alert("test");
            }
         </script>

    It will give you the state of the checkbox.

    Regards,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  5. tim
    tim avatar
    27 posts
    Registered:
    12 Oct 2010
    23 May 2011
    Link to this post
    sorry im probably missing something here, I added that but it does nothing, surely I need to capture the click event on the checkbox, but as they dont exist until the page is rendered I dont know where to add it.

    normally i'd do something like

    myCheckBox.Attributes.Add("onclick", "functionName()");

  6. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    09 Dec 2016
    26 May 2011
    Link to this post
    Hello tim,

    I attached a short video for you.

    The code is added inside

    Sitefinity\Admin\CmsAdmin\Users.aspx

    <%@ Page Language="C#" MasterPageFile="~/Sitefinity/Admin/Admin.master" AutoEventWireup="true" Inherits="Admin_CmsAdmin_Users" CodeFile="~/Sitefinity/Admin/CmsAdmin/Users.aspx.cs" %>
    <%@ Register TagPrefix="cc1" Assembly="Telerik.Security" Namespace="Telerik.Security.WebControls" %>
    <%@ Register TagPrefix="cc1" Namespace="Telerik.Cms.Web.UI" Assembly="Telerik.Cms.Web.UI" %>
    <%@ Register TagPrefix="cc2" Assembly="Telerik.Cms.Web.UI" Namespace="Telerik.Cms.Web.UI" %>
    <%@ Register TagPrefix="cc2" Namespace="Telerik.Libraries.WebControls" Assembly="Telerik.Libraries" %>



    <asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
        <div id="main">
        
        <script type="text/javascript">
            function ChangeCheckBoxState(id, checkState) {
                alert("test");
            }
         </script>

    Best wishes,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Register for webinar
6 posts, 0 answered