package com.zt.plat.module.base.controller.admin.unitConversion.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.NotBlank;

import java.math.BigDecimal;

@Schema(description = "管理后台 - 按符号单位转换 Request VO")
@Data
public class UnitConvertBySymbolReqVO {

    @Schema(description = "源单位符号", requiredMode = Schema.RequiredMode.REQUIRED, example = "kg")
    @NotBlank(message = "源单位符号不能为空")
    private String srcUnitSymbol;

    @Schema(description = "目标单位符号", requiredMode = Schema.RequiredMode.REQUIRED, example = "t")
    @NotBlank(message = "目标单位符号不能为空")
    private String tgtUnitSymbol;

    @Schema(description = "待转换的值", requiredMode = Schema.RequiredMode.REQUIRED, example = "1000")
    @NotNull(message = "待转换的值不能为空")
    private BigDecimal value;

    @Schema(description = "精度(小数位数)", example = "6")
    private Integer precision = 6;
}
