<%@ page language="C#" autoeventwireup="true" inherits="Forms_VehicleGeozoneAssignment, App_Web_niziglsf" %>

<%@ 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="TimePicker" Namespace="MKB.TimePicker" TagPrefix="MKB" %>

<%--<%@ Register Assembly="DevExpress.Web.ASPxGridView.v8.2, Version=8.2.10.0, Culture=neutral, PublicKeyToken=9b171c9fd64da1d1"
    Namespace="DevExpress.Web.ASPxGridView" TagPrefix="dxwgv" %>
<%@ Register Assembly="DevExpress.Web.ASPxEditors.v8.2, Version=8.2.10.0, Culture=neutral, PublicKeyToken=9b171c9fd64da1d1"
    Namespace="DevExpress.Web.ASPxEditors" TagPrefix="dxe" %>
<%@ Register Assembly="DevExpress.Web.ASPxEditors.v8.2" Namespace="DevExpress.Web.ASPxEditors"
    TagPrefix="dxe" %>
<%@ Register Assembly="DevExpress.Web.ASPxGridView.v8.2.Export" Namespace="DevExpress.Web.ASPxGridView.Export"
    TagPrefix="exp" %>--%>

<%@ Register Assembly="DevExpress.Web.v14.2" Namespace="DevExpress.Web" TagPrefix="dxw" %>

<!DOCTYPE html>
<html lang="en">
<head runat="server">
    <title>tSense-IoT Vehicle Geozone Assignment</title>
    <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" />
    <%--<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta http-equiv="Page-Enter" content="blendTrans(Duration=0)" />
    <meta http-equiv="Page-Exit" content="blendTrans(Duration=0)" />
    <meta http-equiv="X-UA-Compatible" content="IE=7" />--%>
    <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 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="" />
    <%--Custom Theme for DevEx 14.2--%>
    <link id="GridView" runat="server" type="text/css" href="~/App_Themes/Office2003Blue/GridView/grid.css" rel="stylesheet" />
    <link id="Editors" runat="server" type="text/css" href="~/App_Themes/Office2003Blue/Editors/styles.css" rel="stylesheet" />
    <link rel="SHORTCUT ICON" href="../images/favicon.ico" />

    <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>

    <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" />
    <link id="uidatepicker" runat="server" type="text/css" href="../css/ui.datepicker.css"
        rel="stylesheet" />

    <script language="JavaScript1.2" type="text/javascript" src="../js/GridCheckBoxMaintaining.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>
    <%--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/wow.min.js"></script>
</head>
<body>
    <div class="pageContainer">
        <form id="form1" runat="server">
            <asp:ScriptManager ID="ScriptManager1" runat="server">
            </asp:ScriptManager>
            <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                <ContentTemplate>
                    <uc1:Header ID="ucHeader" runat="server" />
                    <!-- 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 col-lg-3">
                                                <asp:Image runat="server" ID="imgGeozone" ImageUrl="../images/geozone-icon.jpg" class="icon" />
                                                <h1>
                                                    <asp:Literal ID="lblGeozoneCaption" runat="server"></asp:Literal></h1>
                                                <a href="Dashboard.aspx">
                                                    <asp:LinkButton ID="lnkHomeCaption" runat="server"></asp:LinkButton></a><span> &gt;</span>
                                                <span><a href="GeozonePanel.aspx">
                                                    <asp:LinkButton ID="lnkGeozoneCaption" runat="server"></asp:LinkButton></a></span>
                                                &gt;<span><a href="VehicleGeozoneAssignment.aspx"><asp:LinkButton ID="lnkAssignmentCaption"
                                                    runat="server"></asp:LinkButton></a></span>
                                            </div>
                                            <div id="" class="col-sm-4 col-md-5 col-lg-5 padding-width-sm-right">
                                                <div class="topIconControl">
                                                    <div class="col-sm-12 padding-width-sm-right">
                                                        <div class="col-sm-6 topControlAlign controllinebreak">
                                                            <div class="col-xs-1 col-sm-2 col-md-2 col-lg-1 padding-width-sm-right">
                                                                <asp:Image ID="imgFleetName" runat="server" ImageUrl="../images/fleet-icon.gif" alt="Fleet Name"
                                                                    title="Fleet Name" CssClass="icon" />
                                                            </div>
                                                            <div class="col-xs-11 col-sm-9 col-md-10 col-lg-11 padding-width-sm">
                                                                <asp:DropDownList ID="ddlFleet" CssClass="form-control FontAlign" runat="server" AutoPostBack="True" OnSelectedIndexChanged="ddlFleet_SelectedIndexChanged">
                                                                </asp:DropDownList>
                                                            </div>
                                                        </div>
                                                        <div class="col-sm-6 topControlAlign controllinebreak">
                                                            <div class="col-xs-1 col-sm-2 col-md-2 col-lg-1 padding-width-sm-right">
                                                                <asp:Image ID="imgVehicle" runat="server" ImageUrl="../images/vehicle-icon.gif"
                                                                    alt="Vehicle" ToolTip="Vehicle" CssClass="icon" />
                                                            </div>
                                                            <div class="col-xs-11 col-sm-9 col-md-10 col-lg-11 padding-width-sm">
                                                                <asp:DropDownList ID="ddlVehicle" CssClass="form-control FontAlign" runat="server" AutoPostBack="true" OnSelectedIndexChanged="ddlVehicle_SelectedIndexChanged">
                                                                </asp:DropDownList>
                                                            </div>
                                                        </div>

                                                    </div>


                                                    <div class="col-sm-12 padding-width-sm-right row-Geozone">
                                                        <div class="col-sm-6  topControlAlign controllinebreak">
                                                            <div class="col-xs-1 col-sm-2 col-md-2 col-lg-1 padding-width-sm-right">
                                                                <asp:Image ID="Image1" runat="server" ImageUrl="../images/icn-time.gif" alt="Geozone Time Limit"
                                                                    title="Fleet Name" CssClass="icon" Height="13" Width="16" Visible="false" />
                                                            </div>
                                                            <div class="col-xs-11 col-sm-9 col-md-10 col-lg-11 padding-width-sm">
                                                                <asp:LinkButton ID="ibtDelayNotification" runat="server" CssClass="MultilingualBtn"
                                                                    OnClientClick="LoadDelayNotifyPopup();EnableControlDelay(false);return false;">

                                                                    <span id="Span" runat="server" class="MultilingualBtnspan">
                                                                        <div class="AddGeozone">
                                                                            <div id="DelayNotification" runat="server" class="MultilingualBtnTextAlign">
                                                                                Settings
                                                                            </div>
                                                                        </div>
                                                                    </span>
                                                                </asp:LinkButton>
                                                            </div>
                                                        </div>

                                                        <%--<asp:CheckBox ID="chkEnableGRestricted" runat="server" Text="Is Restricted" />--%>
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="col-sm-4 col-md-4 col-lg-4 head-part-btns">
                                                <div class="pull-right">

                                                    <asp:ImageButton PostBackUrl="~/Forms/ManageGeozone.aspx" ID="ibtManageGeozones1"
                                                        runat="server" ImageUrl="../images/btn-manage-geozone.jpg" OnClientClick="ShowPopUp();"
                                                        Visible="false" />&nbsp;
                                                            <asp:LinkButton ID="ibtManageGeozones" runat="server" CssClass="MultilingualBtn"
                                                                OnClientClick="ShowPopUp();" PostBackUrl="ManageGeozone.aspx">
                                                                <span runat="server" class="MultilingualBtnspan">
                                                                    <div class="ManageGeozone">
                                                                        <div id="ManageGeozoneDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                            Manage Geozone
                                                                        </div>
                                                                    </div>
                                                                </span>
                                                            </asp:LinkButton>
                                                    <asp:ImageButton ID="btnGeozoneVehicleAssignment1" runat="server" ImageUrl="~/images/btn-geozone-vehicle-assign.jpg"
                                                        PostBackUrl="GeozoneVehicleAssignment.aspx" OnClientClick="ShowPopUp();" Visible="false" />
                                                    <asp:LinkButton ID="btnGeozoneVehicleAssignment" runat="server" CssClass="MultilingualBtn"
                                                        OnClientClick="ShowPopUp();" PostBackUrl="GeozoneVehicleAssignment.aspx">
                                                        <span runat="server" class="MultilingualBtnspan">
                                                            <div class="GeozoneVehicle">
                                                                <div id="GeozoneVehicleAssignmentDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                    Geozone Vehicle Assignment
                                                                </div>
                                                            </div>
                                                        </span>
                                                    </asp:LinkButton>
                                                </div>
                                            </div>
                                            <div class="clear clearfix">
                                            </div>
                                            <div class="row-Geozone"></div>
                                        </div>
                                        <asp:UpdatePanel ID="updVehicleGeozoneAssignment" runat="server" UpdateMode="Conditional">
                                            <ContentTemplate>
                                                <asp:Timer ID="tmrCheck" runat="server" Enabled="false" Interval="1000" OnTick="tmrCheck_Tick">
                                                </asp:Timer>
                                                <asp:HiddenField ID="hdnGeozoneIDs" runat="server" Value="" />
                                                <div id="grid-dsply">
                                                    <div id="top">
                                                        <div class="col-sm-12 padding-width-md">
                                                            <span class="icon">
                                                                <asp:Image ID="imgUnassGeozone" runat="server" ImageUrl="../images/icn-unassigned-geozone.gif" /></span>
                                                            <span class="txt">
                                                                <asp:Label ID="lblUnassGeozones" Text="Unassigned Geozones" runat="server"></asp:Label>
                                                                &nbsp;&nbsp;                                                            
                                                            </span>

                                                            <span class="controlLeft checkbox chkSettings">
                                                                <asp:CheckBox ID="chkunAuthorizedGeozone" runat="server" Text="Unauthorised Geozone" />
                                                            </span>
                                                            <asp:HiddenField ID="hdnGeozoneIdsToBeAssinged" runat="server" />
                                                            <asp:HiddenField ID="hdnGeozoneNosToBeAssinged" runat="server" />
                                                            <div class="clear clearfix">
                                                            </div>
                                                        </div>
                                                    </div>
                                                    <div class="clear clearfix">
                                                    </div>
                                                    <div class="table-responsive">
                                                        <dxw:ASPxGridView ID="gvUnAssignedGeozones" ClientInstanceName="gvData" KeyFieldName="GeozoneNo" runat="server"
                                                            CssFilePath="~/App_Themes/Office2003 Blue/{0}/grid.css" CssPostfix="Office2003_Blue"
                                                            EnableTheming="true" Theme="Office2003Blue" Width="100%" AutoGenerateColumns="False"
                                                            OnHtmlRowCreated="gvUnAssignedGeozones_HtmlRowCreated" OnFillContextMenuItems="gvData_FillContextMenuItems">
                                                            <Settings ShowVerticalScrollBar="true" VerticalScrollableHeight="100" />
                                                            <ClientSideEvents SelectionChanged="function(s, e) { OnGridSelectionChanged(); }" />

                                                            <Styles CssFilePath="~/App_Themes/Office2003Blue/{0}/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 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>
                                                            <SettingsContextMenu Enabled="false" EnableGroupPanelMenu="False" ColumnMenuItemVisibility-GroupByColumn="false" ColumnMenuItemVisibility-ShowGroupPanel="false"
                                                                EnableFooterMenu="False" ColumnMenuItemVisibility-ShowFooter="false" RowMenuItemVisibility-NewRow="false" RowMenuItemVisibility-EditRow="false"
                                                                RowMenuItemVisibility-DeleteRow="false" EnableRowMenu="false">
                                                            </SettingsContextMenu>
                                                            <ClientSideEvents ContextMenuItemClick="function(s,e) {                                                         
                                                                                switch(e.item.name) {    
                                                                                        case 'SelectAll':
                                                                                            gvUnAssignedGeozones.SelectRows();
                                                                                            break;
                                                                                        case 'DeselectAll':
                                                                                            gvUnAssignedGeozones.UnselectRows();
                                                                                            break;} }" />
                                                            <Columns>
                                                                <dxw:GridViewCommandColumn ShowSelectCheckbox="True" Width="3%" VisibleIndex="0"
                                                                    Name="Checkbox">
                                                                    <HeaderTemplate>
                                                                        <input type="checkbox" onclick="gvData.SelectAllRowsOnPage(this.checked);" style="vertical-align: middle;"
                                                                            title="Select/Unselect all rows on the page"></input>
                                                                    </HeaderTemplate>
                                                                    <HeaderStyle Paddings-PaddingTop="1" Paddings-PaddingBottom="1" HorizontalAlign="Center" />
                                                                </dxw:GridViewCommandColumn>
                                                                <dxw:GridViewDataTextColumn Caption="Geozone Name" FieldName="GeozoneName" VisibleIndex="2"
                                                                    Width="18%">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image ID="imgGeozoneName" runat="server" ImageUrl="../images/icn-geo-zone-name.gif"
                                                                                align="top" AlternateText="Geozone Name" ToolTip="Geozone Name" /></span>
                                                                        <span class="label">
                                                                            <asp:Label ID="lblGeozoneName" runat="server" Text="Geozone Name"></asp:Label></span>
                                                                    </HeaderCaptionTemplate>
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="15%" Caption="Description" FieldName="Description"
                                                                    VisibleIndex="3">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image ID="imgDescription" runat="server" ImageUrl="../images/icn-description.gif"
                                                                                align="top" AlternateText="Description" ToolTip="Description" /></span>
                                                                        <span class="label">
                                                                            <asp:Label ID="lblDescription" runat="server" Text="Description"></asp:Label>
                                                                        </span>
                                                                    </HeaderCaptionTemplate>
                                                                    <CellStyle Wrap="True">
                                                                    </CellStyle>
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="9%" Caption="Direction" FieldName="Direction"
                                                                    VisibleIndex="4">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image runat="server" ID="imgDirection" ImageUrl="../images/compass.png" align="top"
                                                                                AlternateText="Direction" ToolTip="Direction" /></span> <span class="label">
                                                                                    <asp:Label ID="lblDirection" runat="server" Text="Direction"></asp:Label></span>
                                                                    </HeaderCaptionTemplate>
                                                                    <Settings AllowSort="True" />
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="9%" Caption="Severity" FieldName="AlarmLevelName"
                                                                    VisibleIndex="5">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image ID="imgSeverity" ImageUrl="../images/icn-severity.gif" runat="server"
                                                                                align="top" AlternateText="Severity" ToolTip="Severity" /></span> <span class="label">
                                                                                    <asp:Label ID="lblSeverity" runat="server" Text="Severity"></asp:Label>
                                                                                </span>
                                                                    </HeaderCaptionTemplate>
                                                                    <Settings AllowSort="True" />
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="10%" Caption="Category" FieldName="CategoryName"
                                                                    VisibleIndex="6">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image ID="imgCategory" runat="server" ImageUrl="../images/icn-category.gif"
                                                                                align="top" AlternateText="Category" ToolTip="Category" /></span> <span class="label">
                                                                                    <asp:Label ID="lblCategory" runat="server" Text="Category"></asp:Label>
                                                                                </span>
                                                                    </HeaderCaptionTemplate>
                                                                    <Settings AllowSort="True" />
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="18%" Caption="Email Users" FieldName="Email"
                                                                    VisibleIndex="7">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image ID="imgEmaiUsers" ImageUrl="../images/icn-email-users.gif" runat="server"
                                                                                align="top" AlternateText="Email Users" ToolTip="Email Users" /></span>
                                                                        <span class="label">
                                                                            <asp:Label ID="lblEmailUsers" runat="server" Text="Email Users"></asp:Label>
                                                                        </span>
                                                                    </HeaderCaptionTemplate>
                                                                    <Settings AllowSort="True" AllowAutoFilter="False" />
                                                                    <CellStyle Wrap="True">
                                                                    </CellStyle>
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="18%" Caption="SMS Users" FieldName="SMSUserNameList"
                                                                    VisibleIndex="8">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image ID="imgSMS" runat="server" ImageUrl="../images/icn-sms-users.gif" align="top"
                                                                                AlternateText="SMS" ToolTip="SMS" /></span> <span class="label">
                                                                                    <asp:Label runat="server" ID="lblSMS" Text="SMS"></asp:Label>
                                                                                </span>
                                                                    </HeaderCaptionTemplate>
                                                                    <Settings AllowSort="True" AllowAutoFilter="False" />
                                                                    <CellStyle Wrap="True">
                                                                    </CellStyle>
                                                                </dxw:GridViewDataTextColumn>
                                                            </Columns>
                                                            <Settings ShowFilterRow="true" ShowFilterRowMenu="True" />
                                                            <SettingsText EmptyDataRow="No unassigned Geozones matching to the search criteria" />
                                                        </dxw:ASPxGridView>
                                                    </div>
                                                    <div class="clear clearfix">
                                                    </div>
                                                    <%--<<div class="form-box" style="padding: 0px; margin: 0px">
                                                    div class="form-tbl" style="padding: 0px; margin: 0px">--%>
                                                    <div class="form-box">
                                                        <div class="row rowSpace">
                                                            <div class="col-sm-8 col-md-8"></div>
                                                            <div class="col-sm-4 col-md-4">
                                                                <div class="pull-right">
                                                                    <div class="form-groupAlign">
                                                                        <asp:ImageButton ID="lnkAssign1" runat="server" ImageUrl="~/images/btn-assign-geozones.jpg"
                                                                            OnClick="lnkAssignGeozones_Click" Visible="false" />
                                                                        <asp:LinkButton ID="lnkAssign" runat="server" CssClass="MultilingualBtn" OnClick="lnkAssignGeozones_Click"
                                                                            OnClientClick="return valiadteDelayNotify();">

                                                                            <span runat="server" class="MultilingualBtnspan">
                                                                                <div class="AssignGeozone">
                                                                                    <div id="AssignGeozoneDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                                        Assign Geozones
                                                                                    </div>
                                                                                </div>
                                                                            </span>
                                                                        </asp:LinkButton>&nbsp;
                                                                  
                                                                        <asp:ImageButton ID="btnSchedule1" runat="server" ImageUrl="~/images/add-schedule.png"
                                                                            OnClick="btnSchedule_Click" Visible="false" />
                                                                        <asp:LinkButton ID="btnSchedule" runat="server" CssClass="MultilingualBtn" OnClick="btnSchedule_Click">
                                                                            <span runat="server" class="MultilingualBtnspan">
                                                                                <div class="AddSchedule">
                                                                                    <div id="AddScheduleDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                                        Add Schedule
                                                                                    </div>
                                                                                </div>
                                                                            </span>
                                                                        </asp:LinkButton>

                                                                    </div>
                                                                </div>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="clear clearfix">
                                                </div>
                                                <div id="grid-dsply">
                                                    <div id="top">
                                                        <div class="col-sm-12 padding-width-md">
                                                            <span class="icon">
                                                                <asp:Image ID="imgAssignGeozone" CssClass="icon" runat="server" ImageUrl="../images/icn-assign-geozone.gif" />
                                                            </span>
                                                            <span class="txt">
                                                                <asp:Label ID="lblAssignedGeozones" Text="Assigned Geozones" runat="server"></asp:Label>
                                                                &nbsp;</span>


                                                            <div class="right-col">

                                                                <span class="dropdown">
                                                                    <dxw:ASPxComboBox ID="ASPxCboExport" runat="server" ValueType="System.String" Width="80px" Height="20px"
                                                                        ShowImageInEditBox="false" ItemImage-Height="12px" ClientInstanceName="ASPxCboExport" SelectedIndex="0"
                                                                        CssFilePath="~/App_Themes/Office2003Blue/Editors/styles.css" CssPostfix="Office2003_Blue"
                                                                        EnableTheming="true" Theme="Office2003Blue">
                                                                        <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>&nbsp;
                                                            <asp:ImageButton ID="btnExport1" runat="server" ImageUrl="~/images/btn-export.jpg"
                                                                OnClick="btnExport_Click" Visible="false" />
                                                                    <asp:LinkButton ID="btnExport" runat="server" CssClass="MultilingualBtn" OnClick="btnExport_Click">
                                                                        <span id="Span5" runat="server" class="MultilingualBtnspan">
                                                                            <div class="Export">
                                                                                <div id="ExportButDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                                    Export
                                                                                </div>
                                                                            </div>
                                                                        </span>
                                                                    </asp:LinkButton>
                                                                </span>
                                                                </>
                                                        <asp:HiddenField ID="hdnGeozoneIdsToBeUnassigned" runat="server" />
                                                                <asp:HiddenField ID="hdnGeozoneNosToBeUnassigned" runat="server" />
                                                                <div class="clear clearfix">
                                                                </div>
                                                            </div>
                                                        </div>
                                                    </div>
                                                    <dxw:ASPxPopupMenu ID="ExportContextMenu" runat="server" ClientInstanceName="ExportContextMenu"
                                                        EnableTheming="true" Theme="Office2003Blue" OnItemClick="ExportContextMenu_ItemClick" Visible="false">
                                                        <Items>
                                                            <dxw:MenuItem Name="ExportToPDF" Text="Export to PDF" ToolTip="Click to Export to PDF" />
                                                            <dxw:MenuItem Name="ExportToXLS" Text="Export to XLS" ToolTip="Click to Export to XLS" />
                                                            <dxw:MenuItem Name="ExportToXLSX" Text="Export to XLSX" ToolTip="Click to Export to XLSX" />
                                                            <dxw:MenuItem Name="ExportToRTF" Text="Export to RTF" ToolTip="Click to Export to RTF" />
                                                        </Items>
                                                        <ClientSideEvents ItemClick="function(s, e) { ExportContextMenu.Hide(); }" />
                                                    </dxw:ASPxPopupMenu>
                                                    <div class="clear clearfix"></div>
                                                    <div class="table-responsive">
                                                        <dxw:ASPxGridView ID="gvAssignedGeozones" ClientInstanceName="gvAssigne" runat="server"
                                                            CssFilePath="~/App_Themes/Office2003 Blue/{0}/grid.css" CssPostfix="Office2003_Blue"
                                                            EnableTheming="true" Theme="Office2003Blue" KeyFieldName="GeozoneNo"
                                                            Width="100%" AutoGenerateColumns="False" OnHtmlRowCreated="gvAssignedGeozones_HtmlRowCreated"
                                                            OnFillContextMenuItems="gvData_FillContextMenuItems">
                                                            <Settings ShowVerticalScrollBar="true" VerticalScrollableHeight="100" />
                                                            <ClientSideEvents SelectionChanged="function(s, e) { OnGridSelectionChangedUnAssign(); }" />
                                                            <%--<Images ImageFolder="~/App_Themes/Office2003 Blue/{0}/">
                                                        <CollapsedButton Height="12px" Url="~/App_Themes/Office2003Blue/GridView/gvCollapsedButton.png"
                                                            Width="11px" />
                                                        <ExpandedButton Height="12px" Url="~/App_Themes/Office2003Blue/GridView/gvExpandedButton.png"
                                                            Width="11px" />
                                                        <DetailCollapsedButton Height="12px" Url="~/App_Themes/Office2003Blue/GridView/gvCollapsedButton.png"
                                                            Width="11px" />
                                                        <DetailExpandedButton Height="12px" Url="~/App_Themes/Office2003Blue/GridView/gvExpandedButton.png"
                                                            Width="11px" />
                                                    </Images>--%>
                                                            <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 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>
                                                            <SettingsContextMenu Enabled="false" EnableGroupPanelMenu="False" ColumnMenuItemVisibility-GroupByColumn="false" ColumnMenuItemVisibility-ShowGroupPanel="false"
                                                                EnableFooterMenu="False" ColumnMenuItemVisibility-ShowFooter="false" RowMenuItemVisibility-NewRow="false" RowMenuItemVisibility-EditRow="false"
                                                                RowMenuItemVisibility-DeleteRow="false" EnableRowMenu="false">
                                                            </SettingsContextMenu>
                                                            <ClientSideEvents ContextMenuItemClick="
                                                                            function(s,e) {                                                         
                                                                                switch(e.item.name) {    
                                                                                        case 'SelectAll':
                                                                                            gvAssignedGeozones.SelectAllRowsOnPage();
                                                                                            break;
                                                                                        case 'DeselectAll':
                                                                                            gvAssignedGeozones.UnselectAllRowsOnPage();
                                                                                            break;}
                                                                            }" />
                                                            <%--ContextMenu="function OnContextMenu(s, e) {
                                                                if (e.objectType == 'row') {
                                                                    ExportContextMenu.ShowAtPos(ASPxClientUtils.GetEventX(e.htmlEvent), ASPxClientUtils.GetEventY(e.htmlEvent));
                                                                }
                                                            }" />--%>
                                                            <Columns>
                                                                <dxw:GridViewCommandColumn ShowSelectCheckbox="True" VisibleIndex="0" Name="Checkbox"
                                                                    Width="3%">
                                                                    <HeaderTemplate>
                                                                        <input type="checkbox" onclick="gvAssigne.SelectAllRowsOnPage(this.checked);" style="vertical-align: middle;"
                                                                            title="Select/Unselect all rows on the page"></input>
                                                                    </HeaderTemplate>
                                                                    <HeaderStyle Paddings-PaddingTop="1" Paddings-PaddingBottom="1" HorizontalAlign="Center" />
                                                                </dxw:GridViewCommandColumn>
                                                                <dxw:GridViewDataTextColumn Caption="Geozone Name" FieldName="GeozoneName" VisibleIndex="2"
                                                                    Width="18%">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image ID="imgAssGeozoneName" ImageUrl="../images/icn-geo-zone-name.gif" runat="server"
                                                                                align="top" AlternateText="Geozone Name" ToolTip="Geozone Name" /></span>
                                                                        <span class="label">
                                                                            <asp:Label ID="lblAssGeozoneName" runat="server" Text="Geozone Name"></asp:Label>
                                                                        </span>
                                                                    </HeaderCaptionTemplate>
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="15%" Caption="Description" FieldName="Description"
                                                                    VisibleIndex="3">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image ID="imgAssDescription" ImageUrl="../images/icn-description.gif" runat="server"
                                                                                align="top" AlternateText="Description" ToolTip="Description" /></span>
                                                                        <span class="label">
                                                                            <asp:Label ID="lblAssDescription" runat="server" Text="Description"></asp:Label>
                                                                        </span>
                                                                    </HeaderCaptionTemplate>
                                                                    <CellStyle Wrap="True">
                                                                    </CellStyle>
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="9%" Caption="Direction" FieldName="Direction"
                                                                    VisibleIndex="4">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image ID="imgAssDirection" ImageUrl="../images/compass.png" runat="server" align="top"
                                                                                AlternateText="Direction" ToolTip="Direction" /></span> <span class="label">
                                                                                    <asp:Label ID="lblAssDirection" runat="server" Text="Direction"></asp:Label>
                                                                                </span>
                                                                    </HeaderCaptionTemplate>
                                                                    <Settings AllowSort="True" />
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="9%" Caption="Severity" FieldName="AlarmLevelName"
                                                                    VisibleIndex="5">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image ID="imgAssSeverity" runat="server" ImageUrl="../images/icn-severity.gif"
                                                                                align="top" AlternateText="Severity" ToolTip="Severity" /></span> <span class="label">
                                                                                    <asp:Label ID="lblAssSeverity" runat="server" Text="Severity"></asp:Label>
                                                                                </span>
                                                                    </HeaderCaptionTemplate>
                                                                    <Settings AllowSort="True" />
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="10%" Caption="Category" FieldName="CategoryName"
                                                                    VisibleIndex="6">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image ID="imgAssCategory" ImageUrl="../images/icn-category.gif" runat="server"
                                                                                align="top" AlternateText="Category" ToolTip="Category" /></span> <span class="label">
                                                                                    <asp:Label ID="lblAssCategory" runat="server" Text="Category"></asp:Label>
                                                                                </span>
                                                                    </HeaderCaptionTemplate>
                                                                    <Settings AllowSort="True" />
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="18%" Caption="Email Users" FieldName="Email"
                                                                    VisibleIndex="7">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image runat="server" ID="imgAssEmailUsers" ImageUrl="../images/icn-email-users.gif"
                                                                                align="top" AlternateText="Email Users" ToolTip="Email Users" /></span>
                                                                        <span class="label">
                                                                            <asp:Label ID="lblAssEmailUsers" runat="server" Text="Email Users"></asp:Label>
                                                                        </span>
                                                                    </HeaderCaptionTemplate>
                                                                    <Settings AllowSort="True" AllowAutoFilter="False" />
                                                                    <CellStyle Wrap="True">
                                                                    </CellStyle>
                                                                </dxw:GridViewDataTextColumn>
                                                                <dxw:GridViewDataTextColumn Width="18%" Caption="SMS Users" FieldName="SMSUserNameList"
                                                                    VisibleIndex="8">
                                                                    <HeaderCaptionTemplate>
                                                                        <span class="icon">
                                                                            <asp:Image runat="server" ID="imgAssSMS" ImageUrl="../images/icn-sms-users.gif" align="top"
                                                                                AlternateText="SMS" ToolTip="SMS" /></span> <span class="label">
                                                                                    <asp:Label ID="lblAssSMS" runat="server" Text="SMS"></asp:Label>
                                                                                </span>
                                                                    </HeaderCaptionTemplate>
                                                                    <Settings AllowSort="True" AllowAutoFilter="False" />
                                                                    <CellStyle Wrap="True">
                                                                    </CellStyle>
                                                                </dxw:GridViewDataTextColumn>
                                                            </Columns>
                                                            <Settings ShowStatusBar="Auto" ShowFilterRow="true" ShowFilterRowMenu="True" />
                                                            <SettingsText EmptyDataRow="No assigned Geozones matching to the search criteria" />
                                                        </dxw:ASPxGridView>
                                                        <dxw:ASPxGridViewExporter ID="ASPxGridViewExporter1" runat="server" GridViewID="gvAssignedGeozones"
                                                            ReportHeader="{\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttbl{\f0\fnil\fcharset0 Arial;}}
\viewkind4\uc1\pard\qc\b\fs28 Alert Details    \fs24\par
\pard\par
\par
}
">
                                                            <PageFooter Right="[Page # of Pages #]">
                                                            </PageFooter>
                                                        </dxw:ASPxGridViewExporter>
                                                    </div>
                                                    <div class="clear clearfix">
                                                    </div>
                                                    <div class="form-box">
                                                        <div class="row rowSpace">
                                                            <div class="col-sm-6 col-md-8"></div>
                                                            <div class="col-sm-6 col-md-4">
                                                                <div class="form-groupAlign pull-right">
                                                                    <asp:LinkButton ID="btnReAssignVehicles" runat="server" CssClass="MultilingualBtn"
                                                                        OnClick="btnReSchedule_Click">
                                                                        <span id="Span1" runat="server" class="MultilingualBtnspan">
                                                                            <div class="AssignVehicle">
                                                                                <div id="UpdateSettingsDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                                    Update Settings
                                                                                </div>
                                                                            </div>
                                                                        </span>
                                                                    </asp:LinkButton>&nbsp;
                                                                 
                                                                        <asp:ImageButton ID="lnkUnassignGEozones1" runat="server" ImageUrl="~/images/btn-unassign-geozones.jpg"
                                                                            OnClick="lnkUnassignGeozones_Click" Visible="false" />
                                                                    <asp:LinkButton ID="lnkUnassignGEozones" runat="server" CssClass="MultilingualBtn"
                                                                        OnClick="lnkUnassignGeozones_Click">
                                                                        <span runat="server" class="MultilingualBtnspan">
                                                                            <div class="UnassignGeozone">
                                                                                <div id="UnassignGeozoneDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                                    Unassign Geozones
                                                                                </div>
                                                                            </div>
                                                                        </span>
                                                                    </asp:LinkButton>&nbsp;
                                                                 
                                                                        <asp:ImageButton ID="btnSchedule_Unassign1" runat="server" ImageUrl="~/images/add-schedule.png"
                                                                            OnClick="btnSchedule_Unassign_Click" Visible="false" />
                                                                    <asp:LinkButton ID="btnSchedule_Unassign" runat="server" CssClass="MultilingualBtn"
                                                                        OnClick="btnSchedule_Unassign_Click">
                                                                        <span runat="server" class="MultilingualBtnspan">
                                                                            <div class="AddSchedule">
                                                                                <div id="AddScheduleUnDiv" runat="server" class="MultilingualBtnTextAlign">
                                                                                    Add Schedule
                                                                                </div>
                                                                            </div>
                                                                        </span>
                                                                    </asp:LinkButton>
                                                                </div>
                                                            </div>
                                                        </div>
                                                    </div>
                                                    <div class="clear clearfix">
                                                    </div>
                                                </div>
                                            </ContentTemplate>
                                        </asp:UpdatePanel>
                                    </div>
                                </div>
                                <!-- Main Content Ends Here -->
                                <div id="left">
                                </div>
                                <div class="clear clearfix">
                                </div>
                            </div>
                            <div id="right">
                            </div>
                            <div class="clear clearfix">
                            </div>
                        </div>
                    </div>
                </ContentTemplate>
                <Triggers>
                    <asp:PostBackTrigger ControlID="btnExport" />
                </Triggers>
            </asp:UpdatePanel>
            <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="z-index: 1000; display: none;">
                <center>
                    <br />
                    <img id="imgLoad" runat="server" alt="Please Wait ..." src="../images/47.gif" /><br />
                    <br />
                    <asp:Label ID="lbl_msg12" Text="Command is in-progress...." runat="server" CssClass="specialdisplay"></asp:Label>
                    <br />
                    <br />
                </center>
            </asp:Panel>

            <asp:Panel ID="pnlDelayNotify" runat="server" CssClass="pnlTimeGeozone col-xs-10 col-sm-8 col-md-8 col-lg-5">
                <asp:UpdatePanel ID="upDelayNotify" runat="server">
                    <ContentTemplate>
                        <div class="popup">
                            <div class="top">
                                <h1>
                                    <asp:Label ID="lblDelaynotify" Text="Geozone Settings" runat="server"></asp:Label></h1>
                                <div class="close">
                                    <asp:ImageButton ID="imgCloseDelay" runat="server" OnClientClick="CloseDelayNotifyPopup(); return false;"
                                        ImageUrl="~/Images/popup-close.gif" />
                                </div>
                                <div class="clear clearfix">
                                </div>
                            </div>
                            <div class="popup-cont">
                                <asp:CheckBox ID="chkDelayNotification" CssClass="checkbox chkDealyNotify" runat="server" Text="Delay Notifications" />
                                <asp:Panel ID="Panel2" runat="server" GroupingText="Delay Notification Settings">

                                    <b id="rec" runat="server">Recurring :</b>
                                    <asp:Panel ID="Panel1" runat="server">
                                        <div class="row">
                                            <div class="col-sm-12">
                                                <div style="overflow: hidden; padding-left: 15px;" id="Div4">
                                                    <asp:CheckBox ID="chkSelectAllDelay" CssClass="checkbox" runat="server" Text="" onclick="selectAllDelay(this.checked);" />
                                                </div>

                                                <div class="col-sm-12 nullpadding">
                                                    <asp:CheckBoxList ID="chkRecurringDelay" runat="server" onclick="CheckItemDelay(this)"
                                                        RepeatDirection="Horizontal" CssClass="col-sm-10 col-md-10 col-lg-12" Style="vertical-align: middle">
                                                    </asp:CheckBoxList>
                                                </div>
                                            </div>

                                        </div>
                                    </asp:Panel>

                                    <div>&nbsp;</div>

                                    <b id="time" runat="server">Time :</b>
                                    <div class="time">
                                        <div class="row">

                                            <div class="col-sm-3">
                                                <asp:CheckBox ID="chkTrip1" runat="server" />

                                                <asp:Label ID="lblTrip1Time" runat="server" Text="Trip 1 Time"></asp:Label>
                                            </div>
                                            <div class="col-sm-3">
                                                <div class="time1 Responsivetime">
                                                    <MKB:TimeSelector ID="tmTrip1" runat="server" AmPm="AM" DisplaySeconds="False" Hour="10" Font-Size="10pt" Height="21px" SelectedTimeFormat="Twelve">
                                                    </MKB:TimeSelector>
                                                </div>
                                                <dxw:ASPxTimeEdit ID="taTrip" Visible="false" runat="server" DateTime="2009/11/01 15:31:34" CssClass="form-control"
                                                    EnableTheming="true" Theme="Office2003Blue">
                                                    <ValidationSettings ErrorDisplayMode="None" />
                                                </dxw:ASPxTimeEdit>
                                            </div>
                                            <div class="col-sm-3">
                                                <asp:Label ID="lblTrip1Grace" runat="server" Text="Trip 1 Grace Time"></asp:Label>
                                            </div>
                                            <div class="col-sm-3">
                                                <asp:DropDownList ID="ddlTrip1Grace" CssClass="form-control" runat="server">
                                                </asp:DropDownList>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="time">
                                        <div class="row">
                                            <div class="col-sm-3">
                                                <asp:CheckBox ID="chkTrip2" runat="server" />

                                                <asp:Label ID="lblTrip2Time" runat="server" Text="Trip 2 Time"></asp:Label>
                                            </div>
                                            <div class="col-sm-3">
                                                <div class="time1 Responsivetime">
                                                    <MKB:TimeSelector ID="tmTrip2" runat="server" AmPm="AM" DisplaySeconds="False" Hour="10" Font-Size="10pt" Height="21px" SelectedTimeFormat="Twelve">
                                                    </MKB:TimeSelector>
                                                </div>
                                                <dxw:ASPxTimeEdit ID="tbTrip" runat="server" Visible="false" DateTime="2009/11/01 15:31:34" CssClass="form-control"
                                                    EnableTheming="true" Theme="Office2003Blue">
                                                    <ValidationSettings ErrorDisplayMode="None" />
                                                </dxw:ASPxTimeEdit>
                                            </div>
                                            <div class="col-sm-3">
                                                <asp:Label ID="lblTrip2Grace" runat="server" Text="Trip 2 Grace Time"></asp:Label>
                                            </div>
                                            <div class="col-sm-3">
                                                <asp:DropDownList ID="ddlTrip2Grace" CssClass="form-control" runat="server">
                                                </asp:DropDownList>
                                            </div>
                                        </div>
                                    </div>

                                    <div class="time">
                                        <div class="row">
                                            <div class="col-sm-3">
                                                <asp:CheckBox ID="chkTrip3" runat="server" />

                                                <asp:Label ID="lblTrip3Time" runat="server" Text="Trip 3 Time"></asp:Label>
                                            </div>
                                            <div class="col-sm-3">
                                                <div class="time1 Responsivetime">
                                                    <MKB:TimeSelector ID="tmTrip3" runat="server" AmPm="AM" DisplaySeconds="False" Hour="10" Font-Size="10pt" Height="21px" SelectedTimeFormat="Twelve">
                                                    </MKB:TimeSelector>
                                                </div>
                                                <dxw:ASPxTimeEdit ID="tcTrip3" Visible="false" runat="server" DateTime="2009/11/01 15:31:34" CssClass="form-control"
                                                    EnableTheming="true" Theme="Office2003Blue">
                                                    <ValidationSettings ErrorDisplayMode="None" />
                                                </dxw:ASPxTimeEdit>
                                            </div>
                                            <div class="col-sm-3">
                                                <asp:Label ID="lblTrip3Grace" runat="server" Text="Trip 2 Grace Time"></asp:Label>
                                            </div>
                                            <div class="col-sm-3">
                                                <asp:DropDownList ID="ddlTrip3Grace" CssClass="form-control" runat="server">
                                                </asp:DropDownList>
                                            </div>

                                        </div>
                                    </div>

                                </asp:Panel>

                                <asp:Panel ID="Panel3" runat="server" GroupingText="Others">
                                    <div class="rowSpace">
                                        <div class="col-sm-4 padding-width-lg-right">
                                            <asp:CheckBox ID="chkEnableGeozoneSpeed" CssClass="checkbox chkSettings" runat="server" Text="Enable Speed Limit" onclick="hideControlForGeozone(this.checked,1)" />
                                        </div>
                                        <div class="col-sm-4 padding-width-lg-right">
                                            <div class="col-sm-5 col-md-4 col-lg-5 padding-width-lg-right">
                                                <div id="tdGeozoneSpeedDropDown" class="ControlHide">
                                                    <dxw:ASPxComboBox runat="server" ID="ddlGeozoneSpeedTh" ClientInstanceName="ddlGeozoneSpeedTh"
                                                        Width="60px" Height="20px" ValueType="System.Int32" EnableTheming="true" Theme="Office2003Blue"
                                                        CssFilePath="~/App_Themes/Office2003Blue/Editors/styles.css" CssPostfix="Office2003_Blue"
                                                        EnableIncrementalFiltering="true">
                                                    </dxw:ASPxComboBox>
                                                </div>
                                            </div>
                                            <div class="col-sm-4 col-md-3 col-lg-3 padding-width-lg-right" style="margin-top: 4px;">
                                                <asp:Label ID="lblGeozoneSpeedThMetrics" runat="server" class="ControlHide"></asp:Label>
                                            </div>
                                        </div>
                                        <div class="clearfix"></div>
                                    </div>
                                    <div class="rowGeozone">
                                        <asp:CheckBox ID="chkEnableGRestricted" CssClass="checkbox chkSettings" runat="server" Text="Is Restricted" />
                                    </div>
                                    <div class="rowGeozone">
                                        <asp:CheckBox ID="chkEnableGeozoneAlarm" CssClass="checkbox chkSettings" runat="server" Text="Enable" />

                                    </div>
                                    <div class="row-Geozone">
                                        <div class="col-sm-4 padding-width-lg-right">
                                            <asp:CheckBox ID="chkEnableGTimeLimit" CssClass="checkbox chkSettings" runat="server" Text="Enable Time Limit" onclick="hideControlForGeozone(this.checked,2)" />
                                        </div>
                                        <div class="col-sm-4 padding-width-lg-right">
                                            <div id="trGTimelimit" class="ControlHide">
                                                <div class="col-sm-5 col-md-4 col-lg-5 nullpadding">
                                                    <dxw:ASPxComboBox runat="server" ID="ddlGTimeLimit" ClientInstanceName="ddlGTimeLimit"
                                                        Width="60px" Height="20px" ValueType="System.Int32" EnableTheming="true" Theme="Office2003Blue"
                                                        CssFilePath="~/App_Themes/Office2003Blue/Editors/styles.css" CssPostfix="Office2003_Blue"
                                                        EnableIncrementalFiltering="true">
                                                        <Items>
                                                            <dxw:ListEditItem Text="30 mints" Value="1800" />
                                                            <dxw:ListEditItem Text="1" Value="3600" />
                                                            <dxw:ListEditItem Text="2" Value="7200" />
                                                            <dxw:ListEditItem Text="3" Value="10800" />
                                                            <dxw:ListEditItem Text="4" Value="14400" />
                                                            <dxw:ListEditItem Text="5" Value="18000" />
                                                            <dxw:ListEditItem Text="6" Value="21600" />
                                                            <dxw:ListEditItem Text="7" Value="25200" />
                                                            <dxw:ListEditItem Text="8" Value="28800" />
                                                        </Items>
                                                    </dxw:ASPxComboBox>
                                                </div>
                                                <div class="col-sm-4 col-md-3 col-lg-3 padding-width-lg-right" style="margin-top: 4px;">
                                                    <asp:Label ID="lblGTimeLimitMetrics" runat="server" Text="Hrs" class="ControlHide"></asp:Label>
                                                </div>
                                            </div>
                                        </div>

                                        <div class="col-sm-4 padding-width-lg-right">
                                            <div id="trGTimelimit2" class="ControlHide">
                                                <asp:CheckBox ID="chkEXtTimelimit" CssClass="checkbox chkSettings" runat="server" Text=" Enable Ext. Time Limit" />
                                            </div>
                                        </div>
                                    </div>
                                </asp:Panel>
                                </td>
                                            
                                        <div>
                                            &nbsp;
                                        </div>
                                <div id="divClose" runat="server" align="right">
                                    <asp:Button ID="btnCloseDelay" runat="server" Text="OK" OnClientClick="CloseDelayNotifyPopup(); return false;" />
                                </div>
                            </div>

                        </div>
                    </ContentTemplate>
                </asp:UpdatePanel>
            </asp:Panel>
            <asp:HiddenField ID="hdnRecurrenceDays" runat="server" />
            <asp:HiddenField ID="ddlFrequency" runat="server" Value="0" />
            <asp:HiddenField ID="hdnRecurrenceDaysDelay" runat="server" />

            <script type="text/javascript" language="javascript" src="../js/DateValidations.js"></script>

            <script type="text/javascript" language="javascript" src="../js/myformvalidations.js"></script>

            <script type="text/javascript" language="javascript" src="../js/VehicleGeozoneAssignmentScript.js"></script>

            <asp:HiddenField ID="hdnLogout" runat="server" />
        </form>
    </div>
    <!-- Content Ends Here -->
    <uc2:Footer ID="ucFooter" runat="server" />

    <script type="text/javascript" language="javascript">


        function ClearControlDelay() {
            document.getElementById("tmTrip1").disabled = true;
            document.getElementById("ddlTrip1Grace").disabled = true;
            document.getElementById("tmTrip2").disabled = value;
            document.getElementById("ddlTrip2Grace").value = "0";
            document.getElementById("tmTrip3").disabled = true;
            document.getElementById("ddlTrip3Grace").disabled = true;
            document.getElementById("ddlTrip1Grace").value = "0";
            document.getElementById("ddlTrip2Grace").value = "0";
            document.getElementById("ddlTrip3Grace").value = "0";
        }

        function EnableControlDelay(value) {
            document.getElementById("tmTrip1").disabled = value;
            document.getElementById("ddlTrip1Grace").disabled = value;
            document.getElementById("tmTrip2").disabled = value;
            document.getElementById("ddlTrip2Grace").disabled = value;
            document.getElementById("tmTrip3").disabled = value;
            document.getElementById("ddlTrip3Grace").disabled = value;

            if (!value) {
                document.getElementById("ddlTrip1Grace").value = "0";
                document.getElementById("ddlTrip2Grace").value = "0";
                document.getElementById("ddlTrip3Grace").value = "0";
            }
        }

        function valiadteDelayNotify() {
            ShowPopUp();

            var chkDelayNotification = document.getElementById("chkDelayNotification");
            var hdnRecurrenceDaysDelay = document.getElementById("hdnRecurrenceDaysDelay");
            var chkTrip1 = document.getElementById("chkTrip1");
            var chkTrip2 = document.getElementById("chkTrip2");
            var chkTrip3 = document.getElementById("chkTrip3");

            var errror = '';

            if (chkDelayNotification.checked != false) {
                if (hdnRecurrenceDaysDelay.value == '') {
                    errror += 'Select Recurring days.\n';
                }

                if (!chkTrip1.checked && !chkTrip2.checked && !chkTrip3.checked) {
                    errror += 'Select atleast one trip time.\n';
                }

                if (errror.length > 0) {
                    alert(errror);
                    HidePopUp();
                    return false;
                }
                else {
                    ShowPopUp();
                    return true;
                }
            }
            else {
                ShowPopUp();
                return true;
            }
        }
        function hideControlForGeozone(isChecked, val) {
            var isIE = CheckBrowser();
            if (val == 1) {
                if (isChecked) {
                    if (isIE) {
                        document.getElementById('tdGeozoneSpeedDropDown').setAttribute('class', 'ControlShow');
                        document.getElementById('lblGeozoneSpeedThMetrics').setAttribute('class', 'ControlShow');
                    }
                    else {
                        document.getElementById('tdGeozoneSpeedDropDown').setAttribute('class', 'ControlShowFF');
                        document.getElementById('lblGeozoneSpeedThMetrics').setAttribute('class', 'ControlShowFF');
                    }
                }
                else {
                    document.getElementById('tdGeozoneSpeedDropDown').setAttribute('class', 'ControlHide');
                    document.getElementById('lblGeozoneSpeedThMetrics').setAttribute('class', 'ControlHide');
                }
            }
            else {
                if (isChecked) {
                    if (isIE) {
                        document.getElementById('trGTimelimit').setAttribute('class', 'ControlShow');
                        document.getElementById('trGTimelimit2').setAttribute('class', 'ControlShow');
                        document.getElementById('lblGTimeLimitMetrics').setAttribute('class', 'ControlShow');
                    }
                    else {
                        document.getElementById('trGTimelimit').setAttribute('class', 'ControlShowFF');
                        document.getElementById('trGTimelimit2').setAttribute('class', 'ControlShowFF');
                        document.getElementById('lblGTimeLimitMetrics').setAttribute('class', 'ControlShowFF');
                    }
                }
                else {
                    document.getElementById('trGTimelimit').setAttribute('class', 'ControlHide');
                    document.getElementById('trGTimelimit2').setAttribute('class', 'ControlHide');
                    document.getElementById('lblGTimeLimitMetrics').setAttribute('class', 'ControlHide');
                }
            }
        }
    </script>

</body>
</html>
