<!--#include virtual="/includes/topofpage.asp"-->
<%@ Language=VBScript %>
<%'Setting Up Connection
	Dim Conn
	Set Conn = Server.CreateObject("ADODB.Connection")
	Conn.Open "DRIVER={SQL Server};SERVER=WEBSRV01;UID=web;pwd=w3bs1t3;DATABASE=AVANTE"
%>

<% 'Getting Group List
	Dim SQL, RS
	
	SQL = "Select * from [Group] where Lookup_ID = '6'"
		
	Set RS=Conn.Execute(SQL)
%>

<%	' Call to SQL for Current Amenity Type List
	Dim SQL1, RS1
	
	SQL1 = "select * from amenity_type"
		
	Set RS1=Conn.Execute(SQL1)
%>

<HTML>
<STYLE>
BODY {SCROLLBAR-FACE-COLOR: #5e5ebe; SCROLLBAR-HIGHLIGHT-COLOR: #5e5ebe; SCROLLBAR-SHADOW-COLOR: #5e5ebe; SCROLLBAR-3DLIGHT-COLOR: #5e5ebe; SCROLLBAR-ARROW-COLOR:  #6666CC; SCROLLBAR-TRACK-COLOR: #E3E3E3; SCROLLBAR-DARKSHADOW-COLOR: #666666; }
</STYLE>
<head>
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
</HEAD>
<BODY>
<%
	'Checking for No Data
    if rs1.eof then
		Response.Write "<TR><Center><h1> No Data Available </h1></center></TR>"  
%>
	
	<TR>
		<TD colSpan=4>
			<P align=center>
				<FONT face=Verdana Color=red>
					<STRONG>No Data Available</STRONG>
				</FONT>
			</P>
		</TD>
	</TR>
<%
	'Writting Header if Data is Available
	Else
%>
<P><TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
  
  <TR>
    <TD colSpan=3 bgcolor=royalblue>
      <P align=center><STRONG><FONT face=Verdana>Create New Amenity Detail(s)</FONT></STRONG></P>
    </TD>
  </TR>
  <TR>
    <TD width="15%" colSpan=3>&nbsp;&nbsp;&nbsp;</TD></TR>
  <TR>
    <TD width="15%"></TD>
    <TD width="40%">
      <P align=center><INPUT id=CloseWindow onclick=window.close(); type=button value="Close Window" name=CloseWindow></P></TD>
    <TD width="45%">
      <P align=center><INPUT type=submit value="Create Amenity" name=Submit></P></TD>
    </TR>
  <TR>
    <TD width="15%" colSpan=3>&nbsp;&nbsp;&nbsp;</TD>
  </TR>
  <TR>
    <TD width="25%"><P align=right><FONT face=Verdana size=1><STRONG>Name of Amenity Package:</Font></p></TD>
    <TD colspan=2><INPUT style="WIDTH: 100%; HEIGHT: 22px" maxLength=100 size=60 title=Name id=text1 name=text1></TD>
  </TR>
  <TR>
    <TD width="25%">
      <P align=right><FONT face=Verdana size=1><STRONG>Group:</STRONG></FONT></P></TD>
    <TD width="40%" colSpan=2>
		<SELECT id=GroupID style="WIDTH: 100%" name=GroupID>
		<%	Do until RS.EOF %>
				<OPTION value="<%=RS("Group_ID")%>"><%=RS("Name")%></OPTION>
		<%		RS.Movenext()
			Loop
			RS.Close
		%>
		</SELECT>		
	</TD>  
  </TR>
  <TR>
    <TD width="15%" colSpan=3>
		<FONT size=1>
		<HR> 
		</FONT>
	</TD>
  </TR>
  <TR>
    <TD width="15%">
      <P align=center><FONT face=Verdana size=2><STRONG>Check all that are applicable</STRONG></FONT></P>
    </TD>
    <TD width="40%">
      <P align=center><FONT face=Verdana size=2><STRONG>Amenity Name</STRONG></FONT></P> 
    </TD>
    <TD width="45%">
      <P align=center><FONT face=Verdana size=2><STRONG>Amenity Detail</STRONG></FONT></P>
    </TD>
  </TR>
  <%
	' Writting Data if Data Present to Table
		Do while not rs1.eof
  %>
  <TR>
    <TD>
      <P align=center><%=RS1("Amenity_Type_ID")%> 
		<INPUT type=checkbox id=checkbox1 name=Amenity<%=RS1("Amenity_Type_ID")%>>
	  </P>
	</TD>
    <TD><FONT face=Verdana size=2><%=RS1("Name")%></FONT></TD>
    <TD><FONT face=Verdana size=1><%=RS1("Description")%></FONT></TD></TR>
  <%
			rs1.movenext
		Loop
	End If
	RS1.Close
  %>  
</TABLE></p>

</BODY>
</HTML>
