⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 orderhotel.jsp

📁 有关医院方向的开发
💻 JSP
字号:
<%@ page language="java" pageEncoding="GBK"%>
<%@ 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"%>
<%@ include file="../../common/common.jsp"%>
<%@ page import="com.dc.common.*"%>
<%@ page import="com.util.sendmessage.*"%>
<%
String RenCode = (String) session.getAttribute(SysConstant.RETCODE);
String SVCNUM = (String) session.getAttribute(SysConstant.PHONE);
String sendmessage = (String) session.getAttribute(SysConstant.SENDMESSAGE);
%>
<html:html>
<head>
	<title>客房预订信息</title>
	<link href="<%=request.getContextPath()%>/css/style.css"
		rel="stylesheet" type="text/css">
	<script language="javaScript" src="<%=request.getContextPath()%>/scripts/check.js"></script>
	<script language="javaScript" src="<%=request.getContextPath()%>/scripts/calendar/WdatePicker.js"></script>
    <script language="javaScript" src="<%=request.getContextPath()%>/scripts/others.js"></script>
    <script language="javaScript" src="<%=request.getContextPath()%>/scripts/dialog.js"></script>
    <script language="javaScript" src="<%=request.getContextPath()%>/scripts/print.js"></script>
    <script language="javaScript" src="<%=request.getContextPath()%>/scripts/ajax.js"></script>
    <script language="javaScript" src="<%=request.getContextPath()%>/scripts/pagination.js"></script>
    <script language="javaScript" src="<%=request.getContextPath()%>/scripts/calendar.js"></script>
	<meta http-equiv="Content-Type" content="text/html; charset=GBK">
</head>
<script language="javascript">
window.name="_window_hotel";
</script>
<%
if (RenCode !=null){
	if (SysConstant.SUCRETCODE.equals(RenCode)) {
	%>
	<script language="javascript">
		    alert("客房预订成功!");
		    if(confirm("是否发送短信?")){
		       <%     
		      	 int stat= SendMessage.sendMessage(SVCNUM,sendmessage,0);
		      	 if (stat == 1){
		       %>
		        alert("短信发送成功!");
		        <%
		        }else{%>
		         alert("短信发送失败!");
		        <%}%>
		   }
		    window.close();
	        </script>
	<%
	
	}else{
	%>
	<script language="javascript">
		    alert("客房预订失败,请联系管理员!");
	        </script>
	 <%
	}
	session.removeAttribute(SysConstant.RETCODE);
	session.removeAttribute(SysConstant.PHONE);
	session.removeAttribute(SysConstant.SENDMESSAGE);
}

%>

<body class="navtree">
	<html:form action="/HoteOrderDetailAction"  method="post" target="_window_hotel">
	<html:hidden property="HotelForm"  property="hotelInfo.hotelsId"  />
	<html:hidden property="HotelForm"  property="hotelInfo.hotelsId1"  />
	<html:hidden property="HotelForm"  property="hotelInfo.hotelname"  />
	<html:hidden property="HotelForm"  property="hotelInfo.hotelsize"  />
	<html:hidden property="HotelForm"  property="hotelInfo.hotelprice"  />
	<html:hidden property="HotelForm"  property="hotelInfo.hotellevel"  />
	<html:hidden property="HotelForm"  property="hotelDetailInfo.hotelstatus"  value="1"/>
		<table cellpadding="1" cellspacing="0" class="nav01">
			<tr>
				<td>
					<img src="<%=request.getContextPath()%>/images/b1.gif" width="12"
						height="12" />
					您现在的位置:酒店餐饮管理>>客房预订
					<br>
				</td>
			</tr>
		</table>
		<html:errors />
		<table id="info" border="1" bordercolor="#7FB0DE"
			bordercolordark="#ffffff" cellpadding="1" cellspacing="0"
			class="content01">

			<tr class="listHead">
				<td align=left colspan=6>
					预订信息
				</td>
			</tr>
			<tr class="listContent">
				<td align=right>
					<font color="red">*</font>客户名称:
				</td>
				<td>
					<html:text name="HotelForm" property="hotelDetailInfo.custname"  maxlength="29" />
				</td>
				<td align=right>
					<font color="red">*</font>客户类型:
				</td>
				<td align=left id="td3">
					<select  name="querytype" onchange="changeType()">
							<option value="0">普通客户</option>
							<option value="1">酒店会员</option>
					</select>
				</td>
				<td align=right id="td1" style="display:none">
					<font color="red">*</font>会员类型:
				</td>
	
					<td align=left id="td2" style="display:none">
					<html:select name="HotelForm" property="hotelDetailInfo.clubId" >
					 	<html:options collection="club_info_list" property="id" labelProperty="name" />
					</html:select>
				</td>

			</tr>
			<tr class="listContent">
				<td align=right>
					<font color="red">*</font>身份证号码:
				</td>
				<td>
					<html:text name="HotelForm" property="hotelDetailInfo.custcertid" maxlength="19" />
				</td>
				<td align=right>
					<font color="red">*</font>手机号码:
				</td>
				<td align=left>
				    <html:text name="HotelForm" property="hotelDetailInfo.custphone" maxlength="20" />
				</td>
				<td align=right>
					其他信息:
				</td>
				<td align=left>
						<html:text name="HotelForm" property="hotelDetailInfo.remark" maxlength="128" />
				</td>
			</tr>
			<tr>
				<td align=right >
					<font color="red">*</font>预订日期:
				</td>
				<td align=left>
					<input type ="text" name="begintime"  maxlength="8" />	
					<font color='red'>
							*
						</font>
						<IMG align="middle" src="<%=request.getContextPath()%>/images/calendar.gif" onclick="calendar(document.all('begintime'))">
				</td>
				<td align=right >
				<font color="red">*</font>退订日期:
				</td>
				<td align=left colspan=3>
				   <input type ="text" name="endtime"  maxlength="8" />		
					<font color='red'>
							*
						</font>
						<IMG align="middle" src="<%=request.getContextPath()%>/images/calendar.gif" onclick="calendar(document.all('endtime'))">
	
				</td>
			</tr>
			<tr class="listContent">
				<td align=left colspan=6>
					<input type=button class=save onClick="doSave();" />	
				    <input type=button class=cancel onClick="window.close();" />				
		       	</td>
			</tr>
		</table>
	</html:form>

</body>
</html:html>
<script language="javascript">
function doSave(){
 var items = new CheckItem();
	items.add("0|1|hotelDetailInfo.custname|客户名称|-1");
	if(document.forms[0].elements["querytype"].value =="1"){
		if (document.forms[0].elements["hotelDetailInfo.clubId"].value ==""){
		 alert("请选择会员类型,谢谢!");
		 return;
		}
	}
	items.add("7|1|hotelDetailInfo.custcertid|身份证号码|-1");
	items.add("5|1|hotelDetailInfo.custphone|手机号码|-1");
	items.add("6|1|begintime|预订日期|-1");
	items.add("6|1|endtime|退订日期|-1");
	items.add("10|LE|begintime|预订日期|endtime|不能大于退订日期!");
	if(!checkForm(document.forms[0],items))
		return false;
	document.forms[0].action="HoteOrderDetailAction.do?method=OrdHotelInfo";
    document.forms[0].submit();
   
}



   function changeType(){
       if (document.forms[0].elements["querytype"].value == "0"){
       		 window.td1.style.display='none';
       		 window.td2.style.display='none';

       }else{  
       		window.td1.style.display='';
       		window.td2.style.display='';

       }
   }
</script>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -