<%@ control language="VB" autoeventwireup="false" inherits="RCC_SharePoint_CC_EditSPUser, MachSol.MachPanel.Web" %>
<%@ Register Src="~/Template/CC/Selectable_Selected_LBX.ascx" TagName="AddSelectableSelected" TagPrefix="EM" %>

<script type="text/javascript" lang="javascript">
    function CopyEditEmail() {

        var parent2 = document.getElementById("<%=TxBx_EditUserEmail.ClientID%>");
        var child2 = document.getElementById("<%=TxBx_SendSetupEmail.ClientID%>");

        if (parent2 != null && child2 != null) {
            if (document.getElementById('<%=ChBx_SendSetupEmail.ClientID%>').checked == true) {
                child2.value = parent2.value;
            }
            else {
                child2.value = '';
            }
        }
    }

    function CopyUserEditRole() {
        var TxBx_UserRolesValidator = $get('<% = TxBx_UserRolesValidator.ClientID %>');
        var Lbx_UserRoles = $get('<% = Lbx_EditUserRoles.ClientID %>');
        TxBx_UserRolesValidator.value = Lbx_UserRoles.options[Lbx_UserRoles.selectedIndex].text;
    }
</script>
<asp:Panel ID="Pnl_EditUser" runat="server" Visible="false">
    <%--<div class="breadCrumbTrackingBox" id="div_breadCrumbTrackingBox" runat="server">
        <asp:Literal ID="Literal43" runat="server" EnableViewState="false" Text="<%$ Resources:Content,DEV1209%>" />

        &nbsp;
                            <asp:LinkButton ID="" runat="server" Text="<%$ Resources:Content,DGN1110542%>" />
    </div>--%>

    <div class="card">
        <div class="header" id="Div_Hearder" runat="server">
            <div class="displayInlineBlock" id="div_breadCrumbTrackingBox" runat="server">
                <h2>
                    <asp:Label ID="Label1" runat="server" Text="<%$ Resources:Content,GN0000276%>" /><asp:Label ID="lbl_User" runat="server" /></h2>
            </div>
            <asp:LinkButton ID="lb_GoBack" runat="server" Text="<%$ Resources:Content,DGN1110542 %>" CausesValidation="false"
                CssClass="btn btn-primary waves-effect pull-right m-t--4px" />
        </div>
        <div class="body">
            <div class="row">
                <div class="col-xs-12" id="tbl_productStepButtonContainer" runat="server">

                    <div class="products-step">
                        <span id="div_s1" runat="server" nowrap="true" class="label label-success">
                            <asp:LinkButton ID="lb_General" runat="server" Text='<%$ Resources:Content, GN00001466 %>' />
                        </span>
                        <span id="div_s2" runat="server" nowrap="true" class="label label-default">
                            <asp:LinkButton ID="Lb_ChangePwd" runat="server" Text='<%$ Resources:Content, DGN1110442 %>' />
                        </span>
                        <span id="div1" runat="server" nowrap="true" class="label label-default">
                            <asp:LinkButton ID="lb_Advanced1" runat="server" Text='' />
                        </span>
                    </div>
                    <div class="col-xs-12"></div>
                </div>

                <div class="col-xs-12">
                    <asp:Panel ID="Pnl_General" runat="server" DefaultButton="Btn_SaveGeneralInfo">
                        <div class="card">
                            <div class="header">
                                <h3>

                                    <asp:Literal ID="Literal36" runat="server" Text="<%$ Resources:Content,SM400028%>" EnableViewState="false" /></h3>
                            </div>
                            <div class="body">
                                <div class="row" id="TR_TxBx_EditUserName" runat="server">
                                    <div class="col-sm-2 col-xs-12 row-label">

                                        <asp:Literal ID="Literal33" runat="server" Text="<%$ Resources:Content,GN0001288%>" />:
                                  
                                    </div>
                                    <div class="col-sm-3 col-xs-12">
                                        <div class="form-group">
                                            <div class="form-line">
                                                <asp:TextBox ID="TxBx_EditUserName" runat="server"></asp:TextBox>
                                            </div>
                                        </div>

                                    </div>
                                    <div class="col-sm-5 col-xs-12">

                                        <div class="form-group at-the-rate">
                                            @<asp:DropDownList ID='Ddl_UpnSuffix' runat='server'>
                                            </asp:DropDownList>
                                           <%-- <asp:RegularExpressionValidator ID="REV_UserAlias" runat="server" ValidationGroup="EditSPUser" Display="None" ErrorMessage="<%$Resources:Content,InvalidUPN %>"
                                                ValidationExpression="<%$Resources:MPRegex,Alias %>" ControlToValidate="TxBx_EditUserName" SetFocusOnError="true">
                                            </asp:RegularExpressionValidator>--%>
                                            <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="TxBx_EditUserName"
                                                Display="None" SetFocusOnError="True" ValidationGroup="EditSPUser"></asp:RequiredFieldValidator>
                                        </div>
                                    </div>
                                </div>

                                <div class="row" id="TR_TxBx_EditDisplayName" runat="server">
                                    <div class="col-sm-2 col-xs-12 row-label">

                                        <asp:Literal ID="Literal27" runat="server" Text="<%$Resources:Content,GN00001113%>" />:
                                   
                                    </div>
                                    <div class="col-sm-3 col-xs-12">
                                        <div class="form-group">
                                            <div class="form-line">
                                                <asp:TextBox ID="TxBx_EditDisplayName" runat="server"></asp:TextBox>
                                            </div>
                                        </div>
                                        <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="TxBx_EditDisplayName"
                                            Display="None" SetFocusOnError="True" ValidationGroup="EditSPUser"></asp:RequiredFieldValidator>
                                    </div>
                                </div>

                                <div class="row">
                                    <div class="col-sm-2 col-xs-12 row-label">

                                        <asp:Literal ID="Literal30" runat="server" Text="<%$ Resources:Content,String353%>" />:
                                    
                                    </div>
                                    <div class="col-sm-3 col-xs-12">
                                        <asp:ListBox ID="Lbx_EditUserRoles" runat="server" CssClass="ms" Height="110px" SelectionMode="Multiple" Width="145px" onClick="CopyUserEditRole()"></asp:ListBox>
                                        <%-- <div class="form-group form-float">
                                            <div class="form-line">--%>
                                        <asp:TextBox ID="TxBx_UserRolesValidator" runat="server" Style="display: none" CssClass="visibility-hidden"></asp:TextBox>
                                        <%--   </div>
                                        </div>--%>
                                        <asp:RequiredFieldValidator ID="RFV_UserRoles" runat="server" ControlToValidate="TxBx_UserRolesValidator"
                                            Enabled="false" Display="None" SetFocusOnError="True" ValidationGroup="SPUser" ErrorMessage="<%$ Resources:Content,UserRoleRequired %>"></asp:RequiredFieldValidator>
                                    </div>
                                </div>

                                <div class="row" id="tr_EditmemberOf" runat="server">
                                    <div class="col-xs-12 row-label">

                                        <asp:Label ID="Lbl_EditMemberOf" runat="server" Text="<%$ Resources:Content,SMI0418%>" />:
                                    
                                    </div>
                                    <div class="col-xs-12">
                                        <EM:AddSelectableSelected ID="UCEditGroupMembers" runat="server" />
                                    </div>
                                </div>

                                <div class="row" id='tredit_setadmin' runat='server' visible='false'>
                                    <div class="col-sm-2 col-xs-12 row-label">

                                        <asp:Literal ID="LtrlEdit_setAdmin" runat="server" Text="<%$Resources:Content,SMI0214%>" />:
                                    
                                    </div>
                                    <div class="col-sm-3 col-xs-12">
                                        <asp:CheckBox ID='CBEdit_setAdmin' runat='server' Text=" " Checked='false' />
                                    </div>
                                </div>

                                <div class="row" id="TR_EmailEdit" runat="server">
                                    <div class="col-sm-2 col-xs-12 row-label">

                                        <asp:Literal ID="Literal31" runat="server" Text="<%$Resources:Content,GN0000491%>" />:
                                    
                                    </div>
                                    <div class="col-sm-3 col-xs-12">
                                        <div class="form-group">
                                            <div class="form-line">
                                                <asp:TextBox ID="TxBx_EditUserEmail" runat="server" onblur="CopyEditEmail()"></asp:TextBox>
                                            </div>
                                        </div>
                                        <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="TxBx_EditUserEmail"
                                            Display="None" SetFocusOnError="True" ValidationGroup="EditSPUser"></asp:RequiredFieldValidator>
                                        <%--<asp:RegularExpressionValidator ErrorMessage='<%$ Resources:Content,DGN1110038%>'
                                            ID="RegularExpressionValidator3" runat="server" ControlToValidate="TxBx_EditUserEmail"
                                            Display="None" ValidationExpression="<%$ Resources:MPRegex,EmailAddress %>"
                                            ValidationGroup="EditSPUser" SetFocusOnError="true"></asp:RegularExpressionValidator>--%>
                                    </div>
                                </div>

                                <div class="row">
                                    <div class="col-sm-2 col-xs-12 row-label">

                                        <asp:Literal ID="Literal35" runat="server" Text="<%$Resources:Content,GN00001336%>" />:
                                    
                                    </div>
                                    <div class="col-sm-3 col-xs-12">
                                        <asp:TextBox ID="TxBx_EditNotes" Columns="50" Rows="5" TextMode="MultiLine" runat="server"></asp:TextBox>
                                    </div>
                                </div>

                                <div class="row">
                                    <div class="col-sm-2 col-xs-12">
                                        <asp:Button ID="Btn_SaveGeneralInfo" runat="server" Text="<%$ Resources:Content,GN0000281%>" CssClass="btn btn-primary waves-effect btnAction" ValidationGroup="EditSPUser" />
                                        <asp:ValidationSummary ID="VS" runat="server" ShowMessageBox="true" ShowSummary="false"
                                            ValidationGroup="EditSPUser" HeaderText="<%$ Resources:Content,EM000001%>" />
                                    </div>
                                </div>
                            </div>
                        </div>


                    </asp:Panel>
                </div>

                <div class="col-xs-12">
                    <asp:Panel ID="Pnl_Password" runat="server" DefaultButton="Btn_ChangePassword">

                        <div class="card">
                            <div class="header">
                                <h3>

                                    <asp:Literal
                                        ID="Literal37" runat="server" Text="<%$ Resources:Content,DGN1110442%>" EnableViewState="false"></asp:Literal></h3>
                            </div>
                            <div class="body">
                                <div class="row">
                                    <div class="col-sm-2 col-xs-12 row-label">
                                        <asp:Literal ID="Literal32" runat="server" Text="<%$ Resources:Content,DGN1110554%>" />:
                                    </div>
                                    <div class="col-sm-3 col-xs-12">
                                        <div class="form-group">
                                            <div class="form-line">
                                                <asp:TextBox ID="TxBx_EditPassword" runat="server" TextMode="Password" MaxLength="30" />
                                                <asp:RequiredFieldValidator ID="RFV_TxBx_EditPassword" runat="server" ControlToValidate="TxBx_EditPassword"
                                                    Display="None" SetFocusOnError="True" ValidationGroup="ChangePassword"></asp:RequiredFieldValidator>
                                            </div>
                                        </div>
                                        <asp:Literal ID="Literal10" runat="server" Text="<%$ Resources:Content,GN00001530%>"
                                            EnableViewState="false"></asp:Literal>
                                        <br />
                                        <asp:CheckBox ID="CB_Show" runat="server" Text="<%$ Resources:Content,FAM0049 %>" />
                                    </div>
                                    <div class="col-sm-7 col-xs-12">
                                        <div class="form-group">
                                            <asp:Button ID="lb_Generate" runat="server" Text="<%$ Resources:Content,SMI0195%>"
                                                CausesValidation="false" CssClass="btn btn-primary waves-effect" TabIndex="-1"></asp:Button>
                                        </div>
                                        <div id="Div_PasswordPolicy" runat="server" class="help-text sm"></div>
                                    </div>

                                </div>

                                <div class="row">
                                    <div class="col-sm-2 col-xs-12 row-label">
                                        <asp:Literal ID="Literal34" runat="server" Text="<%$ Resources:Content,DGN1110555%>" />:
                                    </div>
                                    <div class="col-sm-3 col-xs-12">
                                        <asp:CompareValidator Display="None" ID="CompareValidator1" ValidationGroup="ChangePassword"
                                            runat="server" ErrorMessage="Password do not match." ControlToCompare="TxBx_EditPassword"
                                            ControlToValidate="TxBx_EditConfirmPassword"></asp:CompareValidator>
                                        <div class="form-group">
                                            <div class="form-line">
                                                <asp:TextBox ID="TxBx_EditConfirmPassword" TextMode="Password" runat="server"></asp:TextBox>
                                            </div>
                                        </div>
                                        <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ControlToValidate="TxBx_EditConfirmPassword"
                                            Display="None" SetFocusOnError="True" ValidationGroup="ChangePassword"></asp:RequiredFieldValidator>
                                    </div>

                                </div>

                                <div class="row">
                                    <div class="col-sm-2 col-xs-12 row-label">
                                        <asp:Literal ID="Literal80" runat="server" Text="<%$ Resources:Content,GN0000752%>"> </asp:Literal>:
                                    </div>
                                    <div class="col-sm-3 col-xs-12">
                                        <asp:CheckBox ID="ChBx_SendSetupEmail" runat="server" Checked="true" Text=" " />
                                    </div>

                                </div>

                                <div class="row" id="Tr_SendSetupEmail" runat="server">
                                    <div class="col-sm-2 col-xs-12 row-label">
                                        <asp:Literal ID="Literal79" runat="server" Text="<%$ Resources:Content,String389%>"></asp:Literal>:
                                                    
                                    </div>
                                    <div class="col-sm-3 col-xs-12">
                                        <div class="form-group">
                                            <div class="form-line">
                                                <asp:TextBox ID="TxBx_SendSetupEmail" runat="server"></asp:TextBox>
                                            </div>
                                        </div>
                                        <asp:RequiredFieldValidator ID="RFV_TxBx_SendSetupEmail" runat="server" ControlToValidate="TxBx_SendSetupEmail"
                                            Display="None" SetFocusOnError="True" ValidationGroup="ChangePassword"></asp:RequiredFieldValidator>
                                       <%-- <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" ErrorMessage='<%$ Resources:Content,DEV1055%>'
                                            ControlToValidate="TxBx_SendSetupEmail" Display="None" ValidationExpression="<%$ Resources:MPRegex,EmailAddress %>"
                                            ValidationGroup="SPUser"></asp:RegularExpressionValidator>--%>
                                    </div>

                                </div>

                                <div class="row">
                                    <div class="col-sm-2 col-xs-12 row-label">
                                        <asp:ValidationSummary ID="ValidationSummary4" runat="server" ShowMessageBox="true"
                                            ShowSummary="false" ValidationGroup="ChangePassword" HeaderText="<%$ Resources:Content,EM000001%>" />
                                        <asp:Button ID="Btn_ChangePassword" CausesValidation="true" ValidationGroup="ChangePassword"
                                            runat="server" Text="<%$ Resources:Content,GN0000281%>" CssClass="btn btn-primary waves-effect btnAction" />
                                    </div>

                                </div>
                            </div>
                        </div>



                    </asp:Panel>
                </div>
            </div>
        </div>
    </div>




</asp:Panel>
