• 大小: 23.49MB
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2023-07-06
  • 语言: 其他
  • 标签:

资源简介

基于web的文档管理系统,使用了ssh三大架构,可以作为毕业设计直接使用。

资源截图

代码片段和文件信息

package cn.ujn.action;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts2.interceptor.ServletRequestAware;
import org.hibernate.Query;

import cn.ujn.dao.AccountDAO;
import cn.ujn.model.Account;

import com.opensymphony.xwork2.ActionSupport;
import common.Constants;

public class AccountManageAction extends ActionSupport implements ServletRequestAware {
private HttpServletRequest request;
private Account account;
private AccountDAO aDao;
private Constants constants;

public Constants getConstants() {
return constants;
}
public void setConstants(Constants constants) {
this.constants = constants;
}
public String init(){
try {
constants.session.clear();
String hql=“from Account a where a.accountName=? “;
Query query=constants.session.createQuery(hql);
query.setParameter(0 constants.getAccount().getAccountName());
Account a=(Account)query.list().get(0);
request.setAttribute(“account“ a);
} catch (Exception e) {
request.setAttribute(“message“ e.getMessage());
}
return “showAccount“;
}
public String modify(){
try {
String hql=“update Account a set a.accountPassword=? where a.accountName=?“;
Query query=constants.session.createQuery(hql);
query.setParameter(0 account.getAccountPassword());
query.setParameter(1 constants.getAccount().getAccountName());
query.executeUpdate();
constants.session.beginTransaction().commit();
request.setAttribute(“message“ “修改密码成功“);
} catch (Exception e) {
request.setAttribute(“message“ e.getMessage());
}
return “showAccount“;
}

public Account getAccount() {
return account;
}
public void setAccount(Account account) {
this.account = account;
}
public AccountDAO getaDao() {
return aDao;
}
public void setaDao(AccountDAO aDao) {
this.aDao = aDao;
}
public void setServletRequest(HttpServletRequest request) {
this.request = request;
}

}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件       6439  2012-02-02 09:38  jes\.classpath

     文件        579  2011-12-23 11:32  jes\.myhibernatedata

     文件        282  2012-02-02 09:38  jes\.mymetadata

     文件        240  2011-12-17 20:40  jes\.mystrutsdata

     文件       2106  2012-02-02 09:38  jes\.project

     文件        500  2012-02-02 09:38  jes\.settings\.jsdtscope

     文件        395  2012-02-02 09:38  jes\.settings\org.eclipse.jdt.core.prefs

     文件        447  2012-02-02 09:38  jes\.settings\org.eclipse.wst.common.component

     文件        252  2012-02-02 09:38  jes\.settings\org.eclipse.wst.common.project.facet.core.xml

     文件         49  2012-02-02 09:38  jes\.settings\org.eclipse.wst.jsdt.ui.superType.container

     文件          6  2012-02-02 09:38  jes\.settings\org.eclipse.wst.jsdt.ui.superType.name

     文件        462  2011-12-17 20:42  jes\.springBeans

     文件       3936  2011-12-22 20:59  jes\src\.struts.mex

     文件       5892  2011-12-23 15:38  jes\src\applicationContext.xml

     文件       1989  2011-12-22 21:28  jes\src\cn\ujn\action\AccountManageAction.java

     文件       4661  2011-12-23 16:07  jes\src\cn\ujn\action\ApplicantManageAction.java

     文件       8478  2011-12-20 12:47  jes\src\cn\ujn\action\BatchManageAction.java

     文件       4698  2011-12-23 12:24  jes\src\cn\ujn\action\DistributionManageAction.java

     文件       6771  2011-12-21 10:16  jes\src\cn\ujn\action\ExpertManageAction.java

     文件       3503  2011-12-23 15:31  jes\src\cn\ujn\action\LoginAction.java

     文件       6839  2011-12-21 19:24  jes\src\cn\ujn\action\QuotaManageAction.java

     文件       5477  2011-12-23 13:34  jes\src\cn\ujn\action\ReviewManageAction.java

     文件       1126  2011-12-22 19:12  jes\src\cn\ujn\dao\Account.hbm.xml

     文件       4384  2011-12-22 19:12  jes\src\cn\ujn\dao\AccountDAO.java

     文件       3329  2011-12-23 15:29  jes\src\cn\ujn\dao\Applicant.hbm.xml

     文件       6089  2011-12-20 11:20  jes\src\cn\ujn\dao\ApplicantDAO.java

     文件       1511  2011-12-19 18:16  jes\src\cn\ujn\dao\Batch.hbm.xml

     文件       4228  2011-12-19 18:16  jes\src\cn\ujn\dao\BatchDAO.java

     文件       1403  2011-12-23 11:33  jes\src\cn\ujn\dao\ExceptApplicant.hbm.xml

     文件       4802  2011-12-23 11:34  jes\src\cn\ujn\dao\ExceptApplicantDAO.java

............此处省略196个文件信息

评论

共有 条评论

相关资源