<%@ Page Language="C#" AutoEventWireup="false" CodeBehind="AliPay.aspx.cs" Inherits="web.AliPay" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
	<HEAD>
		<title>使用支付宝购买商品</title><meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> 
		<!--#include file="inc/head.inc"-->
		<script language="JavaScript">
function GetDiv(sDiv)
{
	var div;
	if (document.getElementById)
		div = document.getElementById(sDiv);
	else if (document.all)
		div = eval("window." + sDiv);
	else if (document.layers)
		div = document.layers[sDiv];
	else
		div = null;

	return div;
}

function HideDiv(sDiv)
{
	d = GetDiv(sDiv);
	if (d)
	{
		if (document.layers) d.visibility = "hide";
		else d.style.visibility = "hidden";
	}
}

function PleaseWait(sDivButton, sDivMessage, sInnerHtml)
{
	HideDiv(sDivButton);
	var d = GetDiv(sDivMessage);
	if (d) d.innerHTML = sInnerHtml;
}
		</script>
	</HEAD>
	<body>
		<form id="Form1" method="post" runat="server">
			<div class="mframe">
				<table width="100%" cellspacing="0" cellpadding="0">
					<tr>
						<td class="tl"></td>
						<td class="tm">
							<table width="100%" cellpadding="0" cellspacing="0">
								<tr>
									<td>
										<span class="tt"><%=GetResourceString("UseAlipay")%></span>
									</td>
								</tr>
							</table>
						</td>
						<td class="tr"></td>
					</tr>
				</table>
				<table width="100%" cellspacing="0" cellpadding="0">
					<tr>
						<td class="ml"></td>
						<td class="mm">
							<table width="100%" cellpadding="0" cellspacing="0" border="0">
								<tr>
									<td valign="top">
										<table align="center" width="98%" cellpadding="0" cellspacing="0">
											<tr>
												<td><b><%=GetResourceString("OrderEmail_ProductName")%></b></td>
												<td><b><%=GetResourceString("OrderEmail_ProductNumber")%></b></td>
												<td><b><%=GetResourceString("MemberPrices")%></b></td>
												<td><b><%=GetResourceString("FittingsPrice")%></b></td>
												<td><b><b><%=GetResourceString("SumPrice")%></b></b></td>
												<td width="80"><b><%=GetResourceString("DiscountOrNot")%></b></td>
											</tr>
											<TR>
												<TD><a href='Show.aspx?PID=<%=product.ProductID %>' target=_blank><%=product.Name %></a>
												</TD>
												<TD><%=product.ProductNo %></TD>
												<TD><%=product.MemberPrice %></TD>
												<TD>
													1
													<%=product.Unit %>
												</TD>
												<TD><%=product.MemberPrice %></TD>
												<TD width="80" align="center"><%=product.IsDiscount ? "是" : "否" %></TD>
											</TR>
										</table>
									</td>
								</tr>
								<tr>
									<td class="hr">
									</td>
								</tr>
								<tr>
									<td align="right">
										<table>
											<tr>
												<td align="right"><b><%=GetResourceString("Weight")%></b>：</td>
												<td><%=product.Weight%>Kg</td>
											</tr>
											<tr>
												<td align="right"><b><%=GetResourceString("IsDiscount")%></b>：</td>
												<td><%=GetDiscount()%>%</td>
											</tr>
											<tr>
												<td align="right"><b><%=GetResourceString("AfterDiscount")%></b>：</td>
												<td>￥<%=string.Format("{0:f2}",GetDiscountTotal())%></td>
											</tr>
										</table>
									</td>
								</tr>
							</table>
						</td>
					</tr>
				</table>
				<table width="100%" cellspacing="0" cellpadding="0">
					<tr>
						<td class="tl"></td>
						<td class="tm"><div class="tt"><%=GetResourceString("ReceiverInfo")%></div></td>
						<td class="tr"></td>
					</tr>
				</table>
				<table width="100%" cellspacing="0" cellpadding="0">
					<tr>
						<td class="ml"></td>
						<td class="mm">
							<table cellSpacing="0" cellPadding="0" align="center" width="98%">
								<tr>
									<td height="16"><%=GetResourceString("ReceiverAddress")%>：</td>
									<td colSpan="3" height="16"><asp:dropdownlist id="ddlTopAreas" runat="server" AutoPostBack="True"></asp:dropdownlist><asp:dropdownlist id="ddlSubAreas" runat="server" AutoPostBack="True"></asp:dropdownlist><asp:textbox id="txtRAddress" runat="server" Width="300px"></asp:textbox><font color="red">*</font></td>
								</tr>
								<tr>
									<td><%=GetResourceString("ReceiverName")%>：</td>
									<td><asp:textbox id="txtRName" runat="server"></asp:textbox><FONT color="red">*</FONT></td>
									<td><%=GetResourceString("ReceiverEmail")%>：</td>
									<td><asp:textbox id="txtREmail" runat="server"></asp:textbox><FONT color="red">*</FONT></td>
								</tr>
								<tr>
									<td><%=GetResourceString("ReceiverTelephone")%>：</td>
									<td><asp:textbox id="txtRPhone" runat="server"></asp:textbox><FONT color="red">*</FONT></td>
									<td><%=GetResourceString("ReceiverPostalcode")%>：</td>
									<td><asp:textbox id="txtRPostalcode" runat="server"></asp:textbox></td>
								</tr>
								<tr>
									<td colSpan="4">
										<asp:CheckBox id="cbxSame" runat="server" Text="购买人与收货人相同" Checked="True" TextAlign="Left"></asp:CheckBox></td>
								</tr>
							</table>
						</td>
					</tr>
				</table>
				<SPAN id="buyer" style="DISPLAY: none">
					<table width="100%" cellspacing="0" cellpadding="0">
						<tr>
							<td class="tl"></td>
							<td class="tm">
								<span class="tt"><%=GetResourceString("BuyerInfo")%></span>
							</td>
							<td class="tr"></td>
						</tr>
					</table>
					<table width="100%" cellspacing="0" cellpadding="0">
						<tr>
							<td class="ml"></td>
							<td class="mm">
								<table cellSpacing="0" cellPadding="0" width="98%" align="center">
									<tr>
										<td height="16"><%=GetResourceString("BuyerAddress")%>：</td>
										<td colSpan="3" height="16"><asp:textbox id="txtBAddress" runat="server" Width="400px"></asp:textbox></td>
									</tr>
									<tr>
										<td><%=GetResourceString("BuyerName")%></td>
										<td><asp:textbox id="txtBName" runat="server"></asp:textbox></td>
										<td>Email</td>
										<td><asp:textbox id="txtBEmail" runat="server"></asp:textbox></td>
									</tr>
									<tr>
										<td><%=GetResourceString("BuyerTelephone")%></td>
										<td><asp:textbox id="txtBPhone" runat="server"></asp:textbox></td>
										<td><%=GetResourceString("BuyerPostalcode")%></td>
										<td><asp:textbox id="txtBPostalcode" runat="server"></asp:textbox></td>
									</tr>
								</table>
							</td>
						</tr>
					</table>
				</SPAN>
				<script language="javascript">
					function BuyerSame()
					{
						if(document.Form1.cbxSame.checked)
						{
							eval("buyer" + ".style.display=\"none\";");
						}
						else
						{
							eval("buyer" + ".style.display=\"\";");
						}
					}
					BuyerSame();
				</script>
				<table width="100%" cellspacing="0" cellpadding="0">
					<tr>
						<td class="tl"></td>
						<td class="tm"><div class="tt"><%=GetResourceString("ShippingWay")%></div></td>
						<td class="tr"></td>
					</tr>
				</table>
				<table width="100%" cellspacing="0" cellpadding="0">
					<tr>
						<td class="ml"></td>
						<td class="mm">
							<asp:RadioButtonList ID="rblShipping" Runat="server" RepeatDirection="Vertical" RepeatLayout="Table"></asp:RadioButtonList>
						</td>
					</tr>
				</table>
				<table id="TABLE1" cellSpacing="0" cellPadding="0" width="100%" runat="server">
					<tr>
							<td class="tl"></td>
							<td class="tm"><div class="tt"><%=GetResourceString("DeliverGoodsDate")%></div></td>
							<td class="tr"></td>
					</tr>
					<tr>
						<td width="100%" colspan=3>						
							<table width="100%" cellspacing="0" cellpadding="0">
								<tr>
								<td class="ml"></td>
								<td class="mm">
									<table width="100%"  cellspacing="0" cellpadding="0">
										<tr>
											<td width=25%>
											<asp:textbox id="txt_Date" runat="server" ForeColor="ControlDark"></asp:textbox><A onMouseOver="window.status='Date Picker';return true;" onMouseOut="window.status='';return true;"
											href="javascript:show_calendar('Form1.txt_Date');" border="0"><IMG src="images/imgbtn_Date.jpg" align="absMiddle" border="0"></A>								  
											</td>
											<td align="left">
												<table cellpadding="0" cellspacing="0" id="TABLE2" height="22" runat="server">
													<tr>
														<td>
														<%=GetResourceString("TimeFrom")%>
														<asp:dropdownlist id="ddlHours" Runat="server">
															<asp:ListItem Value="0">0:00</asp:ListItem>
															<asp:ListItem Value="1">1:00</asp:ListItem>
															<asp:ListItem Value="2">2:00</asp:ListItem>
															<asp:ListItem Value="3">3:00</asp:ListItem>
															<asp:ListItem Value="4">4:00</asp:ListItem>
															<asp:ListItem Value="5">5:00</asp:ListItem>
															<asp:ListItem Value="6">6:00</asp:ListItem>
															<asp:ListItem Value="7">7:00</asp:ListItem>
															<asp:ListItem Value="8">8:00</asp:ListItem>
															<asp:ListItem Value="9">9:00</asp:ListItem>
															<asp:ListItem Value="10">10:00</asp:ListItem>
															<asp:ListItem Value="11">11:00</asp:ListItem>
															<asp:ListItem Value="12">12:00</asp:ListItem>
															<asp:ListItem Value="13">13:00</asp:ListItem>
															<asp:ListItem Value="14">14:00</asp:ListItem>
															<asp:ListItem Value="15">15:00</asp:ListItem>
															<asp:ListItem Value="16">16:00</asp:ListItem>
															<asp:ListItem Value="17">17:00</asp:ListItem>
															<asp:ListItem Value="18">18:00</asp:ListItem>
															<asp:ListItem Value="19">19:00</asp:ListItem>
															<asp:ListItem Value="20">20:00</asp:ListItem>
															<asp:ListItem Value="21">21:00</asp:ListItem>
															<asp:ListItem Value="22">22:00</asp:ListItem>
															<asp:ListItem Value="23">23:00</asp:ListItem>
															<asp:ListItem Value="24" Selected>请选择</asp:ListItem>
														</asp:dropdownlist>&nbsp; <%=GetResourceString("To")%>
														<asp:DropDownList ID="ddlHours1" runat="server">
                                                          <asp:ListItem Value="0">0:00</asp:ListItem>
                                                          <asp:ListItem Value="1">1:00</asp:ListItem>
                                                          <asp:ListItem Value="2">2:00</asp:ListItem>
                                                          <asp:ListItem Value="3">3:00</asp:ListItem>
                                                          <asp:ListItem Value="4">4:00</asp:ListItem>
                                                          <asp:ListItem Value="5">5:00</asp:ListItem>
                                                          <asp:ListItem Value="6">6:00</asp:ListItem>
                                                          <asp:ListItem Value="7">7:00</asp:ListItem>
                                                          <asp:ListItem Value="8">8:00</asp:ListItem>
                                                          <asp:ListItem Value="9">9:00</asp:ListItem>
                                                          <asp:ListItem Value="10">10:00</asp:ListItem>
                                                          <asp:ListItem Value="11">11:00</asp:ListItem>
                                                          <asp:ListItem Value="12">12:00</asp:ListItem>
                                                          <asp:ListItem Value="13">13:00</asp:ListItem>
                                                          <asp:ListItem Value="14">14:00</asp:ListItem>
                                                          <asp:ListItem Value="15">15:00</asp:ListItem>
                                                          <asp:ListItem Value="16">16:00</asp:ListItem>
                                                          <asp:ListItem Value="17">17:00</asp:ListItem>
                                                          <asp:ListItem Value="18">18:00</asp:ListItem>
                                                          <asp:ListItem Value="19">19:00</asp:ListItem>
                                                          <asp:ListItem Value="20">20:00</asp:ListItem>
                                                          <asp:ListItem Value="21">21:00</asp:ListItem>
                                                          <asp:ListItem Value="22">22:00</asp:ListItem>
                                                          <asp:ListItem Value="23">23:00</asp:ListItem>
                                                          <asp:ListItem Value="24" selected>请选择</asp:ListItem>
                                                        </asp:DropDownList>
																									</td>
											</tr>
										</table>
									</td>
									</tr>
									</table>
								</td>
								</tr>
							</table>
							<table width="100%" cellspacing="0" cellpadding="0" >
								<tr>
									<td class="bl"></td>
									<td class="bm"></td>
									<td class="br"></td>
								</tr>
							</table>						
						</td>							
					</tr>
				</table>
				<table width="100%" cellspacing="0" cellpadding="0">
					<tr>
						<td class="tl"></td>
						<td class="tm"><div class="tt"><%=GetResourceString("PaymentInfo")%></div></td>
						<td class="tr"></td>
					</tr>
				</table>
				<table width="100%" cellspacing="0" cellpadding="0">
					<tr>
						<td class="ml"></td>
						<td class="mm">
							<asp:RadioButtonList ID="rblPayment" Runat="server" RepeatDirection="Vertical" RepeatLayout="Table"></asp:RadioButtonList>
						</td>
					</tr>
				</table>
				<table width="100%" cellspacing="0" cellpadding="0">
					<tr>
						<td class="tl"></td>
						<td class="tm"><div class="tt"><%=GetResourceString("OrderComment")%></div></td>
						<td class="tr"></td>
					</tr>
					<tr>
						<td colspan="3" align="center"><asp:textbox id="txtRemark" runat="server" Width="400" Height="40px" TextMode="MultiLine"></asp:textbox></td>
					</tr>
				</table>
				<table width="100%" cellspacing="0" cellpadding="0">
					<tr>
						<td align="center" colSpan="4">
						
						<div id='pleaseWaitButtonDiv2_PleaseWaitButton1'></div>
							<div id='pleaseWaitButtonDiv_PleaseWaitButton1'><asp:button id="btnSave" Runat="server" Text="确认以上选择，提交食单并使用支付宝支付"></asp:button></div>
						</td>
					</tr>
				</table>
			</div>
		</form>
	</body>
</HTML>
