package com.zsElectric.boot.business.model.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;

import java.io.Serial;
import java.io.Serializable;
import java.util.List;

/**
 * 小程序电站充电终端列表VO
 *
 * @author system
 * @since 2025-12-18
 */
@Getter
@Setter
@Schema(description = "小程序电站充电终端列表VO")
public class AppletConnectorListVO implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "站点ID")
    private Long stationId;

    @Schema(description = "站点名称")
    private String stationName;

    @Schema(description = "空闲终端数")
    private Integer idleCount;

    @Schema(description = "占用终端数")
    private Integer occupiedCount;

    @Schema(description = "离线终端数")
    private Integer offlineCount;

    @Schema(description = "充电终端列表")
    private List<ConnectorItemVO> connectorList;

    /**
     * 充电终端信息
     */
    @Getter
    @Setter
    @Schema(description = "充电终端信息")
    public static class ConnectorItemVO implements Serializable {

        @Serial
        private static final long serialVersionUID = 1L;

        @Schema(description = "充电终端ID")
        private Long connectorId;

        @Schema(description = "终端名称（如：101号直流充电桩）")
        private String connectorName;

        @Schema(description = "设备分类（如：直流设备）")
        private String equipmentType;

        @Schema(description = "终端编码")
        private String connectorCode;

        @Schema(description = "状态：0-离网 1-空闲 2-占用(未充电) 3-占用(充电中) 4-占用(预约锁定) 255-故障")
        private Integer status;

        @Schema(description = "状态名称")
        private String statusName;
    }
}
