New file |
| | |
| | | package com.dy.pmsGlobal.aop; |
| | | |
| | | import com.dy.pmsGlobal.daoBa.BaLogMapper; |
| | | import com.dy.pmsGlobal.pojoBa.BaLog; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.Date; |
| | | |
| | | @Service |
| | | public class LogService { |
| | | |
| | | @Autowired |
| | | private BaLogMapper dao; |
| | | |
| | | public void save(long operator, String operation,String ip,String code,String msg) { |
| | | BaLog log = new BaLog(); |
| | | log.userId=operator; |
| | | log.content = operation; |
| | | log.dt = new Date(); |
| | | log.ip = ip; |
| | | log.code = code; |
| | | log.msg = msg; |
| | | dao.insert(log); |
| | | } |
| | | |
| | | } |