当前位置:   article > 正文

基于Javaweb实现的人脸识别考勤系统_人脸识别系统后台如何进入

人脸识别系统后台如何进入

 

人脸识别考勤系统使用说明书

此系统是人脸识别考勤系统的后台管理系统,考勤数据从人脸识别机器上获取,自动识别员工信息记录考勤。系统基于JSP/SERVLET来开发实现,开发工具采用IDEA或ECLIPSE,数据库采用MYSQL数据库。Util包中jdbcinfo.properties文件进行数据库连接的相关配置修改。

访问路径为:faceattendsystem为发布的虚拟目录

1. 进入主页,点击未登录。如下图:

2. 输入工号和密码,点击【登录】按钮。管理员默认工号是admin,密码是111111。如下图:

3. 登录成功后,进入后台管理页面。如下图:

4. 点击【机构管理】,进入机构详情页面。该页面可添加机构、搜索机构、修改机构、删除机构和设置机构的作息管理。

5. 点击【添加机构】按钮,进入添加机构页面。根据文本框提示的信息进行输入信息,点击【添加】按钮。(*是必填项)如下图:

6. 添加成功后,输入1111,点击【搜索】按钮。如下图:

7. 点击【修改】,进入修改机构页面。修改信息后,点击【修改】按钮。(机构号不能修改)如下图:

8. 点击【删除】,删除该机构。

9. 点击【作息管理】,进入作息时间页面。该页面可添加作息和搜索日期。如下图:

10. 点击【添加作息】,进入添加作息页面。根据文本框提示输入信息,点击【添加】按钮。如下图:

11. 添加成功后,输入2017-12-05,点击【搜索】按钮。如下图:

12. 点击【员工管理】,进入查询员工页面。选择刚添加的机构,点击【查询】按钮。如下图:

13. 查询成功后,进入员工信息页面。该页面可添加员工、搜索员工、修改员工和删除员工。如下图:

14. 点击【添加员工】按钮,进入添加员工页面。根据文本框的提示输入信息,点击【添加】按钮。如下图:

15. 添加员工成功后,在搜索框输入2222,点击【搜索】按钮。如下图:

16. 点击【详情】,进入员工详情页面。如下图:

17. 点击【修改】,进入员工修改页面。修改信息后,点击【修改】按钮。如下图:

18. 点击【删除】,删除该员工。

19. 点击【节假日管理】,进入节假日页面。该页面可添加节假日和搜索日期。如下图:

20. 点击【添加节假日】按钮,进入添加节假日页面。根据文本框提示输入信息,点击【添加】按钮。如下图:

21. 添加成功后,在搜索框输入2018-01-01,点击【搜索】按钮。如下图:

22. 点击【考勤管理】,进入查询考勤页面。如下图:

23. 点击【存在异常日期,点击查看详情】,进入异常日期页面。点击【开始统计】,则服务器会跑当前的日期的考勤。如下图:

24. 若根据文本框提示输入信息,选择异常,点击【查询】按钮。进入异常的考勤统计页面。如下图:

25. 若要把查询数据导出,则点击【导出excel】按钮。如下图:

25. 若根据文本框提示输入信息,选择流水,点击【查询】按钮。如下图:

26. 进入流水的考勤统计页面。如下图:

27. 点击【修改密码】,进入修改密码页面。根据文本框提示输入信息后,点击【修改】按钮。如下图:

以上是基于人脸识别的考勤系统的说明

  1. package faceattendsystem.serviceImpl;
  2. import java.sql.Date;
  3. import java.util.List;
  4. import faceattendsystem.dao.IDaytimeDao;
  5. import faceattendsystem.dao.IMechanismDao;
  6. import faceattendsystem.daoImpl.DaytimeDaoImpl;
  7. import faceattendsystem.daoImpl.MechanismDaoImpl;
  8. import faceattendsystem.entity.Daytime;
  9. import faceattendsystem.entity.PageBean;
  10. import faceattendsystem.service.IDaytimeService;
  11. public class DaytimeServiceImpl implements IDaytimeService {
  12. private IDaytimeDao daytimeDao = new DaytimeDaoImpl();
  13. private IMechanismDao mechanismDao = new MechanismDaoImpl();
  14. @Override
  15. public int add(Daytime daytime) {
  16. return daytimeDao.add(daytime);
  17. }
  18. @Override
  19. public int update(Daytime daytime) {
  20. return daytimeDao.update(daytime);
  21. }
  22. @Override
  23. public PageBean<Daytime> queryByMechid(String mechid, int pc, int ps) {
  24. PageBean<Daytime> pb =daytimeDao.queryByMechid(mechid, pc, ps);
  25. List<Daytime> daytimeList = pb.getBeanList();
  26. for(Daytime daytime:daytimeList){
  27. daytime.setMechanism(mechanismDao.queryByMechid(mechid));
  28. daytime.setBegintime(getRealTime(daytime.getBegintime()));
  29. daytime.setEndtime(getRealTime(daytime.getEndtime()));
  30. }
  31. return pb;
  32. }
  33. private String getRealTime(String time){
  34. while(time.length()<6){
  35. time = "0"+time;
  36. }
  37. time = time.substring(0,2)+":"+time.substring(2,4)+":"+time.substring(4,6);
  38. return time;
  39. }
  40. @Override
  41. public int isRepeatDate(Daytime daytime) {
  42. return daytimeDao.isRepeatDate(daytime);
  43. }
  44. @Override
  45. public Daytime queryByMechid(String mechid, Date nowdate) {
  46. Daytime daytime = daytimeDao.queryByMechid(mechid, nowdate);
  47. daytime.setMechanism(mechanismDao.queryByMechid(mechid));
  48. return daytime;
  49. }
  50. @Override
  51. public PageBean<Daytime> query(Daytime daytime, int pc, int ps) {
  52. PageBean<Daytime> pb =daytimeDao.query(daytime, pc, ps);
  53. List<Daytime> daytimeList = pb.getBeanList();
  54. for(Daytime d:daytimeList){
  55. d.setMechanism(mechanismDao.queryByMechid(d.getMechanism().getMechid()));
  56. d.setBegintime(getRealTime(d.getBegintime()));
  57. d.setEndtime(getRealTime(d.getEndtime()));
  58. }
  59. return pb;
  60. }
  61. }

  1. package faceattendsystem.serviceImpl;
  2. import java.util.List;
  3. import faceattendsystem.dao.IEmployeeDao;
  4. import faceattendsystem.dao.IMechanismDao;
  5. import faceattendsystem.daoImpl.EmployeeDaoImpl;
  6. import faceattendsystem.daoImpl.MechanismDaoImpl;
  7. import faceattendsystem.entity.Employee;
  8. import faceattendsystem.entity.Mechanism;
  9. import faceattendsystem.entity.PageBean;
  10. import faceattendsystem.service.IEmployeeService;
  11. public class EmployeeServiceImpl implements IEmployeeService {
  12. private IEmployeeDao employeeDao = new EmployeeDaoImpl();
  13. private IMechanismDao mechanismDao = new MechanismDaoImpl();
  14. @Override
  15. public int add(Employee employee) {
  16. return employeeDao.add(employee);
  17. }
  18. @Override
  19. public int delete(String empid) {
  20. return employeeDao.delete(empid);
  21. }
  22. @Override
  23. public int update(Employee employee) {
  24. return employeeDao.update(employee);
  25. }
  26. @Override
  27. public int updatePw(String empid,String npw) {
  28. return employeeDao.updatePw(empid,npw);
  29. }
  30. @Override
  31. public Employee queryByEmpid(String empid) {
  32. Employee employee = employeeDao.queryByEmpid(empid);
  33. employee.setMechanism(mechanismDao.queryByMechid(employee.getMechanism().getMechid()));
  34. return employee;
  35. }
  36. @Override
  37. public PageBean<Employee> queryByMechid(String mechid, int pc, int ps) {
  38. return employeeDao.queryByMechid(mechid, pc, ps);
  39. }
  40. @Override
  41. public List<Employee> queryAll() {
  42. return employeeDao.queryAll();
  43. }
  44. @Override
  45. public PageBean<Employee> query(Employee employee, int pc, int ps) {
  46. PageBean<Employee> pb = employeeDao.query(employee,pc,ps);
  47. List<Employee> employeeList = pb.getBeanList();
  48. for(Employee e : employeeList){
  49. e.setMechanism(mechanismDao.queryByMechid(e.getMechanism().getMechid()));
  50. }
  51. pb.setBeanList(employeeList);
  52. return pb;
  53. }
  54. @Override
  55. public List<Employee> queryByMechid(String mechid) {
  56. List<Employee> employeeList = employeeDao.queryByMechid(mechid);
  57. for(Employee emp : employeeList){
  58. Mechanism mechanism = mechanismDao.queryByMechid(emp.getMechanism().getMechid());
  59. emp.setMechanism(mechanism);
  60. }
  61. return employeeList;
  62. }
  63. @Override
  64. public boolean isRepeatEmpid(String empid) {
  65. Employee employee = employeeDao.queryByEmpid(empid);
  66. return employee!=null?true:false;
  67. }
  68. @Override
  69. public Employee isEmployee(String empid) {
  70. Employee employee = employeeDao.queryByEmpid(empid);
  71. if(employee!=null){
  72. employee.setMechanism(mechanismDao.queryByMechid(employee.getMechanism().getMechid()));
  73. }
  74. return employee;
  75. }
  76. @Override
  77. public Employee isRepeatIdnumber(String idnumber) {
  78. return employeeDao.queryByIdnumber(idnumber);
  79. }
  80. }

  1. package faceattendsystem.serviceImpl;
  2. import java.util.List;
  3. import faceattendsystem.dao.IEmployeeDao;
  4. import faceattendsystem.dao.IErrorsheetDao;
  5. import faceattendsystem.dao.IMechanismDao;
  6. import faceattendsystem.daoImpl.EmployeeDaoImpl;
  7. import faceattendsystem.daoImpl.ErrorsheetDaoImpl;
  8. import faceattendsystem.daoImpl.MechanismDaoImpl;
  9. import faceattendsystem.entity.Errorsheet;
  10. import faceattendsystem.entity.PageBean;
  11. import faceattendsystem.service.IErrorsheetService;
  12. public class ErrorsheetServiceImpl implements IErrorsheetService {
  13. IErrorsheetDao errorsheetDao = new ErrorsheetDaoImpl();
  14. IMechanismDao mechanismDao = new MechanismDaoImpl();
  15. IEmployeeDao employeeDao = new EmployeeDaoImpl();
  16. @Override
  17. public PageBean<Errorsheet> query(Errorsheet errorsheet, String bdate, String edate, int pc, int ps) {
  18. PageBean<Errorsheet> pb = errorsheetDao.query(errorsheet, bdate, edate, pc, ps);
  19. List<Errorsheet> errorsheetList = pb.getBeanList();
  20. for (Errorsheet e : errorsheetList) {
  21. e.setMechanism(mechanismDao.queryByMechid(e.getMechanism().getMechid()));
  22. e.setEmployee(employeeDao.queryByEmpid(e.getEmployee().getEmpid()));
  23. }
  24. pb.setBeanList(errorsheetList);
  25. return pb;
  26. }
  27. @Override
  28. public int add(Errorsheet errorsheet) {
  29. return errorsheetDao.add(errorsheet);
  30. }
  31. @Override
  32. public List<Errorsheet> queryAll() {
  33. return errorsheetDao.queryAll();
  34. }
  35. @Override
  36. public PageBean<Errorsheet> queryAll(Errorsheet errorsheet, String bdate, String edate) {
  37. PageBean<Errorsheet> pb = errorsheetDao.queryAll(errorsheet, bdate, edate);
  38. List<Errorsheet> errorsheetList = pb.getBeanList();
  39. for (Errorsheet e : errorsheetList) {
  40. e.setMechanism(mechanismDao.queryByMechid(e.getMechanism().getMechid()));
  41. e.setEmployee(employeeDao.queryByEmpid(e.getEmployee().getEmpid()));
  42. }
  43. pb.setBeanList(errorsheetList);
  44. return pb;
  45. }
  46. }

  1. package faceattendsystem.serviceImpl;
  2. import java.sql.Date;
  3. import java.util.List;
  4. import faceattendsystem.dao.IEmployeeDao;
  5. import faceattendsystem.dao.IFlowsheetDao;
  6. import faceattendsystem.daoImpl.EmployeeDaoImpl;
  7. import faceattendsystem.daoImpl.FlowsheetDaoImpl;
  8. import faceattendsystem.entity.Employee;
  9. import faceattendsystem.entity.Flowsheet;
  10. import faceattendsystem.entity.PageBean;
  11. import faceattendsystem.service.IFlowsheetService;
  12. public class FlowsheetServiceImpl implements IFlowsheetService {
  13. IFlowsheetDao flowsheetDao = new FlowsheetDaoImpl();
  14. IEmployeeDao employeeDao = new EmployeeDaoImpl();
  15. @Override
  16. public List<Flowsheet> query(Date date, String empid) {
  17. return flowsheetDao.query(date,empid);
  18. }
  19. @Override
  20. public Date getMindate(Employee employee) {
  21. return flowsheetDao.getMindate(employee);
  22. }
  23. @Override
  24. public PageBean<Flowsheet> query(String empid, String bdate, String edate, int pc, int ps) {
  25. PageBean<Flowsheet> pb = flowsheetDao.query(empid,bdate,edate,pc,ps);
  26. List<Flowsheet> flowsheetList = pb.getBeanList();
  27. for(Flowsheet fs:flowsheetList){
  28. fs.setEmployee(employeeDao.queryByEmpid(fs.getEmployee().getEmpid()));
  29. fs.setLogtime(getRealTime(fs.getLogtime()));
  30. fs.setClientdatetime(getDatetime(fs.getClientdatetime()));
  31. //fs.setSimilarity(getExactValue(fs.getSimilarity()));
  32. }
  33. return pb;
  34. }
  35. @Override
  36. public PageBean<Flowsheet> queryAll(String empid, String bdate, String edate) {
  37. PageBean<Flowsheet> pb = flowsheetDao.queryAll(empid,bdate,edate);
  38. List<Flowsheet> flowsheetList = pb.getBeanList();
  39. for(Flowsheet fs:flowsheetList){
  40. fs.setEmployee(employeeDao.queryByEmpid(fs.getEmployee().getEmpid()));
  41. fs.setLogtime(getRealTime(fs.getLogtime()));
  42. fs.setClientdatetime(getDatetime(fs.getClientdatetime()));
  43. }
  44. return pb;
  45. }
  46. /**
  47. * 添加打卡记录
  48. * @param flowsheet
  49. */
  50. public void addSheet(Flowsheet flowsheet){
  51. flowsheetDao.addSheet(flowsheet);
  52. }
  53. /* private float getExactValue(float similarity) {
  54. return (Math.round(similarity*100)/100);
  55. }*/
  56. private String getDatetime(String datetime) {
  57. String date = datetime.substring(0,8);
  58. date = date.substring(0,4)+"-"+date.substring(4,6)+"-"+date.substring(6);
  59. String time = datetime.substring(8);
  60. time = getRealTime(time);
  61. datetime = date+" "+time;
  62. return datetime;
  63. }
  64. private String getRealTime(String time){
  65. while(time.length()<6){
  66. time = "0"+time;
  67. }
  68. time = time.substring(0,2)+":"+time.substring(2,4)+":"+time.substring(4);
  69. return time;
  70. }
  71. }

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/花生_TL007/article/detail/150484
推荐阅读
相关标签
  

闽ICP备14008679号