package cn.iocoder.yudao.module.mes.controller.admin.goview.vo;

import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat;
import cn.iocoder.yudao.framework.excel.core.convert.DictConvert;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.util.*;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import com.alibaba.excel.annotation.*;

@Schema(description = "管理后台 - 可视化大屏 Response VO")
@Data
@ExcelIgnoreUnannotated
public class GoviewRespVO {

    @Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "11354")
    @ExcelProperty("ID")
    private Long id;

    @Schema(description = "名称", example = "赵六")
    @ExcelProperty("名称")
    private String name;

    @Schema(description = "备注", example = "你猜")
    @ExcelProperty("备注")
    private String remark;

    @Schema(description = "启用状态")
    @ExcelProperty("启用状态")
    private Long state;

    @Schema(description = "图片路径")
    @ExcelProperty("图片路径")
    private String indexImage;

    @Schema(description = "路由路径")
    @ExcelProperty("路由路径")
    private String route;

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

    @Schema(description = "内容")
    @ExcelProperty("内容")
    private String content;

    @Schema(description = "产线ID")
    @ExcelProperty("产线ID")
    private Long orgId;

    @Schema(description = "产线名称")
    @ExcelProperty("产线名称")
    private String orgName;

    @Schema(description = "大屏类型")
    @ExcelProperty(value="大屏类型", converter = DictConvert.class)
    @DictFormat("mes_goview_type")
    private String type;

    @Schema(description = "设备ids")
    @ExcelProperty("设备ids")
    private String deviceIds;

    @Schema(description = "设备ids与点位ids列表")
    private List<GoviewSaveReqVO.DevicePointVO> deviceIdsList;

    @Data
    public static class DevicePointVO {
        @Schema(description = "设备ID", example = "12")
        private Long deviceId;
        @Schema(description = "点位ID列表", example = "[1,5,9]")
        private List<Long> attributesIds;
    }

}