<%@ page language="C#" autoeventwireup="true" inherits="Shop_Browse_ShopList, HoWaveVGO" title="商城店铺列表" enableviewstate="false" enableEventValidation="false" %>
<%@ OutputCache Duration="600"  VaryByParam="*"  %>
<html>
<head>
<link type="text/css" href="../../skin/css/browse/ShopCategory.css" rel="stylesheet" />

</head>
<body>
    <form id="form_1" runat="server">
    <asp:ScriptManager ID="ScriptManager1" runat="server" EnablePartialRendering="True"/>
<script language="javascript" type="text/javascript" src="../Js/howave_time.js"></script> 
<script language="javascript" type="text/javascript" src="../Js/f_function.js"></script> 
<div id="Category_Content" style="left: 0px; top: -5px">
   <!--导航栏--->
   <div id="Navigator_Bar"></div>    
   <!--分类导航条-->
   <div id="Catergor_Navgitor">
      <hl:ClassMapPath id="ClassMapPath1" runat="server"/>
   </div>

   <!--主栏目-->
   <div id="Main_Frame">

      <!--商品展示主栏-->
      <div id="Product_List">
          <div id="mainSarR">
             <!--商品显示按钮栏-->
             <div id="MainMenu">
	             <div class="TabMenu">
		                <!--一级导航-->				
                        <ul id="M1" ><li class="active"><a href="#">店铺列表</a></li></ul>
                 </div>
                 <!--商品显示方式选择栏-->
                 <div id="Prodcut_Show_Type">           
                    <div class="show_num">每页显示数量：</div>
                    <div class="show_page">
                       <asp:ImageButton ImageUrl="../Images/page_20.gif" runat="server" ID="Page20" CommandName="Page_20" />
                       <asp:ImageButton ImageUrl="../Images/page_40.gif" runat="server" ID="Page40" CommandName="Page_40" />
                       <asp:ImageButton ImageUrl="../Images/page_80.gif" runat="server" ID="Page80" CommandName="Page_80" />
                    </div>         
                    <div class="show_place">
                       排序方式：
                       <asp:DropDownList ID="Sort_Type" runat="server" Width="150px" AutoPostBack="true" >
                              <asp:ListItem Text="商品数量从少到多" Value="1" />
                              <asp:ListItem Text="商品数量从多到少" Value="2" />
                              <asp:ListItem Text="卖家信用从高到低" Value="3" />
                              <asp:ListItem Text="卖家信用从低到高" Value="4" />
                             
                       </asp:DropDownList>
                    </div>
                 </div> 
             </div>          
             <!--店铺列表栏-->
             <div id="Porduct_List_Main">

                  <asp:GridView id="GridView1" runat="server" BorderWidth="0" CssClass="ProductList" EnableViewState="False" DataSourceID="ObjectDataSource2" AllowSorting="True" AllowPaging="True" DataKeyNames="ShopID" OnRowDataBound="GridView_ItemDataBound" AutoGenerateColumns="False" PageSize="80">
                     <Columns>
                        <asp:TemplateField>
                            <HeaderTemplate>店标</HeaderTemplate>
                            <HeaderStyle Width="15%"></HeaderStyle>
                            <ItemTemplate>
                                <asp:HyperLink id="HyperLink2" runat="server" NavigateUrl='<%#"../Shop1/MyShop.aspx?ShopID="+ Eval("ShopID") %>'   Target="_blank">
                                   <asp:Image ID="ShopImage" runat="server"  ImageUrl='<%#"../Shop/"+Eval("ShopImageUrl") %>'  Width="100px"/>
                                </asp:HyperLink> 
                            </ItemTemplate>
                            </asp:TemplateField>
                        <asp:TemplateField>
                            <HeaderTemplate>店名</HeaderTemplate>
                            <ItemStyle HorizontalAlign="Left"></ItemStyle>
                            <HeaderStyle Width="35%"></HeaderStyle>
                            <ItemTemplate>
                                 <asp:HyperLink ID="ShopName" Text='<%#Eval("ShopName") %>' NavigateUrl='<%#"../Shop1/MyShop.aspx?ShopID="+ Eval("ShopID") %>' runat="server" Target="_blank"/><br />
                                 <span class="shop_main_item"><asp:Literal runat="server" ID="MainItem" Text='<%#"主营：" +Eval("ShopOperatorItem") %>' /></span>
                                                       
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:TemplateField>
                            <HeaderTemplate>店长</HeaderTemplate>
                            <HeaderStyle Width="10%"></HeaderStyle>
                            <ItemTemplate>
                                 <asp:HyperLink ID="HyperLink3" Text='<%#Eval("ShopOwnerName") %>' NavigateUrl='<%#"../Shop1/Shop_Review.aspx?UserID="+ Eval("ShopOwnerID") %>' runat="server" Target="_blank"/>
                                 <br/><br/>
                                 <asp:HyperLink ID="QQLink" runat="server" NavigateUrl='<%# "http://wpa.qq.com/msgrd?V=1&Uin="+Eval("OICQ")+"&amp;Site="+Eval("ShopOwnerName")+"&amp;Menu=yes" %>' Target="_blank">
                                  <asp:Image  ID="QQImage" ImageUrl='<%# Eval("OICQ")%>' runat="server" />
                                  </asp:HyperLink>&nbsp;
                                 <asp:HyperLink ID="TaobaoLink" runat="server" NavigateUrl='<%# Eval("Taobaowangwang") %>' Target="_blank">
                                    <asp:Image ID="TaobaoImage" ImageUrl='<%# Eval("Taobaowangwang") %>' runat="server"  AlternateText="点击此可以直接和对方交流"/>
                                 </asp:HyperLink>
                            </ItemTemplate>
                       </asp:TemplateField>
                       <asp:TemplateField>
                           <HeaderTemplate>商品数量</HeaderTemplate>
                           <HeaderStyle Width="10%"></HeaderStyle>
                           <ItemTemplate>
                                <asp:Literal ID="ProductType" Text='<%#Eval("ShopProductNum") %>' runat="server" />
                           </ItemTemplate>
                       </asp:TemplateField>
                       <asp:TemplateField>
                           <HeaderTemplate>
                               <asp:DropDownList ID="F_ProductPlace" runat="server" DataSourceID="ObjectDataSource5" 
                         DataTextField="City" DataValueField="City" AppendDataBoundItems="True" >
                                   <asp:ListItem Text="所在地" Value="-1" />
                               </asp:DropDownList>
                           </HeaderTemplate>
                           <HeaderStyle Width="10%"></HeaderStyle>
                           <ItemTemplate>
                               <asp:Literal ID="ProductPlace" Text='<%#Eval("ShopAddress") %>' runat="server" />
                               <asp:HiddenField ID="F_ShopID" Value='<%#Eval("ShopID") %>' runat="server" />
                           </ItemTemplate>
                      </asp:TemplateField>
                      <asp:TemplateField>
                          <HeaderTemplate>卖家信用等级</HeaderTemplate>
                          <HeaderStyle Width="15%"></HeaderStyle>
                          <ItemTemplate>
                             <asp:HyperLink ID="shop_saler_credit" runat="server"  Text='<%#"<script>displayStar("+ Eval("SalerCrediet")+")</script>" %>' NavigateUrl='<%#"../Shop1/Shop_Review.aspx?UserID="+Eval("ShopOwnerID") %>'/>
                          </ItemTemplate>
                      </asp:TemplateField>
                      </Columns>
                      <EmptyDataTemplate>很抱歉!没有你查找的店铺,缩减你的关键字查找的机率会高些!</EmptyDataTemplate>
                  </asp:GridView>
             </div>
          
          </div>
      <!--侧栏-->
      </div>
      <div id="Side_Bar">        
          <div  class="SideBox">
              <div class="title"><b>搜索店铺</b></div>              
                    <hl:ShopDetailSearch id="ShopDetailSearch1" runat="server"/>
          </div >
          <div  class="SideBox">
             <div class="title"><b>店铺类目</b></div>
               <asp:literal ID="ShopClassListLiteral" runat="server" />
          </div> 
      </div>
       
   </div>

    <asp:ObjectDataSource ID="ObjectDataSource1" runat="server" SelectMethod="GetCategoryListByParentID" TypeName="Shop_Class">
        <SelectParameters>
            <asp:QueryStringParameter DefaultValue="0" Name="ParentID" QueryStringField="ParentID"  Type="Int32" />
        </SelectParameters>
    </asp:ObjectDataSource>
    <asp:ObjectDataSource ID="ObjectDataSource2" runat="server" SelectMethod="GetCategoryShopByParentID" TypeName="Shop_Shop" >
        <SelectParameters>
            <asp:QueryStringParameter Name="ParentID" QueryStringField="ParentID"
                Type="Int32" DefaultValue="0" />
            <asp:ControlParameter ControlID="Sort_Type" Name="SortType" PropertyName="SelectedValue"
                Type="Int32" />
        </SelectParameters>
    </asp:ObjectDataSource>  
    <asp:ObjectDataSource ID="ObjectDataSource5" runat="server" SelectMethod="GetImportantCityByFlag" TypeName="Shop_City"/> 
    </form>
</body>
</html>


