package com.yc.ship.module.product.controller.app.voyage.vo;

import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.yc.ship.framework.excel.core.annotations.DictFormat;
import com.yc.ship.framework.excel.core.convert.DictConvert;
import com.yc.ship.module.product.controller.admin.pricetemplate.vo.*;
import com.yc.ship.module.product.controller.admin.voyage.vo.VoyageRespVO;
import com.yc.ship.module.resource.controller.admin.roommodel.vo.ResourceRoomModelRespVO;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

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

@Schema(description = "APP端 - 航次价格 Response VO")
@Data
@ExcelIgnoreUnannotated
public class AppPriceVoyageRespVO {

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

    @Schema(description = "模板名称", example = "王五")
    @ExcelProperty("模板名称")
    private String name;

    @Schema(description = "游轮ID", example = "11190")
    @ExcelProperty("游轮ID")
    private Long shipId;

    @Schema(description = "游轮名称", example = "王五")
    @ExcelProperty("游轮名称")
    private String shipName;

    @Schema(description = "航线ID", example = "18479")
    @ExcelProperty("航线ID")
    private Long routeId;

    @Schema(description = "航线名称", example = "王五")
    @ExcelProperty("航线名称")
    private String routeName;

    @Schema(description = "价格模板ID", example = "27165")
    @ExcelProperty("价格模板ID")
    private Long templateId;

    @Schema(description = "航次ID", example = "1860")
    @ExcelProperty("航次ID")
    private Long voyageId;

    @Schema(description = "航次名称", example = "王五")
    @ExcelProperty("航次名称")
    private String voyageName;

    @Schema(description = "价格模式（字典）")
    @ExcelProperty(value = "价格模式（字典）", converter = DictConvert.class)
    @DictFormat("product_price_model") // TODO 代码优化：建议设置到对应的 DictTypeConstants 枚举类中
    private Integer priceMode;

    @Schema(description = "有效期")
    @ExcelProperty("有效期")
    private LocalDateTime validateTime;

    @Schema(description = "状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @ExcelProperty("状态")
    private Integer status;

    @Schema(description = "基准价格", example = "100")
    @ExcelProperty("基准价格")
    private BigDecimal basicPrice;

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

    @Schema(description = "房型价格系数")
    private PriceRoomModelRespVO priceRoomModel;

    private ResourceRoomModelRespVO roomModel;

    @Schema(description = "航次详情")
    private VoyageRespVO voyage;

    @Schema(description = "楼层价格系数")
    private List<PriceFloorRespVO> floorList;

    @Schema(description = "区域价格")
    private List<PriceAreaRespVO> areaList;

    @Schema(description = "国家价格")
    private List<PriceCountryRespVO> countryList;

    @Schema(description = "附加产品设置")
    private List<PriceSpuRespVO> spuList;

    @Schema(description = "基础区域价格")
    private List<BasicPriceAreaRespVO> basicAreaList;

    @Schema(description = "基础国家价格")
    private List<BasicPriceCountryRespVO> basicCountryList;

}