Web课程设计Word下载.docx

上传人:b****4 文档编号:16367138 上传时间:2022-11-23 格式:DOCX 页数:58 大小:2.38MB
下载 相关 举报
Web课程设计Word下载.docx_第1页
第1页 / 共58页
Web课程设计Word下载.docx_第2页
第2页 / 共58页
Web课程设计Word下载.docx_第3页
第3页 / 共58页
Web课程设计Word下载.docx_第4页
第4页 / 共58页
Web课程设计Word下载.docx_第5页
第5页 / 共58页
点击查看更多>>
下载资源
资源描述

Web课程设计Word下载.docx

《Web课程设计Word下载.docx》由会员分享,可在线阅读,更多相关《Web课程设计Word下载.docx(58页珍藏版)》请在冰豆网上搜索。

Web课程设计Word下载.docx

不同的用户拥有不同的权限,各自完成各自的管理功能,不同的用户看到不同的系统功能。

用Sqlserver2000创建后台数据库,然后利用JSP技术编写程序实现对数据库的操作,按照要求完成所有的功能和模块。

职工的主要功能模块包括:

(1)职工注册与登录

(2)职工岗位工资信息查询

(3)职工留言板

人事管理员的主要功能模板包括:

(1)工资信息的查询、添加、更新

(2)职工个人工资信息的更新和维护

(3)留言板管理

2.主要数据库表单

(1)职工基本信息表单

主要字段有:

职工号、姓名、性别、出生日期、岗位编号、工作年限

(2)岗位信息表单

岗位编号、岗位名称、岗位基本工资、岗位津贴、特殊津贴、月工资(岗位工资+岗位工资+岗位津贴+特殊津贴)、养老保险(月工资*8%)、医疗保险(月工资*6%)、失业保险(月工资*1%)

第2章系统功能模块设计

第3章数据库设计

3.1职工基本信息表worker

3.2岗位信息表单Job

3.3所有员工工资记录表Allwage

第4章各功能模块的程序设计及运行测试结果

4.1职工功能模块

4.1.1职工的注册与登陆

程序设计代码:

//登录

<

linkrel="

stylesheet"

type="

text/css"

href="

style.css"

/>

/head>

bodyonload="

a()"

>

h1>

palign="

center"

big>

企业职工工资在线管理信息系统<

/big>

/p>

/h1>

p>

br>

divclass="

login"

<

login-top"

登录<

<

formid="

form1"

name="

method="

post"

action="

Servlet1"

>

<

inputtype="

text"

user"

value="

id="

onfocus="

this.value='

'

;

"

onblur="

if(this.value=='

){this.value='

UserId'

}"

password"

value="

password'

forgot"

submit"

登陆"

onclick="

tsubmit()"

inputname="

radio"

radio1"

checked="

checked"

/>

职工

radio2"

管理员

/form>

/div>

login-bottom"

h3>

ahref="

register.jsp"

在这里注册?

/a>

/h3>

/body>

scriptlanguage="

javascript"

functiontsubmit(){

varmyForm=document.getElementById("

);

varuserName=document.getElementById("

).value;

varpassword=document.getElementById("

varregPassWord=/^[a-zA-Z0-9]+$/;

if(userName.length>

8){

alert("

请填写正确的用户名!

(最长8位)"

document.getElementById("

userName"

).value="

).focus();

}

elseif(!

regPassWord.test(password)||password.lenth>

16||password.length<

4){

请填写正确的用户名密码!

(4-16位的数字或字母)"

}else{

//myForm.action="

login.jsp"

myForm.submit();

//注册

body>

dataEye"

loginboxregistbox"

login-contentreg-content"

loginbox-title"

<

注册<

signupForm"

Servlet2"

login-error"

row"

placeholder="

用户名"

class="

input-text-usernoPicinput-click"

required>

密码"

input-text-passwordnoPicinput-click"

passwordAgain"

确认密码"

name"

姓名"

tel"

联系电话"

rowtips"

checkbox"

checkBox"

label>

我已阅读并同意

#"

target="

_blank"

隐私政策、服务条款<

/label>

rowbtnArea"

button"

login-btn"

注册"

checkForm()"

go-regist"

已有帐号,请<

link"

scripttype='

text/javaScript'

functioncheckForm(){

varb=true;

varmyForm=document.getElementById("

varuserName=document.getElementById("

varpassword=document.getElementById("

varAgainPassword=document.getElementById("

varName=document.getElementById("

varregPassWord=/^[a-zA-Z0-9]+$/;

if(userName.length>

8||!

userName){

alert("

用户名为空或用户名格式错误(最长8位)"

document.getElementById("

b=false;

}

elseif(!

alert("

密码为空或请用户密码格式错误(4-16位的数字或字母)"

document.getElementById("

b=false;

elseif(password!

=AgainPassword){

您两次输入的密码不一样,请重新输入!

b=false;

Name){

姓名不能為空!

b=false;

if(b){

注册成功!

myForm.submit();

}

}

/script>

/html>

//Servlet

@WebServlet("

/Servlet2"

publicclassServlet2extendsHttpServlet{

privatestaticfinallongserialVersionUID=1L;

/**

*@seeHttpServlet#HttpServlet()

*/

publicServlet2(){

super();

//TODOAuto-generatedconstructorstub

*@seeHttpServlet#doGet(HttpServletRequestrequest,HttpServletResponseresponse)

protectedvoiddoGet(HttpServletRequestrequest,HttpServletResponseresponse)throwsServletException,IOException{

//TODOAuto-generatedmethodstub

request.setCharacterEncoding("

UTF-8"

response.setContentType("

text/html;

charset=utf-8"

InsertInformationdata=newInsertInformation();

SelectInformationnum=newSelectInformation();

Stringuser=request.getParameter("

Stringpassword=request.getParameter("

StringpasswordAgain=request.getParameter("

Stringname=request.getParameter("

Stringtel=request.getParameter("

if(data.InsertData(num.Length(),user,password,passwordAgain,name,tel)==true){

request.getRequestDispatcher("

/login.jsp"

).forward(request,response);

}

else

RegisterFail.jsp"

*@seeHttpServlet#doPost(HttpServletRequestrequest,HttpServletResponseresponse)

protectedvoiddoPost(HttpServletRequestrequest,HttpServletResponseresponse)throwsServletException,IOException{

doGet(request,response);

}

4.1.2职工岗位工资信息查询

session()"

center>

职工岗位工资信息查询<

/br>

返回主菜单"

ons8()"

style="

background-color:

transparent"

查看留言板"

ons9()"

/center>

divalign="

tableborder="

0"

trwidth="

50px"

bycolor="

#00ffff"

tdwidth="

70px"

height="

岗位编号<

/td>

td>

岗位名称<

岗位基本工资<

岗位津贴<

月工资<

养老保险<

医疗保险<

失业保险<

/tr>

%Stringstr[][]=newString[100][100];

str=(String[][])request.getAttribute("

str"

for(inti=1;

i<

=10;

i++){

out.print("

tr>

if(str[i][1]==null)

break;

for(intj=1;

j<

=8;

j++){%>

%=str[i][j]%>

%}

out.print("

%>

/table>

scriptlang

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 教学研究 > 教学案例设计

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1