package com.ywt.outpatient.domain.entity.center;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;

/**
 * 用户的个人资料
 */
@Entity
@Table(name = "user_patient")
public class UserPatient {

    @Id
    private Integer id;

    /**
     * 用户ID，对应user表的ID
     */
    @Column(name = "user_id")
    private Integer userId;

    /**
     * 姓名
     */
    @Column(name = "name")
    private String name;

    /**
     * 手机号
     */
    @Column(name = "mobile")
    private String mobile;

    /**
     * 身份证号
     */
    @Column(name = "id_no", nullable = false)
    private String idNo;

    /**
     * 家长姓名
     */
    @Column(name = "parent_name")
    private String parentName;

    /**
     * 性别
     */
    @Column(name = "sex")
    private Integer sex;

    /**
     * 是否删除（标识物理删除）
     */
    @Column(name = "deleted", nullable = false)
    private boolean deleted;

    /**
     * 创建时间
     */
    @Column(name = "create_time", nullable = false)
    private Date createTime;

    /**
     * 修改时间
     */
    @Column(name = "update_time", nullable = false)
    private Date updateTime;

    //与本人关系
    @Column(name = "relationship")
    private Integer relationship;

    @Column(name = "address")
    private String address;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getMobile() {
        return mobile;
    }

    public void setMobile(String mobile) {
        this.mobile = mobile;
    }

    public String getIdNo() {
        return idNo;
    }

    public void setIdNo(String idNo) {
        this.idNo = idNo;
    }

    public String getParentName() {
        return parentName;
    }

    public void setParentName(String parentName) {
        this.parentName = parentName;
    }

    public Integer getSex() {
        return sex;
    }

    public void setSex(Integer sex) {
        this.sex = sex;
    }

    public boolean getDeleted() {
        return deleted;
    }

    public void setDeleted(boolean deleted) {
        this.deleted = deleted;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public Integer getRelationship() {
        return relationship;
    }

    public void setRelationship(Integer relationship) {
        this.relationship = relationship;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }
}
