35 lines
1.0 KiB
Java
35 lines
1.0 KiB
Java
package com.billpaymentservice.bbps.entites;
|
|
|
|
import java.util.List;
|
|
|
|
import jakarta.persistence.CascadeType;
|
|
import jakarta.persistence.Column;
|
|
import jakarta.persistence.Entity;
|
|
import jakarta.persistence.GeneratedValue;
|
|
import jakarta.persistence.GenerationType;
|
|
import jakarta.persistence.Id;
|
|
import jakarta.persistence.JoinColumn;
|
|
import jakarta.persistence.OneToMany;
|
|
import jakarta.persistence.Table;
|
|
import lombok.Getter;
|
|
import lombok.Setter;
|
|
|
|
@Getter
|
|
@Setter
|
|
@Entity
|
|
|
|
@Table(name = "bbps_amount_option_biller_id")
|
|
public class AmountOptionByBillerId extends Auditable {
|
|
|
|
@Id
|
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
|
@Column(name = "id")
|
|
private Long id; // Use Long for auto-increment identity
|
|
|
|
@Column(name = "amount_options")
|
|
private Boolean amountOptions; // This is true or false
|
|
|
|
@OneToMany(cascade = CascadeType.ALL, orphanRemoval = true)
|
|
@JoinColumn(name = "amount_option_id_long") // Foreign key field that links to the 'Long' column
|
|
private List<AmountOptionDetails> amountOptionDetails; // List of AmountOptionDetails
|
|
} |