<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ProductAdd.aspx.cs" Inherits="web.Supply.ProductAdd" %>

<%@ Register Assembly="FredCK.FCKeditorV2" Namespace="FredCK.FCKeditorV2" TagPrefix="FCKeditorV2" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
	<HEAD>
		<title>ProductAdd</title><meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />

		    <link href="css/css.css" rel="stylesheet" type="text/css" />
    <link href="css/css_list.css" rel="stylesheet" type="text/css" />
    <script language="javascript" type="text/javascript" src="My97DatePicker/WdatePicker.js"></script>
   <style type="text/css">
    .head {background-image: url(img/labelbg.gif);background-repeat: repeat-x;}
    </style>





			<script language="JavaScript">
    function addFileControl()
    {
    	var str = '<br><INPUT type="file" NAME="File">'
    	document.getElementById('FileCollection').insertAdjacentHTML("beforeEnd",str)
    }
			</script>
			
			<script language="javascript"> 
              //jb函数会根据不同的浏览器初始化个xmlhttp对象 
              function jb() 
              { 
                 var A=null; 
               try 
               { 
                   A=new ActiveXObject("Msxml2.XMLHTTP"); 
                } 
                 catch(e) 
                 { 
                  try 
                   { 
                      A=new ActiveXObject("Microsoft.XMLHTTP"); 
                   } 
                       catch(oc) 
                      { 
                     A=null 
                   } 
              } 
           if ( !A && typeof XMLHttpRequest != "undefined" ) 
            { 
               A=new XMLHttpRequest() 
             } 
           return A 
              } 
              
              //下面Go函数是父列表框改变的时候调用，参数是选择的条目 
              function Go(obj) 
              { 
                 //得到选择框的下拉列表的value 
                var svalue = obj.value; 
                 //定义要处理数据的页面 
                 var weburl = "productadd.aspx?product_category_id="+svalue; 
                 //初始化个xmlhttp对象 
                 var xmlhttp = jb(); 
                 //提交数据，第一个参数最好为get，第三个参数最好为true 
                 xmlhttp.open("get",weburl,true); 
                 //如果已经成功的返回了数据 
                 xmlhttp.onreadystatechange=function() 
                 { 
                   if(xmlhttp.readyState==4)//4代表成功返回数据 
                    { 
						var result = xmlhttp.responseText.split("<")[0].toString();//得到服务器返回的数据 
						
                    } 
                 } 
                 //发送数据，请注意顺序和参数，参数一定为null或者"" 
                 xmlhttp.send(null); 
              } 
		</script>


	</HEAD>
	<body  leftmargin="0" rightmargin="0" topmargin="0">
	
		<form id="Form1" method="post" runat="server" >
		
		
  <table width="100%" align="center" cellpadding="0" cellspacing="0" background="img/labelbg.gif" bgcolor="#EDF6FF">
    <tr> 
              <td width="1%" height="36" class="tl"></td>
              <td class="tm"><span class="tt">店铺管理 &gt;&gt; &nbsp;&nbsp; 
                <asp:label id="lblTitleInfo" Runat="server">优惠信息添加</asp:label>&nbsp; </span><span class="tt"></span></td>
            </tr>
          </table>
  <table width="100%" height="550" border="0" cellpadding="0" cellspacing="0">
    <tr>
    <td valign="top" style="width: 100%">

        <div class="mframe"> 
          <table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
      <td class="ml"></td>
    <td  class="mm" align="left" valign="top">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
                    <td bgcolor="#FFFFFF" valign="top"><table width="98%" align="center" cellpadding="0"  cellspacing="0" >
                        <tr>
		<td width="0%" class="ml1"></td>
		                  <td class="mm1" style="width: 97%"> 
             
                          
                              <table width="100%" border="0" cellpadding="0" cellspacing="0">
                              <tr> 
                                <td width="385" height="35" > <div align="right">优惠信息名称：</div></td>
                                <td width="764">&nbsp; <asp:textbox id="txtName" CssClass="input" runat="server" Width="239px"></asp:textbox> 
                                </td>
                                <td width="420" rowspan="12" valign="top"> <br /> 
                                  <asp:listbox id="lbxCategories" runat="server" SelectionMode="Multiple" Rows="14" Height="157px" ></asp:listbox> （按住ctrl或者shift键可多选）</td>
                              </tr>
                              <tr> 
                                <td height="35" > <div align="right">细分类：</div></td>
                                <td width="764" ><br /> &nbsp; <asp:DropDownList ID="plei" runat="server"> 
                                  </asp:DropDownList> &nbsp; 
                                  <asp:HiddenField ID="sjid" runat="server" /> 
                                   </td>
                              </tr>
                              <tr> 
                                <td height="35" > <div align="right">截止日期：</div></td>
                                <td>&nbsp; <asp:textbox id="txtShortDesc" CssClass="input" runat="server" Width="239px" onClick="WdatePicker()"></asp:textbox></td>
                              </tr>
                              <tr> 
                                <td height="35" > <div align="right">送积分点数： </div></td>
                                <td>&nbsp; <asp:textbox id="txtScore" CssClass="input" runat="server" Width="239px" Enabled="False">0</asp:textbox>
                                  点 <span style="color: #ff0033">不赠送积分设置为0<FONT color="red">&nbsp;</FONT></span></td>
                              </tr>
                              <tr style="display:none;"> 
                                <td height="38" > 
                                  <div align="right">赠送代餐券：</div></td>
                                <td>&nbsp; <asp:TextBox ID="djq" runat="server" Width="237px" Enabled="False">0</asp:TextBox>
                                  元 <span style="color: #ff0033">不赠代餐券送设置为0</span></td>
                              </tr>
                         
                        
                              <tr> 
                                <td height="35" > <div align="right">添加水印：</div></td>
                                <td>&nbsp; <asp:radiobutton id="rbNoWatermark" runat="server" GroupName="watermark" Text="不添加水印" Checked="True"></asp:radiobutton> 
                                  <asp:radiobutton id="rbPicWatermark" runat="server" Text="添加图片水印" GroupName="watermark"></asp:radiobutton> 
                                  <asp:radiobutton id="rbFontWatermark" runat="server" Text="添加文字水印" GroupName="watermark"></asp:radiobutton> 
                                </td>
                              </tr>
                              <tr> 
                                <td height="35"> <div align="right"> 信息图片：</div></td>
                                <td>&nbsp; <INPUT id="File2" type="file" class="input" name="file2" runat="server" style="width: 328px">（可不选择添加）
                                    &nbsp; &nbsp;<br /> &nbsp; <asp:Label ID="xgsm" runat="server"></asp:Label></td>
                              </tr>
                              <tr style="display:none;"> 
                                <td height="35" > <div align="right"> 缩略图：</div></td>
                                <td>&nbsp;<SPAN id="ThumbnailPic" style="DISPLAY: none"></SPAN> 
                                  <SPAN id="SPAN1" style="DISPLAY: none"> 
                                  <INPUT id="File1" type="file" name="file2" runat="server" style="width: 326px">
                                  </SPAN> <asp:checkbox id="cbxFromBigPic" runat="server" Checked="True" Visible="false"></asp:checkbox>
                                  自动生成宽度为 
                                  <asp:textbox id="txtPicWidth" runat="server" Width="30px" Enabled="false">70</asp:textbox>
                                  象素的缩略图 <br /> <span style="color: #ff3333">(说明:只指定宽度,程序会根据宽度进行等比例缩小)</span></td>
                              </tr>
                     
                              <tr> 
                                <td height="35" > <div align="right">优惠信息介绍：</div></td>
                                <td colspan="2"><FCKeditorV2:FCKeditor id="ftbContent" runat ="server" ToolbarSet="Default" Height="300px" Width="98%"></FCKeditorV2:FCKeditor> 
                                </td>
                              </tr>
                                        <tr> 
                                <td style="height: 93px" > <div align="right">发送优惠信息的短信内容（根据优惠信息精简）：</div></td>
                                <td colspan="2" style="height: 93px">
                                    &nbsp;<asp:TextBox ID="dxnr" runat="server" Height="58px" TextMode="MultiLine"
                                        Width="459px"></asp:TextBox>
                                   
                                </td>
                              </tr>
                            </table>
                              
                          
                            <div align="center">
                           
                
                 
                         
                              
                            </div>
                            <center> <asp:button id="btnSave" runat="server" CssClass="btn" Text="保存内容" ></asp:button> 
                                  &nbsp;&nbsp; <asp:button id="btnCancel" runat="server" CssClass="btn" Text="取消" CausesValidation="False"></asp:button></center>
                            <br>
                            
			<script language="javascript">
				
				function ShowCustomFieldPanel()
				{
					if(document.Form1.cbxShowCustomFieldPanel.checked)
					{
						eval("customFieldPage" + ".src=\"ProductCustomField.aspx\";");
					}
					else
					{
						eval("customFieldPage" + ".src=\"\";");
					}
				}
				
	
				function CardManage()
				{
					if(document.Form1.cbxIsCard.checked)
					{
						eval("card" + ".style.display=\"\";");
					}
					else
					{
						eval("card" + ".style.display=\"none\";");
					}
				}
				function ManageCustomFields(pid)
				{
					temp=window.open('ProductCustomField.aspx?productid='+pid,'customfield','width=680,height=600,scrollbars=yes,top=0,left=0');
					temp.focus();
				}




			</script>
		</td>
		<td class="mr1"></td>
	</tr>
</table>
                    </td>
  </tr>
</table>


<table width="100%" align="center" cellspacing="0" cellpadding="0">
	<tr>
		<td class="bl"></td>
		<td class="bm">&nbsp;</td>
		<td class="br"></td>
	</tr>
</table>
</td>
    <td  class="mr"></td>
  </tr>
</table>
<table width="100%" align="center" cellspacing="0" cellpadding="0">
	<tr>
		<td class="bl"></td>
		<td class="bm">&nbsp;</td>
		<td class="br"></td>
	</tr>
</table>

</div>
    </td>
  </tr>
</table>
		</form>
	</body>
</HTML>
