package com.ikon.projectmanagement.entity;

import java.util.UUID;

import jakarta.persistence.*;
import lombok.*;

@Entity
@Table(name = "fx_rate_details_v2")
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class FxRateDetailsEntity {

    @Id
    @GeneratedValue(strategy = GenerationType.UUID)
    @Column(name = "id")
    private UUID id;

    @ManyToOne(fetch = FetchType.LAZY)
    @JoinColumn(name = "fx_rate_id", nullable = false)
    @ToString.Exclude
    @EqualsAndHashCode.Exclude
    private FxRateEntity fxRateEntity;

    @Column(name = "currency_id", nullable = false)
    private String currencyId;

    @Column(name = "currency")
    private String currency;

    @Column(name = "fx_rate")
    private Double fxRate;

    @Column(name = "active_status")
    private Boolean activeStatus;

    @Column(name = "year")
    private String year;
}