<%@ page language="C#" autoeventwireup="true" inherits="admin2_sp4a, GJ_YM" enableviewstatemac="false" enableEventValidation="false" %>
<head><title>无标题页</title></head><link href="css/yb.css" rel="stylesheet" type="text/css">
<script language="javascript" src="js/sbyk.js" ></script><script language="javascript" src="js/db.js" ></script>
<script language="javascript" src="js/xzrl.js" ></script>
<script >var en=new PopupCalendar("en");en.Init();var zw=new PopupCalendar("zw");
zw.weekDaySting=new Array("日","一","二","三","四","五","六");
zw.monthSting=new Array("一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月");
zw.oBtnTodayTitle="今天";zw.oBtnCancelTitle="取消";zw.Init();
var dqs="1";function dq1(){dqs="1";}function dq2(){dqs="2";}
function sj(){var ddd=document.getElementById("h").value+":"+document.getElementById("min").value;
if(dqs=="1"){document.getElementById("TextBox2").value=ddd;} else{document.getElementById("TextBox4").value=ddd;}}
function yc(){if(dqs=="1"){document.getElementById("TextBox2").value="";} else{document.getElementById("TextBox4").value="";}document.getElementById("xzsj").style.display="none";}function qd(){document.getElementById("xzsj").style.display="none";}function sjxz(zg){var iddd=document.getElementById("xzsj");iddd.style.pixelLeft=getPos(zg,"Left");iddd.style.pixelTop=getPos(zg,"Top")+zg.offsetHeight;iddd.style.display=(iddd.style.display=="none")?"":"none";}
function getPos(el,ePro){var ePos=0;while(el!=null){ePos+=el["offset"+ePro];el=el.offsetParent;}return ePos;}
function bmmm(){
var jj = document.getElementById('DropDownList1');
if(jj.value=="1"){
document.getElementById('PlaceHolder1').style.display="";
document.getElementById('PlaceHolder2').style.display="none";
document.getElementById('btwz').value=document.getElementById('TextBox5').value+""+document.getElementById('TextBox6').value+"元，送一"+document.getElementById('hrr').value;
}
else
{document.getElementById('PlaceHolder1').style.display="none";
document.getElementById('PlaceHolder2').style.display="";
document.getElementById('HiddenField1').value="";
document.getElementById('hrr').value="";
document.getElementById('btwz').value=document.getElementById('TextBox5').value+""+document.getElementById('TextBox6').value+"元，返"+document.getElementById('TextBox7').value+"元购物券";
}}
</script>
<body>
<form id="form1" runat="server">
<input type="hidden" name="hid_xz" id="hid_xz" /><input type="hidden" name="hid_cz" id="hid_cz" />
<table width="100%" border="0" cellpadding="4" cellspacing="1" bgcolor="#e2e2e2"  style="margin-bottom:5px;">
<tr style="background-color:#f2f2f2;"><td >
<div class="bt"><asp:label ID="btxs" runat="server" text="添加返赠送促销 "></asp:label>
<span style="margin-left:30px;font-weight:normal;"><a href="sp4.aspx">返赠送促销列表</a></span>
</div>
</td></tr></table>

<table width="100%" border="0" cellpadding="4" cellspacing="1" bgcolor="#e2e2e2"  style="margin-bottom:5px;">
<tr style="background-color:#ffffff;"><td align="right" style="padding:8px;">类别：</td>
<td ><asp:DropDownList ID="DropDownList1" runat="server" Width="100px" onchange="bmmm();"></asp:DropDownList> <span style="color:Red;">*</span></td></tr>

<tr style="background-color:#ffffff;"><td width="100px" align="right" style="padding:8px;">开始日期：</td>
<td ><asp:TextBox ID="TextBox1" runat="server" Width="150px" onClick="getDateString(this,zw);"></asp:TextBox> 
&nbsp;&nbsp;&nbsp;&nbsp;开始时间：<asp:TextBox ID="TextBox2" runat="server" onfocus="this.blur();" onClick="dq1();sjxz(this);" width="100px"></asp:TextBox>
 </td></tr>

<tr style="background-color:#ffffff;"><td align="right" style="padding:8px;">结束时间：</td>
<td ><asp:TextBox ID="TextBox3" runat="server" Width="150px" onClick="getDateString(this,zw);"></asp:TextBox> 
&nbsp;&nbsp;&nbsp;&nbsp;结束时间：<asp:TextBox ID="TextBox4" runat="server" onfocus="this.blur();" onClick="dq2();sjxz(this);" width="100px"></asp:TextBox> 
</td></tr>

<tr style="background-color:#ffffff;"><td align="right" style="padding:8px;">满足条件文字：</td>
<td ><asp:TextBox ID="TextBox5" runat="server" Width="150px" Text="实付满" OnkeyUp="bmmm();"></asp:TextBox> 如：单笔订单实付金额满/实付满</td></tr>

<tr style="background-color:#ffffff;"><td align="right" style="padding:8px;">满足条件数字：</td>
<td ><asp:TextBox ID="TextBox6" runat="server" Width="50px" OnkeyUp="bmmm();"></asp:TextBox> 如：198，数字 元（￥）</td></tr>

<tr style="background-color:#ffffff;" id="PlaceHolder1"><td align="right" style="padding:8px;">所送商品：</td>
<td ><asp:TextBox ID="hrr" runat="server" Width="236px" onfocus="this.blur();" TextMode="MultiLine" Height="65px" ></asp:TextBox> 
<a href="javascript:showhrsp4();">点击选择商品</a>

<asp:HiddenField ID="HiddenField1" runat="server" /> </td></tr>

<tr style="background-color:#ffffff;display:none;" id="PlaceHolder2"><td align="right" style="padding:8px;">返购物券面值：</td>
<td ><asp:TextBox ID="TextBox7" runat="server" Width="50px" OnkeyUp="bmmm();"></asp:TextBox> 元（￥）</td></tr>

<tr style="background-color:#ffffff;"><td align="right" style="padding:8px;">标题：</td>
<td > <asp:TextBox ID="btwz" runat="server" Width="336px" ></asp:TextBox></td></tr>

</table>

<table width="100%" border="0" cellpadding="4" cellspacing="1" bgcolor="#e2e2e2"  style="margin-top:5px;">
<tr style="background-color:#f2f2f2;"><td >

<input id="Button1" type="button" value="添加" onclick="xz3('4');sendRequest('sp4c.aspx','sp4.aspx');" style="width:80px;" onfocus="this.blur();" />
<input id="Button2" type="button" value="修改" onclick="xz3('5');sendRequest('sp4c.aspx','sp4.aspx');" style="width:80px;" onfocus="this.blur();" />

</td></tr></table>    
<asp:Label ID="Label1" runat="server" Text=""></asp:Label>
<%=rfh()%>
</form><div id='xzsj' style='display:none;position:absolute;width:130px;border:1px solid #000000;padding:5px;background-color:#ffffff; font-size:12px;'>
选择时间：<br /><select name="h" id="h" onchange="sj();"><script>for(var i=0;i<=23;i++){document.write("<option value='"+i+"'>"+i+"</option>");}</script></select>时<select name="min" id="Select1" onchange="sj();">
<script>for(var i=0;i<=59;i++){document.write("<option value='"+i+"'>"+i+"</option>");}</script></select>分<br /><a href="javascript:" onclick="qd();" style='width:40%;border:1px solid #BCD0DE;background-color:#eeeeee;cursor:hand;text-align:center;margin-top:5px;'>确定</a><a href="javascript:" onclick="yc();" style='width:40%;border:1px solid #BCD0DE;background-color:#eeeeee;cursor:hand;text-align:center; margin-top:5px;'>取消</a></div>
</body>