<commit_before><%@ Control Language="C#" AutoEventWireup="false" Inherits="DotNetNuke.Modules.Admin.Security.SecurityRoles" CodeFile="SecurityRoles.ascx.cs" %>
<%@ Register TagPrefix="dnn" TagName="Label" Src="~/controls/LabelControl.ascx" %>
<%@ Register TagPrefix="dnn" Assembly="DotNetNuke" Namespace="DotNetNuke.UI.WebControls"%>
<%@ Register TagPrefix="dnn" Assembly="DotNetNuke.Web" Namespace="DotNetNuke.Web.UI.WebControls" %>
<div class="dnnForm dnnManageSecurityRoles">
    <asp:Panel ID="pnlRoles" runat="server" Visible="True">
        <h2 class="dnnFormSectionHead"><asp:Label ID="lblTitle" runat="server" /></h2>
             <div class="dnnFormItem">
        <table cellspacing="0" cellpadding="0" border="0" class="dnnSecurityRoles dnnClear">
            <tr>
                <td valign="top" width="250">                  
                    <div class="dnnFormItem" style="z-index: 10;">
                    <dnn:Label ID="plRoles" runat="server" />  
                    <dnn:Label ID="plUsers" runat="server" /> 
                    </div>               
                </td>
                <td width="30"></td>
                <td valign="top" width="100">
                    <dnn:Label ID="plEffectiveDate" runat="server"/>
                 </td>
                <td width="30"></td>
                <td valign="top" width="100">
                    <dnn:Label ID="plExpiryDate" runat="server" />
                </td>
                
                <asp:Placeholder runat="server" ID="placeIsOwnerHeader" Visible="false">
                    <td width="30"></td>
                    <td valign="top" width="150"><dnn:Label ID="lblIsOwner" runat="server" /></td>
                </asp:Placeholder>

                <td width="30"></td>
                <td valign="top" width="200"></td>
            </tr>
            <tr>
                <td valign="top" width="250">
                    <asp:TextBox ID="txtUsers" runat="server" Width="150" />
                    <asp:LinkButton ID="cmdValidate" runat="server" CssClass="dnnSecondaryAction" resourceKey="cmdValidate" />
                    <%--<asp:DropDownList ID="cboUsers" runat="server" AutoPostBack="True" Width="100%" />--%>
                    <dnn:DnnComboBox ID="cboUsers" runat="server" AutoPostBack="True" />
                    <%--<asp:DropDownList ID="cboRoles" runat="server" AutoPostBack="True" DataValueField="RoleID" DataTextField="RoleName" Width="100%" />--%>
                    <dnn:DnnComboBox ID="cboRoles" runat="server" AutoPostBack="True" DataValueField="RoleID" DataTextField="RoleName" />
                </td>
                <td width="30"></td>
                <td valign="top" width="100" nowrap="nowrap">
                    <dnn:DnnDatePicker ID="effectiveDatePicker" runat="server"/>
                </td>
                <td width="30"></td>
                <td valign="top" width="100" nowrap="nowrap">
                    <dnn:DnnDatePicker ID="expiryDatePicker" runat="server"/>
                </td>
                <asp:PlaceHolder runat="server" ID="placeIsOwner" Visible="false">
                    <td width="30"></td>
                    <td valign="top" width="150" nowrap="nowrap" align="right"><asp:CheckBox runat="server" ID="chkIsOwner"/></td>
                </asp:PlaceHolder>
                <td width="30"></td>
                <td valign="top" width="200" nowrap="nowrap">
                    <asp:LinkButton ID="cmdAdd" CssClass="dnnPrimaryAction" runat="server"  CausesValidation="true" ValidationGroup="SecurityRole" />
                </td>
            </tr>
        </table>
        <asp:CompareValidator ID="valEffectiveDate" CssClass="dnnFormError" runat="server" resourcekey="valEffectiveDate" Display="Dynamic" Type="Date" Operator="DataTypeCheck" ControlToValidate="effectiveDatePicker" ValidationGroup="SecurityRole" />
        <asp:CompareValidator ID="valExpiryDate" CssClass="dnnFormError" runat="server" resourcekey="valExpiryDate" Display="Dynamic" Type="Date" Operator="DataTypeCheck" ControlToValidate="expiryDatePicker" ValidationGroup="SecurityRole" />
        <asp:CompareValidator ID="valDates" CssClass="dnnFormError" runat="server" resourcekey="valDates" Display="Dynamic" Type="Date" Operator="GreaterThan" ControlToValidate="expiryDatePicker" ControlToCompare="effectiveDatePicker" ValidationGroup="SecurityRole" />
         </div>
    </asp:Panel>
    <asp:CheckBox ID="chkNotify" resourcekey="SendNotification" runat="server" Checked="True" />

    <asp:Panel ID="pnlUserRoles" runat="server" CssClass="WorkPanel" Visible="True">
        <asp:DataGrid ID="grdUserRoles" runat="server" Width="100%" GridLines="None" DataKeyField="UserRoleID" EnableViewState="false" AutoGenerateColumns="false" CellSpacing="0" CellPadding="0" CssClass="dnnGrid">
            <headerstyle cssclass="dnnGridHeader" verticalalign="Top"/>
            <itemstyle cssclass="dnnGridItem" horizontalalign="Left" />
            <alternatingitemstyle cssclass="dnnGridAltItem" />
            <edititemstyle cssclass="dnnFormInput" />
            <selecteditemstyle cssclass="dnnFormError" />
            <footerstyle cssclass="dnnGridFooter" />
            <pagerstyle cssclass="dnnGridPager" />
            <Columns>
                <asp:TemplateColumn>
                    <ItemTemplate>
                        <!-- [DNN-4285] Hide the button if the user cannot be removed from the role -->
                        <dnn:DnnImageButton ID="cmdDeleteUserRole" runat="server" AlternateText="Delete" CausesValidation="False" CommandName="Delete" IconKey="Delete" resourcekey="cmdDelete"  Visible='<%# DeleteButtonVisible(Convert.ToInt32(Eval("UserID")), Convert.ToInt32(Eval("RoleID")))  %>' OnClick="cmdDeleteUserRole_click">
                        </dnn:DnnImageButton>
                    </ItemTemplate>
                </asp:TemplateColumn>
                <asp:TemplateColumn HeaderText="UserName">
                    <ItemTemplate>
                         <a href='<%# DotNetNuke.Common.Globals.LinkClick("userid=" + Eval("UserID").ToString(), TabId, ModuleId) %>' class=""> <%# Eval("FullName").ToString()%> </a><commit_msg>Fix bug DNN-3079: move the checkbox after the add button.<commit_after><%@ Control Language="C#" AutoEventWireup="false" Inherits="DotNetNuke.Modules.Admin.Security.SecurityRoles" CodeFile="SecurityRoles.ascx.cs" %>
<%@ Register TagPrefix="dnn" TagName="Label" Src="~/controls/LabelControl.ascx" %>
<%@ Register TagPrefix="dnn" Assembly="DotNetNuke" Namespace="DotNetNuke.UI.WebControls"%>
<%@ Register TagPrefix="dnn" Assembly="DotNetNuke.Web" Namespace="DotNetNuke.Web.UI.WebControls" %>
<div class="dnnForm dnnManageSecurityRoles">
    <asp:Panel ID="pnlRoles" runat="server" Visible="True">
        <h2 class="dnnFormSectionHead"><asp:Label ID="lblTitle" runat="server" /></h2>
             <div class="dnnFormItem">
        <table cellspacing="0" cellpadding="0" border="0" class="dnnSecurityRoles dnnClear">
            <tr>
                <td valign="top" width="250">                  
                    <div class="dnnFormItem" style="z-index: 10;">
                    <dnn:Label ID="plRoles" runat="server" />  
                    <dnn:Label ID="plUsers" runat="server" /> 
                    </div>               
                </td>
                <td width="30"></td>
                <td valign="top" width="100">
                    <dnn:Label ID="plEffectiveDate" runat="server"/>
                 </td>
                <td width="30"></td>
                <td valign="top" width="100">
                    <dnn:Label ID="plExpiryDate" runat="server" />
                </td>
                
                <asp:Placeholder runat="server" ID="placeIsOwnerHeader" Visible="false">
                    <td width="30"></td>
                    <td valign="top" width="150"><dnn:Label ID="lblIsOwner" runat="server" /></td>
                </asp:Placeholder>

                <td width="30"></td>
                <td valign="top" width="200"></td>
            </tr>
            <tr>
                <td valign="top" width="220">
                    <asp:TextBox ID="txtUsers" runat="server" Width="150" />
                    <asp:LinkButton ID="cmdValidate" runat="server" CssClass="dnnSecondaryAction" resourceKey="cmdValidate" />
                    <dnn:DnnComboBox ID="cboUsers" runat="server" AutoPostBack="True" />
                    <dnn:DnnComboBox ID="cboRoles" runat="server" AutoPostBack="True" DataValueField="RoleID" DataTextField="RoleName" />
                </td>
                <td width="30"></td>
                <td valign="top" width="100" nowrap="nowrap">
                    <dnn:DnnDatePicker ID="effectiveDatePicker" runat="server"/>
                </td>
                <td width="30"></td>
                <td valign="top" width="100" nowrap="nowrap">
                    <dnn:DnnDatePicker ID="expiryDatePicker" runat="server"/>
                </td>
                <asp:PlaceHolder runat="server" ID="placeIsOwner" Visible="false">
                    <td width="30"></td>
                    <td valign="top" width="150" nowrap="nowrap" align="right"><asp:CheckBox runat="server" ID="chkIsOwner"/></td>
                </asp:PlaceHolder>
                <td width="30"></td>
                <td valign="top" width="" nowrap="nowrap">
                    <asp:LinkButton ID="cmdAdd" CssClass="dnnPrimaryAction" runat="server"  CausesValidation="true" ValidationGroup="SecurityRole" />
                    <asp:CheckBox ID="chkNotify" resourcekey="SendNotification" runat="server" Checked="True" />
                </td>
            </tr>
        </table>
        <asp:CompareValidator ID="valEffectiveDate" CssClass="dnnFormError" runat="server" resourcekey="valEffectiveDate" Display="Dynamic" Type="Date" Operator="DataTypeCheck" ControlToValidate="effectiveDatePicker" ValidationGroup="SecurityRole" />
        <asp:CompareValidator ID="valExpiryDate" CssClass="dnnFormError" runat="server" resourcekey="valExpiryDate" Display="Dynamic" Type="Date" Operator="DataTypeCheck" ControlToValidate="expiryDatePicker" ValidationGroup="SecurityRole" />
        <asp:CompareValidator ID="valDates" CssClass="dnnFormError" runat="server" resourcekey="valDates" Display="Dynamic" Type="Date" Operator="GreaterThan" ControlToValidate="expiryDatePicker" ControlToCompare="effectiveDatePicker" ValidationGroup="SecurityRole" />
         </div>
    </asp:Panel>
    <asp:Panel ID="pnlUserRoles" runat="server" CssClass="WorkPanel" Visible="True">
        <asp:DataGrid ID="grdUserRoles" runat="server" Width="100%" GridLines="None" DataKeyField="UserRoleID" EnableViewState="false" AutoGenerateColumns="false" CellSpacing="0" CellPadding="0" CssClass="dnnGrid">
            <headerstyle cssclass="dnnGridHeader" verticalalign="Top"/>
            <itemstyle cssclass="dnnGridItem" horizontalalign="Left" />
            <alternatingitemstyle cssclass="dnnGridAltItem" />
            <edititemstyle cssclass="dnnFormInput" />
            <selecteditemstyle cssclass="dnnFormError" />
            <footerstyle cssclass="dnnGridFooter" />
            <pagerstyle cssclass="dnnGridPager" />
            <Columns>
                <asp:TemplateColumn>
                    <ItemTemplate>
                        <!-- [DNN-4285] Hide the button if the user cannot be removed from the role -->
                        <dnn:DnnImageButton ID="cmdDeleteUserRole" runat="server" AlternateText="Delete" CausesValidation="False" CommandName="Delete" IconKey="Delete" resourcekey="cmdDelete"  Visible='<%# DeleteButtonVisible(Convert.ToInt32(Eval("UserID")), Convert.ToInt32(Eval("RoleID")))  %>' OnClick="cmdDeleteUserRole_click">
                        </dnn:DnnImageButton>
                    </ItemTemplate>
                </asp:TemplateColumn>
                <asp:TemplateColumn HeaderText="UserName">
                    <ItemTemplate>
                         <a href='<%# DotNetNuke.Common.Globals.LinkClick("userid=" + Eval("UserID").ToString(), TabId, ModuleId) %>' class=""> <%# Eval("FullName").ToString()%> </a>
{'fraction_non_alphanumeric': 0.15183505154639176, 'fraction_numerical': 0.011958762886597939, 'mean_word_length': 2.614307004470939, 'pattern_counts': {'":': 0, '<': 209, '<?xml version=': 0, '>': 209, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '527740', 'n_tokens_mistral': 3709, 'n_tokens_neox': 3437, 'n_words': 576}