• 大小: 18.16MB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-07-08
  • 语言: Java
  • 标签:

资源简介

哈工大javaee大作业,学生信息管理系统。应用了SSH框架

资源截图

代码片段和文件信息

package action;

import java.util.ArrayList;
import java.util.List;

import service.Service;

import com.opensymphony.xwork2.ActionContext;
import com.opensymphony.xwork2.ActionSupport;
import com.sun.org.apache.regexp.internal.recompile;

import entity.Student;

public class AdminAction extends ActionSupport {

private ArrayList students = new ArrayList();
private ArrayList find = new ArrayList();
private ArrayList noRight = new ArrayList();
private ArrayList max = new ArrayList();
private ArrayList min = new ArrayList();
private String findnum;
private String username;
private String password;
private String avgPoint;
private String stuNum;
private String name;
private String sex;
private String point;
private String address;
private String findkey;
private Student student;
private String findtype;
private Service service;
private String className;
private String classNum;
private String classTeach;
private String findClass;

private ArrayList classes = new ArrayList();

public String Login() {

int ret = service.Login(username password);
if (ret==1) {
ActionContext.getContext().getSession().put(“findClass“ “1“);
return “AdminLoginOk“;
}
else if (ret==2) {
return “StuLoginOk“;
}
else{
return “LoginError“;
}


}

public String queryAll() {
ActionContext.getContext().getSession().put(“findClass“findClass);
avgPoint = service.queryAll(findClassstudents max min avgPoint noRight);
return “ok“;
}

public String queryMan() {
findClass = ActionContext.getContext().getSession().get(“findClass“)+““;
avgPoint = service.queryMan(findClassstudents max min avgPoint noRight);
return “ok“;
}

public String queryWoman() {
findClass = ActionContext.getContext().getSession().get(“findClass“)+““;
avgPoint = service.queryWoman(findClassstudents max min avgPoint noRight);
return “ok“;
}

public String Add() {

findClass = ActionContext.getContext().getSession().get(“findClass“)+““;
if(service.Add(findClassstuNum name sex pointaddress)){
return “ok2“;
}else{
return “AddError“;
}


}

public String Alter() {
findClass = ActionContext.getContext().getSession().get(“findClass“)+““;
service.Alter(findClassstuNum name sex pointaddressfindnum);
return “ok2“;
}

public String Delete() {
findClass = ActionContext.getContext().getSession().get(“findClass“)+““;
findClass = ActionContext.getContext().getSession().get(“findClass“)+““;
service.Delete(findClassfindnum);
return “ok2“;
}

public String find() {
findClass = ActionContext.getContext().getSession().get(“findClass“)+““;
findClass = ActionContext.getContext().getSession().get(“findClass“)+““;
service.find(findClassfindkeyfindtype find);
return “FindOk“;
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2017-04-28 19:31  homework3\
     文件        4234  2017-04-21 23:56  homework3\.classpath
     文件        1042  2017-04-28 19:31  homework3\.project
     目录           0  2017-04-28 19:31  homework3\.settings\
     文件         503  2017-04-03 20:18  homework3\.settings\.jsdtscope
     文件         364  2017-04-03 20:18  homework3\.settings\org.eclipse.jdt.core.prefs
     文件         479  2017-04-03 20:18  homework3\.settings\org.eclipse.wst.common.component
     文件         345  2017-04-03 20:18  homework3\.settings\org.eclipse.wst.common.project.facet.core.xml
     文件          49  2017-04-03 20:18  homework3\.settings\org.eclipse.wst.jsdt.ui.superType.container
     文件           6  2017-04-03 20:18  homework3\.settings\org.eclipse.wst.jsdt.ui.superType.name
     目录           0  2017-04-28 19:31  homework3\build\
     目录           0  2017-04-28 23:15  homework3\build\classes\
     目录           0  2017-04-28 19:31  homework3\build\classes\action\
     文件        8801  2017-04-28 21:04  homework3\build\classes\action\AdminAction.class
     文件        3332  2017-04-28 19:31  homework3\build\classes\action\StudentAction.class
     文件         552  2017-04-28 20:06  homework3\build\classes\class.hbm.xml
     目录           0  2017-04-28 19:31  homework3\build\classes\dao\
     文件        1730  2017-04-28 21:07  homework3\build\classes\dao\DAO.class
     文件       10950  2017-04-28 21:20  homework3\build\classes\dao\DAOImpl.class
     目录           0  2017-04-28 23:08  homework3\build\classes\entity\
     文件        1159  2017-04-28 20:03  homework3\build\classes\entity\Class.class
     文件        1211  2017-04-28 23:15  homework3\build\classes\entity\selectClass.class
     文件        2596  2017-04-28 19:31  homework3\build\classes\entity\Student.class
     文件         578  2017-04-28 23:15  homework3\build\classes\selectClass.hbm.xml
     目录           0  2017-04-28 23:47  homework3\build\classes\service\
     文件        2023  2017-04-28 23:47  homework3\build\classes\service\applicationContext.xml
     文件        1742  2017-04-28 21:04  homework3\build\classes\service\Service.class
     文件        5279  2017-04-28 21:07  homework3\build\classes\service\ServiceImpl.class
     文件        1836  2017-04-28 20:23  homework3\build\classes\struts.xml
     文件         861  2017-04-28 20:04  homework3\build\classes\student.hbm.xml
     目录           0  2017-04-28 23:07  homework3\src\
............此处省略81个文件信息

评论

共有 条评论