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

📄 sheet_return.inc

📁 物业管理和办公自动化系统
💻 INC
字号:
<%
'###############################################################################
'#
'#	文件名	 : sheet_item.inc
'#	
'#      创建人	 : yaoxiaohui
'#      日期	 : 2002-11-06
'#
'#	修改历史  : ****年**月**日 ****** 
'#      修改内容  : *********************************
'#
'#	功能描述	 : 领用单函数文件
'#      版   本	 : v1.0
'#
'#      Copyright(c) 2001-2002 上海阿尔卡特网络支援系统有限公司
'#
'###############################################################################

'*******************************************************************************
Function SheetTop()
    SheetTop = _
		"<table cellspacing=0 cellpadding=3 width=""640"" align=center border=0>" & vbLF & _
		"  <tr height=50 bgcolor=white>" & vbLF & _
		"	<td align=center style=""color:black;font-size:16pt;font-weight:600;"">退货单</td>" & vbLF & _
		"  </tr>" & vbLF & _		
		"</table>" & vbLF
End Function
'*******************************************************************************
Function Border()
	Border = _
	"<table cellspacing=0 cellpadding=3 width=""20"" align=center border=0>" & vbLF & _
	"  <tr bgcolor=white>" & vbLF & _
	"	<td></td>" & vbLF & _
	"  </tr>" & vbLF & _
	"</table>" & vbLF
End Function
'*******************************************************************************
Function SheetMasterUp()
    SheetMasterUp = _
		"<table cellspacing=0 cellpadding=3 width=""640"" align=center border=0>" & vbLF & _
		"  <tr height=25 bgcolor=white>" & vbLF & _
		"	<td width=200 align=left style=""color:black;"">&nbsp;&nbsp;&nbsp;类别:&nbsp;" & sGoodsDesc & "</td>" & vbLF & _
		"	<td width=250 align=left style=""color:black;"">部门:&nbsp;" & sNodeName & "</td>" & vbLF & _
		"	<td width=150 align=left style=""color:black;"">编号:&nbsp;" & pSheetID & "</td>" & vbLF & _
		"  </tr>" & vbLF & _	
		"</table>" & vbLF
End Function
'*******************************************************************************
Function TableHeader()
	TableHeader = _
		"<table cellspacing=0 cellpadding=0 width=600 align=center bgcolor=silver style=""table-layout:fixed;border-style:solid;border-color:black;border-top-width:1px;border-bottom-width:2px;border-left-width:1px;border-right-width:2px;"">" & vbLF & _
		"<tr style=""display:none"">" & vbLF & _
		"	<td width=40>这一行仅用于控制表格的宽度</td>" & vbLF & _
		"	<td width=90></td>" & vbLF & _
		"	<td width=80></td>" & vbLF & _
		"	<td width=40></td>" & vbLF & _
		"	<td width=75></td>" & vbLF & _
		"	<td width=75></td>" & vbLF & _
		"	<td width=75></td>" & vbLF & _
		"	<td width=75></td>" & vbLF & _
		"	<td width=""*""></td></tr>" & vbLF & _
		"<tr bgcolor=white height=35 style=""border-style:groove;border-color:black;border-width:1;"">" & _
        "<td class=tdHead align=center>序号</td>" & _
		"<td class=tdHead align=center>物品名称</td>" & _
		"<td class=tdHead align=center>型号规格</td>" & _
		"<td class=tdHead align=center>单位</td>" & _
		"<td class=tdHead align=center>数量</td>" & _
		"<td class=tdHead align=center>购买日期</td>" & _
		"<td class=tdHead align=center>退货原因</td>" & _
		"<td class=tdHead align=center>供货商</td>" & _
		"<td class=tdHead align=center>备注</td>" & _
		"</tr>"
End Function

'*******************************************************************************
Function TableRecords(sSQL, iCols, iRecordsPerPage, iTotalRecords, iCurrentPage, iTotalPages, sFileName, sFormParams, sSortParams)
	dim sTemp	: sTemp = ""	' 临时字符串变量
	dim j					' 临时循环变量

	'------------------------------------
	' 分页所需的变量定义
	'------------------------------------
	Dim iCounter		: iCounter = 1
	Dim iPrevPage, iNextPage
	Dim rowCount        : rowCount = 0
	
	'------------------------------------
	' 获取数据库连接
	'------------------------------------
	dim rs	: set rs = Openrs(conn,sSQL)

	dim sGoodsID, sGoodsName, sModel, sUnit, sQuantity, sUnitPrice, sReturnReason, sPurDate, sSupplier, sRemark
	dim sTotalPrices
	
	''response.write sSQL : response.end
	
	' 如果未到记录尾,将记录定位到你翻到的页面的第一个记录,否则显示空行
	if Not rs.EOF then		
		rs.move (iCurrentPage - 1) * iRecordsPerPage
	end if

	
	while not rs.EOF and iCounter <= iRecordsPerPage
	    rowCount = rowCount + 1
		sGoodsID		= GetValue(rs,"goods_id")
		sGoodsName		= GetValue(rs,"goods_name")
		sModel			= GetValue(rs,"model")
		sUnit			= GetValue(rs,"unit")
		sQuantity		= GetValue(rs,"quantity")
		sUnitPrice		= GetValue(rs,"unit_price")
		sReturnReason	= GetValue(rs,"return_reason")
		sPurDate		= GetValue(rs,"purchase_date")
		sSupplier		= GetValue(rs,"supplier")
		sRemark			= GetValue(rs,"remark")

		sql = "select name from t_firm where id =" & ToSQL(sSupplier,"number")
		sSupplier = DLookUp(conn,sql)

		sTemp = sTemp & "<tr bgcolor=white height=25>" & _
		        "<td class=tdlist align=center nowrap>" & rowCount & "</td>" & _
				"<td class=tdlist align=center title=""" & sGoodsName & """ nowrap>" & sGoodsName & "&nbsp;</td>" & _
				"<td class=tdlist align=center title=""" & sModel & """ nowrap>" & sModel & "&nbsp;</td>" & _
				"<td class=tdlist align=center title=""" & sUnit & """ nowrap>" & sUnit & "&nbsp;</td>" & _
				"<td class=tdlist align=center title=""" & sQuantity & """ nowrap>" & sQuantity & "&nbsp;</td>" & _
				"<td class=tdlist align=center title=""" & sPurDate & """ nowrap>" & sPurDate & "&nbsp;</td>" & _
				"<td class=tdlist align=center title=""" & sReturnReason & """ nowrap>" & sReturnReason & "&nbsp;</td>" & _
				"<td class=tdlist align=center title=""" & sSupplier & """ nowrap>" & sSupplier & "&nbsp;</td>" & _
				"<td class=tdlist align=center title=""" & sRemark & """ nowrap>"& sRemark &"&nbsp;</td>" & _
				"</tr>"
		iCounter = iCounter + 1
		rs.movenext
	wend
	rs.Close()
	set rs = nothing

	' 填补空白行
	sTemp = sTemp & WhiteRowsMod(iCols, iCounter, iRecordsPerPage)

	TableRecords = _ 
				sTemp & _
				"</table>"

End Function
'*******************************************************************************
Function SheetMasterDown
	SheetMasterDown = _	
		"<table cellspacing=0 cellpadding=3 width=""640"" align=center border=0>" & vbLF & _
		

		"  <tr height=30 bgcolor=white>" & vbLF & _
		"	<td width=200 align=left style=""color:black;"">&nbsp;&nbsp;&nbsp;制表人:&nbsp;" & pHandover & "</td>" & vbLF & _
		"	<td width=250 align=left style=""color:black;"">部门主管:&nbsp;" & pDepartMgr & "</td>" & vbLF & _
		"	<td width=150 align=left style=""color:black;"">日期:&nbsp;" & pOpdate & "</td>" & vbLF & _
		"  </tr>" & vbLF & _
		
		"</table>" & vbLF
End Function
'*******************************************************************************
Function SheetBottom()
    SheetBottom = _
		"<table cellspacing=0 cellpadding=3 width=""640"" align=center border=0>" & vbLF & _
		"  <tr height=30 bgcolor=white>" & vbLF & _
		"	<td align=right style=""color:black;"">仲量联行上海信息大楼物业管理中心&nbsp;&nbsp;</td>" & vbLF & _
		"  </tr>" & vbLF & _		
		"</table>" & vbLF
End Function
'*******************************************************************************
function TableAction()
	dim sTemp : sTemp = ""
'	if IsHrAdmin then		'' 只有人事管理员才显示管理的链接
'		sTemp = _
'			"		&nbsp;&nbsp;&nbsp;" & vbLF & _
'			"		<a style=""color:blue"" href=""emp_oe.asp?emp_serial=" & pEmpSerial & """><img border=0 src=""../images/edit.gif"">&nbsp;修改员工信息</a>" & vbLF & _
'			"		&nbsp;&nbsp;&nbsp;" & vbLF & _
'			"		<a style=""color:blue"" href=""emp_od.asp?emp_serial=" & pEmpSerial & """><img border=0 src=""images/dismiss.gif"">&nbsp;员工离职</a>" & vbLF
'	end if

	TableAction = _
		"<table width=600 cellspacing=0 cellpadding=5 height=30 align=center>" & vbLF & _
		"	<tr>" & vbLF & _
		"	<td align=center>" & _
		"		<a style=""color:blue"" target=_blank href=""sheet_return.asp?sheet_id=" & pSheetID & "&forprint=1""><img border=0 src=""../images/edit.gif"">&nbsp;察看打印版</a>" & vbLF & _
		"		&nbsp;&nbsp;&nbsp;" & vbLF & _
		"		<a style=""color:blue"" href=""sheet_mgr.asp""><img border=0 src=""../images/property.gif"">&nbsp;出入库单管理</a>" & vbLF & _
			sTemp & vbLF & _
				"</td>" & vbLF & _
		"	</tr>" & vbLF & _
		"</table>"
end function
'*******************************************************************************
Function WhiteRowsMod(piCols, piStart, piRecordsPerPage)
	dim i, j, sTemp, iCols, iStart, iRecordsPerPage

	iCols = piCols
	iStart = piStart
	iRecordsPerPage = piRecordsPerPage

	'' 如果起始行已经等于或超过每页总行数,则返回空字串
	'' 如果从第一行开始就是空行,则显示(哎呀,一条记录也没有找到!)
	'' 否则,就从起始行开始填补空行
	if iStart > iRecordsPerPage then
		sTemp = ""
	else
		sTemp = "<tr bgcolor=white height=30>"
		sTemp = sTemp & "<td class=tdlist align=center>" & iStart & "</td>"
		for i = 2 to iCols
			sTemp = sTemp & "<td class=tdlist>&nbsp;</td>"
		next
		sTemp = sTemp & "</tr>"
	end if
	for j = iStart + 1 to iRecordsPerPage step 1
		sTemp = sTemp & "<tr bgcolor=white height=30>"
		sTemp = sTemp & "<td class=tdlist align=center>" & j & "</td>"
		for i = 2 to iCols
			sTemp = sTemp & "<td class=tdlist>&nbsp;</td>"
		next
		sTemp = sTemp & "</tr>"
	next
	WhiteRowsMod = sTemp
End Function
'*******************************************************************************
Function TableLink()
	TableLink = _
		"<table width=""100%"" cellspacing=0 cellpadding=0 border=0 align=center>" & vbLF & _
		"<tr height=10>" & vbLF & _ 
		"	<td width=600><img src=""../images/bg/line.gif"" width=600 height=3></td>" & vbLF & _
		"</tr>" & vbLF & _
		"<tr>" & vbLF & _
		"	<td width=600>&nbsp;" & vbLF & _
		"		<img src=""../images/goto.gif"">&nbsp;<a href=""../stock/goods_input.asp"">物品入库</a>" & vbLF & _
		"		&nbsp;&nbsp;&nbsp;" & vbLF & _
		"		<img src=""../images/goto.gif"">&nbsp;<a href=""../stock/output.asp"">物品出库</a>" & vbLF & _
		"		&nbsp;&nbsp;&nbsp;" & vbLF & _		
		"		<img src=""../images/goto.gif"">&nbsp;<a href=""../stock/goods_move.asp"">物品移动</a>" & vbLF & _
		"		&nbsp;&nbsp;&nbsp;" & vbLF & _
		"		<img src=""../images/goto.gif"">&nbsp;<a href=""../stock/goods_query.asp"">库存查询</a></td>" & vbLF & _
		"</tr>" & vbLF & _
		"</table>" & vbLF
End Function
%>

⌨️ 快捷键说明

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