package com.cpop.oam.business.entity;

import com.cpop.core.base.entity.BaseEntity;
import com.cpop.core.base.entity.BaseInsertListener;
import com.cpop.core.base.entity.BaseUpdateListener;
import com.mybatisflex.annotation.Column;
import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.Table;
import java.io.Serializable;
import java.time.LocalDate;
import java.time.LocalDateTime;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;

/**
 * Oam-事务表 实体类。
 *
 * @author DB
 * @since 2023-12-12
 */
@Data
@EqualsAndHashCode(callSuper=false)
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Accessors(chain = true)
@Table(value = "cp_oam_business", onInsert = BaseInsertListener.class, onUpdate = BaseUpdateListener.class, mapperGenerateEnable = false)
public class Business extends BaseEntity implements Serializable {

    /**
     * 主键
     */
    @Id
    private String id;

    /**
     * 业务等级(0：轻；1：重；2：缓；3：急)
     */
    private Integer businessLevel;

    /**
     * 业务类型(0:机构对接；1：机构签约)
     */
    private Integer businessType;

    /**
     * 描述
     */
    private String desc;

    /**
     * 开始时间
     */
    private LocalDate startDate;

    /**
     * 结束时间
     */
    private LocalDate endDate;

    /**
     * 分发人id
     */
    private String initiatorId;

    /**
     * 备注
     */
    private String remark;

    /**
     * 状态（0:进行中;1:已完成）
     */
    private Integer status;

    /**
     * 总剩余数量
     */
    private Integer allSurplusQuantity;

    /**
     * 逻辑删除（0否1是）
     */
    @Column(isLogicDelete = true)
    private Boolean isDelete;

}
