package com.njcn.rdms.module.project.controller.admin.project.vo.project;

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

import java.util.List;
import java.util.Map;

@Schema(description = "管理后台 - 项目产品分组 Response VO")
@Data
public class ProjectGroupRespVO {

    @Schema(description = "产品编号，游离组为 null", example = "1001")
    private Long productId;

    @Schema(description = "产品名称，游离组固定为「游离项目」", example = "智能网关")
    private String productName;

    @Schema(description = "产品编码，游离组为 null", example = "CNPD2026001")
    private String productCode;

    @Schema(description = "产品方向字典值，游离组为空串", example = "platform")
    private String directionCode;

    @Schema(description = "产品负责人用户编号，游离组为 null", example = "1024")
    private Long managerUserId;

    @Schema(description = "产品负责人昵称，游离组为 null", example = "张三")
    private String managerUserNickname;

    @Schema(description = "当前筛选口径下该组项目总数")
    private Long projectTotal;

    @Schema(description = "组内前 topN 条项目（更新时间倒序），字段与项目分页接口行一致")
    private List<ProjectRespVO> projects;

    @Schema(description = "项目类型计数，恒按「全部」口径（不含已取消/已归档）统计，不随状态筛选变化")
    private Map<String, Long> typeCounts;

    @Schema(description = "是否存在非已取消的主线（基线）项目，口径与创建唯一性校验一致")
    private Boolean hasBaseline;

    @Schema(description = "是否游离组")
    private Boolean orphan;

}
