package com.ffii.fpsms.modules.master.entity

import com.ffii.core.entity.BaseEntity
import jakarta.persistence.*
import jakarta.validation.constraints.NotNull

@Table(name = "bom_process")
@Entity
open class BomProcess : BaseEntity<Long>() {
    @NotNull
    @ManyToOne(optional = false)
    @JoinColumn(name = "processId", nullable = false)
    open var process: Process? = null

    @NotNull
    @ManyToOne(optional = false)
    @JoinColumn(name = "uomId", nullable = false)
    open var uom: UomConversion? = null

    @NotNull
    @Column(name = "seqNo", nullable = false)
    open var seqNo: Long? = null

    @NotNull
    @ManyToOne(optional = false)
    @JoinColumn(name = "bomId", nullable = false)
    open var bom: Bom? = null
}