<%@ page language="C#" masterpagefile="MyShopMasterPage.master" autoeventwireup="true" inherits="Member_ShopProductSold, WebApp_deploy" title="已出售商品" enableEventValidation="false" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
 <div class="pageTitle">已卖出的商品</div>
 <br />
 <table class="SearchTableStyle">
    <tr class="tdbg">
           <td class="tdbg5" align="right">下单起始日期：</td>
           <td class="tdbg5"><asp:TextBox ID="TxtBeginDate" runat="server" Height="16px" /></td>
           <td class="tdbg5" align="right">至：</td>
           <td class="tdbg5" ><asp:TextBox ID="TxtEndDate" runat="server" Height="16px" /></td>
    </tr>
    <tr class="tdbg">
        <td class="tdbg5" align="right">商品名称：</td>
        <td class="tdbg5"><asp:TextBox ID="TxtOrderName" runat="server"  Width="200px" Height="16px" />&nbsp;&nbsp;</td>
        <td class="tdbg5" align="right">交易类型：</td>
        <td class="tdbg5">
             <asp:DropDownList ID="RadProductType" runat="server" RepeatDirection="Horizontal"  AutoPostBack="true" OnSelectedIndexChanged="Search_OnClick">
               <asp:ListItem Text="所有" Value="0" Selected="True" />
               <asp:ListItem Text="一口价" Value="1"/>
               <asp:ListItem Text="拍卖" Value="2" />
               <asp:ListItem Text="团购" Value="3" />
            </asp:DropDownList>
         </td>
     </tr>
     <tr class="tdbg">
         <td class="tdbg5" align="center" colspan="4">
         <asp:Button ID="search_btn" runat="server" Text=" 查 询 " OnClick="Search_OnClick" />
     </td>
     </tr>
 </table>

 <div style="clear:both"></div>
 <div id="product_history">
     <asp:GridView ID="GridView1" runat="server" CssClass="tableHead" width="98%" AutoGenerateColumns="False"  AllowPaging="True" OnDataBound="GridView1_DataBound" >
         <Columns>
             <asp:TemplateField HeaderText="商品名称">
                 <ItemTemplate>
                    <asp:HyperLink ID="ProductNameUrl" runat="server" Text='<%# Bind("ProductName") %>' NavigateUrl='<%#"../ShopProduct.aspx?ProductID="+Eval("ProductID") %>'  Target="_blank"/>
                 </ItemTemplate>
             </asp:TemplateField>
             <asp:TemplateField HeaderText="商品类型">                 
                 <ItemTemplate>
                    <asp:HyperLink ID="LabStatus" runat="server" Text='<%# HoWave.Web.Shop.TextFormat.GetProductType(Eval("ProductType").ToString()) %>'/>
                 </ItemTemplate>
                 <ItemStyle Width="15%" />
             </asp:TemplateField>
             <asp:BoundField DataField="EndDate" HeaderText="结束时间" ItemStyle-Width="15%"/>
              <asp:TemplateField HeaderText="操作">                
                 <ItemTemplate>
                     <asp:HyperLink ID="review" runat="server" Text="评价" />
                     <asp:HyperLink ID="view" runat="server" Text="查看订单" NavigateUrl='<%# "Shop_ManageOrder.aspx?all=all&productname="+HttpContext.Current.Server.UrlEncode(Eval("ProductName").ToString()) %>' />
                 </ItemTemplate>
                  <ItemStyle Width="15%" />
             </asp:TemplateField>
         </Columns>
         <EmptyDataTemplate>
          <table style="width:98%">
          <tr>
          <th>商品名称</th>
          <th>商品类型</th>
          <th>结束时间</th>
          <th>操作</th>
          </tr>
          <tr><td colspan="4">暂无任何商品</td></tr>
          </table>
         </EmptyDataTemplate>     
     </asp:GridView>
 </div>
 
</asp:Content>

