<%@ page language="C#" autoeventwireup="true" inherits="admin_by, aoshuosoft" %>


<!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>
    <link rel="stylesheet" href="admin.css" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
    <div>
    <asp:Panel ID="addedit" runat="server"  Width="100%" Visible="false">
            <table class="adminmaintable" border="0" cellpadding="3" cellspacing="1">
                <tr>
                    <td class="bt" style="text-align: center; height: 40px;" colspan="2">
                        查看修改订单</td>
                </tr>
                <tr>
                    <td>
                        产品名称：</td>
                    <td >
                        <asp:Literal ID="name" runat="server"></asp:Literal></td>
                </tr>
                <tr>
                    <td >
                        数量：</td>
                    <td >
                        <asp:Literal ID="number" runat="server"></asp:Literal></td>
                </tr>
                <tr>
                    <td>
                        收货地址：</td>
                    <td>
                        <asp:Literal ID="incomeaddress" runat="server"></asp:Literal></td>
                </tr>
                <tr>
                    <td>
                        收货人姓名：</td>
                    <td>
                        <asp:Literal ID="incomename" runat="server"></asp:Literal></td>
                </tr>
                <tr>
                    <td>
                        收货人电话：</td>
                    <td>
                        <asp:Literal ID="incomephone" runat="server"></asp:Literal></td>
                </tr>
                <tr>
                    <td >
                        其他要求：</td>
                    <td >
                        <asp:TextBox ID="explain" runat="server" Height="106px" TextMode="MultiLine" Width="488px"></asp:TextBox></td>
                </tr>
                <tr>
                    <td>
                        状态：</td>
                    <td>
                        <asp:RadioButton ID="no" Text="等待发货" runat="server" GroupName="0" />
                        <asp:RadioButton ID="yes" runat="server" Text="完成" GroupName="0" /></td>
                </tr>
                <tr>
                    <td>
                    </td>
                    <td>
                        <asp:Button ID="editfrom" runat="server" Text="修 改" OnClick="editfrom_Click"  />
                        </td>
                </tr>
            </table>
        </asp:Panel>
        <asp:Panel ID="all" runat="server"  Width="100%" Visible="false">
                 <asp:GridView  ID="GridView1" OnPageIndexChanging="GridView1_PageIndexChanging" runat="server" AutoGenerateColumns="False" Width="100%" GridLines="None" ForeColor="#333333" AllowPaging="True" CellPadding="4" PageSize="20">
                <Columns>
                    <asp:TemplateField HeaderText="产品名称" ><ItemTemplate><a href="by.aspx?action=edit&id=<%#Eval("id") %>"><%#Eval("name")%></a></ItemTemplate></asp:TemplateField>
                    <asp:TemplateField HeaderText="产品数量"><ItemTemplate><a> <%#Eval("number") %></a></ItemTemplate></asp:TemplateField>
                    <asp:TemplateField HeaderText="收货地址"><ItemTemplate><a><%#Eval("incomeaddress").ToString().PadRight(100).Remove(10) %></a></ItemTemplate></asp:TemplateField> 
                    <asp:TemplateField HeaderText="收货人姓名"><ItemTemplate><a><%#Eval("incomename") %></a></ItemTemplate></asp:TemplateField> 
                    <asp:TemplateField HeaderText="收货人电话"><ItemTemplate><a><%#Eval("incomephone") %></a></ItemTemplate></asp:TemplateField>
                    <asp:TemplateField HeaderText="订单状态"><ItemTemplate><a><%#Eval("state") %></a></ItemTemplate></asp:TemplateField>
                    <asp:BoundField DataField="user" HeaderText="订购人" />
                    <asp:TemplateField HeaderText="编辑"><ItemTemplate><a href="by.aspx?action=edit&id=<%#Eval("id") %>">编辑</a></ItemTemplate></asp:TemplateField>
                    <asp:TemplateField HeaderText="删除"><ItemTemplate><a href="by.aspx?action=del&id=<%#Eval("id") %>" onclick="return confirm('删除将不可恢复，您真的要删除吗？')">删除</a></ItemTemplate></asp:TemplateField>
                </Columns>
             <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
             <RowStyle BackColor="#EFF3FB" />
             <EditRowStyle BackColor="#2461BF" />
             <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
             <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
             <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
             <AlternatingRowStyle BackColor="White" />
            </asp:GridView>
           <asp:Literal ID="tj" runat="server"></asp:Literal></asp:Panel>
    </div>
    </form>
</body>
</html>