📄 emp_oe.inc
字号:
<%
function TableFormEmp()
dim sDepartId, sDepartment, sPos, sEmpId, sEmpNo, sEmpName, sBirthday, sGender, sFolk, sEducation, sGraduateDate, sGraduateSchool, sSpeciality, sPolitical, sPosition, sTitle, sMarriage, sHAddr, sHZip, sHPhone, sMobile, sWorkDate, sTelecomDate, sEmpDate, sEmail
dim sSQL
sSQL = "select t1.emp_id, t1.emp_no, t1.name, t2.gender_desc as gender, t1.birthday, t3.education_desc as education, " & _
" t1.graduate_date, t1.graduate_school, t1.specialty, t1.home_address, home_phone, home_zip, " & _
" t1.mobile, t1.work_date, t1.telecom_date, t1.emp_date, t1.co_email as email, " & _
" t4.position_desc as pos, t5.title_desc as title, t6.parent_node_id as depart_id, t6.node_name as position, " & _
" t7.folk_desc as folk, t8.political_desc as political, t9.marriage_desc as marriage" & _
" from t_employee t1" & _
" left join t_gender t2 on t1.gender = t2.gender_id" & _
" left join t_education t3 on t1.education = t3.education_id" & _
" left join t_position t4 on t1.pos = t4.position_id" & _
" left join t_title t5 on t1.title = t5.title_id" & _
" left join t_node t6 on t1.node_id = t6.node_id" & _
" left join t_folk t7 on t1.folk = t7.folk_id" & _
" left join t_political t8 on t1.political = t8.political_id" & _
" left join t_marriage t9 on t1.marriage = t9.marriage_id" & _
" where serial = " & pEmpSerial & _
" and t1.co_id = 1 and t1.isdummy = 0"
dim crs, rs
set crs = New CRecordset
set rs = crs.Open(dbLocal, sSQL)
'' 若找不到相应的记录,则跳转到出错页面
if rs.EOF then
Response.Clear
Server.Transfer("../common/error.asp")
Response.end
end if
sEmpid = crs.GetValue("emp_id") '' 用户名
sEmpNo = crs.GetValue("emp_no") '' 工号
sEmpName = crs.GetValue("name") '' 姓名
sGender = crs.GetValue("gender") '' 性别
sBirthday = crs.GetValue("birthday") '' 出生日期
sEducation = crs.GetValue("education") '' 教育程度
sGraduateDate = crs.GetValue("graduate_date") '' 毕业时间
sGraduateSchool = crs.GetValue("graduate_school") '' 毕业学校
sSpeciality = crs.GetValue("specialty") '' 专业
sPos = crs.GetValue("pos") '' 职务
sTitle = crs.GetValue("title") '' 职称
sDepartId = crs.GetValue("depart_id") '' 部门标识
sPosition = crs.GetValue("position") '' 现任岗位
sFolk = crs.GetValue("folk") '' 民族
sPolitical = crs.GetValue("political") '' 政治面貌
sMarriage = crs.GetValue("marriage") '' 婚姻状况
sHAddr = crs.GetValue("home_address") '' 家庭地址
sHZip = crs.GetValue("home_zip") '' 邮政编码
sHPhone = crs.GetValue("home_phone") '' 住宅电话
sMobile = crs.GetValue("mobile") '' 移动电话
sWorkDate = crs.GetValue("work_date") '' 参加工作年月
sTelecomDate = crs.GetValue("telecom_date") '' 进邮电年月
sEmpDate = crs.GetValue("emp_date") '' 进本单位年月
sEmail = sEmpId & "@infortower.com"
if sHPhone <> "" then sHAddr = sHAddr & "(邮编:" & sHZip & ")"
'' 部门名称
sDepartment = DLookUp(dbLocal, "t_node", "node_name", "node_id=" & sDepartId)
TableFormEmp = _
"<table cellspacing=1 cellpadding=3 bgcolor=""silver"" width=600 border=0>" & vbLF & _
" <tr bgcolor=""#0040a0"" style=""color:white;font-weight:600"">" & vbLF & _
" <td colspan=7 align=center>修 改 员 工 信 息</td>" & vbLF & _
" </tr>" & vbLF & _
" <tr bgcolor=white height=25>" & vbLF & _
" <td align=center width=85>姓 名</td><td width=75 class=tdValue>" & sEmpName & "</td>" & vbLF & _
" <td align=center width=75>所在部门</td><td width=120 class=tdValue>" & sDepartment & "</td>" & vbLF & _
" <td align=center width=65>现任岗位</td><td width=60 class=tdValue>" & sPos & "</td>" & vbLF & _
" <td rowspan=5 width=90><img border=1 width=85 height=110 src=""photo/s10072.gif""></td>" & vbLF & _
" </tr>" & vbLF & _
" <tr bgcolor=white height=25>" & vbLF & _
" <td align=center>工 号</td><td class=tdValue>" & sEmpNo & " </td>" & vbLF & _
" <td align=center>出生年月</td><td class=tdValue>" & sBirthday & "</td>" & vbLF & _
" <td align=center>性 别</td><td class=tdValue>" & sGender & "</td>" & vbLF & _
" </tr>" & vbLF & _
" <tr bgcolor=white height=25>" & vbLF & _
" <td align=center>学 历</td><td class=tdValue>" & sEducation & "</td>" & vbLF & _
" <td align=center colspan=1>学历取得时间</td><td class=tdValue>" & sGraduateDate & "</td>" & vbLF & _
" <td align=center>民 族</td><td class=tdValue>" & sFolk & "</td>" & vbLF & _
" </tr>" & vbLF & _
" <tr bgcolor=white height=25>" & vbLF & _
" <td align=center>原毕业学校</td><td colspan=2 class=tdValue>" & sGraduateSchool & "</td>" & vbLF & _
" <td align=center>所学专业</td><td colspan=2 class=tdValue>" & sSpeciality & "</td>" & vbLF & _
" </tr>" & vbLF & _
" <tr bgcolor=white height=25>" & vbLF & _
" <td align=center>职务或职称</td><td class=tdValue>" & sTitle & "</td>" & vbLF & _
" <td align=center>政治面貌</td><td class=tdValue>" & sPolitical & "</td>" & vbLF & _
" <td align=center>婚姻状况</td><td class=tdValue>" & sMarriage & "</td>" & vbLF & _
" </tr>" & vbLF & _
" <tr bgcolor=white height=25>" & vbLF & _
" <td align=center>家庭地址</td><td colspan=3 class=tdValue>" & sHAddr & "</td>" & vbLF & _
" <td align=center>家庭电话</td><td colspan=2 class=tdValue>" & sHPhone & "</td>" & vbLF & _
" </tr>" & vbLF & _
" <tr bgcolor=white height=25>" & vbLF & _
" <td align=center>手机或BP机</td><td colspan=2 class=tdValue>" & sMobile & "</td>" & vbLF & _
" <td align=center>电子信箱</td><td colspan=3 class=tdValue>" & sEmail & "</td>" & vbLF & _
" </tr>" & vbLF & _
" <tr bgcolor=white height=25>" & vbLF & _
" <td align=center>参加工作年月</td><td colspan=2 class=tdValue>" & sWorkDate & "</td>" & vbLF & _
" <td align=center>进邮电年月</td><td colspan=3 class=tdValue>" & sTelecomDate & "</td>" & vbLF & _
" </tr>" & vbLF & _
" <tr bgcolor=white height=25>" & vbLF & _
" <td align=center>进本单位年月</td><td colspan=2 class=tdValue>" & sEmpDate & "</td>" & vbLF & _
" <td align=center> </td><td colspan=3 class=tdValue> </td>" & vbLF & _
" </tr>" & vbLF & _
Relations & _
Resumes & _
"</table>" & vbLF & _
"<table width=600 cellspacing=0 cellpadding=5 height=30 align=center>" & vbLF & _
" <tr>" & vbLF & _
" <td align=center>" & _
" <a style=""color:blue"" href=""emp_oe.asp?emp_serial=" & pEmpSerial & """><img border=0 src=""../images/edit.gif""> 修改员工信息</a>" & vbLF
" </tr>" & vbLF & _
"</table>"
end function
'****************************************************************************************
' 员工主要社会关系
'****************************************************************************************
function Relations()
Relations = _
"<IFRAME frameborder=0 width=580 height=300 src=""relation.asp?emp_serial=" & pEmpSerial & """ scrolling=no>" & vbLF & _
"</IFRAME>" & vbLF
end function
'****************************************************************************************
' 员工主要学习工作经历
'****************************************************************************************
function Resumes()
dim iCounter, sInfor, sHeader
dim crs, rs
dim sPeriod, sCompany, sCertifier
dim sSQL : sSQL = "select period, company, certifier from t_resume" & _
" where emp_serial = " & pEmpSerial
set crs = New CRecordset
set rs = crs.Open(dbLocal, sSQL)
sHeader = _
" <td align=center colspan=2>年、月 ~ 年、月</td>" & _
" <td align=center colspan=3>所在单位及担任工作</td>" & _
" <td align=center>证明人</td>" & vbLF
sInfor = ""
iCounter = 0
while Not rs.EOF
iCounter = iCounter + 1
sPeriod = crs.GetValue("period")
sCompany = crs.GetValue("company")
sCertifier = crs.GetValue("certifier")
sInfor = sInfor & _
"<tr bgcolor=""white"" height=25>" & vbLF & _
" <td align=center colspan=2 class=tdValue>" & sPeriod & "</td>" & vbLF & _
" <td colspan=3 class=tdValue>" & sCompany & "</td>" & vbLF & _
" <td align=center class=tdValue>" & sCertifier & "</td>" & vbLF & _
"</tr>" & vbLF
rs.movenext
wend
crs.Close()
if iCounter > 0 then '' 有记录
Resumes = _
"<tr bgcolor=""white"" height=25>" & vbLF & _
" <td rowspan=" & iCounter + 1 & " align=center>主 要<br>学习工作经历</td>" & sHeader & vbLF & _
"</tr>" & vbLF & _
sInfor
else '' 无记录
Resumes = _
"<tr bgcolor=""white"" height=25>" & vbLF & _
" <td align=center>主 要<br>学习工作经历</td><td colspan=6 class=tdValue>(无)</td>" & vbLF & _
"</tr>" & vbLF
end if
end function
Function TableLink()
TableLink = _
"<table width=600 cellspacing=0 cellpadding=0 border=0 align=center>" & _
"<tr height=10>" & _
" <td width=600><img src=""../images/bg/line.gif"" width=600 height=3></td>" & _
"</tr>" & _
"<tr>" & _
" <td width=600> " & _
" <img src=""../images/goto.gif""> <a href=""emp_ol.asp"">员工信息查询</a>" & _
" " & _
" <img src=""../images/goto.gif""> <a href=""position.asp"">职务管理</a>" & _
" " & _
" <img src=""../images/goto.gif""> <a href=""title.asp"">职称管理</a>" & _
" " & _
" <img src=""../images/goto.gif""> <a href=""node_o.asp"">组织结构管理</a>" & _
" " & _
" <img src=""../images/goto.gif""> <a href=""emp_odl.asp"">离职员工查询</a></td>" & _
"</tr>" & _
"</table>"
End Function
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -