📄 employee.prg
字号:
TheMessage = "登录名为【"+allt(SysEm)+"】,姓名为【"+allt(user_name)+"】的员工的信息已经删除"
delete
endcase
go top
LOCATE FOR allt(user_id)==ALLT(u1) and ALLT(pass_word)==ALLT(p1)
if found() and "A" $ user_power
xm = allt(user_name)
USE
if allt(SysEm)="User_id" or allt(SysEm)="User_Name" or allt(SysEm) = "Department"
select * from userinfo NOCONSOLE order by &SysEm
else
select * from userinfo NOCONSOLE
endif
go top
do while not eof()
TEXT TO cHtmlEm0 TEXTMERGE noshow
<tr bgcolor=white>
<td align=center><input type=radio name="SelectWho" value=##user_id##></td>
<td align=center><font size="2" face=arial>##user_id##</font></td>
<td align=center><font size="2" face=arial>##User_name##</font></td>
<td align=center><font size="2" face=arial>##Department##</font></td>
<td align=center><font size="2" face=arial>##telinside##</font></td>
<td align=center><font size="2" face=arial>##teloutside##</font></td>
<td align=center><font size="2" face=arial>##telephone##</font></td>
<td align=center><font size="2" face=arial>##QQ##</font></td>
<td align=left><font size="2" face=arial>##EMAILDRESS##</font></td>
<td align=center><font size="2" face=arial>##User_power##</font></td></tr>
ENDTEXT
cHtmlEm = cHtmlEm + cHtmlEm0
skip
enddo
use
TEXT TO cHtml TEXTMERGE noshow
<HTML><HEAD><TITLE>系统管理员页面</TITLE>
<META NAME="Generator" CONTENT="NetObjects Fusion 2.0.2 for Windows"></HEAD>
<BODY BGCOLOR="">
<table width=760 border=0 bgcolor=#164DA8 cellspacing=1 cellpadding=2 align=center>
<tr bgcolor=white><td valign=center ><img src="image/ASPLogo3.jpg" width=730 height=56></td></tr>
</table>
<table width="760" border="0" bordercolor="#164DA8" align="center" cellpadding="0" cellspacing="0">
<tr><td height="13"><img src="image/banner2.jpg" width="758" height="12"></td></tr>
</table><br>
<table WIDTH="760" border=0 bgcolor=#164DA8 cellspacing=1 cellpadding=2 align=center>
<tr><td colspan=3><font color=white><P ALIGN="CENTER">VFP 狐狸办公信息管理系统(测试版)->员工信息查询->系统管理员选项 [当前用户-##xm##]</FONT></font></td></tr>
<tr bgcolor=white >
<td><a href="index.asp"><font color="#164DA8">返回到登录页面</font></a></td>
<td align=center> <font color="#164DA8" >管理员更新用户信息</FONT></td>
<td align=right><a href="javascript:history.back()"><font color="#164DA8">返回上一级网页</font></a></td></tr></table>
<table width="760" border="0" bordercolor="#164DA8" align="center" cellpadding="0" cellspacing="0">
<tr><td height="13"><img src="image/banner2.jpg" width="758" height="12"></td></tr>
</table><br>
<FORM ACTION="SystemManager.asp" METHOD=POST>
<TABLE WIDTH=760 border=0 bgcolor=#164DA8 cellspacing=1 cellpadding=2 align=center>
<TR><TD COLSPAN=14 align=center><font color=white>##TheMessage##</font></TD></TR>
<TR VALIGN="center" ALIGN="center" bgcolor=white>
<td><font size="2">选中</font></td><td><font size="2">登录名</font></td><td><font size="2">姓名</font></td>
<td><font size="2">部门</font></td><td><font size="2">内线</font></td><td><font size="2">外线</font></td><td><font size="2">个人电话</font></td>
<td><font size="2">QQ号</font></td><td><font size="2">电子邮箱</font></td><td><font size="2">权限</font></td>
</TR>
ENDTEXT
TEXT TO cHtmlEm1 TEXTMERGE noshow
</TABLE>
<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=1 WIDTH=760 align=center>
<TR VALIGN="top" ALIGN="center">
<TD WIDTH=100% align=center >
<INPUT TYPE="submit" NAME="Manager_Usr" VALUE="修改此用户信息" style="border: 1px solid #3466BB; background-color: #B6CAEB; color: #3466BB">
<INPUT TYPE="submit" NAME="Manager_Usr" VALUE="删除此用户信息" style="border: 1px solid #3466BB; background-color: #B6CAEB; color: #3466BB">
<INPUT TYPE="submit" NAME="Manager_Usr" VALUE="添加新用户信息" style="border: 1px solid #3466BB; background-color: #B6CAEB; color: #3466BB"></TD>
</TD></TR></table><br></FORM></body></html>
ENDTEXT
cHtml = cHtml + cHtmlEm + cHtmlEm1
else
use
cHtml = this.dlcw()
endif
RETURN cHtml
ENDFUNC
*****************************************************************************************************************
FUNCTION Smanager(u1 as string, p1 as string,Pm1 as String,Pm2 as String) as String
SET TEXTMERGE DELIMITERS TO "##","##"
LOCAL cResult as String, TheMessage as String
TheMessage = "请在下面填写新增用户的信息"
if allt(Pm2)="添加新用户信息"
cResult = this.AddUsr(u1,p1,TheMessage)
else
if empty(Pm1)
cResult = this.dlcw()
else
if allt(Pm2)="修改此用户信息"
cResult = this.ModUser(u1,p1,Pm1)
else
cResult = this.SystemEm(u1,p1,Pm1)
endif
endif
endif
IF !USED('userinfo')
USE userinfo IN 0
ENDIF
sele userinfo
go top
LOCATE FOR allt(user_id)==ALLT(u1) and ALLT(pass_word)==ALLT(p1) && 查询登录人员
if !found()
cResult = this.dlcw()
endif
use
RETURN cResult
ENDFUNC
**************************************************************************************
HIDDEN FUNCTION ModUser(u1 as string, p1 as string,PmSele as String) as String
SET TEXTMERGE DELIMITERS TO "##","##"
SET DELETED ON
LOCAL cResult as String, cResult1 as String, cDepart as String, cDepart0 as String, xm
cResult = ""
cDepart = ""
cResult1 = ""
cDepart0 = ""
IF !USED('departments') && 部门数据
USE departments IN 0
ENDIF
sele departments
go top
Do while not EOF()
TEXT TO cDepart0 TEXTMERGE noshow
<option value=##department##>##department##</option>
ENDTEXT
cDepart = cDepart + cDepart0
skip
Enddo
use
IF !USED('userinfo')
USE userinfo IN 0
ENDIF
sele userinfo
go top
Loca for allt(user_id)==ALLT(u1) and ALLT(pass_word)==ALLT(p1)
if found()
xm = allt(user_name)
go top
Loca for allt(user_id)==allt(PmSele)
TEXT TO cResult TEXTMERGE noshow
<HTML><HEAD><TITLE>管理员修改某个员工信息</TITLE>
<META NAME="Generator" CONTENT="NetObjects Fusion 2.0.2 for Windows"></HEAD>
<BODY BGCOLOR=""><table width=760 border=0 bgcolor=#164DA8 cellspacing=1 cellpadding=2 align=center>
<tr bgcolor=white><td valign=center ><img src="image/ASPLogo3.jpg" width=730 height=56></td></tr></table>
<table width="760" border="0" bordercolor="#164DA8" align="center" cellpadding="0" cellspacing="0">
<tr><td height="13"><img src="image/banner2.jpg" width="758" height="12"></td></tr></table><br>
<table width=760 border=0 bgcolor=#164DA8 cellspacing=1 cellpadding=2 align=center>
<tr><td colspan=3><font color=white><P ALIGN="CENTER">员工信息查询->系统管理员选项->修改某个员工信息 [当前用户-##xm##]</font></td></tr>
<tr bgcolor=white>
<td><a href="index.asp"><font color="#164DA8">返回到登录页面</font></a></td>
<td align=center> <font color="#164DA8" >请在下面修改此用户信息</FONT></td>
<td align=right><a href="javascript:history.back()"><font color="#164DA8">返回上一级网页</font></a></td></tr></table>
<table width="760" border="0" bordercolor="#164DA8" align="center" cellpadding="0" cellspacing="0">
<tr><td height="13"><img src="image\banner2.jpg" width="758" height="12"></td></tr></table>
<table width="760" border="0" bordercolor="#164DA8" align="center" cellpadding="3" cellspacing="0"><tr><td><br>
<FORM ACTION="ModifyUserInformation.asp" METHOD=POST>
<TABLE CELLPADDING=1 CELLSPACING=1 BORDER=1 bordercolor="#164DA8" WIDTH=760 align=center>
<TR VALIGN="center" ALIGN="center">
<TD WIDTH=30% bgcolor=#B5C7EF><img src="image\Employee.jpg"></td><td><br>
<table CELLPADDING=0 CELLSPACING=1 BORDER=1 align=center width=100%>
<tr><td width=25%><font color="#164DA8"> 登录名</font></td><td>##User_id##</td></tr>
<tr><td width=25%><font color="#164DA8"> 姓名</font></td><td><INPUT TYPE="text" NAME="UsrName" VALUE=##User_name## SIZE=51 MAXLENGTH=5 > *</td></tr>
<tr><td width=25%><font color="#164DA8"> 部门</font></td>
<td><SELECT NAME="DepartName" size=1 width=10>
<option value=##department##>##department##</option>
ENDTEXT
TEXT TO cResult1 TEXTMERGE noshow
</SELECT> *</td></tr>
<tr><td width=25%><font color="#164DA8"> 内线电话</font></td><td><INPUT TYPE="text" NAME="TELIN" VALUE=##telinside## SIZE=51 MAXLENGTH=3 > *</td></tr>
<tr><td width=25%><font color="#164DA8"> 外线电话</font></td><td><INPUT TYPE="text" NAME="TELOUT" VALUE=##teloutside## SIZE=51 MAXLENGTH=7 > *</td></tr>
<tr><td width=25%><font color="#164DA8"> 个人电话</font></td><td><INPUT TYPE="text" NAME="TELE" VALUE=##telephone## SIZE=51 MAXLENGTH=20 > *</td></tr>
<tr><td width=25%><font color="#164DA8"> QQ号</font></td><td><INPUT TYPE="text" NAME="QQ" VALUE=##QQ## SIZE=51 MAXLENGTH=15 > *</td></tr>
<tr><td width=25%><font color="#164DA8"> 电子邮箱</font></td><td><INPUT TYPE="text" NAME="EDRESS" VALUE=##EMAILDRESS## SIZE=51 MAXLENGTH=30 > *</td></tr>
<tr><td width=25%><font color="#164DA8"> 口令(1--8字符)</font></td><td><INPUT TYPE="password" NAME="Pw" VALUE=##pass_word## SIZE=51 MAXLENGTH=8 > *</td></tr>
<tr><td width=25%><font color="#164DA8"> 权限</font></td><td><INPUT TYPE="text" NAME="Qx" VALUE=##user_power## SIZE=51 MAXLENGTH=20 > *</td></tr>
</table><br></td></TR></table>
<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=1 WIDTH=760 align=center>
<TR VALIGN="top" ALIGN="center"><TD WIDTH=100% align=center >
<INPUT TYPE="submit" NAME="ModUsrInfo" VALUE="确认修改此用户信息" style="border: 1px solid #3466BB; background-color: #B6CAEB; color: #3466BB">
</TD></TR></table></FORM></body></html>
ENDTEXT
use
cResult = cResult + cDepart + cResult1
else
use
cResult = this.dlcw()
endif
RETURN cResult
ENDFUNC
**************************************************************************************
FUNCTION ModUsrResult(u1 as string, p1 as string,Pm1 as String,Pm2 as String,Pm3 as String,Pm4 as String,Pm5 as String,Pm6 as String,Pm7 as String,Pm8 as String,Pm9 as String,Pm10 as String) as String
SET TEXTMERGE DELIMITERS TO "##","##"
SET DELETED ON
LOCAL cResult as String, cResult1 as String, cDepart as String, cDepart0 as String, xm
cResult = ""
cDepart = ""
cResult1 = ""
cDepart0 = ""
LenAll = len(allt(Pm2))*len(allt(Pm3))*len(allt(Pm4))*len(allt(Pm5))*len(allt(Pm6))*len(allt(Pm7))*len(allt(Pm8))*len(allt(Pm9))*len(allt(Pm10))
IF !USED('userinfo')
USE userinfo IN 0
ENDIF
sele userinfo
go top
LOCATE FOR allt(user_id)==ALLT(u1) and ALLT(pass_word)==ALLT(p1)
xm = allt(user_name)
go top
LOCATE FOR allt(user_id)==allt(Pm1)
if LenAll>0 and found()
repl user_name with allt(Pm2),department with allt(Pm3),telinside with allt(Pm4),;
teloutside with allt(Pm5),telephone with allt(Pm6),qq with allt(Pm7),;
EMAILDRESS with allt(Pm8),pass_word with allt(Pm9),user_power with allt(Pm10)
use
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -