package com.seer.teach.teacher.convert;

import com.seer.teach.teacher.common.dto.SubjectTag;
import com.seer.teach.teacher.common.resp.*;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.math.BigDecimal;
import java.util.List;

/**
 * <p>
 *
 * </p >
 *
 * @author Captain
 * @since 2025-08-12 10:33
 */
@Mapper
public interface ReportConvert {
    ReportConvert INSTANCE = Mappers.getMapper(ReportConvert.class);

    UserReportResp toUserReportResp(List<KeyValueResp> subjectDetail,
                                    Integer questionCount,
                                    Integer rightCount,
                                    List<KeyValueResp> subjectRightRate);

    ChildrenQuestionInfoResp toChildrenQuestionInfoResp(String time,
                                                        Integer questionCount,
                                                        Integer rightCount,
                                                        BigDecimal rightRate,
                                                        List<ChildrenQuestionDetailResp> subjectDetail);

    ReportResp toReportResp(
            String time,
            List<SubjectScoreResp> subjectDetail,
            Integer questionCount,
            Integer rightRate,
            Integer wrongRate,
            List<SubjectReportResp> subjectQuestionCounts,
            List<SubjectTag> labels,
            String potentialSummary,
            String score,
            String overRate
    );


}