67 lines
1.0 KiB
Java
67 lines
1.0 KiB
Java
package com.example.building.entity;
|
|
|
|
import com.baomidou.mybatisplus.annotation.*;
|
|
import lombok.Data;
|
|
|
|
import java.time.LocalDateTime;
|
|
|
|
/**
|
|
* 库存流水实体类
|
|
* 记录库存变动历史
|
|
*/
|
|
@Data
|
|
@TableName("stock_flow")
|
|
public class StockFlow {
|
|
|
|
@TableId(type = IdType.ASSIGN_UUID)
|
|
private String flowId;
|
|
|
|
/**
|
|
* 商品ID
|
|
*/
|
|
private String productId;
|
|
|
|
/**
|
|
* 类型: 1入库 2出库 3调整 4盘点
|
|
*/
|
|
private Integer type;
|
|
|
|
/**
|
|
* 变动数量(正数增加/负数减少)
|
|
*/
|
|
private Integer quantity;
|
|
|
|
/**
|
|
* 变动前数量
|
|
*/
|
|
private Integer beforeQuantity;
|
|
|
|
/**
|
|
* 变动后数量
|
|
*/
|
|
private Integer afterQuantity;
|
|
|
|
/**
|
|
* 关联单据ID
|
|
*/
|
|
private String relatedId;
|
|
|
|
/**
|
|
* 关联单据类型
|
|
*/
|
|
private String relatedType;
|
|
|
|
/**
|
|
* 操作人ID
|
|
*/
|
|
private String operatorId;
|
|
|
|
/**
|
|
* 备注
|
|
*/
|
|
private String remark;
|
|
|
|
@TableField(fill = FieldFill.INSERT)
|
|
private LocalDateTime createdAt;
|
|
}
|