<%@ Language=VBScript %>
<!--#include File="../Functions2.asp"-->
<!--#include File="../Const.asp"-->
<!--#include file="../../yns_chklogin.asp" -->
<%

Dim Page
Page = Request("Page")
If Page = "" Then
  Page = 1
End If
Dim IsFirst
IsFirst = Request("IsFirst")
If IsEmpty(IsFirst) Or IsNull(IsFirst) Then
	IsFirst = 0
End If

Dim MyConn, RS, SqlSelect
Set MyConn = Server.CreateObject("Adodb.Connection")
Set MyConn = GetConnection
Set RS = Server.CreateObject("Adodb.RecordSet")

SqlSelect = "Select * From SitcomType"

RS.Open SqlSelect, MyConn, 1, 1
RS.PageSize = SitcomTypePageSize
%>
<HTML>
<HEAD>
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
<link rel="stylesheet" href="../../zf.css">
<TITLE>产品类别列表</TITLE>
</HEAD>

<script language=javascript>
<!--
function ifrefresh()
	{
	if (isfirst.value==0)
		isfirst.value=1;
	else
		window.location='ListSitcomType.asp?IsFirst=0';
	}
//-->
</script>

<BODY onload="ifrefresh();" bgcolor="#ffffff">
<input type=hidden id=isfirst name=isfirst value=<%=IsFirst%>>
<table>
  <%If RS.EOF Then%>
  <tr>
    <td valign=middle height=60 align=center>
      对不起，系统中还没有产品类别！<br>
      &nbsp;&nbsp;&nbsp;&nbsp; <a href=AddSitcomType.asp>添加</a> </td>
  </tr>
  <%
  Else
  %>
   <tr>
    <td height=40 valign=bottom align=right> <a href=AddSitcomType.asp>添加产品类别</a> 
      &nbsp;&nbsp;&nbsp;&nbsp; </td>
  </tr>
  <tr>
    <td align=center>产品类别列表</td>
  </tr>
 <tr>
    <td><HR></td>
  </tr>
  <tr>
    <td><%ShowOnePageSitcomType RS, Page%></td>
  </tr>
  <tr>
    <td height=20><HR></td>
  </tr>
  <tr>
    <td><%ShowPageBorrows FileName, Page, RS%></td>
  </tr>
</table>
<%
  End If
RS.Close
Set RS = Nothing
MyConn.Close
Set MyConn = Nothing
%>
</BODY>
</HTML>
