日志模块
This commit is contained in:
parent
acda782e6e
commit
b58bc365af
@ -85,6 +85,7 @@ public class LogInstanceController {
|
|||||||
@Operation(summary = "获得我收到的日志分页列表")
|
@Operation(summary = "获得我收到的日志分页列表")
|
||||||
@PreAuthorize("@ss.hasPermission('system:view-log:query')")
|
@PreAuthorize("@ss.hasPermission('system:view-log:query')")
|
||||||
public CommonResult<PageResult<LogInstanceRespVO>> getLogInstancePage(@Valid LogInstancePageReqVO pageReqVO) {
|
public CommonResult<PageResult<LogInstanceRespVO>> getLogInstancePage(@Valid LogInstancePageReqVO pageReqVO) {
|
||||||
|
|
||||||
PageResult<LogInstanceDO> pageResult = logInstanceService.getLogInstancePage(pageReqVO);
|
PageResult<LogInstanceDO> pageResult = logInstanceService.getLogInstancePage(pageReqVO);
|
||||||
return success(BeanUtils.toBean(pageResult, LogInstanceRespVO.class));
|
return success(BeanUtils.toBean(pageResult, LogInstanceRespVO.class));
|
||||||
}
|
}
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
package cn.iocoder.yudao.module.system.controller.admin.worklog.vo.loginstance;
|
package cn.iocoder.yudao.module.system.controller.admin.worklog.vo.loginstance;
|
||||||
|
|
||||||
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
import cn.iocoder.yudao.module.system.controller.admin.worklog.vo.upload.UploadUserFile;
|
|
||||||
import io.swagger.v3.oas.annotations.media.Schema;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
import lombok.EqualsAndHashCode;
|
import lombok.EqualsAndHashCode;
|
||||||
@ -48,4 +47,12 @@ public class LogInstancePageReqVO extends PageParam {
|
|||||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
private LocalDateTime[] createTime;
|
private LocalDateTime[] createTime;
|
||||||
|
|
||||||
|
@Schema(description = "其他数据")
|
||||||
|
private OtherData data;
|
||||||
|
|
||||||
|
private static class OtherData{
|
||||||
|
|
||||||
|
private List<Long> deptIds;
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
@ -40,6 +40,11 @@ public class LogReadDo extends BaseDO {
|
|||||||
*/
|
*/
|
||||||
private Long readUserId;
|
private Long readUserId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 日志查看人的部门编号
|
||||||
|
*/
|
||||||
|
private Long readUserDept;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 日志查看状态
|
* 日志查看状态
|
||||||
* 0:未读
|
* 0:未读
|
||||||
|
@ -30,6 +30,7 @@ public class LogReadServiceImpl implements LogReadService{
|
|||||||
LogReadDo logReadDo = new LogReadDo();
|
LogReadDo logReadDo = new LogReadDo();
|
||||||
logReadDo.setLogInstanceId(logInstanceId);
|
logReadDo.setLogInstanceId(logInstanceId);
|
||||||
logReadDo.setStartUserId(startUserId);
|
logReadDo.setStartUserId(startUserId);
|
||||||
|
logReadDo.setReadUserDept(user.getDeptId());
|
||||||
logReadDo.setReadUserId(user.getUserId());
|
logReadDo.setReadUserId(user.getUserId());
|
||||||
logReadDo.setReadStatus(0);
|
logReadDo.setReadStatus(0);
|
||||||
return logReadDo;
|
return logReadDo;
|
||||||
|
@ -13,4 +13,9 @@ public class LogReadUserRespDTO {
|
|||||||
* 可查看日志的用户编号
|
* 可查看日志的用户编号
|
||||||
*/
|
*/
|
||||||
private Long userId;
|
private Long userId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 可查看日志的用户部门编号
|
||||||
|
*/
|
||||||
|
private Long deptId;
|
||||||
}
|
}
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
-->
|
-->
|
||||||
<select id="selectRaedUser">
|
<select id="selectRaedUser">
|
||||||
SELECT
|
SELECT
|
||||||
*
|
DISTINCT result.user_id, result.dept_id
|
||||||
FROM
|
FROM
|
||||||
(
|
(
|
||||||
SELECT
|
SELECT
|
||||||
|
Loading…
Reference in New Issue
Block a user