📄 list_role.inc
字号:
<%
'************************************************************************************************
' 函数名 : TableHeader()
' 输 入 :
' 输 出 : 一个用于显示角色列表的表头
' 功能描述:
' 调用模块: list_role.asp
' 作 者 : 蔡晓燕
' 日 期 : 2002-08-01
' 版 本 :
'************************************************************************************************
Function TableHeader()
Response.Write TableTitle("系统现有的角色列表", 600, "", "#0040a0")
TableHeader = _
"<table cellspacing=0 cellpadding=0 width=600 align=center class=tablelist style=""table-layout:fixed"">" & _
"<tr>" & _
"<td class=tdHead width=200> <img src=""../images/bg/ar-y.gif"" width=8 height=8> " & TableHeaderField(sFileName, "meeting_name", "角色编号", sFormParams, iSort, iSorted) & "</td>" & _
"<td class=tdHead width=400> " & TableHeaderField(sFileName, "role_desp", "角色名称", sFormParams, iSort, iSorted) & "</td>" & _
"</tr>"
End Function
'************************************************************************************************
' 函数名 : TableRecords(sSQL, iCols, iRecordsPerPage, iTotalRecords, iCurrentPage, iTotalPages,
' sFileName, sFormParams, sSortParams)
' 输 入 : 查询语句,栏目数量,每页记录条数,总记录条数,当前页码,总页数,文件名,查询表单参数,排序参数
' 输 出 : 显示待审批的会议列表
' 功能描述: 根据输入参数,显示相应的结果
' 调用模块: list_role.asp
' 作 者 : 蔡晓燕
' 日 期 : 2002-07-11
' 版 本 :
'************************************************************************************************
Function TableRecords(sSQL, iCols, iRecordsPerPage, iTotalRecords, iCurrentPage, iTotalPages, sFileName, sFormParams, sSortParams)
dim sTemp : sTemp = "" ' 临时字符串变量
dim j ' 临时循环变量
'------------------------------------
' 分页所需的变量定义
'------------------------------------
Dim iCounter : iCounter = 1
Dim iPrevPage, iNextPage
'------------------------------------
' 获取数据库连接
'------------------------------------
dim crs : set crs = New CRecordset
dim rs : set rs = crs.open(dbLocal,sSQL)
dim iRole_id, sRole_type, sRole_desp
' 如果未到记录尾,将记录定位到你翻到的页面的第一个记录,否则显示空行
if Not rs.EOF then
rs.Move (iCurrentPage - 1) * iRecordsPerPage
end if
while not rs.EOF and iCounter <= iRecordsPerPage
iRole_id = crs.GetValue("role_id")
sRole_desp = crs.GetValue("role_desp")
sRole_type = crs.GetValue("role_type")
sTemp = sTemp & "<tr>" & _
"<td class=tdlist style=""cursor:hand;color:blue;"" align=left nowrap title=""" & Tohtml(iRole_id) & """ ><a href=""newrole.asp?roleid=" & iRole_id &"&page="&iCurrentPage& """ ><img border=0 src=""../images/bg/ar-g.gif"" width=8 height=8> " & Tohtml(iRole_id) & "</a> </td>" & _
"<td class=tdlist align=left title="""& Tohtml(sRole_desp) & """ nowrap> " & ToHTML(sRole_desp) & " </td>" & _
"</tr>"
iCounter = iCounter + 1
rs.movenext
wend
crs.Close()
' 填补空白行
sTemp = sTemp & WhiteRows(iCols, iCounter, iRecordsPerPage)
' 首页、前页、后页、尾页等分页信息
sTemp = sTemp & "<tr><td class=tdlist colspan=" & iCols & " align=right>" & _
Paginate(sFileName, sFormParams, sSortParams, iCurrentPage, iTotalPages) & _
" </td></tr>"
TableRecords = sTemp&"</table>"
End Function
'************************************************************************************************
' 函数名 : TableLink()
' 输 入 :
' 输 出 :
' 功能描述: 角色管理相关连接
' 调用模块: list_role.asp
' 作 者 : 蔡晓燕
' 日 期 : 2002-08-01
' 版 本 :
'************************************************************************************************
Function TableLink()
TableLink = _
"<table width=600 cellspacing=0 cellpadding=0 border=0 align=center>" & _
"<tr height=30>" & _
" <td width=600><img src=""../images/bg/line.gif"" width=600 height=3></td>" & _
"</tr>" & _
"<tr height=30>" & _
" <td width=600> " & _
" <img src=""../images/goto.gif"" width=11 height=11> <a href=""newrole.asp"">新增角色</a>" & _
" " & _
" <img src=""../images/goto.gif"" width=11 height=11> <a href=""list_role.asp"">角色列表</a></td>" & _
"</tr>" & _
"</table>"
End Function
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -