<%@ page language="C#" autoeventwireup="true" inherits="ProduceAdmin_ProduceOrder_List, GroupTGWeb_deploy" %>

<%@ Register Assembly="ShopNum1.Control" Namespace="ShopNum1.Control" TagPrefix="cc1" %>
<%@ Register Src="UserControl/MessageShow.ascx" TagName="MessageShow" TagPrefix="ShopNum1" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ShopNum1" %>
<!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" type="text/css" href="style/index.css" />

    <script type="text/javascript" language="javascript" src="../../js/CommonJS.js"></script>

</head>
<body style="padding: 0; background-image: url(images/Bg_right.gif); background-repeat: repeat;">
    <form id="form1" runat="server">
    <ShopNum1:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server" EnableScriptGlobalization="True"
        EnableScriptLocalization="True" />
    <div class="main">
        <div class="table1">
            <div class="title">
                订单列表
            </div>
            <div class="query">
                <table style="width: 100%">
                    <tr>
                        <td align="right">
                            <asp:Label ID="Label5" runat="server" Text="活动名称："></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxActivename" runat="server" CssClass="input1"></asp:TextBox>
                        </td>
                        <td align="right">
                            <asp:Label ID="Label6" runat="server" Text="是否为虚拟："></asp:Label>
                        </td>
                        <td>
                            <asp:DropDownList ID="DropDownListIsUse" runat="server" CssClass="select1">
                                <asp:ListItem Value="-1">-全部-</asp:ListItem>
                                <asp:ListItem Value="0">实体订单</asp:ListItem>
                                <asp:ListItem Value="1">虚拟订单</asp:ListItem>
                            </asp:DropDownList>
                        </td>
                        <td align="right">
                            <asp:Label ID="LabelOderStatus" runat="server" Text="订单状态："></asp:Label>
                        </td>
                        <td>
                            <asp:DropDownList ID="DropDownListOderStatus" runat="server" CssClass="select1">
                            </asp:DropDownList>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            <asp:Label ID="LabelOrderNumber" runat="server" Text="订单号："></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxOrderNumber" runat="server" CssClass="input1"></asp:TextBox>
                        </td>
                        <td align="right">
                            <asp:Label ID="LabelMemLoginID" runat="server" Text="购买人："></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxMemLoginID" runat="server" CssClass="input1"></asp:TextBox>
                        </td>
                        <td align="right">
                            <asp:Label ID="LabelPaymentGuid" runat="server" Text="支付方式："></asp:Label>
                        </td>
                        <td>
                            <asp:DropDownList ID="DropDownListPaymentGuid" runat="server" CssClass="select1">
                            </asp:DropDownList>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            <asp:Label ID="LabelAddress" runat="server" Text="详细地址："></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxAddress" runat="server" CssClass="input1"></asp:TextBox>
                        </td>
                        <td align="right">
                            <asp:Label ID="LabelPostalcode" runat="server" Text="邮编："></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxPostalcode" runat="server" CssClass="input1"></asp:TextBox>
                        </td>
                        <td align="right">
                            <asp:Label ID="LabelDispatchModeGuid" runat="server" Text="配送方式："></asp:Label>
                        </td>
                        <td>
                            <asp:DropDownList ID="DropDownListDispatchModeGuid" runat="server" CssClass="select1">
                            </asp:DropDownList>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            <asp:Label ID="LabelMobile" runat="server" Text="手机号码："></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxMobile" runat="server" CssClass="input1"></asp:TextBox>
                        </td>
                        <td align="right">
                            <asp:Label ID="LabelEmail" runat="server" Text="电子邮件："></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxEmail" runat="server" CssClass="input1"></asp:TextBox>
                        </td>
                        <td rowspan="3" colspan="2" align="center">
                            <asp:Button ID="ButtonSearch" runat="server" OnClick="ButtonSearch_Click" Text="查询"
                                CssClass="bnt1" />
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            <asp:Label ID="LabelTel" runat="server" Text="联系电话："></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxTel" runat="server" CssClass="input1"></asp:TextBox>
                        </td>
                        <td align="right">
                            <asp:Label ID="LabelShouldPayPrice" runat="server" Text="应付金额："></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxShouldPayPrice1" runat="server" CssClass="input1"></asp:TextBox>
                            <asp:RegularExpressionValidator ID="RegularExpressionValidatorShouldPayPrice1" runat="server"
                                ControlToValidate="TextBoxShouldPayPrice1" Display="Dynamic" ErrorMessage="输入格式不正确"
                                ValidationExpression="^[0-9]+(.[0-9]{1,3})?$"></asp:RegularExpressionValidator>
                            -<asp:TextBox ID="TextBoxShouldPayPrice2" runat="server" CssClass="input1"></asp:TextBox>
                            <asp:RegularExpressionValidator ID="RegularExpressionValidatorShouldPayPrice2" runat="server"
                                ControlToValidate="TextBoxShouldPayPrice2" Display="Dynamic" ErrorMessage="输入格式不正确"
                                ValidationExpression="^[0-9]+(.[0-9]{1,3})?$"></asp:RegularExpressionValidator>
                            <span style="display: none">
                                <asp:DropDownList ID="DropDownListIsAccounts" runat="server" CssClass="select1">
                                    <asp:ListItem Value="-1">-全部-</asp:ListItem>
                                    <asp:ListItem Value="1">已结算</asp:ListItem>
                                    <asp:ListItem Value="0">未结算</asp:ListItem>
                                </asp:DropDownList>
                            </span>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            <asp:Label ID="Label2" runat="server" Text="收货人："></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxName" runat="server" CssClass="input1"></asp:TextBox>
                        </td>
                        <td align="right">
                            <asp:Label ID="LabelCreateTime" runat="server" Text="下单日期："></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxCreateTime1" runat="server" CssClass="input1"></asp:TextBox>
                            <img id="imgCreateTime1" alt="" src="images/Calendar.png" style="width: 16px; height: 18px;"
                                align="absmiddle" />
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" ControlToValidate="TextBoxCreateTime1"
                                Display="Dynamic" ErrorMessage="时间格式不正确" ValidationExpression="^\d{4}-(\d{2}|\d{1})-(\d{2}|\d{1})( (\d{2}|\d{1}):(\d{2}|\d{1}):(\d{2}|\d{1}))*"></asp:RegularExpressionValidator><ShopNum1:CalendarExtender
                                    ID="CalendarExtender3" runat="server" TargetControlID="TextBoxCreateTime1" PopupButtonID="imgCreateTime1"
                                    CssClass="ajax__calendar">
                                </ShopNum1:CalendarExtender>
                            &nbsp;-<asp:TextBox ID="TextBoxCreateTime2" runat="server" CssClass="input1"></asp:TextBox>
                            <img id="imgCreateTime2" alt="" src="images/Calendar.png" style="width: 16px; height: 18px;"
                                align="absmiddle" />
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="TextBoxCreateTime2"
                                Display="Dynamic" ErrorMessage="时间格式不正确" ValidationExpression="^\d{4}-(\d{2}|\d{1})-(\d{2}|\d{1})( (\d{2}|\d{1}):(\d{2}|\d{1}):(\d{2}|\d{1}))*"></asp:RegularExpressionValidator><ShopNum1:CalendarExtender
                                    ID="CalendarExtender1" runat="server" TargetControlID="TextBoxCreateTime2" PopupButtonID="imgCreateTime2"
                                    CssClass="ajax__calendar">
                                </ShopNum1:CalendarExtender>
                        </td>
                    </tr>
                </table>
            </div>
            <div class="vote">
                <asp:Button ID="ButtonReport" runat="server" OnClick="ButtonReport_Click" Text="导出到Excel"
                    CausesValidation="False" CssClass="bt3" />
                &nbsp;<asp:Button ID="ButtonHtml" runat="server" Text="导出到Html" CausesValidation="False"
                    CssClass="bt3" OnClick="ButtonHtml_Click" />
                <asp:RadioButtonList ID="RadioButtonListOutPage" runat="server" AutoPostBack="True"
                    RepeatDirection="Horizontal">
                    <asp:ListItem Selected="True" Value="0">仅打印当前页</asp:ListItem>
                    <asp:ListItem Value="1">打印所有查询记录</asp:ListItem>
                </asp:RadioButtonList>
            </div>
            <cc1:Num1GridView ID="Num1GridViewShow" runat="server" AutoGenerateColumns="False"
                AllowPaging="True" AllowSorting="True" AscendingImageUrl="~/images/SortAsc.gif"
                DescendingImageUrl="~/images/SortDesc.gif" Width="100%" AddSequenceColumn="False"
                AllowMultiColumnSorting="False" BorderColor="#CCDDEF" BorderStyle="Solid" BorderWidth="1px"
                CellPadding="4" Del="False" DeletePromptText="确实要删除指定的记录吗？" Edit="False" FixHeader="False"
                GridViewSortDirection="Ascending" PagingStyle="None" Style="margin-left: 2px;"
                TableName="" Font-Size="Small" DataSourceID="ObjectDataSourceData" OnRowDataBound="Num1GridViewShow_RowDataBound">
                <HeaderStyle HorizontalAlign="Center" BackColor="#6699CC" Font-Bold="True" ForeColor="#FFFFFF">
                </HeaderStyle>
                <PagerStyle HorizontalAlign="Left" BackColor="#EEEEEE" ForeColor="#6699CC"></PagerStyle>
                <Columns>
                    <asp:TemplateField>
                        <HeaderTemplate>
                            <input id="checkboxAll" onclick="javascript:SelectAllCheckboxes(this);" type="checkbox" />
                        </HeaderTemplate>
                        <ItemTemplate>
                            <input id="checkboxItem" value='<%# Eval("Guid") %>' type="checkbox" />
                        </ItemTemplate>
                        <ItemStyle HorizontalAlign="Center" Width="30px" />
                    </asp:TemplateField>
                    <asp:BoundField DataField="Guid" HeaderText="Guid">
                        <HeaderStyle CssClass="hidden" />
                        <ItemStyle CssClass="hidden" HorizontalAlign="Center" />
                    </asp:BoundField>
                    <asp:TemplateField HeaderText="订单号">
                        <ItemTemplate>
                            <a href='<%# "ProduceOrder_Operate.aspx?Guid="+ Eval("Guid") %>'>
                                <%# Eval("OrderNumber") %></a>
                        </ItemTemplate>
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="活动名称">
                        <ItemTemplate>
                            <asp:Label ID="Label2" runat="server" Text='<%# ReturnTitle(Eval("ActiveName")) %>'></asp:Label>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="虚拟商品订单">
                        <ItemTemplate>
                            <asp:Label ID="Label3" runat="server" Text='<%# ReturnIsUser(Eval("IsUse")) %>'></asp:Label>
                            <asp:HiddenField ID="HiddenFieldIsUse" runat="server" Value='<%# Eval("IsUse") %>' />
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:BoundField DataField="CreateTime" HeaderText="下单日期" SortExpression="CreateTime">
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:BoundField>
                    <asp:BoundField HeaderText="收货人" DataField="Name" SortExpression="Name">
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:BoundField>
                    <asp:BoundField DataField="MemLoginID" HeaderText="购买人" SortExpression="MemLoginID">
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:BoundField>
                    <asp:BoundField DataField="PaymentName" HeaderText="支付方式" SortExpression="PaymentName">
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:BoundField>
                    <asp:BoundField DataField="ProductPrice" HeaderText="商品总金额" SortExpression="ProductPrice">
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:BoundField>
                    <asp:BoundField HeaderText="应付金额" DataField="ShouldPayPrice" SortExpression="ShouldPayPrice">
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:BoundField>
                    <asp:TemplateField HeaderText="订单状态">
                        <ItemTemplate>
                            <asp:Label ID="Label1" runat="server" Text='<%# ChangeOderStatus(DataBinder.Eval(Container, "DataItem(OderStatus)","{0}")) %>'></asp:Label>
                        </ItemTemplate>
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="支付状态" SortExpression="OderStatus">
                        <ItemTemplate>
                            <asp:Label ID="Label12" runat="server" Text='<%# ChangePaymentStatus(DataBinder.Eval(Container, "DataItem(PaymentStatus)","{0}")) %>'></asp:Label>
                        </ItemTemplate>
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="发货状态">
                        <ItemTemplate>
                            <asp:Label ID="LabelStatus" runat="server" Text='<%# ChangeShipmentStatus(Eval("ShipmentStatus").ToString()) %>'></asp:Label>
                            <asp:HiddenField ID="HiddenField1" runat="server" Value="aaaaaaa" />
                        </ItemTemplate>
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:TemplateField>
                </Columns>
            </cc1:Num1GridView>
        </div>
    </div>
    <div class="vote">
        <asp:Button ID="ButtonEdit" runat="server" OnClick="ButtonEdit_Click" OnClientClick="return EditButton()"
            Text="查看" CausesValidation="False" CssClass="bnt1" />
    </div>
    <asp:HiddenField ID="SupplierID" runat="server" Value="0" />
    <asp:HiddenField ID="CheckGuid" runat="server" Value="0" />
    <asp:HiddenField ID="hiddenGuid" runat="server" Value="0" />
    <asp:ObjectDataSource ID="ObjectDataSourceData" runat="server" SelectMethod="SearchOrderInfo"
        TypeName="GroupFly.ProduceBusinessLogic.GroupFlyProduce_OrderInfo_Action" OldValuesParameterFormatString="original_{0}">
        <SelectParameters>
            <asp:ControlParameter ControlID="TextBoxOrderNumber" Name="orderNumber" PropertyName="Text"
                Type="String" />
            <asp:ControlParameter ControlID="TextBoxMemLoginID" Name="memLoginID" PropertyName="Text"
                Type="String" />
            <asp:ControlParameter ControlID="TextBoxName" Name="name" PropertyName="Text" Type="String" />
            <asp:ControlParameter ControlID="TextBoxAddress" Name="address" PropertyName="Text"
                Type="String" />
            <asp:ControlParameter ControlID="TextBoxPostalcode" Name="postalcode" PropertyName="Text"
                Type="String" />
            <asp:ControlParameter ControlID="TextBoxTel" Name="tel" PropertyName="Text" Type="String" />
            <asp:ControlParameter ControlID="TextBoxMobile" Name="mobile" PropertyName="Text"
                Type="String" />
            <asp:ControlParameter ControlID="TextBoxEmail" Name="email" PropertyName="Text" Type="String" />
            <asp:ControlParameter ControlID="DropDownListDispatchModeGuid" Name="dispatchModeGuid"
                PropertyName="SelectedValue" Type="String" />
            <asp:ControlParameter ControlID="DropDownListPaymentGuid" Name="paymentGuid" PropertyName="SelectedValue"
                Type="String" />
            <asp:ControlParameter ControlID="DropDownListOderStatus" Name="oderStatus" PropertyName="SelectedValue"
                Type="String" />
            <asp:ControlParameter ControlID="TextBoxShouldPayPrice1" Name="shouldPayPrice1" PropertyName="Text"
                Type="Decimal" />
            <asp:ControlParameter ControlID="TextBoxShouldPayPrice2" Name="shouldPayPrice2" PropertyName="Text"
                Type="Decimal" />
            <asp:ControlParameter ControlID="TextBoxCreateTime1" Name="createTime1" PropertyName="Text"
                Type="String" />
            <asp:ControlParameter ControlID="TextBoxCreateTime2" Name="createTime2" PropertyName="Text"
                Type="String" />
            <asp:ControlParameter ControlID="DropDownListIsAccounts" Name="IsAccounts" PropertyName="SelectedValue"
                Type="String" />
            <asp:Parameter Name="isDeleted" Type="Int32" />
            <%--<asp:ControlParameter ControlID="TextBoxActiveGuid" Name="ActiveGuid" 
                PropertyName="Text" Type="String" />--%>
            <asp:ControlParameter ControlID="TextBoxActivename" Name="Activename" PropertyName="Text"
                Type="String" />
            <asp:ControlParameter ControlID="DropDownListIsUse" Name="Isuse" PropertyName="SelectedValue"
                Type="String" />
            <asp:ControlParameter ControlID="SupplierID" Name="supplierID" PropertyName="Value"
                Type="String" />
        </SelectParameters>
    </asp:ObjectDataSource>
    <br />
    </form>
</body>
</html>
