项目个人总结报告Word文件下载.doc
《项目个人总结报告Word文件下载.doc》由会员分享,可在线阅读,更多相关《项目个人总结报告Word文件下载.doc(12页珍藏版)》请在冰豆网上搜索。
(1-1)系统登录图
(1-2)系统主界面
(1-3)图书借阅
(1-4)图书归还
(1-5)添加图书
(1-6)删除图书
(1-7)修改图书信息
(1-8)新办借阅证
(1-9)补办借阅证
(1-10)图书查询
二、个人在项目中承担的任务:
我在项目中承担了GUI工程师,和编码人员的工作。
在GUI设计中我参考了部分网络上的图书馆管理软件界面。
并且根据用户提出的要求设计出了我们自己项目的GUI图:
如图(1-1)-图(1-10)
另外我还在项目中担当了编码人员的工作。
在代码的编写阶段
我根据GUI设计和设计人员提交的图书管理系统流程图等图编写了该系统的实现代码:
下面是该系统的主要功能代码:
登录代码:
UserLoginProcessb=newUserLoginProcess();
Stringuname=jTextField0.getText();
Stringupass=jpassword.getText();
if(b.login_check(uname,upass)){
newSysMain();
dispose();
}else{
JOptionPane.showMessageDialog(null,"
账号密码错误"
);
}
}
privatevoidjButton1ActionActionPerformed(ActionEventevent){
dispose();
图书借阅代码:
publicvoidactionPerformed(java.awt.event.ActionEvente){
System.out.println("
lending"
//TODOAuto-generatedEvent
//stubactionPerformed()
Stringsid=jTextField.getText();
Stringbid=jTextField1.getText();
BookDAObook=newBookDAO();
BorrowRegistrationDAOborrow=newBorrowRegistrationDAO();
StudentDAOstu=newStudentDAO();
System.out.print(sid);
System.out.print(book.getBookByID(bid).getBook_id());
if((stu.getStudentByID(sid).getStudent_id()!
=0)
&
&
(book.getBookByID(bid).getBook_id()!
=0)){
if(!
book.getBookByID(bid).getBook_state().equals(
"
借出未还"
)){
BorrowViewb=borrow.insertBorrowInfor(bid,sid);
jLabel6.setText(b.getBookname());
jLabel7.setText(b.getBookISBN());
jLabel8.setText(b.getBorrowdate());
jLabel9.setText(b.getReturndate());
book.modifyBookState("
bid);
}else{
JOptionPane.showMessageDialog(null,"
此书已经借出,不可再借!
"
}
}else{
JOptionPane
.showMessageDialog(null,"
输入的借阅证编号或图书编号不正确!
}
}
});
图书归还代码:
actionPerformed()"
//TODO
//Auto-generated
//Eventstub
//actionPerformed()
BorrowRegistrationDAObdao=newBorrowRegistrationDAO();
Stringbid=jTextField.getText();
if(bdao.deleteBorrowInfo(bid)){
JOptionPane.showMessageDialog(null,"
归还成功!
BookDAObook=newBookDAO();
book.modifyBookState("
在库可借"
bid);
};
图书添加代码:
privatevoidjButton0ActionActionPerformed(ActionEventevent){
b=newBook();
b.setBook_name(jTextField0.getText());
b.setISBN(jTextField1.getText());
b.setBook_author(jTextField2.getText());
b.setBook_pub(jTextField3.getText());
b.setBook_date(jTextField4.getText());
b.setBook_price(jTextField5.getText());
b.setBook_page(Integer.parseInt(jTextField6.getText()));
b.setBook_state(jTextField7.getText());
BookDAOb1=newBookDAO();
b1.insertBook(b);
图书修改代码:
Bookb=newBook();
b.setBook_name(jTextField1.getText());
b.setISBN(jTextField2.getText());
b.setBook_author(jTextField3.getText());
b.setBook_pub(jTextField4.getText());
b.setBook_date(jTextField7.getText());
b.setBook_type(jTextField8.getText());
BookDAOb2=newBookDAO();
b.setBook_id(Integer.parseInt(jTextField0.getText()));
b.setBook_state(jTextField9.getText());
b2.modifyBook(b);
JOptionPane.showMessageDialog(null,"
修改成功"
图书删除代码:
BookDAOb=newBookDAO();
b.deletBook(jTextField0.getText());
删除成功"
新办借阅证代码:
s=newStudent();
s.setStudent_class(jTextField2.getText());
s.setStudent_name(jTextField1.getText());
s.setStudent_num(jTextField0.getText());
s.setStudent_subject(jTextField3.getText());
if(jRadioButton0.isSelected())
sex="
男"
;
else
sex="
女"
s.setStudent_sex(sex);
StudentDAOs1=newStudentDAO();
s1.insertStudent(s);
补办借阅证代码:
StudentDAOs=newStudentDAO();
newstu=s.insertStudent(s1);
newid=newstu.getStudent_id()+"
Stringsql="
update借阅视图set学生_ID='
+newid+"
'
where学生_ID='
+oldsid+"
try{
stmt=conn.getconnection().createStatement();
stmt.executeUpdate(sql);
s.delStudent(oldsid);
}catch(Exceptione){
e.printStackTrace();
已经补办成功,您的新借阅号是"
Stringsql1="
select*from借阅视图where学生_ID="
+newid;
conn=newDBConnection();
try{
rs=stmt.executeQuery(sql1);
tableModel=getTableModel(rs);
jTa