package com.srs.dormitory.domain;

import com.baomidou.mybatisplus.annotation.*;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * <p>
 * 调宿申请表
 * </p>
 *
 * @author szz
 * @since 2023年07月26日
 */
@Data
@TableName("dms_transfer_application")
@ApiModel(value = "DmsTransferApplication对象", description = "调宿申请表")
public class DmsTransferApplication implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("主键ID")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty("学生学号")
    @TableField("stu_no")
    private String stuNo;

    @ApiModelProperty("调宿时间")
    @TableField("time")
    private Date time;

    @ApiModelProperty("原宿舍居住时间")
    @TableField("duration")
    private BigDecimal duration;

    @ApiModelProperty("原宿舍ID")
    @TableField("current_dorm_id")
    private Long currentDormId;

    @ApiModelProperty("原床位ID")
    @TableField("current_bed_id")
    private Long currentBedId;

    @ApiModelProperty("新宿舍ID")
    @TableField("target_dorm_id")
    private Long targetDormId;

    @ApiModelProperty("新床位ID")
    @TableField("target_bed_id")
    private Long targetBedId;

    @ApiModelProperty("申请理由")
    @TableField("reason")
    private String reason;

    @ApiModelProperty("创建时间")
    @TableField(value = "create_time", fill = FieldFill.INSERT)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    @ApiModelProperty("创建人")
    @TableField("create_by")
    private String createBy;

    @ApiModelProperty("修改时间")
    @TableField(value = "update_time", fill = FieldFill.UPDATE)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updateTime;

    @ApiModelProperty("修改人")
    @TableField("update_by")
    private String updateBy;

    @ApiModelProperty("审核状态 (0未审核 1 通过 -1 拒绝)")
    @TableField("status")
    private Integer status;

    @ApiModelProperty("删除标志（0代表存在 2代表删除）")
    @TableField("del_flag")
    private String delFlag;


}
