package com.hys.app.model.erp.dos;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.hys.app.model.erp.enums.DetailOrderTypeEnum;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.Date;


/**
 * 商品库存实体类
 *
 * @author 张崧
 * @since 2023-12-07 10:08:44
 */
@TableName("erp_locked_stock_detail")
@Data
public class LockedStockDetailDO implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(type = IdType.ASSIGN_ID)
    @ApiModelProperty(name = "id", value = "id")
    private Long id;

    @ApiModelProperty(name = "product_stock_id", value = "库存id")
    private Long productStockId;

    @ApiModelProperty(name = "order_id", value = "单据id")
    private Long orderId;

    @ApiModelProperty(name = "order_sn", value = "单据编号")
    private  String orderSn;

    @ApiModelProperty(name = "order_id", value = "商品详情id")
    private Long orderItemId;

    @ApiModelProperty(name = "order_type", value = "单据类型")
    private DetailOrderTypeEnum orderType;

    @ApiModelProperty(name = "locked_num", value = "锁定数量")
    private Integer lockedNum;

    @ApiModelProperty(name = "locked_time", value = "锁定时间")
    private Date lockedTime;

    @ApiModelProperty(name = "status", value = "状态未解锁")
    private Boolean status = false;

    @ApiModelProperty(name = "un_locked_num", value = "最后解锁时间")
    private Integer unLockedNum =0;

    @ApiModelProperty(name = "un_locked_time", value = "解锁数量")
    private Date unLockedTime;

    @TableField(exist = false)
    private GoodsDO goodsVO;

    @TableField(exist = false)
    private ProductDO productVO;


}
