package com.yimeng.okr.dto;

import lombok.Data;
import java.util.List;

@Data
public class WorkspaceOverviewDto {
    private RecommendedPeriod recommendedPeriod;
    private List<PeriodOption> availablePeriods;
    private String currentPhase;
    private List<TodoItem> myTodos;
    private TeamSummary teamSummary;
    private List<RiskItem> risks;
    private List<DeadlineItem> upcomingDeadlines;
    private List<WorkflowActionDto> allowedActions;

    @Data
    public static class RecommendedPeriod {
        private Long id;
        private String name;
        private String status;
        private String startDate;
        private String endDate;
    }

    @Data
    public static class PeriodOption {
        private Long id;
        private String name;
        private String status;
    }

    @Data
    public static class TodoItem {
        private String type;
        private String label;
        private String targetUrl;
        private Long periodId;
        private Long objectId;
        private Integer count;
        private String urgency;
    }

    @Data
    public static class TeamSummary {
        private int totalMembers;
        private int okrSubmitted;
        private int selfScoreSubmitted;
        private int finalScoreCompleted;
        private Double avgOkrScore;
        private Double avgTotalScore;
    }

    @Data
    public static class RiskItem {
        private String type;
        private String label;
        private String severity;
        private Long userId;
        private String userName;
        private String detail;
    }

    @Data
    public static class DeadlineItem {
        private String label;
        private String date;
        private String type;
    }
}
