diff --git a/.idea/misc.xml b/.idea/misc.xml
index 5d8d5c0..a57100a 100644
--- a/.idea/misc.xml
+++ b/.idea/misc.xml
@@ -9,7 +9,7 @@
-
+
\ No newline at end of file
diff --git a/src/main/java/cn/edu/cqwu/repair/service/RecordService.java b/src/main/java/cn/edu/cqwu/repair/service/RecordService.java
index 90ca4c5..d4c7d44 100644
--- a/src/main/java/cn/edu/cqwu/repair/service/RecordService.java
+++ b/src/main/java/cn/edu/cqwu/repair/service/RecordService.java
@@ -1,10 +1,12 @@
package cn.edu.cqwu.repair.service;
import cn.edu.cqwu.repair.entity.AdminUser;
+import cn.edu.cqwu.repair.entity.Worker;
import cn.edu.cqwu.repair.util.PageModel;
public interface RecordService {
int add(AdminUser user, String ip);
+ int add(Worker user, String ip);
PageModel pageByLogname(String logname, String group, int pageSize, int pageNo);
}
diff --git a/src/main/java/cn/edu/cqwu/repair/service/impl/RecordServiceImpl.java b/src/main/java/cn/edu/cqwu/repair/service/impl/RecordServiceImpl.java
index e5f2c05..4402557 100644
--- a/src/main/java/cn/edu/cqwu/repair/service/impl/RecordServiceImpl.java
+++ b/src/main/java/cn/edu/cqwu/repair/service/impl/RecordServiceImpl.java
@@ -3,6 +3,7 @@ package cn.edu.cqwu.repair.service.impl;
import cn.edu.cqwu.repair.dao.RecordDao;
import cn.edu.cqwu.repair.entity.AdminUser;
import cn.edu.cqwu.repair.entity.Record;
+import cn.edu.cqwu.repair.entity.Worker;
import cn.edu.cqwu.repair.service.RecordService;
import cn.edu.cqwu.repair.util.PageModel;
import org.springframework.beans.factory.annotation.Autowired;
@@ -26,6 +27,15 @@ public class RecordServiceImpl implements RecordService {
return recordDao.add(record);
}
+ @Override
+ public int add(Worker user, String ip) {
+ Record record = new Record();
+ record.setLogname(user.getUsername());
+ record.setUsergroup("工人");
+ record.setLogip(ip);
+ return recordDao.add(record);
+ }
+
@Override
public PageModel pageByLogname(String logname, String group, int pageSize, int pageNo) {
return recordDao.pageByLogname(logname, group, pageSize, pageNo);
diff --git a/src/main/webapp/includes/menu.jsp b/src/main/webapp/includes/menu.jsp
index 75ef5d9..f87b811 100644
--- a/src/main/webapp/includes/menu.jsp
+++ b/src/main/webapp/includes/menu.jsp
@@ -62,6 +62,25 @@
+
+
+
+ >> 个人中心
+
+
+ >> 维修列表
+
+
+ >> 历史维修记录
+
+
+ >> 历史登录记录
+
+
+ >> 个人中心
+
+
+