package com.xunhong.erp.turbo.biz.infrastructure.entity;

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.xunhong.erp.turbo.datasource.domain.entity.BaseDO;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * @author shenyifei
 */
@Data
@TableName(value = "expense_cost")
@EqualsAndHashCode(callSuper = true)
public class ExpenseCostDO extends BaseDO<ExpenseCostDO> {

    /**
     * 明细ID
     */
    @TableId(value = "expense_cost_id", type = IdType.ASSIGN_ID)
    private Long expenseCostId;

    /**
     * 花销统计记录ID
     */
    @TableField(value = "expense_record_id")
    private Long expenseRecordId;

    /**
     * 费用类型ID
     */
    @TableField(value = "cost_id")
    private Long costId;

    /**
     * 费用类型名称
     */
    @TableField(value = "cost_name")
    private String costName;

    /**
     * 花销金额
     */
    @TableField(value = "expense_amount")
    private BigDecimal expenseAmount;

    /**
     * 备注（可填员工、事由等）
     */
    @TableField(value = "remark")
    private String remark;

    /**
     * 创建时间
     */
    @TableField(value = "created_at")
    private LocalDateTime createdAt;

}

