package com.ffii.fpsms.modules.stock.entity.projection

import org.springframework.beans.factory.annotation.Value
import java.math.BigDecimal
import java.time.LocalDate

interface InventoryLotLineItemInfo {
    val id: Long
    val code: String
    val name: String
}

interface InventoryLotLineWarehouseInfo {
    val id: Long
    val code: String
    val name: String
    val description: String
    val capacity: BigDecimal
}

interface InventoryLotLineInfo {
    val id: Long?

    @get:Value("#{target.inventoryLot.item}")
    val item: InventoryLotLineItemInfo?
    val warehouse: InventoryLotLineWarehouseInfo?
    var inQty: BigDecimal?
    var outQty: BigDecimal?
    var holdQty: BigDecimal?

    @get:Value("#{target.status.value}")
    val status: String?
    val remarks: String?

    @get:Value("#{target.stockUom.uom.udfudesc}")
    val uom: String?

    @get:Value("#{target.inventoryLot.expiryDate}")
    val expiryDate: LocalDate
}

interface CurrentInventoryItemInfo {
    val id: Long? // item id
    val code: String?
    val name: String?
    val uomDesc: String?
    val availableQty: BigDecimal?
    val requiredQty: BigDecimal?
}