package com.yhy.module.core.controller.admin.boq.vo;

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

import java.time.LocalDateTime;
import java.util.List;

/**
 * 清单明细树 - Response VO
 *
 * @author yhy
 */
@Schema(description = "管理后台 - 清单明细树 Response VO")
@Data
public class BoqDetailTreeRespVO {

    @Schema(description = "节点ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    private Long id;

    @Schema(description = "清单子项ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    private Long boqSubItemId;

    @Schema(description = "父节点ID", example = "1")
    private Long parentId;

    @Schema(description = "编码", requiredMode = Schema.RequiredMode.REQUIRED, example = "01")
    private String code;

    @Schema(description = "名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "土石方工程")
    private String name;

    @Schema(description = "单位", example = "m³")
    private String unit;

    @Schema(description = "节点类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "directory")
    private String nodeType;

    @Schema(description = "定额基价【第三层】节点ID", example = "1003")
    private Long quotaCatalogItemId;

    @Schema(description = "定额编码", example = "CONT_001")
    private String quotaCode;

    @Schema(description = "定额名称", example = "平整场地")
    private String quotaName;

    @Schema(description = "定额单位", example = "m²")
    private String quotaUnit;

    @Schema(description = "排序", example = "1")
    private Integer sortOrder;

    @Schema(description = "层级路径", example = "[\"1\", \"2\"]")
    private String[] path;

    @Schema(description = "层级", example = "1")
    private Integer level;

    @Schema(description = "子节点列表")
    private List<BoqDetailTreeRespVO> children;

    @Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
    private LocalDateTime createTime;
}
