dev add violation notion
Test Workflow / test (push) Successful in 9s

This commit is contained in:
vladp
2026-03-17 16:35:27 +07:00
parent 15d1824757
commit f1e0f9594e
10 changed files with 549 additions and 2 deletions
@@ -53,7 +53,9 @@ public enum MessageCode {
FILE_FOR_SEARCH_NOT_VALID(2, "File for search unsupported"),
NOT_VALID_FILE_TYPE_OR_COUNT_FILE(2, "Cost for file type not found, count is negative or files count" +
"more than max valid"),
USER_NOT_ACTIVE(2, "User not active");
USER_NOT_ACTIVE(2, "User not active"),
NOTION_NOT_FOUND(4, "Notion not found"),
MESSAGE_IS_REQUIRED_FOR_NOTION(4, "Message is required for notion");
private final Integer code;
@@ -0,0 +1,12 @@
package ru.soune.nocopy.dto.violation;
import lombok.Builder;
import lombok.Data;
@Data
@Builder
public class DeleteNotionResponse {
private Long notionId;
private String message;
private boolean deleted;
}
@@ -0,0 +1,12 @@
package ru.soune.nocopy.dto.violation;
import lombok.Data;
@Data
public class ViolationNotionRequest {
private String token;
private String fileId;
private String message;
private String action;
private Long notionId;
}
@@ -0,0 +1,30 @@
package ru.soune.nocopy.dto.violation;
import lombok.Builder;
import lombok.Data;
import java.time.LocalDateTime;
@Data
@Builder
public class ViolationNotionResponse {
private Long id;
private String message;
private LocalDateTime createdAt;
private LocalDateTime updatedAt;
private UserInfo user;
private FileInfo file;
@Data
@Builder
public static class UserInfo {
private Long id;
private String fullName;
private String email;
}
@Data
@Builder
public static class FileInfo {
private String id;
private String originalFileName;
}
}
@@ -0,0 +1,15 @@
package ru.soune.nocopy.dto.violation;
import lombok.Builder;
import lombok.Data;
import java.util.List;
@Data
@Builder
public class ViolationNotionsListResponse {
private String fileId;
private String fileName;
private int totalCount;
private List<ViolationNotionResponse> notions;
}