<%@ page language="C#" masterpagefile="~/Member/MyShopMasterPage.master" autoeventwireup="true" inherits="Member_StockManage_StockNumberDetail, WebApp_deploy" title="库存明细信息" %>

<asp:Content ID="cphContent" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <script type="text/javascript">
        //详细信息
        function CheckInfo(stocktype, infoorderid) {
            var linkurl = "?stockType=" + stocktype + "&Action=checkinfo&infoOrderID=" + infoorderid;
            var beforeurl = "";
            if (stocktype == "inPurchase") {
                //采购入库
                beforeurl = "StockInfoInRecord.aspx";
            } else if (stocktype == "outSell") {
                //销售出库
                beforeurl = "StockInfoOut.aspx"; //../JXC/StockOrderSale.aspx
            } else if (stocktype == "bad") {
                //报损单
                beforeurl = "DepotListManage.aspx";
            } else if (stocktype == "baoyi") {
                // 报溢单
                beforeurl = "DepotListManage.aspx";
            }
            if (beforeurl != "") {
                window.location.href = beforeurl + linkurl;
            }
        }
    </script>
    <div class="pageTitle" style="line-height: 30px; vertical-align: middle;">
        &nbsp;&nbsp;&nbsp;&nbsp;<asp:Literal ID="ltrTitle" runat="server">商品库存明细信息</asp:Literal></div>
    <div id="MainMenu">
        <div class="TabText">
            <div style="line-height: 2px;">
                &nbsp;</div>
                <table class="SearchTableStyle">
                    <tr>
                        <th colspan="3" style="float: left; text-align: left">
                            &nbsp;<b>高级查询：</b>
                        </th>
                    </tr>
                    <tr>
                        <td>
                            &nbsp;时间： &nbsp;<asp:TextBox ID="txtSearchBeginDate" runat="server" onfocus="WdatePicker()"
                                CssClass="Wdate" Width="90px"></asp:TextBox>
                            &nbsp;&nbsp;至：&nbsp;&nbsp;<asp:TextBox ID="txtSearchEndDate" runat="server" onfocus="WdatePicker()"
                                CssClass="Wdate" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                            &nbsp;单据编号：<asp:TextBox ID="txtSearchInfoNumber" CausesValidation="false" runat="server"
                                Width="200px"></asp:TextBox>
                        </td>
                        <td>
                            &nbsp;<asp:Button ID="btnSearch" runat="server" Text="查询" OnClick="btnSearch_Click" />
                        </td>
                    </tr>
                </table>
            <asp:Repeater ID="rptList" runat="server">
                <HeaderTemplate>
                    <table class="rptrow" cellspacing="0" cellpadding="0">
                        <tr>
                            <th>
                                行号
                            </th>
                            <th>
                                日期
                            </th>
                            <th>
                                单号
                            </th>
                            <th>
                                货号
                            </th>
                            <th>
                                名称
                            </th>
                            <th>
                                商品类型
                            </th>
                            <th>
                                单位
                            </th>
                            <th>
                                数量
                            </th>
                            <th>
                                价格
                            </th>
                            <th>
                                金额
                            </th>
                        </tr>
                </HeaderTemplate>
                <ItemTemplate>
                    <tr style="cursor: pointer" onclick="CheckInfo('<%#Eval("StockOrderType")%>','<%#Eval("InfoOrderID") %>')"
                        onmouseover="c=this.style.backgroundColor;this.style.backgroundColor='#E7EDFE'"
                        onmouseout="this.style.backgroundColor=c;">
                        <td align="center">
                            <asp:Label ID="lblRow" runat="server"></asp:Label>
                        </td>
                        <td>
                            <%#Eval("StockDate").ToString()==""?"&nbsp;":Eval("StockDate")%>
                        </td>
                        <td align="left" style="padding: 0px 2px 0px 6px">
                            <%#Eval("InfoNumber")%>
                        </td>
                        <td align="left" style="padding: 0px 2px 0px 6px">
                            <%# Eval("Goods_serial")%>
                        </td>
                        <td align="left" style="padding: 0px 2px 0px 6px; width: 20%;">
                            <%#Eval("ProductName")%>
                        </td>
                        <td align="left" style="padding: 0px 2px 0px 6px">
                            <%# HoWave.Web.Shop.TextFormat.GetProductType(Eval("ProductType").ToString())%>
                        </td>
                        <td>
                            <%# Eval("Unit")%>
                        </td>
                        <td align="right">
                            <asp:Label ID="lblStockCount" runat="server"></asp:Label>&nbsp;&nbsp;
                        </td>
                        <td align="right">
                            <%# Eval("Price") %>&nbsp;&nbsp;
                        </td>
                        <td align="right">
                            <asp:HiddenField ID="hfStockStatus" runat="server" Value='<%# Eval("StockStatus") %>' />
                            <asp:HiddenField ID="hfCount" runat="server" Value='<%# Eval("StockCount") %>' />
                            <asp:HiddenField ID="hfStandPrice" runat="server" Value='<%# Eval("Price") %>' />
                            <asp:Label ID="lblMoney" runat="server" ForeColor="Green"></asp:Label>
                            &nbsp;&nbsp;
                        </td>
                    </tr>
                </ItemTemplate>
                <FooterTemplate>
                    <tr class="rptrowTrBg">
                        <td align="center">
                            合计
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td align="right">
                            <asp:Label ID="lblTotalCount" runat="server" ForeColor="Black"></asp:Label>&nbsp;&nbsp;
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td align="right">
                            <asp:Label ID="lblTotalMoney" runat="server" ForeColor="Green"></asp:Label>&nbsp;&nbsp;
                        </td>
                    </tr>
                    </table>
                </FooterTemplate>
            </asp:Repeater>
            <div style="text-align: center">
                &nbsp;&nbsp;&nbsp;&nbsp;
                <asp:Literal ID="ltrPagePanel" runat="server"></asp:Literal></div>
            <div style="line-height: 6px;">
                &nbsp;</div>
        </div>
    </div>
</asp:Content>
