package cn.iocoder.yudao.module.asset.controller.admin.parking.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Pattern;
import jakarta.validation.constraints.Min;
import java.time.LocalDate;

/**
 * 停车场 Base VO
 *
 * @author 芋道源码
 */
@Data
public class ParkingBaseVO {

    @Schema(description = "停车场名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "张江停车场")
    @NotBlank(message = "停车场名称不能为空")
    private String name;

    @Schema(description = "地址", example = "上海市浦东新区张江高科技园区")
    private String address;

    @Schema(description = "容量", example = "100")
    @Min(value = 1, message = "容量必须大于0")
    private Integer capacity;

    @Schema(description = "省份", example = "浙江省")
    private String province;

    @Schema(description = "城市", example = "嘉兴市")
    private String city;

    @Schema(description = "租赁开始时间", example = "2026-01-01")
    private LocalDate leaseStartDate;

    @Schema(description = "租赁结束时间", example = "2027-01-01")
    private LocalDate leaseEndDate;

    @Schema(description = "负责人", example = "张三")
    private String managerName;

    @Schema(description = "负责人联系方式", example = "13800138000")
    @Pattern(regexp = "^1[3-9]\\d{9}$", message = "手机号格式不正确")
    private String managerPhone;

    @Schema(description = "停车场联系人", example = "李四")
    private String contactName;

    @Schema(description = "停车场联系方式", example = "13900139000")
    @Pattern(regexp = "^1[3-9]\\d{9}$", message = "手机号格式不正确")
    private String contactPhone;

    @Schema(description = "已停车辆数", example = "50")
    @Min(value = 0, message = "已停车辆数不能为负数")
    private Integer parkedAmount;

    @Schema(description = "经度", example = "120.123456")
    @Pattern(regexp = "^-?((0|[1-9]\\d?|1[0-7]\\d)(\\.\\d{1,6})?|180(\\.0{1,6})?)$", message = "经度格式不正确，范围：-180~180")
    private String longitude;

    @Schema(description = "纬度", example = "30.123456")
    @Pattern(regexp = "^-?((0|[1-8]?\\d)(\\.\\d{1,6})?|90(\\.0{1,6})?)$", message = "纬度格式不正确，范围：-90~90")
    private String latitude;

    @Schema(description = "租金费用（元/月）", example = "5000.00")
    @Min(value = 0, message = "租金费用不能为负数")
    private java.math.BigDecimal rentFee;

    @Schema(description = "合同文件URL", example = "https://example.com/contract.pdf")
    private String contractFileUrl;

}
