<%@ page language="C#" autoeventwireup="true" inherits="Pages_BaseFramework_Configuration_MachinePrinterMapping, App_Web_jccoqsvx" masterpagefile="~/Pages/Common/MasterPages/MainMasterPage_new.master" enableEventValidation="false" viewStateEncryptionMode="Never" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<%@ Register Src="~/UserControls/GridViewPager/GridViewPager.ascx" TagName="GridViewPager"  TagPrefix="uc1" %>
<%@ Register Src="~/UserControls/AutoComplete/AutoCompleteControl.ascx" TagName="AutoCompleteControl" TagPrefix="acc" %>
<%@ Register Src="~/UserControls/Common/CommonSearch/CommonSearch.ascx" TagName="CommonSearchUserControl" TagPrefix="Common" %> 
<%@ Register Src="~/UserControls/Common/ScreenGroup/ScreenGroup.ascx" TagName="ScreenGroupControl" TagPrefix="ScreenGroup" %>

<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
    <asp:ScriptManagerProxy ID="ScriptManager1" runat="server">
    </asp:ScriptManagerProxy>
    <asp:UpdatePanel ID="MachinePrinterMappingUpdatePanel" runat="server" UpdateMode="Always">
        <ContentTemplate>
        
            <div id="divContentPage">
                <!-- ContentPlaceHolder Box Starts -->
                <div style="width: 100%;padding:2px;margin:2px">
                    <table width="100%" border="0" style="vertical-align: top; margin-top: -1px;border-collapse:collapse;background-color:White" cellpadding="0"
                        cellspacing="0">
                        <tr>
                            <td class="dashBoardLeftCont" valign="top">
                                <div class="himssuHeader3WireBox">
                                    <div class="himsBoxHeader">
                                        <div class="leftdiv">
                                        </div>
                                        <div class="himsBoxTitle">
                                            <div class="headerText">
                                            <asp:Label runat="server" ID="ScreenGroupNameLabel"></asp:Label>    
                                            </div>
                                        </div>
                                    </div>
                                    <table width="200px" cellpadding="0" cellspacing="0">
                                        <tr>
                                            <td>
                                                <div class="himsBoxContent">
                                                    <div class="leftUlMenu">
                                                        <ScreenGroup:ScreenGroupControl EnableViewState="true" ID="ScreenGroupControl" ScreenGroupId="125"
                                                            Visible="true" runat="server" />
                                                    </div>
                                                </div>
                                            </td>
                                        </tr>
                                    </table>
                                </div>
                            </td>
                            <td style="vertical-align: top;padding-left:10px" width="99%">
        <Common:CommonSearchUserControl ID="CommonSearchControl" runat ="server" Visible="false"/>
            <div class="himssuHeader2WireBox">
                <div class="himsBoxHeader">
                    <asp:Panel ID="Panel1" runat="server">
                        <div class="leftdiv">
                        </div>
                        <div class="himsBoxTitle">
                            <asp:Image ID="Image2" runat="server" class="fLeft" />
                            <div class="headerText">
                                <asp:Label ID="Label3" runat="server" Text="Search"></asp:Label>
                                <cc1:CollapsiblePanelExtender ID="CollapsiblePanelExtender1" runat="Server" TargetControlID="DetailPanel"
                                    ExpandControlID="Image2" CollapseControlID="Image2" TextLabelID="Label3" Collapsed="true"
                                    ImageControlID="Image2" ExpandedImage="~/images/buttonCollapse.gif" CollapsedImage="~/images/buttonExpand.gif"
                                    ExpandDirection="Vertical" />
                            </div>
                        </div>
                    </asp:Panel>
                </div>
                <div class="himsBoxContent">
                    <asp:Panel ID="DetailPanel" runat="Server">
                        <div class="contentHolder">
                            <asp:Panel ID="SearchCriteriaPanel" runat="Server">
                                <div class="outerBox pTop5">
                                    <div class="controlLabelWidth">
                                        <asp:Label ID="Label1" Text="Machine Name" runat="server"></asp:Label>
                                    </div>
                                    <div class="fLeft pRight5">
                                        <asp:TextBox onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()" ID="SearchMachineTextbox"
                                            SkinID="CustomWidthTextBox" Width="150px" runat="Server"></asp:TextBox>
                                    </div>
                                </div>
                                <div class="outerBoxPreBtn pTop5">
                                    <div class="controlLabelWidth">
                                        <asp:Label ID="Label2" Text="Printer Name" runat="server"></asp:Label>
                                    </div>
                                    <div class="fLeft pRight5">
                                        <asp:TextBox onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()" ID="SearchPrinterTextBox"
                                            SkinID="CustomWidthTextBox" Width="150px" runat="Server" onkeypress="return fnKeyPressForDescriptionField(event)"
                                            onblur="return fnonTextChangeDescriptionField(this)"></asp:TextBox>
                                    </div>
                                </div>
                                <div class="outerBox pTop5">
                                    <div class="searchBoxBtn">
                                        <asp:Button ID="SearchButton" Text="Search" runat="Server" OnClick="SearchButton_Click" SkinID="0" CssClass="PrimaryButton" />
                                        <asp:Button ID="ResetButton" runat="server" Text="Clear" 
                                            OnClick="ResetButton_Click" />
                                    </div>
                                </div>
                                <div class="cBoth">
                                </div>
                            </asp:Panel>
                            <div id="ReasonMasterDetailDiv" visible="false" class="himssuHeader1WireBox" runat="server"
                                style="width: 100%; margin-right: 5px;">
                                <div id="ReasonMasterDetailDiv1" runat="server">
                                    <div class="spacer">
                                        <asp:Image ID="Image3" runat="server" ImageUrl="~/Images/spacer.gif" />
                                    </div>
                                    <div class="himsBoxHeader" id="PatientRelationDiv" runat="server">
                                        <div class="leftdiv">
                                        </div>
                                        <div class="himsBoxTitle" style="width: 99%">
                                            <div class="headerText">
                                                <div class="fLeft">
                                                    <asp:Label ID="GridViewLabel" Text="List" runat="server" Font-Bold="true" />
                                                </div>
                                            </div>
                                            <div align="right" class="fRight" style="margin-top: -3px;">
                                                <uc1:GridViewPager ID="MachinePrinterMappingGridView_GridViewPager" runat="server"
                                                    ParentGridView="MachinePrinterMappingGridView" OnFirstRecordClick="MachinePrinterMappingGridView_GridViewPager_FirstRecordClick"
                                                    OnLastRecordClick="MachinePrinterMappingGridView_GridViewPager_LastRecordClick"
                                                    OnNextRecordClick="MachinePrinterMappingGridView_GridViewPager_NextRecordClick"
                                                    OnPrevRecordClick="MachinePrinterMappingGridView_GridViewPager_PrevRecordClick"
                                                    OnTextBoxValueChange="MachinePrinterMappingGridView_GridViewPager_TextBoxValueChange" />
                                            </div>
                                        </div>
                                    </div>
                                    <div class="himsBoxContent">
                                        <asp:UpdatePanel ID="MenuPlanDetailUpdatePanel" runat="server" UpdateMode="Always">
                                            <ContentTemplate>
                                                <div id="Div5" runat="server" visible="false">
                                                    <%--<div id="DivHeader" style="vertical-align: top; width: 100%;">
                                                        <asp:Table ID="PeriodicPaySetupGridViewTable" runat="server" CellPadding="0" CellSpacing="0"
                                                            BackColor="#E8E8E8" ForeColor="#000000" Width="100%" GridLines="Both">
                                                            <asp:TableRow Height="20px">
                                                                <asp:TableCell Text="" Width="15%" Font-Bold="true" HorizontalAlign="Center"> </asp:TableCell>
                                                                <asp:TableCell Text="Machine Name" Width="20%" Font-Bold="true"> </asp:TableCell>
                                                                <asp:TableCell Text="Printer Name" Width="20%" Font-Bold="true"> </asp:TableCell>
                                                                <asp:TableCell Text="Printer Path" Width="30%" Font-Bold="true"> </asp:TableCell>
                                                                <asp:TableCell Text="InActive" Width="15%" Font-Bold="true" HorizontalAlign="Center"> </asp:TableCell>
                                                            </asp:TableRow>
                                                        </asp:Table>
                                                    </div>--%>
                                                    <%--<div id="Div2" visible="true" runat="server" class="Container" style="vertical-align: top;
                                                        height: 109px;">--%>
                                                        <asp:GridView ID="MachinePrinterMappingGridView" runat="server" Width="100%" AutoGenerateColumns="False"
                                                            ShowHeader="True" AllowPaging="true" PageSize="5" SkinID="" PagerSettings-Visible="false"
                                                            OnRowDataBound="MachinePrinterMappingGridView_RowDataBound">
                                                            <Columns>
                                                                <asp:TemplateField ItemStyle-HorizontalAlign="Center" ItemStyle-Width="15%">
                                                                    <ItemTemplate>
                                                                        <asp:LinkButton ID="EditLinkButton" runat="server" OnClick="LinkButton_Click" Text="Select"
                                                                            CausesValidation="false" CommandName="Select"></asp:LinkButton>
                                                                    </ItemTemplate>
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Id" SortExpression="Id" Visible="false">
                                                                    <ItemTemplate>
                                                                        <asp:Label ID="IdLabel" runat="server" Text='<%# Bind("Id") %>'></asp:Label>
                                                                    </ItemTemplate>
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Machine Name" SortExpression="MachineName" ItemStyle-Width="20%" HeaderStyle-HorizontalAlign="Left">
                                                                    <ItemTemplate>
                                                                        <asp:Label ID="GridMachineNameLabel" runat="server" Text='<%# Bind("MachineName") %>'></asp:Label>
                                                                    </ItemTemplate>
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Printer Name" SortExpression="PrinterName" ItemStyle-Width="20%" HeaderStyle-HorizontalAlign="Left">
                                                                    <ItemTemplate>
                                                                        <asp:Label ID="GridPrinterNameLabel" runat="server" Text='<%#  Bind("PrinterName")  %>'></asp:Label>
                                                                    </ItemTemplate>
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Printer Path" SortExpression="PrinterPath" ItemStyle-Width="30%" HeaderStyle-HorizontalAlign="Left">
                                                                    <ItemTemplate>
                                                                        <asp:Label ID="GridPrinterPath" runat="server" Text='<%#  Bind("PrinterPath")  %>'></asp:Label>
                                                                    </ItemTemplate>
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="InActive" SortExpression="IsObsolete" HeaderStyle-HorizontalAlign="Center"
                                                                    ItemStyle-HorizontalAlign="Center" ItemStyle-Width="15%">
                                                                    <ItemTemplate>
                                                                        <asp:Label ID="ObsoleteLabel" runat="server" Text='<%# DataBinder.Eval(Container.DataItem,"IsObsolete").ToString().ToUpper()=="TRUE"?"Y":"N" %>'></asp:Label>
                                                                    </ItemTemplate>
                                                                </asp:TemplateField>
                                                            </Columns>
                                                        </asp:GridView>
                                                  <%--  </div>--%>
                                                </div>
                                            </ContentTemplate>
                                        </asp:UpdatePanel>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </asp:Panel>
                </div>
            </div>
            <div class="spacer">
                <asp:Image ID="Image1" runat="server" ImageUrl="~/Images/spacer.gif" />
            </div>
            <div class="himssuHeader1WireBox">
                <div class="himsBoxHeader">
                    <div class="leftdiv">
                    </div>
                    <div class="himsBoxTitle">
                        <div class="headerText">
                            <asp:Label ID="MachinePrinterMappingDetailLabel" runat="server" Text="Maintenance"></asp:Label>
                        </div>
                    </div>
                </div>
                <div class="himsBoxContent">
                    <div class="contentHolder">
                        <div class="outerBox pTop5">
                            <div class="controlLabelWidth">
                                <asp:Label ID="MachineNameLabel" runat="server" Text="Machine Name" SkinID="MandatoryLabel"></asp:Label>
                            </div>
                            <div class="fLeft pRight5">
                                <acc:AutoCompleteControl ID="MachineNameTextBox" runat="Server" MinimumPrefixLength="2"
                                    Width="150px" ContextKey="Config.MachineName"  AutoPostBack="true" DisplayLoadingStatus="true"
                                    FirstRowSelected="false" MaxLength="20" ValidateOnTextChanged="true" />
                                <asp:HiddenField ID="IdHiddenField" runat="server" />
                                <asp:ImageButton ID="MachineNameSearchImageButton" ToolTip="Machine Search" SkinID="FindImage"
                                    runat="server" OnClick="MachineNameSearchImageButton_Click" />
                            </div>
                        </div>
                        <div class="outerBox pTop5">
                            <div class="controlLabelWidth">
                                <asp:Label ID="PrinterNameLabel" runat="server" Text="Printer Name" SkinID="MandatoryLabel"></asp:Label>
                            </div>
                            <div class="fLeft pRight5">
                                <acc:AutoCompleteControl ID="PrinterNameAutoCompleteControl" runat="Server" MinimumPrefixLength="2"
                                    Width="150px" ContextKey="Config.PrinterName" AutoPostBack="true" DisplayLoadingStatus="true"
                                    FirstRowSelected="false" MaxLength="20" ValidateOnTextChanged="true" />
                                <asp:ImageButton ID="PrinterNameSearchImageButton" ToolTip="Printer Search" SkinID="FindImage"
                                    runat="server" OnClick="PrinterNameSearchImageButton_Click" />
                            </div>
                        </div>
                        <div class="cBoth">
                        </div>
                        <div class="outerBox pTop5">
                            <div class="fLeft">
                                <asp:CheckBox ID="HeaderObsoleteCheckBox" runat="server" />
                            </div>
                            <div class="fLeft pLeft5 pTop5">
                                <asp:Label ID="HeaderObsoleteLabel" runat="server" Text="InActive"></asp:Label>
                            </div>
                        </div>
                        <div class="cBoth">
                        </div>
                        
                    </div>
                </div>
            </div>
                            </td>
                        </tr>
                    </table>
                    <%--HEDP History Ends Here--%>
                </div>
            </div>
            <div class="spacer">
                <img src="../../../Images/spacer.gif" />
            </div>
        </ContentTemplate>
    </asp:UpdatePanel>
      <%--   <script data-main="../../../JavaScript/rjs/encrypt/machineprinter-mapping-encrypt" src="../../../JavaScript/rjs/require.js"></script>--%>
      <script data-main='<%=ResolveUrl("~/JavaScript/rjs/machineprinter-mapping")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>
</asp:Content>
