<%@ page language="C#" masterpagefile="../ShopMasterPage/MyShopMasterPage.master" autoeventwireup="true" inherits="Shop_Member_Shop_MyAuctionProduct, HoWaveVGO" title="竞拍商品" enableEventValidation="false" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<asp:ScriptManager ID="ScriptManager1" runat="server" EnablePartialRendering="True"/>

<script type="text/javascript" src="../JS/howave_time.js"></script>
<div class="pageTitle">
  <asp:Literal ID="buy_type" runat="server" />
</div>
<br />
    <table class="SearchTableStyle">   
        <tr>
            <td style="height: 26px">
            <asp:Button ID="Bidding" runat="server" Text="竞拍中的商品" CommandName="Bidding" OnCommand="AuctionProductBtn_Click"/>&nbsp;&nbsp;&nbsp;
            <asp:Button ID="Bided" runat="server" Text="竞拍结束的商品" CommandName="Bided" OnCommand="AuctionProductBtn_Click"/>
            </td>
        </tr>
    </table>
<br />
<div id="product_history">
<%--  <asp:UpdatePanel ID="UpdatePanel1" runat="server">
    <ContentTemplate>  --%>
        <asp:GridView ID="GridView1" runat="server" CssClass="tableHead" AutoGenerateColumns="False" DataSourceID="ObjectDataSource1" 
         AllowPaging="True"  OnDataBound="GridView1_DataBound"
        DataKeyNames="OrderFormID"  >
         <Columns>
             <asp:TemplateField HeaderText="商品名称">                 
                 <ItemTemplate>
                    <asp:HyperLink Target="_blank"  ID="ProductNameUrl" runat="server" Text='<%# Bind("ProductName") %>' NavigateUrl='<%#"../Auction/Auction.aspx?ProductID="+Eval("ProductID") %>'/>
                 </ItemTemplate>
             </asp:TemplateField>
             <asp:BoundField DataField="AuctionEndPrice" HeaderText="我的最高价" />
             <asp:BoundField DataField="AuctionMaxPrice" HeaderText="当前最高价" />
              <asp:BoundField DataField="InputTime" HeaderText="参与拍卖时间" />
             <asp:TemplateField HeaderText="出价状态">
               <ItemTemplate>
                 <asp:HyperLink ID="Status"  runat="server" Text='<%# Eval("Status") %>' />
                 <asp:HiddenField ID="TradeNo" runat="server" Value='<%# Eval("OrderFormNum") %>' />
               </ItemTemplate>
             </asp:TemplateField> 
             <asp:TemplateField HeaderText="剩余时间">
               <ItemTemplate>
                 <asp:Label ID="LeftTime"  runat="server" Text='<%# "<script>showlefttime("+Eval("LeftTime")+")</script>" %>' />
                 <asp:HiddenField ID="AuctionLeftTime" runat="server"  Value='<%# Eval("LeftTime") %>' />
               </ItemTemplate>
             </asp:TemplateField>
             <asp:TemplateField HeaderText="操作">
               <ItemTemplate>
                 <asp:HyperLink ID="AuctionAction"  runat="server" />                
               </ItemTemplate>
             </asp:TemplateField>
         </Columns>
         <EmptyDataTemplate>                   
              <div style="padding:10px;">没有符合查询条件的记录！</div>
        </EmptyDataTemplate>  
     </asp:GridView>
   <%--</ContentTemplate>
        <Triggers>
            <asp:AsyncPostBackTrigger ControlID="Bidding" EventName="Click" />
            <asp:AsyncPostBackTrigger ControlID="Bided" EventName="Click" />
        </Triggers>
    </asp:UpdatePanel> --%>
 </div>
     <asp:ObjectDataSource ID="ObjectDataSource1" runat="server" SelectMethod="GetAuctionProductOrderByUserID" TypeName="Shop_Order" OldValuesParameterFormatString="original_{0}" >
        <SelectParameters>
            <asp:SessionParameter Name="UserID" SessionField="Howave_UserID" Type="Int32" />
            <asp:Parameter DefaultValue="Bidding" Name="Type" Type="String" />
        </SelectParameters>
    </asp:ObjectDataSource>
</asp:Content>

