📄 clintadd.jsp
字号:
<%@ page contentType="text/html; charset=GBK" language="java"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-bean"
prefix="bean"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-html"
prefix="html"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-logic"
prefix="logic"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<meta http-equiv="pragma" content="no-cache" />
<meta http-equiv="Cache-Control" content="no-cache, must-revalidate" />
<meta http-equiv="expires" content="Wed, 26 Feb 1970 08:21:57 GMT" />
<link href="${pageContext.request.contextPath}/image/main.css"
rel="stylesheet" type="text/css">
<title>样式</title>
</head>
<body onLoad="TextGet();">
<html:form action="/clintmanage" method="post" styleId="form1">
<table width="100%" border="0" align="center" cellpadding="0"
cellspacing="0">
<tr>
<td align="center" valign="middle">
<table width="80%" border="0" cellpadding="0" cellspacing="0">
<tr>
<td height="20" align="center" valign="middle">
<strong>用户详细信息 </strong></td>
</tr>
</table>
<table width="49%" height="350" border="1" cellpadding="0" cellspacing="0"
bordercolor="#D71920">
<tr>
<td align="center" valign="middle"><table width="102%" height="302" border="1"
cellpadding="0" cellspacing="0" id="ttc">
<tr>
<td height="20" align="right" valign="middle" nowrap
id="ttc"> 手机号码: </td>
<td width="58%" align="left" valign="middle" nowrap id="ttc">
<html:text property="phone" size="40" style="width:150px;"/> </td>
</tr>
<tr>
<td height="20" align="right" valign="middle" nowrap
id="ttc"> 用户姓名: </td>
<td align="left" valign="middle" nowrap id="ttc">
<html:text property="username" size="40" style="width:150px;"/> </td>
</tr>
<tr>
<td height="20" align="right" valign="middle" nowrap
id="ttc"> 证件号码: </td>
<td align="left" valign="middle" nowrap id="ttc">
<html:text property="paperid" size="40" style="width:150px;" /> </td>
</tr>
<tr>
<td height="20" align="right" valign="middle" nowrap
id="ttc"> 服务类型: </td>
<td align="left" valign="middle" nowrap id="ttc">
<html:select property="servetype" style="width:150px">
<c:forEach var="MeetroomBen"
items="${requestScope.datadictionarylist}">
<html:option value="${MeetroomBen.nid}">${MeetroomBen.sname}</html:option>
</c:forEach>
</html:select> </td>
</tr>
<tr>
<td height="20" align="right" valign="middle" nowrap
id="ttc"> 请选择省: </td>
<td align="left" valign="middle" nowrap id="ttc">
<select name="contrry" onChange="TextGet();" style="width:150px;">
<c:forEach var="MeetroomBen"
items="${requestScope.list}">
<option value="${MeetroomBen.aid}"> ${MeetroomBen.aname} </option>
</c:forEach>
</select> </td>
</tr>
<tr>
<td width="42%" height="20" align="right" id="ttc"> 请选择市: </td>
<td align="left" valign="middle" id="ttc">
<select name="city" style="width:150px;">
</select> </td>
</tr>
<tr>
<td height="20" align="right" valign="middle" nowrap
id="ttc"> 营 业 厅: </td>
<td align="left" valign="middle" nowrap id="ttc">
<html:text property="area" size="40" style="width:150px;"/> </td>
</tr>
<tr>
<td width="42%" height="20" align="right" id="ttc"> 邮寄地址: </td>
<td align="left" valign="middle" id="ttc">
<html:text property="postaddress" size="40" style="width:150px;"/> </td>
</tr>
<tr>
<td width="42%" height="20" align="right" id="ttc"> 联系电话: </td>
<td align="left" valign="middle" id="ttc">
<html:text property="tel" size="40" style="width:150px;"/> </td>
</tr>
<tr>
<td width="42%" height="20" align="right" id="ttc"> 邮政编码: </td>
<td align="left" valign="middle" id="ttc">
<html:text property="postalcode" size="40" style="width:150px;"/> </td>
</tr>
<tr>
<td height="20" align="right" valign="middle" nowrap
id="ttc"> 所属经理: </td>
<td align="left" valign="middle" nowrap id="ttc">
<html:select property="clientmanagerid"
style="width:150px">
<c:forEach var="MeetroomBen"
items="${requestScope.systembeanlist}">
<html:option value="${MeetroomBen.nid}">${MeetroomBen.username}</html:option>
</c:forEach>
</html:select>
</td>
</tr>
<tr>
<td height="20" align="right" valign="middle" nowrap
id="ttc"> 是否集团: </td>
<td align="left" valign="middle" nowrap id="ttc">
<html:checkbox property="isgroupclient" value="1" /> </td>
</tr>
<tr>
<td height="20" align="right" valign="middle" nowrap
id="ttc"> 是否会员: </td>
<td align="left" valign="middle" nowrap id="ttc">
<html:checkbox property="usergrade" value="1" /> </td>
</tr>
<tr>
<td height="20" align="right" valign="middle" nowrap
id="ttc"> 是否冻结: </td>
<td align="left" valign="middle" nowrap id="ttc">
<html:checkbox property="islock" value="1" /> </td>
</tr>
<tr>
<td height="20" align="right" valign="middle" nowrap
id="ttc"><input type="hidden" name="tag" value="add1">
<input type="button" name="Submit1" value="添加" onClick="acheckForm();"> </td>
</tr>
</table></td>
</tr>
</table>
</td>
</tr>
</table>
</html:form>
</body>
<script language="javascript">
var xmlHttp;
function createHttpRequest(){
if (window.ActiveXObject){
xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
}else if (window.XMLHttpRequest){
xmlHttp = new XMLHttpRequest();
}
}
function TextGet(){
createHttpRequest();
var contrry = document.getElementById("contrry").value;
var url = "${pageContext.request.contextPath}/address1.do?praid="+contrry+"&date="+new Date()+"&tag=getsmall";
xmlHttp.open("GET",url,true);
xmlHttp.onreadystatechange = CallBackGet;
xmlHttp.send();
}
function CallBackGet(){
var result = xmlHttp.responseXML;
if (xmlHttp.readyState == 4){
var userList = result.getElementsByTagName("user");
var userSelect = document.getElementById("city");
userSelect.length = 0;
if (userList.length>0){
for (var i = 0;i<userList.length;i++){
var userBean = userList[i];
var username = userBean.childNodes[0].firstChild.nodeValue;
//加入到下拉框
var option = new Option(username,username);
userSelect.add(option);
}
}
}
}
function acheckForm(){
var phone=document.getElementById("phone").value
var username=document.getElementById("username").value
var paperid=document.getElementById("paperid").value
var num_one = document.form1.phone.value.replace(/\s/g,"");
var numone = num_one.replace(/[0-9]/g,"");
var num_one1 = document.form1.paperid.value.replace(/\s/g,"");
var numone1 = num_one1.replace(/[0-9]/g,"");
if(numone.length>0){
alert("请输入数字");
document.form1.numone.focus();
return false;
}
else if(phone==null||phone=="")
{
alert("电话号码不能为空");
}
else if(phone.length>11)
{
alert("电话号码长度过长");
}else if(username==null||username=="")
{
alert(" 真实姓名不能为空");
}
else if(numone1.length>0){
alert("请输入数字");
document.form1.numone.focus();
return false;
}
else if(paperid==null||paperid=="")
{
alert("身份证号码不能为空");
}
else if(paperid.length!=18)
{
alert("身份证长度必须为18位");
}
else
{
form1.submit();
}
}
</script>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -