package com.ycwl.basic.integration.questionnaire.dto.answer;

import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data;

import jakarta.validation.Valid;
import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import java.util.List;

@Data
public class SubmitAnswerRequest {
    
    @JsonProperty("questionnaireId")
    private Long questionnaireId;
    
    @JsonProperty("userId")
    private String userId; // 可选，用于非匿名问卷
    
    @NotEmpty(message = "答案不能为空")
    @Valid
    @JsonProperty("answers")
    private List<AnswerRequest> answers;
}