/*
 * File: src/main/java/reports/model/inventories/Stock.java
 * Description: This model represents the Stock entity, capturing details about the stock
 * levels of products in the inventory system. It includes fields for product ID, batch number,
 * quantity, expiry date, and timestamps for creation and updates.
 */

package com.nebula.erp.reports.model.inventories;

import jakarta.persistence.*;
import lombok.Getter;
import lombok.Setter;

import java.time.LocalDateTime;

@Entity
@Table(name = "stock")
@Getter
@Setter
public class Stock {
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;

    @Column(nullable = false)
    private Long product_id;

    private Long batch_id;

    @Column(nullable = false)
    private Integer quantity;

    @Column(nullable = false)
    private String type;

    @Column(nullable = false)
    private String reason;

    @Column(nullable = false)
    private String tenant;

    private LocalDateTime created_at = LocalDateTime.now();
    private LocalDateTime updated_at = LocalDateTime.now();
    private LocalDateTime deleted_at = null;
}