package com.ruoyi.system.domain.houseInfo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.annotation.Excels;
import com.ruoyi.common.core.domain.BaseEntity;
import com.ruoyi.common.core.domain.entity.ResidentInfo;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * 房屋信息对象 house_info
 * 
 * @author boman
 * @date 2025-02-20
 */
public class HouseInfo extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 房屋信息主键，唯一标识每条房屋信息 */
    private Long houseId;

    /** 权利人姓名 */
    @Excel(name = "权利人姓名")
    private String ownerName;

    /** 房屋坐落位置 */
    @Excel(name = "房屋坐落位置")
    private String location;

    /** 权利类型，如所有权、使用权等 */
    @Excel(name = "权利类型，如所有权、使用权等")
    private String rightType;

    /** 房屋面积，单位为平方米 */
    @Excel(name = "房屋面积，单位为平方米")
    private BigDecimal area;

    /** 房屋相关的字第号 */
    @Excel(name = "房屋相关的字第号")
    private String documentNumber;

    /** 不动产单元号，唯一标识不动产单元 */
    @Excel(name = "不动产单元号，唯一标识不动产单元")
    private String propertyUnitNumber;

    /** 房屋的共有情况，如共有比例等 */
    @Excel(name = "房屋的共有情况，如共有比例等")
    private String coOwnership;

    /** 房屋用途，如住宅、商业等 */
    @Excel(name = "房屋用途，如住宅、商业等")
    private String usageType;

    /** 房屋使用期限 */
    @Excel(name = "房屋使用期限")
    private String usagePeriod;

    /** 房屋登记日期 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "房屋登记日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date registrationDate;

    /** 共有人姓名，多个共有人可以用逗号分隔 */
    @Excel(name = "共有人姓名，多个共有人可以用逗号分隔")
    private String coOwner;

    /** 房屋的详细门牌号 */
    @Excel(name = "房屋的详细门牌号")
    private String detailedAddress;

    /** 是否有车位，Y表示有，N表示无 */
    @Excel(name = "是否有车位，Y表示有，N表示无")
    private String hasParkingSpace;
    /**
     * 车位号
     */
    @Excel(name = "车位号")
    private String parkingNumber;

    /** 房屋所在小区名称 */
    @Excel(name = "房屋所在小区名称")
    private String communityName;

    /** 房屋状态：1-自住，2-出租，3-空闲，4-待售 */
    @Excel(name = "房屋状态：1-自住，2-出租，3-空闲，4-待售")
    private Integer houseStatus;

    /** 房屋住户信息 */
    @Excels({
            @Excel(name = "居住人员的详细门牌号", targetAttr = "detailedAddress"),
            @Excel(name = "居住人员姓名", targetAttr = "residentName"),
            @Excel(name = "居住人员身份证号码", targetAttr = "residentIdCard"),
            @Excel(name = "居住人员出生日期", targetAttr = "residentBirthday"),
            @Excel(name = "居住人员手机号", targetAttr = "residentPhone"),
            @Excel(name = "居住人员性别", targetAttr = "residentGender", readConverterExp = "男=1,女=2"),
            @Excel(name = "居住人员与户主的关系", targetAttr = "residentRelationship"),
            @Excel(name = "是否是户主", targetAttr = "isHouseholder", readConverterExp = "是=Y,否=N"),
            @Excel(name = "是否是租户", targetAttr = "isTenant", readConverterExp = "是=Y,否=N"),
            @Excel(name = "居住人员工作单位", targetAttr = "residentEmployer"),
            @Excel(name = "居住人员面貌", targetAttr = "residentAppearance")
    })
    private List<ResidentInfo> residentInfoList;

    public String getParkingNumber() {
        return parkingNumber;
    }

    public void setParkingNumber(String parkingNumber) {
        this.parkingNumber = parkingNumber;
    }

    public List<ResidentInfo> getResidentInfoList() {
        return residentInfoList;
    }

    public void setResidentInfoList(List<ResidentInfo> residentInfoList) {
        this.residentInfoList = residentInfoList;
    }

    public void setHouseId(Long houseId)
    {
        this.houseId = houseId;
    }

    public Long getHouseId() 
    {
        return houseId;
    }
    public void setOwnerName(String ownerName) 
    {
        this.ownerName = ownerName;
    }

    public String getOwnerName() 
    {
        return ownerName;
    }
    public void setLocation(String location) 
    {
        this.location = location;
    }

    public String getLocation() 
    {
        return location;
    }
    public void setRightType(String rightType) 
    {
        this.rightType = rightType;
    }

    public String getRightType() 
    {
        return rightType;
    }
    public void setArea(BigDecimal area) 
    {
        this.area = area;
    }

    public BigDecimal getArea() 
    {
        return area;
    }
    public void setDocumentNumber(String documentNumber) 
    {
        this.documentNumber = documentNumber;
    }

    public String getDocumentNumber() 
    {
        return documentNumber;
    }
    public void setPropertyUnitNumber(String propertyUnitNumber) 
    {
        this.propertyUnitNumber = propertyUnitNumber;
    }

    public String getPropertyUnitNumber() 
    {
        return propertyUnitNumber;
    }
    public void setCoOwnership(String coOwnership) 
    {
        this.coOwnership = coOwnership;
    }

    public String getCoOwnership() 
    {
        return coOwnership;
    }

    public String getUsageType() {
        return usageType;
    }

    public void setUsageType(String usageType) {
        this.usageType = usageType;
    }

    public void setUsagePeriod(String usagePeriod)
    {
        this.usagePeriod = usagePeriod;
    }

    public String getUsagePeriod() 
    {
        return usagePeriod;
    }
    public void setRegistrationDate(Date registrationDate) 
    {
        this.registrationDate = registrationDate;
    }

    public Date getRegistrationDate() 
    {
        return registrationDate;
    }
    public void setCoOwner(String coOwner) 
    {
        this.coOwner = coOwner;
    }

    public String getCoOwner() 
    {
        return coOwner;
    }
    public void setDetailedAddress(String detailedAddress) 
    {
        this.detailedAddress = detailedAddress;
    }

    public String getDetailedAddress() 
    {
        return detailedAddress;
    }
    public void setHasParkingSpace(String hasParkingSpace) 
    {
        this.hasParkingSpace = hasParkingSpace;
    }

    public String getHasParkingSpace() 
    {
        return hasParkingSpace;
    }
    public void setCommunityName(String communityName) 
    {
        this.communityName = communityName;
    }

    public String getCommunityName() 
    {
        return communityName;
    }
    public void setHouseStatus(Integer houseStatus) 
    {
        this.houseStatus = houseStatus;
    }

    public Integer getHouseStatus() 
    {
        return houseStatus;
    }

    @Override
    public String toString() {
        return "HouseInfo{" +
                "houseId=" + houseId +
                ", ownerName='" + ownerName + '\'' +
                ", location='" + location + '\'' +
                ", rightType='" + rightType + '\'' +
                ", area=" + area +
                ", documentNumber='" + documentNumber + '\'' +
                ", propertyUnitNumber='" + propertyUnitNumber + '\'' +
                ", coOwnership='" + coOwnership + '\'' +
                ", usageType='" + usageType + '\'' +
                ", usagePeriod='" + usagePeriod + '\'' +
                ", registrationDate=" + registrationDate +
                ", coOwner='" + coOwner + '\'' +
                ", detailedAddress='" + detailedAddress + '\'' +
                ", hasParkingSpace='" + hasParkingSpace + '\'' +
                ", parkingNumber='" + parkingNumber + '\'' +
                ", communityName='" + communityName + '\'' +
                ", houseStatus=" + houseStatus +
                ", residentInfoList=" + residentInfoList +
                '}';
    }
}
