<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="TuneOutList.aspx.cs" Inherits="SWTraining.Commodity.TuneOutList"
    Title="仓库管理-调拨查询" %>

<%@ Import Namespace="SWTraining" %>
<!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 runat="server">
    <link id="linkStyle" runat="server" href="../Themes/Orange/css.css" rel="stylesheet"
        type="text/css" />
            <script type="text/javascript"> 
<!--

        function Focus() {
            if (!document.getElementById("tbxBarcode").disabled) {
                document.getElementById("tbxBarcode").focus();
            }
        }

//--> 
    </script>
</head>
<body onload="Focus();">
    <form id="form1" runat="server">
    <div class="divpanel">
            条形码：<asp:TextBox ID="tbxBarcode" runat="server" Width="110px"></asp:TextBox>
&nbsp;分类：<asp:DropDownList ID="ddlCommodityType" runat="server" DataTextField="CommodityTypeName"
                            DataValueField="CommodityTypeID" AutoPostBack="True" OnSelectedIndexChanged="ddlCommodityType_SelectedIndexChanged">
                        </asp:DropDownList>
                        产品：<asp:DropDownList ID="ddlCommodity" runat="server" DataTextField="CommodityName" DataValueField="CommodityID">
            </asp:DropDownList>
        日期：<asp:TextBox ID="tbxStartDate" runat="server" Width="79px"></asp:TextBox>
                        -<asp:TextBox ID="tbxEndDate" runat="server" Width="79px"></asp:TextBox>
                    <asp:Button ID="btnSearch" runat="server" onclick="btnSearch_Click" 
            Text = "查询" />
    </div>
    <div class="divpanel">
        <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" CssClass="gridview"
            DataKeyNames="TuneOutID" OnRowDeleting="GridView1_RowDeleting" 
            onrowdatabound="GridView1_RowDataBound">
            <Columns>
                <asp:BoundField DataField="CommodityID" HeaderText = "书本编号" />
                <asp:BoundField DataField="CommodityName" HeaderText = "书本名称" />
                <asp:BoundField DataField="StoreroomName" HeaderText = "调出仓库" />
                <asp:BoundField DataField="ToStoreroomName" HeaderText = "调入仓库" />
                <asp:BoundField DataField="DateAndTime" HeaderText = "日期" />
                <asp:BoundField DataField="Amount" HeaderText = "调出数量" />
                <asp:BoundField DataField="Remark" HeaderText = "备注" />
                <asp:BoundField DataField="TrueName" HeaderText = "录入员" />
                <asp:TemplateField HeaderText="编辑" ShowHeader="False">
                    <ItemTemplate>
                        <asp:HyperLink runat="server" ID="hlkEdit" Text="编辑" NavigateUrl='<%# string.Format("PostTuneOut.aspx?TuneOutID={0}&StoCommodityID={1}&GetUrl={2}",Eval("TuneOutID"),Eval("StoCommodityID"),swq.Web.PathAndQuery()) %>'></asp:HyperLink>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="删除">
                    <ItemTemplate>
                        <asp:LinkButton ID="lbnDelete" runat="server" Text="删除" CommandName="Delete"
                            OnClientClick="<%# Rs.Messages.确定删除%>"></asp:LinkButton>
                    </ItemTemplate>
                </asp:TemplateField>
            </Columns>
        </asp:GridView>
    </div>
        <div class="divpanel">
            <asp:Literal ID="litPagerButton" runat="server"></asp:Literal>
        </div>
    </form>
</body>
</html>
