<%@ page language="C#" autoeventwireup="true" inherits="V5Shop.Admin.Picture_Select_Dialog, V5Shop.Shop.Picture" enableviewstatemac="false" enableEventValidation="false" viewStateEncryptionMode="Never" %>

<%@ Register Src="control/PageBottom.ascx" TagName="PageBottom" TagPrefix="uc2" %>
<%@ Register Src="control/HiddenField.ascx" TagName="HiddenField" TagPrefix="uc1" %>
<%@ Register TagPrefix="V5Shop" Namespace="V5Shop.Control" Assembly="V5Shop.Control" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title>请选择您要使用的图片</title>
    <base Target="_self" /> 
    <link href="css/css.css" rel="stylesheet" type="text/css">
    <link href="css/css_list.css" rel="stylesheet" type="text/css">
    <link href="css/control.css" rel="stylesheet" type="text/css">
    <script type="text/javascript" src="js/mootools.js"></script>
    <script type="text/javascript">
    function InitPicture(str){
        if (navigator.appVersion.indexOf("MSIE") == -1){
            window.opener.InsertMultiPic(str);
            window.close();
        }else{
            window.returnValue = str;
            window.close();
        }
    }    
    </script>
</head>
<body topmargin="0" leftmargin="0" marginheight="0" marginwidth="0" scroll="no">


       <div id='dhtmltooltip' style="z-index:10001"><img src="" /></div>       
    <form id="form1" runat="server">        
    <div style="height:36px;; background:url(images/labelbg.gif)">
        <div style="float:left; padding:10px 20px; color:#000000; font-weight:bolder">【 图片列表选择 】</div>
            <div style="float:right; padding:8px 30px 0 0;">
                <asp:Button ID="Button1" runat="server" Text="选择所有选中图片" Height="20px" OnClick="Button1_Click" class="button" style="cursor:pointer;"/>
            </div>
      </div>

    <div>
        <div id="search">
            <div style="padding:20px; border-bottom:1px #CCCCCC solid; background:#FFFFFF">
                <asp:Label ID="lblName" runat="server" Text="图片名称：" ForeColor="#4B6888" Font-Bold="true" meta:resourcekey="lblTitleResource1"></asp:Label>
                <asp:TextBox ID="txtName" Width="200px" runat="server" meta:resourcekey="txtTitleResource2"></asp:TextBox>

                <asp:Label ID="lblCategory" runat="server" Text="图片类别：" ForeColor="#4B6888" Font-Bold="true" meta:resourcekey="lblAuthorResource1"></asp:Label>
                <asp:DropDownList ID="listCategory" runat="server"></asp:DropDownList>
                
                <asp:Button ID="btnSearch" runat="server" Text="查询" CausesValidation="false" OnClick="btnSearch_Click" meta:resourcekey="btnSearchResource1" class="button"/>
            </div>
        </div>
          
        <div id="content">
            <asp:DataList ID="GridViewShow" Width="100%" runat="server" DataKeyField="id" GridLines="Horizontal" RepeatDirection="Horizontal" RepeatColumns="6">
                <ItemTemplate>
                    <table>
                        <tr>
                            <td><center><!-- onMouseOver="javascript:ddrivetip('<div align=center><b>双击选择该图片</b></div><br><img id=tmpimg src=../<%#Eval("Src") %>>','#ffffff','','tmpimg','../<%#Eval("Src") %>')"     hideddrivetip(); -->
                                <div style="width:92px; height:92px;"><div style="width:90px; height:90px; margin:1px; background:#ffffff">
                                    <img id="img_<%#Eval("ID") %>" style="padding:1px 0 0 1px;cursor:pointer;" border="0" src='../<%# GetTmpImg(DataBinder.Eval(Container,"DataItem(Src)","{0}")) %>' ondblclick="$(this).getNext().checked=true;$('Button1').click();" width="88" height="88" onmousemove="this.parentNode.parentNode.style.backgroundColor='#006699'" onmouseout="this.parentNode.parentNode.style.backgroundColor='white';" />
                                    <input id="cbxImg" type="checkbox" style="border:none;background-image:none;" runat="server" value='<%#Eval("src") %>'/>
                                </div></div><br />
                                <label title="<%#Eval("Name") %>" ><%#V5Shop.Common.utils.left(Eval("Name").ToString(),6) %></label></center></td>
                        </tr>
                    </table>
                </ItemTemplate>
            </asp:DataList>
            
                        
            <div>
                <div style="padding:10px 10px 30px; text-align:right; color:#000000"><font color=black>共 <asp:Label ID="lbmaxpage" runat="server" Text="1"></asp:Label> 页
                    , 当前第  <asp:Label ID="lbpage" runat="server" Text="1"></asp:Label>  页 &nbsp;&nbsp;
                    [ <asp:LinkButton ID="lbtnIndex" runat="server" Text="首页" style="color:Black;" OnClick="lbtnIndex_Click"></asp:LinkButton>
                    | <asp:LinkButton ID="lbtnLast" Enabled="false" runat="server" Text="上一页" style="color:Black;" OnClick="lbtnLast_Click"></asp:LinkButton>
                    | <asp:LinkButton ID="lbtnNext" runat="server" Text="下一页" style="color:Black;" OnClick="lbtnNext_Click"></asp:LinkButton>
                    | <asp:LinkButton ID="lbtnEnd" runat="server" Text="末页" style="color:Black;" OnClick="lbtnEnd_Click"></asp:LinkButton> ] 
                    页数:
                    <asp:DropDownList ID="ddlPageSelect" runat="server" OnSelectedIndexChanged="ddlPageSelect_SelectedIndexChanged" AutoPostBack="true"></asp:DropDownList>
			    </div>
            </div>
            
            <asp:Panel ID="AddField" runat="server" Visible="false">
            </asp:Panel>
        </div>
        
        <div id="hiddenfield">
            <asp:HiddenField ID="CheckedIDS" runat="server" Value="0" />
            <asp:HiddenField ID="PageIndex" runat="server" Value="0"/>
            <asp:HiddenField ID="MaxPageIndex" runat="server" Value="0"/>
            <uc1:HiddenField ID="Alert" runat="server" />
        </div>
    </div>
    </form>
</body>
</html>