package com.zt.plat.module.api.dto.unitconversion;

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

/**
 * 单位转换请求 DTO
 * 用于Feign远程调用
 *
 * @author ZT
 */
@Schema(description = "RPC 服务 - 单位转换 Request DTO")
@Data
public class UnitConvertReqDTO {

    @Schema(description = "源单位ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @NotNull(message = "源单位ID不能为空")
    private Long srcUntId;

    @Schema(description = "目标单位ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
    @NotNull(message = "目标单位ID不能为空")
    private Long tgtUntId;

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

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