package com.seer.teach.admin.response;

import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;
import java.util.Map;

/**
 * 修改日志响应参数
 *
 * @author Lingma
 * @since 2025-11-27
 */
@Data
@Schema(description = "修改日志响应参数")
public class AdminModificationLogResp {

    @Schema(description = "主键ID")
    private Integer id;

    @Schema(description = "目标类型：1-知识点 2-单元 3-教材")
    private Integer targetType;

    @Schema(description = "目标ID（知识点ID、单元ID或教材ID）")
    private Integer targetId;

    @Schema(description = "目标名称（知识点名称、单元名称或教材名称）")
    private String targetName;

    @Schema(description = "操作类型：1-新增 2-修改 3-删除 4-查看")
    private Integer operationType;

    @Schema(description = "修改前的数据（JSON格式）")
    private String beforeData;

    @Schema(description = "修改后的数据（JSON格式）")
    private String afterData;

    @Schema(description = "操作人ID")
    private Integer operatorId;

    @Schema(description = "备注")
    private String remark;

    @Schema(description = "创建时间")
    private LocalDateTime createTime;

    @Schema(description = "数据变化详情")
    private Map<String, String> changes;

    @Schema(description = "是否有变化")
    private Boolean hasChanges;
}