接口上加注解EpcLog 并加备注 可存储操作日志
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
package com.adc.da.slrs.sysLog.controller;
|
||||
|
||||
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import com.adc.da.slrs.sysLog.entity.SysLog;
|
||||
import io.swagger.annotations.Api;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.adc.da.base.web.BaseController;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 前端控制器
|
||||
* </p>
|
||||
*
|
||||
* @author yzh
|
||||
* @since 2022-02-15
|
||||
*/
|
||||
@RestController
|
||||
@Api(description = "|SysLog|")
|
||||
@RequestMapping("/sysLog/sys-log")
|
||||
public class SysLogController extends BaseController<SysLog> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.adc.da.slrs.sysLog.dao;
|
||||
|
||||
import com.adc.da.slrs.sysLog.entity.SysLog;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author yzh
|
||||
* @since 2022-02-15
|
||||
*/
|
||||
public interface SysLogDao extends BaseMapper<SysLog> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,59 @@
|
||||
package com.adc.da.slrs.sysLog.entity;
|
||||
|
||||
import com.adc.da.base.entity.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author yzh
|
||||
* @since 2022-02-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Accessors(chain = true)
|
||||
@ApiModel(value="SysLog对象", description="")
|
||||
public class SysLog extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
private String id;
|
||||
|
||||
@ApiModelProperty(value = "用户id")
|
||||
private String userId;
|
||||
|
||||
@ApiModelProperty(value = "操作时间")
|
||||
private String operTime;
|
||||
|
||||
@ApiModelProperty(value = "操作类型")
|
||||
private String oper;
|
||||
|
||||
@ApiModelProperty(value = "操作ip")
|
||||
private String operIp;
|
||||
|
||||
@ApiModelProperty(value = "操作系统类型")
|
||||
private String operSystem;
|
||||
|
||||
@ApiModelProperty(value = "使用的浏览器")
|
||||
private String operBrowser;
|
||||
|
||||
@ApiModelProperty(value = "日志等级")
|
||||
private String operLevel;
|
||||
|
||||
@ApiModelProperty(value = "操作模块")
|
||||
private String operLocation;
|
||||
|
||||
@ApiModelProperty(value = "传参")
|
||||
private String json;
|
||||
|
||||
@ApiModelProperty(value = "接口耗时")
|
||||
private int runTime;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.adc.da.slrs.sysLog.service;
|
||||
|
||||
import com.adc.da.slrs.sysLog.entity.SysLog;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author yzh
|
||||
* @since 2022-02-15
|
||||
*/
|
||||
public interface ISysLogService extends IService<SysLog> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
package com.adc.da.slrs.sysLog.service.impl;
|
||||
|
||||
import com.adc.da.slrs.sysLog.entity.SysLog;
|
||||
import com.adc.da.slrs.sysLog.dao.SysLogDao;
|
||||
import com.adc.da.slrs.sysLog.service.ISysLogService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author yzh
|
||||
* @since 2022-02-15
|
||||
*/
|
||||
@Service
|
||||
public class SysLogServiceImpl extends ServiceImpl<SysLogDao, SysLog> implements ISysLogService {
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user