<%@ Page Language="C#" AutoEventWireup="true" debug="true" Inherits="WinLibClass.Form.Admin.SystemConfig.UI_Update"  CodePage="65001" CurrentFile="updateconfig5.aspx" %>


<script type="text/javascript"> 

function SaveConfig_5()
{
	if(!confirm("是否保存短信发送配置?")) return false;
	
	var queryString = $('#form_add').serialize();
	var _url = "../index.aspx?s=/Admin/SystemConfig_Update";
	jQuery.ajax({type:"POST",url:_url,
		data:queryString
		,success:function(msg){
			if(msg==1){ Alert("短信平台配置已保存.",1);Common.EditDialogClose("SystemConfig_List_3");
			}
			else AlertErr("短信平台配置保存失败(异常代码:"+ msg +")",1);
		},
		error:function(msg)
		{
			AlertErr("系统异常:\r\n"+ msg.responseText +"",1);
		}});
	
	return false;
}

//function Config_5_SelectShowItem(id)
{

}
jQuery(document).ready(function(){
	jQuery("a[id^='sms_a_']").click(function(){
		var t ="SMS_"+ this.id.substr("sms_a_".length);
		jQuery("table[id^='SMS_']").hide();
		jQuery("#"+t).show();
	});
	});
</script> 

<div class="W620">

<form id="form_add" >	
<input type="hidden" id="ConfigType" name="ConfigType" value="5" />
<div class="TableUpdateDiv W620"  >
<div class="LH30 "  style="width:98%;">
<table class="TableUpdate">
<tr><td>
<a id="sms_a_03">大豫短信通短信平台</a>
<a id="sms_a_01">短信精灵短信平台</a>
<a id="sms_a_02">亿美WebService短信接口</a>
</td></tr>
<tr><td>

		<B>短信平台选择:</B><select id="SMS_ServerType" name="SMS_ServerType"  class="input" style="width:150px;height:24px" >
		<option value="0" <%=(SMS_ServerType==0?"selected":"")%> >===请选择===</option>
		<option value="1" <%=(SMS_ServerType==1?"selected":"")%> >短信精灵短信平台</option>
		<option value="2" <%=(SMS_ServerType==2?"selected":"")%> >亿美WebService短信平台</option>
		<option value="3" <%=(SMS_ServerType==3?"selected":"")%> style="font-weight:normal;">大豫短信通短信平台</option>

		</select>

<tr><td>
注:上述功能,请根据实际的短信接口来选择和配置,未使用的短信接口不必填写相关内容.
</td></tr></table>
<div class="Clear"></div>
</div>
</div>

<div class="TableUpdateDiv W620"  >
<div style="width:98%;">	

	<table class="TableUpdate <%=(SMS_ServerType==1?"":"Hide")%> " style="text-align:left;" ID="SMS_01" 
	
	<tr>
	<td >
	<b>短信精灵短信平台 - 短信发送配置:</b>
	<%
/*
http://agent.282930.cn/Interface/?sms_num=接受短信的手机号&UserName=短信精灵用户名&smsContent=短信内容&PassWord=短信精灵密码&Safe=短信精灵安全码	
*/
	%>
	</td>
	</tr>
	<tr>
	<td >
		短信发送方式:<select id="SMS_0_FormMethod" name="SMS_0_FormMethod" class="input" style="width:150px;height:24px" >
		<option value="GET" <%=(SMS_0_FormMethod=="GET"?"selected":"")%> >GET</option>
		</select>	
		
	编码类型:　<select id="SMS_0_Charset" name="SMS_0_Charset"  class="input" style="width:150px;height:24px" >
		<option value="GB2312" <%=(SMS_0_Charset=="GB2312"?"selected":"")%> >GB2312</option>
		<!--<option value="UTF-8" <%=(SMS_0_Charset=="UTF-8"?"selected":"")%> >UTF-8</option>-->
		</select>			
	</td>
	</tr>
	
	<tr>
	<td>		
		
		短信发送接口:<input id="SMS_0_Url" name="SMS_0_Url" type="text" class="input" style="width:400px;"  value="<%=SMS_0_Url%>" /><br />
		&nbsp;例: "http://agent.282930.cn/Interface/" 或 "http://agent.282930.cn/Interface/default.aspx"
		
	
	</td>
	</tr>	
	
	<tr>
	<td >
		用　户　名:<input id="SMS_0_UserName" name="SMS_0_UserName" type="text" class="input" style="width:150px;"  value="<%=SMS_0_UserName%>" /> 
		用户名变量名:<input id="SMS_0_UserName_Name" name="SMS_0_UserName_Name" type="text" class="input" style="width:150px;"  value="<%=SMS_0_UserName_Name%>" />
	</td>
	</tr>
	
	<tr>
	<td>
		密　　　码:<input id="SMS_0_PassWord" name="SMS_0_PassWord" type="text" class="input" style="width:150px;"  value="<%=SMS_0_PassWord%>" /> 
		用户名变量名:<input id="SMS_0_PassWord_Name" name="SMS_0_PassWord_Name" type="text" class="input" style="width:150px;"  value="<%=SMS_0_PassWord_Name%>" />
	</td>
	</tr>
	
	<tr>
	<td>
	接口安全码:<input id="SMS_0_Safe" name="SMS_0_Safe" type="text" class="input" style="width:150px;"  value="<%=SMS_0_Safe%>" />(如果该值为空,将导致短信发送失败)
	</td>
	</tr>
	
	<tr>
	<td>

	接口安全码变量名:<input id="SMS_0_Safe_Name" name="SMS_0_Safe_Name" type="text" class="input" style="width:150px;"  value="<%=SMS_0_Safe_Name%>" />
	</td>
	</tr>
	
	
	
	<tr>
	<td>
	短信号码变量名:<input id="SMS_0_sms_NUM_Name" name="SMS_0_sms_NUM_Name" type="text" class="input" style="width:150px;"  value="<%=SMS_0_sms_NUM_Name%>" />
	
	短信内容变量名:<input id="SMS_0_smsContent_Name" name="SMS_0_smsContent_Name" type="text" class="input" style="width:150px;"  value="<%=SMS_0_smsContent_Name%>" />
	</td>
	</tr>
	</table>

	<table class="TableUpdate <%=(SMS_ServerType==2?"":"Hide")%> " style="text-align:left;" ID="SMS_02" >
	
	<tr>
	<td >
	<b>亿美WebService短信接口 - 短信发送配置:</b>
	</td>
	</tr>
	<tr>
	<td >
		序列号:<input id="softwareSerialNo" name="softwareSerialNo" type="text" class="input" style="width:200px;"  value="<%=softwareSerialNo%>" />
	</td>
	</tr>
	
	<tr>
	<td>
		密　码:<input id="serialPwd" name="serialPwd" type="text" class="input" style="width:200px;"  value="<%=serialPwd%>" />
	</td>
	</tr>
	
	<tr>
	<td>
	附加码:<input id="addSerial" name="addSerial" type="text" class="input" style="width:200px;"  value="<%=addSerial%>" />(可置空)
	</td>
	</tr>
	
	<tr>
	<td>
	
	优先级:<select id="smsPriority" name="smsPriority"  class="input" style="width:150px;height:24px" >
		<option value="1" <%=(smsPriority=="1"?"selected":"")%> >1</option>
		<option value="2" <%=(smsPriority=="2"?"selected":"")%> >2</option>
		<option value="3" <%=(smsPriority=="3"?"selected":"")%> >3</option>
		<option value="4" <%=(smsPriority=="4"?"selected":"")%> >4</option>
		<option value="5" <%=(smsPriority=="5"?"selected":"")%> >5</option>
		</select>			
			
	</td>	
	</tr>	
	
	<tr>
	<td >	
	编　码:<select id="srcCharset" name="srcCharset"  class="input" style="width:150px;height:24px" >
		<option value="GBK" <%=(srcCharset=="GBK"?"selected":"")%> >GBK</option>

		</select>			
	
	&nbsp;
	</td>
	</tr>		

	
	</table>


<!---------------------------------------------------->

	<table class="TableUpdate  <%=(SMS_ServerType==3?"":"Hide")%> " style="text-align:left;" ID="SMS_03" >
	
	<tr>
	<td >
	<b>大豫短信通短信平台 - 短信发送配置:</b>
	<%
/*
http://agent.282930.cn/Interface/?sms_num=接受短信的手机号&UserName=短信精灵用户名&smsContent=短信内容&PassWord=短信精灵密码&Safe=短信精灵安全码	
*/
	%>
	</td>
	</tr>
	<tr>
	<td >
		短信发送方式:<select id="SMS_2_FormMethod" name="SMS_2_FormMethod" class="input" style="width:150px;height:24px" >
		<option value="GET" <%=(SMS_2_FormMethod=="GET"?"selected":"")%> >GET</option>
		</select>	
		
	编码类型:　<select id="SMS_2_Charset" name="SMS_2_Charset"  class="input" style="width:150px;height:24px" >
		<option value="GB2312" <%=(SMS_2_Charset=="GB2312"?"selected":"")%> >GB2312</option>
		<!--<option value="UTF-8" <%=(SMS_2_Charset=="UTF-8"?"selected":"")%> >UTF-8</option>-->
		</select>			
	</td>
	</tr>
	
	<tr>
	<td>		
		
		短信发送接口:<input id="SMS_2_Url" name="SMS_2_Url" type="text" class="input" style="width:400px;"  value="<%=SMS_2_Url%>" /><br />
		&nbsp;例: "http://sms.dayusheji.com/sms.php"
		
	
	</td>
	</tr>	
	
	<tr>
	<td >
		用　户　名:<input id="SMS_2_UserName" name="SMS_2_UserName" type="text" class="input" style="width:150px;"  value="<%=SMS_2_UserName%>" /> 
		<input id="SMS_2_UserName_Name" name="SMS_2_UserName_Name" type="hidden" class="input" style="width:150px;"  value="<%=SMS_2_UserName_Name%>" />
	</td>
	</tr>
	
	<tr>
	<td>
		密　　　码:<input id="SMS_2_PassWord" name="SMS_2_PassWord" type="text" class="input" style="width:150px;"  value="<%=SMS_2_PassWord%>" /> 
		<input id="SMS_2_PassWord_Name" name="SMS_2_PassWord_Name" type="hidden" class="input" style="width:150px;"  value="<%=SMS_2_PassWord_Name%>" />
		
		<input id="SMS_2_Safe" name="SMS_2_Safe" type="hidden" class="hidden" style="width:150px;"  value="<%=SMS_2_Safe%>" />
		<input id="SMS_2_Safe_Name" name="SMS_2_Safe_Name" type="hidden" class="input" style="width:150px;"  value="<%=SMS_2_Safe_Name%>" />
		
<input id="SMS_2_sms_NUM_Name" name="SMS_2_sms_NUM_Name" type="hidden" class="input" style="width:150px;"  value="<%=SMS_2_sms_NUM_Name%>" />
<input id="SMS_2_smsContent_Name" name="SMS_2_smsContent_Name" type="hidden" class="input" style="width:150px;"  value="<%=SMS_2_smsContent_Name%>" />
		
	</td>
	</tr>
	
	<tr>
	<td>
	成功返回值:<input id="SMS_2_ReturnValue" name="SMS_2_ReturnValue" type="text" class="input" style="width:150px;"  value="<%=SMS_2_ReturnValue%>" />
	</td>
	</tr>
	</table>
		
	<table class="TableUpdate Bgdddefa " style="margin:3px"> 	
	<tr>
	<td style="color:red">
	注1:本参数表设置内容请参照短信接口平台提供的相关技术文档.
	</td>
	</tr>
	<tr>
	<td >
	注2:如果上述未包含您选择的短信平台，则配置资料存于本站主 Web.Config 的配置文件中。
	</td>
	</tr>	
	</table>
	
</div>
</div>
</form>	

	
</div>
