<%@ Page Title="" Language="C#" MasterPageFile="~/Site1.Master" AutoEventWireup="true" EnableEventValidation="false"  CodeBehind="CloseProject.aspx.cs" Inherits="VMT.CloseProject" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="cphJavaScriptContentPlaceHolder" runat="server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="cphPageTitleContentPlaceHolder" runat="server">
    <div id="CssPageTitle">
        <h1>
           Project/Event Invoice Status
        </h1>
    </div>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="cphMainContentPlaceHolder" runat="server">
    <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>
      <asp:UpdatePanel ID="UpdatePanel2" runat="server">
          <ContentTemplate>
              <div style="text-align:right;"><a href="default.aspx">Home</a> <strong>&#8249;&#8249;</strong> <a href="CurrentYTD.aspx">Current</a> <strong>&#8249;&#8249;</strong> Project/Event Invoice Status</div>
                        <div >
             <fieldset class="masterform">
                <legend> Select Project</legend> 
                <div style=" width: 100%; height:300px; ">
                    <table>
                        <tr>
                            <td> Business Unit:
                                <asp:DropDownList ID="ddlBUnit" runat="server" OnSelectedIndexChanged="ddlBUnit_SelectedIndexChanged" AutoPostBack="true">
                                </asp:DropDownList>
                            </td>

                            <td> Work Year:
                                <asp:DropDownList ID="ddlYear" runat="server" OnSelectedIndexChanged="ddlYear_SelectedIndexChanged" AutoPostBack="true" OnDataBound="ddlYear_DataBound">
                                </asp:DropDownList>
                            <td/>

                            <td> Project/Event:
                                <asp:DropDownList ID="ddlEventCode" runat="server" OnSelectedIndexChanged="ddlEventCode_SelectedIndexChanged" AutoPostBack="true">  
                                </asp:DropDownList>
                            </td>

                             <td> <asp:Button ID="btnGo" runat="server" Text="Go" OnClick="btnGo_Click" Visible="false" CssClass="FormButton"/></td> 
                        </tr>
                    </table>
                    <asp:HiddenField ID="hdn_role" runat="server" />
                    <br />
               <div style=" width: 100%; height: 240px; overflow-y: scroll;" > <br />
                <asp:GridView ID="gdvCloseProject" runat="server"  BorderColor="#014567" CellPadding="3" HeaderStyle-CssClass="FixedHeader"
                     AutoGenerateColumns="false"  emptydatatext="No data in the data source." 
                     OnSorting="gdvCloseProject_Sorting" AllowSorting="True">
                    <AlternatingRowStyle BackColor="#E9EFF2" />
                    <Columns>
                        <asp:TemplateField SortExpression="EVENT_CODE"  HeaderStyle-Width="140px" ItemStyle-Width="140px" >
                            <HeaderTemplate> 
                                <asp:LinkButton  ID="LinkButton1" runat="server" Text="Project/Event"  CommandName="Sort" CommandArgument="EVENT_CODE" ForeColor="Black"/>                       
                            </HeaderTemplate >
                            <ItemTemplate>
                                <asp:Label ID="lbl_event_code_id" runat="server" Text='<%# Eval("EVENT_CODE_ID") %>' Visible="false"></asp:Label>   
                                <%# Eval("EVENT_CODE") %>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:TemplateField  SortExpression="work_area_id"  HeaderStyle-Width="100px" ItemStyle-Width="100px">
                            <HeaderTemplate>
                                <asp:LinkButton  ID="LinkButton2" runat="server" Text="Section/WA"  CommandName="Sort" CommandArgument="work_area_id" ForeColor="Black"/>
                            </HeaderTemplate>
                            <ItemTemplate>
                                 <asp:Label ID="lbl_WORK_AREA_ID" runat="server" Text='<%# Eval("work_area_id") %>' Visible="false"></asp:Label>
                                <%# Eval("WORK_AREA") %>
                            </ItemTemplate>
                        </asp:TemplateField>
                         <asp:TemplateField SortExpression="STATUS"  HeaderStyle-Width="140px" ItemStyle-Width="140px" >
                            <HeaderTemplate>                                      
                                <asp:LinkButton  ID="LinkButton3" runat="server" Text="STATUS"  CommandName="Sort" CommandArgument="STATUS" ForeColor="Black"/>                       
                            </HeaderTemplate >
                            <ItemTemplate>
                                <%# Eval("STATUS") %>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:TemplateField SortExpression="FORECAST_AMT"  HeaderStyle-Width="120px" ItemStyle-Width="120px" >
                            <HeaderTemplate>                                      
                                <asp:LinkButton  ID="LinkButton4" runat="server" Text="FORECAST_AMT"  CommandName="Sort" CommandArgument="FORECAST_AMT" ForeColor="Black"/>                       
                            </HeaderTemplate >
                            <ItemTemplate>
                                <%# Eval("FORECAST_AMT") %>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:TemplateField SortExpression="PAID_AMT"  HeaderStyle-Width="100px" ItemStyle-Width="100px" >
                            <HeaderTemplate>                                      
                                <asp:LinkButton  ID="LinkButton5" runat="server" Text="PAID_AMT"  CommandName="Sort" CommandArgument="PAID_AMT" ForeColor="Black"/>                       
                            </HeaderTemplate >
                            <ItemTemplate>
                                <%# Eval("PAID_AMT") %>
                            </ItemTemplate>
                        </asp:TemplateField>

                        <asp:TemplateField SortExpression="PENDING_AMT"  HeaderStyle-Width="120px" ItemStyle-Width="120px" >
                            <HeaderTemplate>                                      
                                <asp:LinkButton  ID="LinkButton6" runat="server" Text="PENDING_AMT"  CommandName="Sort" CommandArgument="PENDING_AMT" ForeColor="Black"/>                       
                            </HeaderTemplate >
                            <ItemTemplate>
                                <%# Eval("PENDING_AMT") %>
                            </ItemTemplate>
                        </asp:TemplateField>

                        <asp:templatefield  HeaderStyle-Width="71px" ItemStyle-Width="70px" >                           
                            <HeaderTemplate>
                                 <asp:checkbox ID="cbSelectAll"  runat="server" AutoPostBack="true" ForeColor="Black" 
                                     OnCheckedChanged="cbSelectAll_CheckedChanged"></asp:checkbox> CLOSE 
                            </HeaderTemplate>
                            <HeaderStyle  HorizontalAlign="Left" VerticalAlign="Middle"/>
                            <itemtemplate>
                                <asp:checkbox ID="cbSelect"  runat="server" AutoPostBack="true"  
                                   Enabled='<%# Convert.ToBoolean(Eval("ACTIVE_CHECK")) %>' 
                                    />                              
                            </itemtemplate>
                           
                            <ItemStyle  HorizontalAlign="Left" VerticalAlign="Middle" />
                        </asp:templatefield>
                       
                    </Columns>
                    <HeaderStyle BackColor="#98C8DE" Font-Bold="True"/>
                    <SelectedRowStyle BackColor="#FFE98F" />
                </asp:GridView>
                    <td> </td> 
                </div>

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

        <div style="text-align:left; width: 100%;">
                    <fieldset class="masterform">
                        
                              
                        <div style=" width: 100%; height:40px; overflow-y: scroll;">
                            <table>
                <tr>
                            
                        <td> <asp:Button ID="btnSubmit" runat="server" Text="Submit" OnClick="btnSubmit_Click"  enabled="true"  CssClass="FormButton" Visible="false"/>
                            <asp:Button ID="btnExportExcel" runat="server" CssClass="FormButton" OnClick="btnExportExcel_Click" Text="Export To Excel" Visible="false" />
                    </td> 
                </tr>
            </table>


        </div>
                            </fieldset></div>    
                    </ContentTemplate>
     </asp:UpdatePanel>
</asp:Content>
