<%@ page language="C#" autoeventwireup="true" inherits="Forms_ControllerMaster, App_Web_isgq1fab" enableeventvalidation="false" %>

<%@ Register Src="~/UserControls/Notification_List.ascx" TagPrefix="uc3" TagName="NotificationsList" %>
<%--<%@ Register Src="~/UserControls/AMCNotification_List.ascx" TagPrefix="uc6" TagName="NotificationsListAMC" %>--%>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<%@ Register Src="~/UserControls/New_Header.ascx" TagName="Header" TagPrefix="uc1" %>
<%@ Register Src="~/UserControls/New_Footer.ascx" TagName="Footer" TagPrefix="uc2" %>
<%@ Register Assembly="DevExpress.Web.v14.2" Namespace="DevExpress.Web" TagPrefix="dxw" %>

<!DOCTYPE html>

<html lang="en">
<head runat="server">
    <title>Configuration</title>
    <meta content="charset=utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />

    <link href="../css/CustomeAlert/demos.css" rel="stylesheet" type="text/css" />
    <link href="../css/CustomeAlert/themes/jquery.ui.all.css" rel="stylesheet" type="text/css" />
    <link id="reset" runat="server" href="../css/reset.css" rel="stylesheet" type="text/css" />
    <link id="stylesheet2" runat="server" href="../css/stylesheet2.css" rel="stylesheet" type="text/css" />
    <link id="dropdown" runat="server" href="../css/dropdown.css" rel="stylesheet" type="text/css" />
    <link id="ieonly" runat="server" rel="stylesheet" type="text/css" href="" />
    <link id="datepicker" runat="server" type="text/css" href="../css/ui.datepicker.css" rel="stylesheet" />
    <link id="uicore" runat="server" type="text/css" href="../css/ui.core.css" rel="stylesheet" />
    <link id="uitheme" runat="server" type="text/css" href="../css/ui.theme.css" rel="stylesheet" />

    <%--Custom Theme for DevEx 14.2--%>
    <link type="text/css" href="~/App_Themes/Office2003Blue/GridView/grid.css" rel="stylesheet" />
    <link type="text/css" href="~/App_Themes/Office2003Blue/Editors/styles.css" rel="stylesheet" />
    <link rel="SHORTCUT ICON" href="../images/favicon.ico" />

    <%--BootStrap Css--%>
    <link id="BootStrapCss" href="../css/bootstrap.css" runat="server" rel="stylesheet" type="text/css" />
    <link id="mainstyle" runat="server" href="../css/mainstyle.css" rel="stylesheet" type="text/css" />
    <%--End of BootStrap Css--%>

    <script src="../js/CustomAlert/jquery.min.js" type="text/javascript"></script>
    <script src="../js/CustomAlert/jquery-ui-1.10.3.custom.min.js" type="text/javascript"></script>
    <script src="../js/CustomAlert/jquery-ui-1.10.3.custom.js" type="text/javascript"></script>
    <script src="../js/CustomAlert/CustomAlert.js" type="text/javascript"></script>
    <%--<script type="text/javascript" src="../js/jquery-1.3.2.js"></script>--%>
    <script type="text/javascript" src="../js/jquery-1.5.1.min.js"></script>
    <script type="text/javascript" src="../js/ui.datepicker.js"></script>
    <script type="text/javascript" src="../js/JQQueryDatePicker.js"></script>

    <script src="../js/wow.min.js"></script>
</head>
<body>
    <div class="pageContainer">
        <form id="form1" runat="server">
            <asp:ScriptManager ID="ScriptManager1" runat="server" EnablePageMethods="true">
            </asp:ScriptManager>
            <asp:UpdatePanel runat="server" ID="updControllerDetails" UpdateMode="Conditional">
                <ContentTemplate>
                    <!-- Header Starts Here -->
                    <uc1:Header ID="ucHeader" runat="server" />
                    <!-- Nav Ends Here -->
                    <!-- Content Starts Here -->
                    <div id="outer">
                        <div id="inner">
                            <div id="float-wrap">
                                <!-- Main Content Starts Here -->
                                <div id="content">
                                    <div class="content-wrap">
                                        <div id="top-content" class="head-part">
                                            <div id="heading" class="col-sm-4 col-md-3">
                                                <img class="icon" src="../images/configuration-icon.jpg" alt="" />
                                                <h1>
                                                    <asp:Literal ID="lblConfigurationCaption" runat="server">Configuration</asp:Literal>
                                                </h1>
                                                <a href="MapPage.aspx">
                                                    <asp:Label ID="lblHomeCaption" Text="Home" runat="server"></asp:Label>
                                                </a>
                                                <span>&gt;</span>
                                                <asp:LinkButton ID="lnkControllerMgmt" PostBackUrl="ControllerMaster.aspx" runat="server"
                                                    Text="Controller Management" OnClick="lnkControllerMgmt_Click">
                                                </asp:LinkButton>
                                            </div>
                                            <div class="col-sm-8 col-md-9 head-part-btns">
                                                <div class="pull-right">
                                                    <asp:LinkButton ID="lbtnAddController" runat="server" CssClass="MultilingualBtn" OnClick="lbtnAddController_Click"
                                                        OnClientClick="ShowPopUp();">
                                                        <span id="Span1" runat="server" class="MultilingualBtnspan">
                                                            <div class="AddGeozone">
                                                                <div id="AddVendorDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                    Add Controller
                                                                </div>
                                                            </div>
                                                        </span>
                                                    </asp:LinkButton>
                                                    <asp:LinkButton ID="btnBack" runat="server" CssClass="MultilingualBtn" CausesValidation="false"
                                                        PostBackUrl="~/Forms/ConfigurationSetup.aspx">
                                                        <span id="Span4" runat="server" class="MultilingualBtnspan">
                                                            <div class="Back">
                                                                <div id="BacktoConfigurationDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                    Back to Configuration
                                                                </div>
                                                            </div>
                                                        </span>
                                                    </asp:LinkButton>
                                                </div>
                                            </div>
                                            <div class="clear clearfix">
                                            </div>
                                        </div>
                                        <div class="clear clearfix">
                                        </div>
                                    </div>
                                    <asp:Panel ID="pnlControllerInfo" runat="server" Visible="false">
                                        <div class="form-box">
                                            <h1>
                                                <span class="icon" style="padding-top: 5">
                                                    <img src="../images/vehicle-icon.gif" alt="" title="" />
                                                </span>
                                                <asp:Label ID="lblVenInfoHeading" runat="server" Text="Controller Information"></asp:Label>
                                            </h1>
                                            <div class="form-tbl rptFormTbl">
                                                <div class="col-sm-10 col-md-9 form-horizontal nullpadding">
                                                    <asp:Panel ID="pnlequipment" runat="server">
                                                        <div>

                                                            <div class="form-group">
                                                                <div class="col-sm-2 col-xs-4 icon-img">
                                                                    <asp:Label ID="lblDevID" runat="server" Text="ESP"></asp:Label>
                                                                    <asp:Label ID="lblManDeviceID" runat="server" ForeColor="Red">*</asp:Label>
                                                                </div>
                                                                <div class="col-sm-4 col-xs-8">
                                                                    <asp:Label ID="lblDevice" runat="server" Text="Device ID of the Equipment" Visible="false"></asp:Label>
                                                                    <asp:DropDownList ID="ddlEquipmentId" runat="server" TabIndex="1" AppendDataBoundItems="true" CssClass="form-control"
                                                                        OnSelectedIndexChanged="ddlEquipmentId_SelectedIndexChanged" AutoPostBack="true">
                                                                    </asp:DropDownList>
                                                                </div>
                                                            </div>
                                                            <div class="form-group">
                                                                <div class="col-sm-2 col-xs-4 icon-img">
                                                                    <asp:Label ID="lblPassage" runat="server" Text="Passage"></asp:Label>
                                                                    <span style="color: red">*</span>
                                                                </div>
                                                                <div class="col-sm-4 col-xs-7 controllinebreak">
                                                                    <asp:DropDownList ID="ddlPassage" runat="server" TabIndex="2" CssClass="form-control" AutoPostBack="true"
                                                                        OnSelectedIndexChanged="ddlPassage_SelectedIndexChanged" onchange="document.getElementById('divMsg').innerHTML='';ShowPopUp();">
                                                                    </asp:DropDownList>
                                                                </div>
                                                                <div class="col-sm-1 col-xs-1 nullpadding">
                                                                    <div id="AddPassageType" runat="server">
                                                                        <asp:ImageButton ID="ibtnAddNewPassageType" runat="server" ToolTip="Add Passage" ImageUrl="../images/add-icon.gif"
                                                                            OnClick="ibtnAddNewPassageType_Click"></asp:ImageButton>
                                                                    </div>
                                                                    <div id="EditPassageType" runat="server">
                                                                        <asp:ImageButton ID="ibtnEditPassageType" ToolTip="Edit Passage" runat="server" OnClick="ibtnEditPassageType_Click" Visible="false"
                                                                            ImageUrl="../images/icn-edit.gif" Style="width: auto;" OnClientClick="document.getElementById('divMsg').innerHTML='';" />
                                                                    </div>
                                                                </div>
                                                            </div>
                                                            <div class="form-group">
                                                                <div class="col-sm-2 col-xs-4 icon-img">
                                                                    <asp:Label ID="lblField" runat="server" Text="Chamber / Section"></asp:Label>
                                                                    <span style="color: red">*</span>
                                                                </div>
                                                                <div class="col-sm-4 col-xs-7 controllinebreak">
                                                                    <asp:DropDownList ID="ddlField" runat="server" TabIndex="3" CssClass="form-control" AutoPostBack="true"
                                                                        OnSelectedIndexChanged="ddlField_SelectedIndexChanged">
                                                                    </asp:DropDownList>
                                                                </div>
                                                                <div class="col-sm-1 col-xs-1 nullpadding">
                                                                    <div id="AddFieldType" runat="server">
                                                                        <asp:ImageButton ID="ibtnAddNewFieldType" runat="server" ToolTip="Add Field" ImageUrl="../images/add-icon.gif"
                                                                            OnClick="ibtnAddNewFieldType_Click"></asp:ImageButton>
                                                                    </div>
                                                                    <div id="EditFieldType" runat="server">
                                                                        <asp:ImageButton ID="ibtnEditFieldType" ToolTip="Edit Passage" runat="server" OnClick="ibtnEditFieldType_Click" Visible="false"
                                                                            ImageUrl="../images/icn-edit.gif" Style="width: auto;" OnClientClick="document.getElementById('divMsg').innerHTML='';" />
                                                                    </div>
                                                                </div>
                                                            </div>
                                                            <div id="divDCSIM" class="form-group" runat="server" visible="false">
                                                                <div class="col-sm-2 col-xs-4 icon-img">
                                                                    <asp:Label ID="lblDCSIM" runat="server" Text="DCSIM"></asp:Label>
                                                                    <span style="color: red">*</span>
                                                                </div>
                                                                <div class="col-sm-4 col-xs-7 controllinebreak">
                                                                    <asp:DropDownList ID="ddlDCSIM" runat="server" TabIndex="4" CssClass="form-control" AutoPostBack="true"
                                                                        OnSelectedIndexChanged="ddlDCSIM_SelectedIndexChanged">
                                                                    </asp:DropDownList>
                                                                </div>
                                                                <div class="col-sm-1 col-xs-1 nullpadding">
                                                                    <div id="AddDCSIMType" runat="server">
                                                                        <asp:ImageButton ID="ibtnAddNewDCSIMType" runat="server" ToolTip="Add DCSIM" ImageUrl="../images/add-icon.gif"
                                                                            OnClick="ibtnAddNewDCSIMType_Click"></asp:ImageButton>
                                                                    </div>
                                                                    <div id="EditDCSIMType" runat="server">
                                                                        <asp:ImageButton ID="ibtnEditDCSIMType" ToolTip="Edit Passage" runat="server" OnClick="ibtnEditDCSIMType_Click" Visible="false"
                                                                            ImageUrl="../images/icn-edit.gif" Style="width: auto;" OnClientClick="document.getElementById('divMsg').innerHTML='';" />
                                                                    </div>
                                                                </div>
                                                            </div>
                                                            <div class="form-group">
                                                                <div class="col-sm-2 col-xs-4 icon-img">
                                                                    <asp:Label ID="lblCntrlId" runat="server" Text="Controller ID"></asp:Label>
                                                                    <span style="color: red">*</span>
                                                                </div>
                                                                <div class="col-sm-4 col-xs-8 form-controllinebreak">
                                                                    <asp:DropDownList ID="ddlControllerId" runat="server" TabIndex="6" CssClass="form-control">
                                                                    </asp:DropDownList>
                                                                </div>
                                                            </div>
                                                            <div class="form-group">
                                                                <div class="col-sm-2 col-xs-4 icon-img">
                                                                    <asp:Label ID="lblControllerLocation" runat="server" Text="Location"></asp:Label>
                                                                    <%--<span style="color: red">*</span>--%>
                                                                </div>
                                                                <div class="col-sm-4 col-xs-8">
                                                                    <%--OnSelectedIndexChanged="ddlEquipType_SelectedIndexChanged"--%>
                                                                    <asp:DropDownList ID="ddlControllerLocation" runat="server" TabIndex="5" CssClass="form-control" AutoPostBack="false">
                                                                        <asp:ListItem Text="Select" Value="0"></asp:ListItem>
                                                                        <asp:ListItem Text="Inlet" Value="1"></asp:ListItem>
                                                                        <asp:ListItem Text="Outlet" Value="2"></asp:ListItem>
                                                                        <asp:ListItem Text="Intermediate" Value="3"></asp:ListItem>
                                                                    </asp:DropDownList>
                                                                </div>
                                                            </div>
                                                            <div class="form-group">
                                                                <div class="col-sm-2 col-xs-4 icon-img">
                                                                    <asp:Label ID="lblControllerName" runat="server" Text="Controller Name"></asp:Label>
                                                                    <span style="color: red">*</span>
                                                                </div>
                                                                <div class="col-sm-4 col-xs-8">
                                                                    <asp:TextBox ID="txtControllerName" runat="server" onpaste="return false" MaxLength="49"
                                                                        CssClass="form-control" TabIndex="7">
                                                                    </asp:TextBox>
                                                                </div>
                                                            </div>
                                                            <div class="form-group">
                                                                <div class="col-sm-2 col-xs-4 icon-img">
                                                                    <asp:Label ID="lblControllerSrNo" runat="server" Text="Controller Sr.No"></asp:Label>
                                                                    <span style="color: red">*</span>
                                                                </div>
                                                                <div class="col-sm-4 col-xs-8 form-controllinebreak">
                                                                    <%--chkDescription(event,this,49);onkeypress="return false;"--%>
                                                                    <asp:TextBox ID="txtControllerSrNo" runat="server" onpaste="return false" MaxLength="99" TextMode="SingleLine"
                                                                        CssClass="form-control" TabIndex="8">
                                                                    </asp:TextBox>
                                                                </div>
                                                            </div>
                                                            <div class="form-group">
                                                                <div class="col-sm-2 col-xs-4 icon-img">
                                                                    <asp:Label ID="lblWrntyStrtdt" runat="server" Text="Warranty Start Date"></asp:Label>
                                                                    <span style="color: red">*</span>
                                                                </div>
                                                                <div class="col-sm-4 col-xs-8 form-controllinebreak">
                                                                    <asp:TextBox ID="txtWrntyStrtdt" runat="server" onkeypress="return CalendarTab(event);"
                                                                        onpaste="return false" CssClass="form-control" TabIndex="9"></asp:TextBox>
                                                                </div>
                                                            </div>
                                                            <div class="form-group">
                                                                <div class="col-sm-2 col-xs-4 icon-img">
                                                                    <asp:Label ID="lblWrntyEndDt" runat="server" Text="Warranty end Date"></asp:Label>
                                                                    <span style="color: red">*</span>
                                                                </div>
                                                                <div class="col-sm-4 col-xs-8">
                                                                    <asp:TextBox ID="txtWrntyEndDt" runat="server" onkeypress="return CalendarTab(event);"
                                                                        onpaste="return false" CssClass="form-control" TabIndex="10"></asp:TextBox>
                                                                </div>
                                                            </div>
                                                        </div>
                                                    </asp:Panel>
                                                    <div class="form-group">
                                                        <div class="col-sm-10">
                                                            <asp:Label ID="Label1" runat="server" ForeColor="Red">*</asp:Label>
                                                            <asp:Label ID="lblIndicatesMandatory" runat="server">Required Fields</asp:Label>
                                                        </div>
                                                    </div>
                                                    <div class="form-group">
                                                        <div class="col-sm-2"></div>
                                                        <div class="col-sm-8">
                                                            <asp:LinkButton ID="btnUpdateController" ValidationGroup="vgVeh" runat="server" CssClass="MultilingualBtn"
                                                                TabIndex="18" CausesValidation="false" OnClientClick="return ValidateControllerInfo(this);ShowPopUp();"
                                                                OnClick="btnUpdateController_Click">
                                                                <span id="Span6" runat="server" class="MultilingualBtnspan">
                                                                    <div class="Update">
                                                                        <div id="UpdateVehicleButDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                            Update
                                                                        </div>
                                                                    </div>
                                                                </span>
                                                            </asp:LinkButton>
                                                            <asp:LinkButton ID="btnSaveController" runat="server" CssClass="MultilingualBtn" ValidationGroup="vgVeh"
                                                                TabIndex="19" OnClientClick="return ValidateControllerInfo(this);ShowPopUp();" OnClick="btnSaveController_Click">
                                                                <span id="Span7" runat="server" class="MultilingualBtnspan">
                                                                    <div class="Save">
                                                                        <div id="AddVehicleButDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                            Save
                                                                        </div>
                                                                    </div>
                                                                </span>
                                                            </asp:LinkButton>
                                                            <asp:LinkButton ID="btnControllerCancel" runat="server" CssClass="MultilingualBtn" OnClick="btnControllerCancel_Click"
                                                                OnClientClick="return ShowPopUp();" TabIndex="20" CausesValidation="false">
                                                                <%--OnClientClick="return ClearData();"--%>
                                                                <span id="Span8" runat="server" class="MultilingualBtnspan">
                                                                    <div class="Cancel">
                                                                        <div id="UserCancelDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                            Cancel
                                                                        </div>
                                                                    </div>
                                                                </span>
                                                            </asp:LinkButton>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="clear clearfix">
                                            </div>
                                        </div>
                                    </asp:Panel>
                                    <asp:Panel ID="pnlControllersList" runat="server">
                                        <div id="grid-dsply">
                                            <div id="top">
                                                <div class="right-col">
                                                    <span class="dropdown">
                                                        <dxw:ASPxComboBox ID="ASPxCboExport" runat="server" ValueType="System.String" Width="80px"
                                                            ShowImageInEditBox="True" ClientInstanceName="ASPxCboExport" SelectedIndex="0"
                                                            EnableTheming="true" Theme="Office2003Blue"
                                                            CssFilePath="~/App_Themes/Office2003Blue/Editors/styles.css" CssPostfix="Office2003_Blue">
                                                            <Items>
                                                                <dxw:ListEditItem ImageUrl="../images/icn-pdf.jpg" Text="pdf" Value="pdf" />
                                                                <dxw:ListEditItem ImageUrl="../images/icn-excel.jpg" Text="xls" Value="xls" />
                                                                <dxw:ListEditItem ImageUrl="../images/icn-excel-xlsx.png" Text="xlsx" Value="xlsx" />
                                                                <%--<dxw:ListEditItem ImageUrl="../images/icn-word.jpg" Text="rtf" Value="rtf" />--%>
                                                                <%--<dxw:ListEditItem ImageUrl="../images/icn-csv.gif" Text="csv" Value="csv" />--%>
                                                            </Items>
                                                        </dxw:ASPxComboBox>
                                                    </span>
                                                    <span class="txt">
                                                        <asp:LinkButton ID="btnExport" runat="server" CssClass="MultilingualBtn" OnClick="btnExport_Click">
                                                            <span id="Span9" runat="server" class="MultilingualBtnspan">
                                                                <div class="Export">
                                                                    <div id="ExportButDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                        Export
                                                                    </div>
                                                                </div>
                                                            </span>
                                                        </asp:LinkButton>
                                                    </span>
                                                </div>
                                            </div>
                                            <div class="clear clearfix">
                                            </div>
                                            <div class="table-responsive">
                                                <dxw:ASPxGridView ID="gvControllerData" runat="server" Width="100%" EnableTheming="true" Theme="Office2003Blue"
                                                    EnableViewState="true" KeyFieldName="Sno" CssFilePath="~/App_Themes/Office2003Blue/GridView/styles.css"
                                                    CssPostfix="Office2003_Blue" OnHtmlRowCreated="gvControllerData_HtmlRowCreated" OnDataBinding="gvControllerData_DataBinding">
                                                    <Styles CssFilePath="~/App_Themes/Office2003Blue/GridView/grid.css" AlternatingRow-Enabled="True"
                                                        CssPostfix="Office2003_Blue">
                                                        <Header ImageSpacing="5px" SortingImageSpacing="5px">
                                                        </Header>
                                                        <LoadingPanel ImageSpacing="10px">
                                                        </LoadingPanel>
                                                        <PagerBottomPanel CssClass="PageFooter">
                                                        </PagerBottomPanel>
                                                        <PagerTopPanel CssClass="PageFooter">
                                                        </PagerTopPanel>
                                                    </Styles>
                                                    <SettingsPager PageSize="20" PrevPageButton-Image-Url="../App_Themes/Office2003Blue/GridView/pPrev.gif"
                                                        PrevPageButton-Image-UrlDisabled="../App_Themes/Office2003Blue/GridView/pPrevDisabled.gif"
                                                        NextPageButton-Image-UrlDisabled="../App_Themes/Office2003Blue/GridView/pNextDisabled.gif"
                                                        NextPageButton-Image-Url="../App_Themes/Office2003Blue/GridView/pNext.gif" AlwaysShowPager="true">
                                                    </SettingsPager>
                                                    <Columns>
                                                        <dxw:GridViewDataColumn FieldName="ControllerSrNo" Caption="ControllerSrNo" VisibleIndex="0"
                                                            CellStyle-HorizontalAlign="Left" Width="15%">
                                                            <HeaderCaptionTemplate>
                                                                <span class="icon">
                                                                    <img src="../images/icn-division.gif" align="top" alt="" title="" /></span>
                                                                <span class="label">
                                                                    <asp:Label ID="lblControllerSrNoCaption" runat="server" Text="Controller Sr.No"></asp:Label></span>
                                                            </HeaderCaptionTemplate>
                                                        </dxw:GridViewDataColumn>
                                                        <dxw:GridViewDataColumn FieldName="ControllerId" Caption="ControllerId" VisibleIndex="0"
                                                            CellStyle-HorizontalAlign="Left" Width="3%" Visible="false">
                                                            <HeaderCaptionTemplate>
                                                                <span class="icon">
                                                                    <img src="../images/icn-division.gif" align="top" alt="" title="" /></span>
                                                                <span class="label">
                                                                    <asp:Label ID="lblControllerIdCaption" runat="server" Text="ControllerId"></asp:Label></span>
                                                            </HeaderCaptionTemplate>
                                                        </dxw:GridViewDataColumn>
                                                        <dxw:GridViewDataColumn FieldName="EquipmentName" Caption="ESP" VisibleIndex="2" Width="15%"
                                                            CellStyle-Wrap="True" HeaderStyle-HorizontalAlign="Center" CellStyle-HorizontalAlign="Left" GroupIndex="0">
                                                            <HeaderCaptionTemplate>
                                                                <span class="icon">
                                                                    <img src="../images/icn-firmware-update.gif" alt="" title="" align="middle" /></span>
                                                                <span class="label">
                                                                    <asp:Label ID="lblCntrctprdCaption" runat="server" Text="ESP"></asp:Label></span>
                                                            </HeaderCaptionTemplate>
                                                            <Settings AllowGroup="True" />
                                                        </dxw:GridViewDataColumn>
                                                        <dxw:GridViewDataTextColumn FieldName="PassageName" Caption="Passage"
                                                            VisibleIndex="3" Width="8%" HeaderStyle-HorizontalAlign="Center" CellStyle-HorizontalAlign="Left">
                                                            <HeaderCaptionTemplate>
                                                                <span class="icon">
                                                                    <img src="../images/icn-division.gif" alt="" title="" align="middle" /></span>
                                                                <span class="label">
                                                                    <asp:Label ID="lblPassageCaption" runat="server" Text="Passage"></asp:Label></span>
                                                            </HeaderCaptionTemplate>
                                                            <PropertiesTextEdit DisplayFormatString="dd-MMM-yyyy" NullDisplayText="-">
                                                            </PropertiesTextEdit>
                                                            <Settings AllowAutoFilter="False" />
                                                        </dxw:GridViewDataTextColumn>
                                                        <dxw:GridViewDataTextColumn FieldName="FieldName" Caption="Field" VisibleIndex="4"
                                                            CellStyle-Wrap="True" Width="8%" CellStyle-HorizontalAlign="Left">
                                                            <HeaderCaptionTemplate>
                                                                <span class="icon">
                                                                    <img src="../Images/icn-division.gif" alt="" title="" align="middle" /></span>
                                                                <span class="label">
                                                                    <asp:Label ID="lblFieldCaption" runat="server" Text="Field / Chamber"></asp:Label></span>
                                                            </HeaderCaptionTemplate>
                                                            <Settings AllowAutoFilter="False" />
                                                        </dxw:GridViewDataTextColumn>
                                                        <dxw:GridViewDataTextColumn FieldName="DCSIMName" Caption="DCSIM"
                                                            VisibleIndex="4" Width="8%" CellStyle-HorizontalAlign="Left" HeaderStyle-Wrap="True"
                                                            CellStyle-Wrap="True">
                                                            <HeaderCaptionTemplate>
                                                                <span class="icon">
                                                                    <img src="../images/icn-division.gif" alt="" title="" align="middle" /></span>
                                                                <span class="label">
                                                                    <asp:Label ID="lblDCSIMCaption" runat="server" Text="DCSIM"></asp:Label></span>
                                                            </HeaderCaptionTemplate>
                                                            <Settings AllowAutoFilter="False" />
                                                        </dxw:GridViewDataTextColumn>
                                                        <dxw:GridViewDataTextColumn FieldName="ControllerLocation" Caption="Location" VisibleIndex="4"
                                                            CellStyle-Wrap="True" Width="8%" CellStyle-HorizontalAlign="Left">
                                                            <HeaderCaptionTemplate>
                                                                <span class="icon">
                                                                    <img src="../Images/icn-division.gif" alt="" title="" align="middle" /></span>
                                                                <span class="label">
                                                                    <asp:Label ID="lblControllerLocationCaption" runat="server" Text="Location"></asp:Label></span>
                                                            </HeaderCaptionTemplate>
                                                            <Settings AllowAutoFilter="False" />
                                                        </dxw:GridViewDataTextColumn>
                                                        <dxw:GridViewDataColumn FieldName="ControllerPositionId" Caption="ControllerPositionId" VisibleIndex="0"
                                                            CellStyle-HorizontalAlign="Center" Width="5%">
                                                            <HeaderCaptionTemplate>
                                                                <span class="icon">
                                                                    <img src="../images/icn-division.gif" align="top" alt="" title="" /></span>
                                                                <span class="label">
                                                                    <asp:Label ID="lblControllerIdCaption" runat="server" Text="ID"></asp:Label></span>
                                                            </HeaderCaptionTemplate>
                                                        </dxw:GridViewDataColumn>
                                                        <dxw:GridViewDataColumn FieldName="ControllerName" Caption="Controller Name" VisibleIndex="1"
                                                            CellStyle-HorizontalAlign="Left" Width="10%">
                                                            <HeaderCaptionTemplate>
                                                                <span class="icon">
                                                                    <img src="../images/icn-division.gif" align="top" alt="" title="" /></span>
                                                                <span class="label">
                                                                    <asp:Label ID="lblControllerNameCaption" runat="server" Text="Controller Name"></asp:Label></span>
                                                            </HeaderCaptionTemplate>
                                                        </dxw:GridViewDataColumn>
                                                        <dxw:GridViewDataTextColumn FieldName="WarrantyEndDate" Caption="Warranty End Date"
                                                            VisibleIndex="4" Width="10%" CellStyle-HorizontalAlign="Center">
                                                            <HeaderCaptionTemplate>
                                                                <span class="icon">
                                                                    <img src="../images/warranty-expire-date-icon.gif" alt="" title="" align="middle" /></span>
                                                                <span class="label">
                                                                    <asp:Label ID="lblMDaysCaption" runat="server" Text="Warranty End Date"></asp:Label></span>
                                                            </HeaderCaptionTemplate>
                                                            <PropertiesTextEdit DisplayFormatString="dd-MMM-yyyy" NullDisplayText="-">
                                                            </PropertiesTextEdit>
                                                            <Settings AllowAutoFilter="False" />
                                                        </dxw:GridViewDataTextColumn>
                                                        <dxw:GridViewDataTextColumn Caption="View" Width="2%" Name="View" VisibleIndex="5" CellStyle-HorizontalAlign="Center">
                                                            <%--ibtViewVendor_click--%>
                                                            <HeaderTemplate>
                                                            </HeaderTemplate>
                                                            <DataItemTemplate>
                                                                <asp:LinkButton ID="lbtnViewController" runat="server" OnClick="lbtnViewController_Click" CommandArgument='<%# Eval("ControllerId") %>'
                                                                    OnClientClick="return ShowPopUp();" Style="text-decoration: none;">
                                                                    <img src="../images/icn-view.gif" alt="View" title="Click here to View" />
                                                                </asp:LinkButton>
                                                            </DataItemTemplate>
                                                        </dxw:GridViewDataTextColumn>
                                                        <dxw:GridViewDataTextColumn Caption="Edit" VisibleIndex="6" Width="2%" Name="Edit" CellStyle-HorizontalAlign="Center">
                                                            <HeaderTemplate>
                                                            </HeaderTemplate>
                                                            <DataItemTemplate>
                                                                <asp:LinkButton ID="lbtnEditController" runat="server" CommandArgument='<%# Eval("ControllerId") %>'
                                                                    OnClientClick="return ShowPopUp();" OnClick="lbtnEditController_Click" Style="text-decoration: none;">
                                                                    <img src="../images/icn-edit.gif" alt="Edit" title="Click here to Edit"/>
                                                                </asp:LinkButton>
                                                            </DataItemTemplate>
                                                        </dxw:GridViewDataTextColumn>
                                                        <dxw:GridViewDataTextColumn Caption="Delete" Width="2%" HeaderStyle-HorizontalAlign="Center" CellStyle-HorizontalAlign="Center">
                                                            <HeaderTemplate>
                                                            </HeaderTemplate>
                                                            <DataItemTemplate>
                                                                <asp:LinkButton ID="lbtnDeleteController" runat="server" OnClientClick="return ShowPopUp();" CommandArgument='<%# Eval("ControllerId") %>'
                                                                    OnClick="lbtnDeleteController_Click">
                                                                    <img src="../images/delete-icon.gif" alt="Delete" title="Click here to Delete"/>
                                                                </asp:LinkButton>
                                                            </DataItemTemplate>
                                                        </dxw:GridViewDataTextColumn>
                                                    </Columns>
                                                    <Settings ShowVerticalScrollBar="true" VerticalScrollableHeight="500" />
                                                    <Settings ShowFilterRow="true" ShowFilterRowMenu="True" />
                                                    <Settings ShowGroupPanel="true" ShowGroupButtons="true" ShowFooter="True" />
                                                    <SettingsText EmptyDataRow="No Controllers found" />
                                                    <SettingsBehavior AllowFocusedRow="false" AllowDragDrop="false" AutoExpandAllGroups="True" />
                                                    <GroupSummary>
                                                        <%--<dxw:ASPxSummaryItem FieldName="PassageName" DisplayFormat="No.of Passages: {0}" SummaryType="Count" />
                                                        <dxw:ASPxSummaryItem FieldName="FieldName" DisplayFormat="No.of Fields: {0}" SummaryType="Count" />--%>
                                                        <dxw:ASPxSummaryItem FieldName="ControllerName" DisplayFormat="No.of Controllers: {0}" SummaryType="Count" />
                                                    </GroupSummary>
                                                </dxw:ASPxGridView>
                                                <dxw:ASPxGridViewExporter ID="ASPxGridViewExporter1" runat="server" GridViewID="gvControllerData"
                                                    ReportHeader="{\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttbl{\f0\fnil\fcharset0 Times New Roman;}{\f1\fnil\fcharset0 Arial;}}
                                                            \viewkind4\uc1\pard\f0\fs20\b\f1\fs28 Vendor Details\par\par\par}"
                                                    DetailHorizontalOffset="1" DetailVerticalOffset="1" MaxColumnWidth="120">
                                                    <Styles>
                                                        <Default VerticalAlign="Middle">
                                                        </Default>
                                                        <Header BackColor="#D1D1D1" Font-Bold="True" Font-Names="Arial" Font-Size="10pt"
                                                            ForeColor="Black" HorizontalAlign="Center" VerticalAlign="Middle" Wrap="false">
                                                        </Header>
                                                        <Cell VerticalAlign="Middle" Wrap="True" Font-Size="8pt" Font-Names="Arial" HorizontalAlign="Left" ForeColor="Black">
                                                        </Cell>
                                                    </Styles>
                                                    <PageHeader Center="Controller Details" VerticalAlignment="Far">
                                                        <Font Bold="True" Names="Arial" Size="10pt" Underline="True"></Font>
                                                    </PageHeader>
                                                    <PageFooter Right="[Page # of Pages #]">
                                                    </PageFooter>
                                                </dxw:ASPxGridViewExporter>
                                            </div>
                                        </div>
                                    </asp:Panel>
                                </div>
                                <div class="clear clearfix">
                                </div>
                                <asp:Panel ID="pnlAddEditPassage" runat="server" Style="" CssClass="ControlHide edit-LandmarkPanel col-sm-8 col-md-6 col-lg-5">
                                    <asp:UpdatePanel ID="upPassageDetails" runat="server" UpdateMode="Conditional">
                                        <ContentTemplate>
                                            <div class="popup">
                                                <div class="top">
                                                    <h1>
                                                        <asp:Label ID="lblPassageHeading" Text="Add / Edit Data" runat="server"></asp:Label></h1>
                                                    <div class="close">
                                                        <asp:ImageButton ID="ibtClose" runat="server" OnClientClick="CategoryPopup(false, this);"
                                                            ImageUrl="~/Images/popup-close.gif" />
                                                    </div>
                                                    <div class="clear clearfix">
                                                    </div>
                                                </div>
                                                <div class="popup-content">
                                                    <div class="form-tbl form-landmark">
                                                        <div class="form-horizontal">
                                                            <div>
                                                                <div class="row row-Geozone">
                                                                    <div class="col-sm-4">
                                                                        <asp:Label ID="lblPassageName" runat="server" Text="Passage Name" CssClass="label"></asp:Label>
                                                                        <span class="redtxt">*</span>
                                                                    </div>
                                                                    <div class="col-sm-5">
                                                                        <asp:TextBox ID="txtPassageName" runat="server" CssClass="form-control" MaxLength="50" onpaste="return false"
                                                                            ondrop="return false" onkeypress="return chkAlphaNumericWithSpace(event,this,49);" TabIndex="21"></asp:TextBox>
                                                                    </div>
                                                                </div>
                                                                <div class="row row-Geozone">
                                                                    <div class="col-sm-4">
                                                                        <asp:Label ID="Label2" runat="server" Text="Description" CssClass="label"></asp:Label>
                                                                    </div>
                                                                    <div class="col-sm-5">
                                                                        <asp:TextBox ID="txtPassageDescription" TextMode="MultiLine" runat="server" Rows="3" TabIndex="22" MaxLength="149"
                                                                            onkeypress="return chkDescription(event,this,249);" onblur="return disallowScriptTags(this);" CssClass="form-control">
                                                                        </asp:TextBox>
                                                                    </div>
                                                                </div>
                                                                <div class="row row-Geozone">
                                                                    <div class="col-sm-4"></div>
                                                                    <div class="col-sm-8">
                                                                        <div class="col-xs-4 col-sm-3 override-col-width nullpadding">
                                                                            <asp:LinkButton ID="ibtnSavePopupData" runat="server" CssClass="MultilingualBtn" ValidationGroup="vgVeh"
                                                                                TabIndex="23" OnClientClick="return ValidateControllerPopupInfo(this);ShowPopUp();" OnClick="ibtnSavePopupData_Click">
                                                                                <span id="SavePopupData" runat="server" class="MultilingualBtnspan">
                                                                                    <div class="Save">
                                                                                        <div id="divSavePopupData" runat="server" class="MultilingualBtnTextAlign">
                                                                                            Save
                                                                                        </div>
                                                                                    </div>
                                                                                </span>
                                                                            </asp:LinkButton>
                                                                        </div>
                                                                        <div class="col-xs-4 col-sm-3 override-col-width nullpadding">
                                                                            <asp:ImageButton ID="ibtnDeletePopupData" runat="server" TabIndex="24" OnClick="ibtnDeletePopupData_Click"
                                                                                ImageUrl="~/images/btn-delete.jpg" />
                                                                        </div>
                                                                        <div class="col-xs-4 col-sm-3 nullpadding">
                                                                            <asp:ImageButton ID="ibtnCancelPopupData" runat="server" ImageUrl="~/images/btn-cancel.jpg"
                                                                                CausesValidation="false" onkeydown="return setFocus(event,'txtPassageName');"
                                                                                OnClientClick="CategoryPopup(false, this);" TabIndex="25" />
                                                                        </div>
                                                                    </div>
                                                                </div>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </ContentTemplate>
                                    </asp:UpdatePanel>
                                </asp:Panel>
                            </div>
                            <div id="divMsg" runat="server" align="center" style="font-weight: bold;">
                            </div>
                            <cc1:ModalPopupExtender ID="mpeProgressIndicator" runat="server" PopupControlID="progressPopUp"
                                TargetControlID="btnTesting">
                            </cc1:ModalPopupExtender>
                            <asp:Button ID="btnTesting" Style="display: none;" runat="server" />
                            <asp:Panel ID="progressPopUp" runat="server" CssClass="processMessage" Style="display: none;">
                                <center>
                                    <br />
                                    <img alt="Please Wait ..." src="../images/47.gif" /><br />
                                    <br />
                                    <asp:Label ID="lbl_msg12" Text="Processing... Please Wait..." runat="server" CssClass="specialdisplay"></asp:Label>
                                    <br />
                                    <br />
                                </center>
                            </asp:Panel>
                        </div>
                        <!-- Main Content Ends Here -->
                        <div id="left">
                        </div>
                        <div class="clear clearfix">
                        </div>
                    </div>
                    <div id="right">
                    </div>
                    <div class="clear clearfix">
                    </div>
                </ContentTemplate>
                <Triggers>
                    <asp:PostBackTrigger ControlID="btnExport" />
                </Triggers>
            </asp:UpdatePanel>
            <asp:HiddenField ID="hdnPopupType" runat="server" />
        </form>
    </div>
    <!-- Content Ends Here -->
    <uc2:Footer ID="ucFooter" runat="server" />

    <script lang="javascript" type="text/javascript">
        function CategoryPopup(isShow, control) {
            if (document.getElementById('pnlAddEditPassage') != null) {
                document.getElementById('pnlAddEditPassage').style.display = (isShow) ? "block" : "none";
            }
            if (!isShow) {
                if (control == 'ibtnAddNewPassageType' || control.id == 'ibtnEditPassageType')
                    document.getElementById('ddlPassageId').focus();
                else if (control.id == 'ibtnAddNewFieldType' || control.id == 'ibtnEditFieldType')
                    document.getElementById('ddlFieldId').focus();
                else if (control.id == 'ibtnAddNewDCSIMType' || control.id == 'ibtnEditDCSIMType')
                    document.getElementById('ddlDCSIMId').focus();
            }
            else {
                document.getElementById('txtPassageName').focus();
            }
            if (isShow && control != null) {
                document.getElementById('ibtnDeletePopupData').style.display =
                    (control.id == 'ibtnEditPassageType' || control.id == 'ibtnEditFieldType' || control.id == 'ibtnEditDCSIMType') ? "block" : "none";
                if (control.id == 'ibtnAddNewPassageType' || control.id == 'ibtnAddNewFieldType' || control.id == 'ibtnAddNewDCSIMType') {
                    document.getElementById('txtPassageName').value = '';
                    document.getElementById('txtPassageDescription').value = '';
                }
                return true;
            }
            return false;
        }
    </script>
    <script src="../js/myformvalidations.js" type="text/javascript" lang="javascript"></script>
    <script src="../js/CommonFuncitonsInHeader.js" type="text/javascript" lang="javascript"></script>
</body>
</html>
