This commit is contained in:
parent
0d8a4608ce
commit
62b1e1b803
@ -62,7 +62,7 @@ public class TbCommunityController extends BaseController {
|
||||
* @return 树结构数据
|
||||
*/
|
||||
@GetMapping("/tree/{level}")
|
||||
public List<TreeNode<String>> tree(@PathVariable("level") Integer level) {
|
||||
public List<TreeNode<Long>> tree(@PathVariable("level") Integer level) {
|
||||
LoginUser loginUser = LoginHelper.getLoginUser();
|
||||
Assert.notNull(loginUser, "获取账户信息失败!");
|
||||
Assert.notEmpty(loginUser.getTenantId(), "获取租户信息失败");
|
||||
|
@ -1,19 +1,19 @@
|
||||
package org.dromara.property.domain;
|
||||
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 建筑对象 tb_building
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ -24,7 +24,7 @@ public class TbBuilding extends TenantEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
@ -32,12 +32,7 @@ public class TbBuilding extends TenantEntity {
|
||||
/**
|
||||
* 园区编码
|
||||
*/
|
||||
private String communityCode;
|
||||
|
||||
/**
|
||||
* 建筑编码
|
||||
*/
|
||||
private String buildingCode;
|
||||
private String communityId;
|
||||
|
||||
/**
|
||||
* 建筑名称
|
||||
@ -62,22 +57,22 @@ public class TbBuilding extends TenantEntity {
|
||||
/**
|
||||
* 总层数
|
||||
*/
|
||||
private Long floorCount;
|
||||
private Integer floorCount;
|
||||
|
||||
/**
|
||||
* 单元数
|
||||
*/
|
||||
private Long unitCount;
|
||||
private Integer unitCount;
|
||||
|
||||
/**
|
||||
* 建筑类型('1:住宅','2:商业','3:混合')
|
||||
*/
|
||||
private Long buildType;
|
||||
private Integer buildType;
|
||||
|
||||
/**
|
||||
* 电梯数量
|
||||
*/
|
||||
private Long elevatorCount;
|
||||
private Integer elevatorCount;
|
||||
|
||||
/**
|
||||
* 竣工日期
|
||||
@ -99,70 +94,10 @@ public class TbBuilding extends TenantEntity {
|
||||
*/
|
||||
private String lat;
|
||||
|
||||
/**
|
||||
* 产权性质(1:自持,2:承租,3:自持+承租,4:政府免费使用)
|
||||
*/
|
||||
private Long cqxz;
|
||||
|
||||
/**
|
||||
* 不动产编号
|
||||
*/
|
||||
private String bdcbh;
|
||||
|
||||
/**
|
||||
* 产权编号
|
||||
*/
|
||||
private String cqbh;
|
||||
|
||||
/**
|
||||
* 图地编号
|
||||
*/
|
||||
private String tdbh;
|
||||
|
||||
/**
|
||||
* 建筑面积
|
||||
*/
|
||||
private Long jzmj;
|
||||
|
||||
/**
|
||||
* 产权面积
|
||||
*/
|
||||
private Long cqmj;
|
||||
|
||||
/**
|
||||
* 可租面积
|
||||
*/
|
||||
private Long kzmj;
|
||||
|
||||
/**
|
||||
* 自用面积
|
||||
*/
|
||||
private Long zymj;
|
||||
|
||||
/**
|
||||
* 配套面积
|
||||
*/
|
||||
private Long ptmj;
|
||||
|
||||
/**
|
||||
* 车位面积
|
||||
*/
|
||||
private Long cwmj;
|
||||
|
||||
/**
|
||||
* 标准层高
|
||||
*/
|
||||
private Long bzcg;
|
||||
|
||||
/**
|
||||
* 排序字段
|
||||
*/
|
||||
private Long sort;
|
||||
|
||||
/**
|
||||
* 修改时间
|
||||
*/
|
||||
private Date modifyTime;
|
||||
private Integer sort;
|
||||
|
||||
|
||||
}
|
||||
|
@ -13,7 +13,7 @@ import java.io.Serial;
|
||||
* 小区对象 tb_community
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ -24,7 +24,7 @@ public class TbCommunity extends TenantEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
@ -34,15 +34,10 @@ public class TbCommunity extends TenantEntity {
|
||||
*/
|
||||
private String communityName;
|
||||
|
||||
/**
|
||||
* 社区编码
|
||||
*/
|
||||
private String communityCode;
|
||||
|
||||
/**
|
||||
* 社区类型 1:园区,2:小区
|
||||
*/
|
||||
private Long communityType;
|
||||
private Integer communityType;
|
||||
|
||||
/**
|
||||
* 省
|
||||
@ -77,10 +72,10 @@ public class TbCommunity extends TenantEntity {
|
||||
/**
|
||||
* 占地面积(平方米)
|
||||
*/
|
||||
private Long area;
|
||||
private Float area;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
*/
|
||||
private Date builtYear;
|
||||
|
||||
|
@ -11,7 +11,7 @@ import java.io.Serial;
|
||||
* 楼层对象 tb_floor
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ -30,12 +30,7 @@ public class TbFloor extends TenantEntity {
|
||||
/**
|
||||
* 单元编码
|
||||
*/
|
||||
private String unitCode;
|
||||
|
||||
/**
|
||||
* 楼层编码
|
||||
*/
|
||||
private String floorCode;
|
||||
private Long unitId;
|
||||
|
||||
/**
|
||||
* 楼层数名称
|
||||
@ -45,22 +40,22 @@ public class TbFloor extends TenantEntity {
|
||||
/**
|
||||
* 楼层号
|
||||
*/
|
||||
private Long floorNumber;
|
||||
private Integer floorNumber;
|
||||
|
||||
/**
|
||||
* 楼层类型
|
||||
*/
|
||||
private Long floorType;
|
||||
private Integer floorType;
|
||||
|
||||
/**
|
||||
* 房间数量
|
||||
*/
|
||||
private Long roomCount;
|
||||
private Integer roomCount;
|
||||
|
||||
/**
|
||||
* 层高
|
||||
*/
|
||||
private Long floorHeight;
|
||||
private Integer floorHeight;
|
||||
|
||||
|
||||
}
|
||||
|
@ -11,7 +11,7 @@ import java.io.Serial;
|
||||
* 房间信息对象 tb_room
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ -22,7 +22,7 @@ public class TbRoom extends TenantEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
@ -30,12 +30,7 @@ public class TbRoom extends TenantEntity {
|
||||
/**
|
||||
* 所属楼层ID
|
||||
*/
|
||||
private String floorCode;
|
||||
|
||||
/**
|
||||
* 房间编码
|
||||
*/
|
||||
private String roomCode;
|
||||
private Long floorId;
|
||||
|
||||
/**
|
||||
* 房间号(如101,202)
|
||||
@ -45,32 +40,32 @@ public class TbRoom extends TenantEntity {
|
||||
/**
|
||||
* 房间类型('住宅','商铺','办公室','设备间','公共区域')
|
||||
*/
|
||||
private Long roomType;
|
||||
private Integer roomType;
|
||||
|
||||
/**
|
||||
* 面积(平方米)
|
||||
*/
|
||||
private Long area;
|
||||
private Float area;
|
||||
|
||||
/**
|
||||
* 户型(如2室1厅1卫)
|
||||
*/
|
||||
private String layout;
|
||||
private Integer layout;
|
||||
|
||||
/**
|
||||
* 朝向('东','南','西','北','东南','东北','西南','西北')
|
||||
*/
|
||||
private Long orientation;
|
||||
private Integer orientation;
|
||||
|
||||
/**
|
||||
* 是否可售
|
||||
*/
|
||||
private Long isForSale;
|
||||
private Integer isForSale;
|
||||
|
||||
/**
|
||||
* 状态('空置','已售','已租','自用')
|
||||
*/
|
||||
private Long status;
|
||||
private Integer status;
|
||||
|
||||
|
||||
}
|
||||
|
@ -11,7 +11,7 @@ import java.io.Serial;
|
||||
* 单元对象 tb_unit
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ -30,12 +30,7 @@ public class TbUnit extends TenantEntity {
|
||||
/**
|
||||
* 建筑名称
|
||||
*/
|
||||
private String buildingCode;
|
||||
|
||||
/**
|
||||
* 单元编码
|
||||
*/
|
||||
private String unitCode;
|
||||
private Long buildingId;
|
||||
|
||||
/**
|
||||
* 单元名称
|
||||
@ -45,17 +40,17 @@ public class TbUnit extends TenantEntity {
|
||||
/**
|
||||
* 单元层数
|
||||
*/
|
||||
private Long floorCount;
|
||||
private Integer floorCount;
|
||||
|
||||
/**
|
||||
* 单元户数
|
||||
*/
|
||||
private Long householdCount;
|
||||
private Integer householdCount;
|
||||
|
||||
/**
|
||||
* 楼梯数量
|
||||
*/
|
||||
private Long stairCount;
|
||||
private Integer stairCount;
|
||||
|
||||
|
||||
}
|
||||
|
@ -1,21 +1,22 @@
|
||||
package org.dromara.property.domain.bo;
|
||||
|
||||
import org.dromara.property.domain.TbBuilding;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.property.domain.TbBuilding;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
/**
|
||||
* 建筑业务对象 tb_building
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ -23,66 +24,60 @@ import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
public class TbBuildingBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
*/
|
||||
@NotNull(message = "不能为空", groups = { EditGroup.class })
|
||||
@NotNull(message = "不能为空", groups = {EditGroup.class})
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 园区编码
|
||||
*/
|
||||
@NotBlank(message = "园区编码不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private String communityCode;
|
||||
|
||||
/**
|
||||
* 建筑编码
|
||||
*/
|
||||
@NotBlank(message = "建筑编码不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private String buildingCode;
|
||||
@NotBlank(message = "园区编码不能为空", groups = {AddGroup.class, EditGroup.class})
|
||||
private String communityId;
|
||||
|
||||
/**
|
||||
* 建筑名称
|
||||
*/
|
||||
@NotBlank(message = "建筑名称不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
@NotBlank(message = "建筑名称不能为空", groups = {AddGroup.class, EditGroup.class})
|
||||
private String buildingName;
|
||||
|
||||
/**
|
||||
* 省
|
||||
*/
|
||||
@NotBlank(message = "省不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
@NotBlank(message = "省不能为空", groups = {AddGroup.class, EditGroup.class})
|
||||
private String province;
|
||||
|
||||
/**
|
||||
* 市
|
||||
*/
|
||||
@NotBlank(message = "市不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
@NotBlank(message = "市不能为空", groups = {AddGroup.class, EditGroup.class})
|
||||
private String city;
|
||||
|
||||
/**
|
||||
* 区
|
||||
*/
|
||||
@NotBlank(message = "区不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
@NotBlank(message = "区不能为空", groups = {AddGroup.class, EditGroup.class})
|
||||
private String district;
|
||||
|
||||
/**
|
||||
* 总层数
|
||||
*/
|
||||
private Long floorCount;
|
||||
private Integer floorCount;
|
||||
|
||||
/**
|
||||
* 单元数
|
||||
*/
|
||||
private Long unitCount;
|
||||
private Integer unitCount;
|
||||
|
||||
/**
|
||||
* 建筑类型('1:住宅','2:商业','3:混合')
|
||||
*/
|
||||
private Long buildType;
|
||||
private Integer buildType;
|
||||
|
||||
/**
|
||||
* 电梯数量
|
||||
*/
|
||||
private Long elevatorCount;
|
||||
private Integer elevatorCount;
|
||||
|
||||
/**
|
||||
* 竣工日期
|
||||
@ -92,87 +87,24 @@ public class TbBuildingBo extends BaseEntity {
|
||||
/**
|
||||
* 地址
|
||||
*/
|
||||
@NotBlank(message = "地址不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
@NotBlank(message = "地址不能为空", groups = {AddGroup.class, EditGroup.class})
|
||||
private String addr;
|
||||
|
||||
/**
|
||||
* 经度
|
||||
*/
|
||||
@NotBlank(message = "经度不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
@NotBlank(message = "经度不能为空", groups = {AddGroup.class, EditGroup.class})
|
||||
private String lon;
|
||||
|
||||
/**
|
||||
* 维度
|
||||
*/
|
||||
@NotBlank(message = "维度不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
@NotBlank(message = "维度不能为空", groups = {AddGroup.class, EditGroup.class})
|
||||
private String lat;
|
||||
|
||||
/**
|
||||
* 产权性质(1:自持,2:承租,3:自持+承租,4:政府免费使用)
|
||||
*/
|
||||
private Long cqxz;
|
||||
|
||||
/**
|
||||
* 不动产编号
|
||||
*/
|
||||
private String bdcbh;
|
||||
|
||||
/**
|
||||
* 产权编号
|
||||
*/
|
||||
private String cqbh;
|
||||
|
||||
/**
|
||||
* 图地编号
|
||||
*/
|
||||
private String tdbh;
|
||||
|
||||
/**
|
||||
* 建筑面积
|
||||
*/
|
||||
@NotNull(message = "建筑面积不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private Long jzmj;
|
||||
|
||||
/**
|
||||
* 产权面积
|
||||
*/
|
||||
@NotNull(message = "产权面积不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private Long cqmj;
|
||||
|
||||
/**
|
||||
* 可租面积
|
||||
*/
|
||||
private Long kzmj;
|
||||
|
||||
/**
|
||||
* 自用面积
|
||||
*/
|
||||
private Long zymj;
|
||||
|
||||
/**
|
||||
* 配套面积
|
||||
*/
|
||||
private Long ptmj;
|
||||
|
||||
/**
|
||||
* 车位面积
|
||||
*/
|
||||
private Long cwmj;
|
||||
|
||||
/**
|
||||
* 标准层高
|
||||
*/
|
||||
private Long bzcg;
|
||||
|
||||
/**
|
||||
* 排序字段
|
||||
*/
|
||||
private Long sort;
|
||||
|
||||
/**
|
||||
* 修改时间
|
||||
*/
|
||||
private Date modifyTime;
|
||||
|
||||
private Integer sort;
|
||||
|
||||
}
|
||||
|
@ -15,7 +15,7 @@ import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
* 小区业务对象 tb_community
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ -23,7 +23,7 @@ import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
public class TbCommunityBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
*/
|
||||
@NotNull(message = "不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
@ -34,17 +34,11 @@ public class TbCommunityBo extends BaseEntity {
|
||||
@NotBlank(message = "社区名称不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private String communityName;
|
||||
|
||||
/**
|
||||
* 社区编码
|
||||
*/
|
||||
@NotBlank(message = "社区编码不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private String communityCode;
|
||||
|
||||
/**
|
||||
* 社区类型 1:园区,2:小区
|
||||
*/
|
||||
@NotNull(message = "社区类型 1:园区,2:小区不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private Long communityType;
|
||||
private Integer communityType;
|
||||
|
||||
/**
|
||||
* 省
|
||||
@ -88,7 +82,7 @@ public class TbCommunityBo extends BaseEntity {
|
||||
private Long area;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
*/
|
||||
private Date builtYear;
|
||||
|
||||
|
@ -13,7 +13,7 @@ import jakarta.validation.constraints.*;
|
||||
* 楼层业务对象 tb_floor
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ -30,13 +30,7 @@ public class TbFloorBo extends BaseEntity {
|
||||
* 单元编码
|
||||
*/
|
||||
@NotBlank(message = "单元编码不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private String unitCode;
|
||||
|
||||
/**
|
||||
* 楼层编码
|
||||
*/
|
||||
@NotNull(message = "楼层编码不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private String floorCode;
|
||||
private Long unitId;
|
||||
|
||||
/**
|
||||
* 楼层数名称
|
||||
@ -48,22 +42,22 @@ public class TbFloorBo extends BaseEntity {
|
||||
* 楼层号
|
||||
*/
|
||||
@NotNull(message = "楼层号不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private Long floorNumber;
|
||||
private Integer floorNumber;
|
||||
|
||||
/**
|
||||
* 楼层类型
|
||||
*/
|
||||
private Long floorType;
|
||||
private Integer floorType;
|
||||
|
||||
/**
|
||||
* 房间数量
|
||||
*/
|
||||
private Long roomCount;
|
||||
private Integer roomCount;
|
||||
|
||||
/**
|
||||
* 层高
|
||||
*/
|
||||
private Long floorHeight;
|
||||
private Integer floorHeight;
|
||||
|
||||
|
||||
}
|
||||
|
@ -13,7 +13,7 @@ import jakarta.validation.constraints.*;
|
||||
* 房间信息业务对象 tb_room
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ -21,7 +21,7 @@ import jakarta.validation.constraints.*;
|
||||
public class TbRoomBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
*/
|
||||
@NotNull(message = "不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
@ -30,12 +30,7 @@ public class TbRoomBo extends BaseEntity {
|
||||
* 所属楼层ID
|
||||
*/
|
||||
@NotBlank(message = "所属楼层ID不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private String floorCode;
|
||||
|
||||
/**
|
||||
* 房间编码
|
||||
*/
|
||||
private String roomCode;
|
||||
private Long floorId;
|
||||
|
||||
/**
|
||||
* 房间号(如101,202)
|
||||
@ -46,12 +41,12 @@ public class TbRoomBo extends BaseEntity {
|
||||
/**
|
||||
* 房间类型('住宅','商铺','办公室','设备间','公共区域')
|
||||
*/
|
||||
private Long roomType;
|
||||
private Integer roomType;
|
||||
|
||||
/**
|
||||
* 面积(平方米)
|
||||
*/
|
||||
private Long area;
|
||||
private Float area;
|
||||
|
||||
/**
|
||||
* 户型(如2室1厅1卫)
|
||||
@ -61,17 +56,17 @@ public class TbRoomBo extends BaseEntity {
|
||||
/**
|
||||
* 朝向('东','南','西','北','东南','东北','西南','西北')
|
||||
*/
|
||||
private Long orientation;
|
||||
private Integer orientation;
|
||||
|
||||
/**
|
||||
* 是否可售
|
||||
*/
|
||||
private Long isForSale;
|
||||
private Integer isForSale;
|
||||
|
||||
/**
|
||||
* 状态('空置','已售','已租','自用')
|
||||
*/
|
||||
private Long status;
|
||||
private Integer status;
|
||||
|
||||
|
||||
}
|
||||
|
@ -13,7 +13,7 @@ import jakarta.validation.constraints.*;
|
||||
* 单元业务对象 tb_unit
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ -30,13 +30,7 @@ public class TbUnitBo extends BaseEntity {
|
||||
* 建筑名称
|
||||
*/
|
||||
@NotBlank(message = "建筑名称不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private String buildingCode;
|
||||
|
||||
/**
|
||||
* 单元编码
|
||||
*/
|
||||
@NotBlank(message = "单元编码不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private String unitCode;
|
||||
private Long buildingId;
|
||||
|
||||
/**
|
||||
* 单元名称
|
||||
@ -47,17 +41,17 @@ public class TbUnitBo extends BaseEntity {
|
||||
/**
|
||||
* 单元层数
|
||||
*/
|
||||
private Long floorCount;
|
||||
private Integer floorCount;
|
||||
|
||||
/**
|
||||
* 单元户数
|
||||
*/
|
||||
private Long householdCount;
|
||||
private Integer householdCount;
|
||||
|
||||
/**
|
||||
* 楼梯数量
|
||||
*/
|
||||
private Long stairCount;
|
||||
private Integer stairCount;
|
||||
|
||||
|
||||
}
|
||||
|
@ -20,7 +20,7 @@ import java.util.Date;
|
||||
* 建筑视图对象 tb_building
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@ -30,23 +30,14 @@ public class TbBuildingVo implements Serializable {
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
@ExcelProperty(value = "")
|
||||
@ExcelProperty(value = "主键id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 园区编码
|
||||
*/
|
||||
@ExcelProperty(value = "园区编码")
|
||||
private String communityCode;
|
||||
|
||||
/**
|
||||
* 建筑编码
|
||||
*/
|
||||
@ExcelProperty(value = "建筑编码")
|
||||
private String buildingCode;
|
||||
private Long communityId;
|
||||
|
||||
/**
|
||||
* 建筑名称
|
||||
@ -82,19 +73,19 @@ public class TbBuildingVo implements Serializable {
|
||||
* 单元数
|
||||
*/
|
||||
@ExcelProperty(value = "单元数")
|
||||
private Long unitCount;
|
||||
private Integer unitCount;
|
||||
|
||||
/**
|
||||
* 建筑类型('1:住宅','2:商业','3:混合')
|
||||
*/
|
||||
@ExcelProperty(value = "建筑类型('1:住宅','2:商业','3:混合')")
|
||||
private Long buildType;
|
||||
private Integer buildType;
|
||||
|
||||
/**
|
||||
* 电梯数量
|
||||
*/
|
||||
@ExcelProperty(value = "电梯数量")
|
||||
private Long elevatorCount;
|
||||
private Integer elevatorCount;
|
||||
|
||||
/**
|
||||
* 竣工日期
|
||||
@ -124,67 +115,7 @@ public class TbBuildingVo implements Serializable {
|
||||
* 产权性质(1:自持,2:承租,3:自持+承租,4:政府免费使用)
|
||||
*/
|
||||
@ExcelProperty(value = "产权性质(1:自持,2:承租,3:自持+承租,4:政府免费使用)")
|
||||
private Long cqxz;
|
||||
|
||||
/**
|
||||
* 不动产编号
|
||||
*/
|
||||
@ExcelProperty(value = "不动产编号")
|
||||
private String bdcbh;
|
||||
|
||||
/**
|
||||
* 产权编号
|
||||
*/
|
||||
@ExcelProperty(value = "产权编号")
|
||||
private String cqbh;
|
||||
|
||||
/**
|
||||
* 图地编号
|
||||
*/
|
||||
@ExcelProperty(value = "图地编号")
|
||||
private String tdbh;
|
||||
|
||||
/**
|
||||
* 建筑面积
|
||||
*/
|
||||
@ExcelProperty(value = "建筑面积")
|
||||
private Long jzmj;
|
||||
|
||||
/**
|
||||
* 产权面积
|
||||
*/
|
||||
@ExcelProperty(value = "产权面积")
|
||||
private Long cqmj;
|
||||
|
||||
/**
|
||||
* 可租面积
|
||||
*/
|
||||
@ExcelProperty(value = "可租面积")
|
||||
private Long kzmj;
|
||||
|
||||
/**
|
||||
* 自用面积
|
||||
*/
|
||||
@ExcelProperty(value = "自用面积")
|
||||
private Long zymj;
|
||||
|
||||
/**
|
||||
* 配套面积
|
||||
*/
|
||||
@ExcelProperty(value = "配套面积")
|
||||
private Long ptmj;
|
||||
|
||||
/**
|
||||
* 车位面积
|
||||
*/
|
||||
@ExcelProperty(value = "车位面积")
|
||||
private Long cwmj;
|
||||
|
||||
/**
|
||||
* 标准层高
|
||||
*/
|
||||
@ExcelProperty(value = "标准层高")
|
||||
private Long bzcg;
|
||||
private Integer cqxz;
|
||||
|
||||
/**
|
||||
* 排序字段
|
||||
@ -192,11 +123,4 @@ public class TbBuildingVo implements Serializable {
|
||||
@ExcelProperty(value = "排序字段")
|
||||
private Long sort;
|
||||
|
||||
/**
|
||||
* 修改时间
|
||||
*/
|
||||
@ExcelProperty(value = "修改时间")
|
||||
private Date modifyTime;
|
||||
|
||||
|
||||
}
|
||||
|
@ -20,7 +20,7 @@ import java.util.Date;
|
||||
* 小区视图对象 tb_community
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@ -42,12 +42,6 @@ public class TbCommunityVo implements Serializable {
|
||||
@ExcelProperty(value = "社区名称")
|
||||
private String communityName;
|
||||
|
||||
/**
|
||||
* 社区编码
|
||||
*/
|
||||
@ExcelProperty(value = "社区编码")
|
||||
private String communityCode;
|
||||
|
||||
/**
|
||||
* 社区类型 1:园区,2:小区
|
||||
*/
|
||||
|
@ -18,7 +18,7 @@ import java.util.Date;
|
||||
* 楼层视图对象 tb_floor
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@ -38,13 +38,7 @@ public class TbFloorVo implements Serializable {
|
||||
* 单元编码
|
||||
*/
|
||||
@ExcelProperty(value = "单元编码")
|
||||
private String unitCode;
|
||||
|
||||
/**
|
||||
* 楼层编码
|
||||
*/
|
||||
@ExcelProperty(value = "楼层编码")
|
||||
private String floorCode;
|
||||
private Long unitId;
|
||||
|
||||
/**
|
||||
* 楼层数名称
|
||||
@ -62,19 +56,19 @@ public class TbFloorVo implements Serializable {
|
||||
* 楼层类型
|
||||
*/
|
||||
@ExcelProperty(value = "楼层类型")
|
||||
private Long floorType;
|
||||
private Integer floorType;
|
||||
|
||||
/**
|
||||
* 房间数量
|
||||
*/
|
||||
@ExcelProperty(value = "房间数量")
|
||||
private Long roomCount;
|
||||
private Integer roomCount;
|
||||
|
||||
/**
|
||||
* 层高
|
||||
*/
|
||||
@ExcelProperty(value = "层高")
|
||||
private Long floorHeight;
|
||||
private Integer floorHeight;
|
||||
|
||||
|
||||
}
|
||||
|
@ -18,7 +18,7 @@ import java.util.Date;
|
||||
* 房间信息视图对象 tb_room
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@ -29,7 +29,7 @@ public class TbRoomVo implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
*/
|
||||
@ExcelProperty(value = "")
|
||||
private Long id;
|
||||
@ -38,13 +38,7 @@ public class TbRoomVo implements Serializable {
|
||||
* 所属楼层ID
|
||||
*/
|
||||
@ExcelProperty(value = "所属楼层ID")
|
||||
private String floorCode;
|
||||
|
||||
/**
|
||||
* 房间编码
|
||||
*/
|
||||
@ExcelProperty(value = "房间编码")
|
||||
private String roomCode;
|
||||
private Long floorId;
|
||||
|
||||
/**
|
||||
* 房间号(如101,202)
|
||||
@ -56,7 +50,7 @@ public class TbRoomVo implements Serializable {
|
||||
* 房间类型('住宅','商铺','办公室','设备间','公共区域')
|
||||
*/
|
||||
@ExcelProperty(value = "房间类型('住宅','商铺','办公室','设备间','公共区域')")
|
||||
private Long roomType;
|
||||
private Integer roomType;
|
||||
|
||||
/**
|
||||
* 面积(平方米)
|
||||
@ -74,20 +68,20 @@ public class TbRoomVo implements Serializable {
|
||||
* 朝向('东','南','西','北','东南','东北','西南','西北')
|
||||
*/
|
||||
@ExcelProperty(value = "朝向('东','南','西','北','东南','东北','西南','西北')")
|
||||
private Long orientation;
|
||||
private Integer orientation;
|
||||
|
||||
/**
|
||||
* 是否可售
|
||||
*/
|
||||
@ExcelProperty(value = "是否可售")
|
||||
private Long isForSale;
|
||||
private Integer isForSale;
|
||||
|
||||
/**
|
||||
* 状态('空置','已售','已租','自用')
|
||||
*/
|
||||
@ExcelProperty(value = "状态", converter = ExcelDictConvert.class)
|
||||
@ExcelDictFormat(readConverterExp = "'=空置','已售','已租','自用'")
|
||||
private Long status;
|
||||
private Integer status;
|
||||
|
||||
|
||||
}
|
||||
|
@ -18,7 +18,7 @@ import java.util.Date;
|
||||
* 单元视图对象 tb_unit
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-06-26
|
||||
* @date 2025-06-28
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@ -38,13 +38,7 @@ public class TbUnitVo implements Serializable {
|
||||
* 建筑名称
|
||||
*/
|
||||
@ExcelProperty(value = "建筑名称")
|
||||
private String buildingCode;
|
||||
|
||||
/**
|
||||
* 单元编码
|
||||
*/
|
||||
@ExcelProperty(value = "单元编码")
|
||||
private String unitCode;
|
||||
private Long buildingId;
|
||||
|
||||
/**
|
||||
* 单元名称
|
||||
@ -56,19 +50,19 @@ public class TbUnitVo implements Serializable {
|
||||
* 单元层数
|
||||
*/
|
||||
@ExcelProperty(value = "单元层数")
|
||||
private Long floorCount;
|
||||
private Integer floorCount;
|
||||
|
||||
/**
|
||||
* 单元户数
|
||||
*/
|
||||
@ExcelProperty(value = "单元户数")
|
||||
private Long householdCount;
|
||||
private Integer householdCount;
|
||||
|
||||
/**
|
||||
* 楼梯数量
|
||||
*/
|
||||
@ExcelProperty(value = "楼梯数量")
|
||||
private Long stairCount;
|
||||
private Integer stairCount;
|
||||
|
||||
|
||||
}
|
||||
|
@ -74,8 +74,7 @@ public class TbBuildingServiceImpl implements ITbBuildingService {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<TbBuilding> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(TbBuilding::getId);
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getCommunityCode()), TbBuilding::getCommunityCode, bo.getCommunityCode());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getBuildingCode()), TbBuilding::getBuildingCode, bo.getBuildingCode());
|
||||
lqw.eq(bo.getCommunityId() != null, TbBuilding::getCommunityId, bo.getCommunityId());
|
||||
lqw.like(StringUtils.isNotBlank(bo.getBuildingName()), TbBuilding::getBuildingName, bo.getBuildingName());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getProvince()), TbBuilding::getProvince, bo.getProvince());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getCity()), TbBuilding::getCity, bo.getCity());
|
||||
@ -88,19 +87,7 @@ public class TbBuildingServiceImpl implements ITbBuildingService {
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getAddr()), TbBuilding::getAddr, bo.getAddr());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getLon()), TbBuilding::getLon, bo.getLon());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getLat()), TbBuilding::getLat, bo.getLat());
|
||||
lqw.eq(bo.getCqxz() != null, TbBuilding::getCqxz, bo.getCqxz());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getBdcbh()), TbBuilding::getBdcbh, bo.getBdcbh());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getCqbh()), TbBuilding::getCqbh, bo.getCqbh());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getTdbh()), TbBuilding::getTdbh, bo.getTdbh());
|
||||
lqw.eq(bo.getJzmj() != null, TbBuilding::getJzmj, bo.getJzmj());
|
||||
lqw.eq(bo.getCqmj() != null, TbBuilding::getCqmj, bo.getCqmj());
|
||||
lqw.eq(bo.getKzmj() != null, TbBuilding::getKzmj, bo.getKzmj());
|
||||
lqw.eq(bo.getZymj() != null, TbBuilding::getZymj, bo.getZymj());
|
||||
lqw.eq(bo.getPtmj() != null, TbBuilding::getPtmj, bo.getPtmj());
|
||||
lqw.eq(bo.getCwmj() != null, TbBuilding::getCwmj, bo.getCwmj());
|
||||
lqw.eq(bo.getBzcg() != null, TbBuilding::getBzcg, bo.getBzcg());
|
||||
lqw.eq(bo.getSort() != null, TbBuilding::getSort, bo.getSort());
|
||||
lqw.eq(bo.getModifyTime() != null, TbBuilding::getModifyTime, bo.getModifyTime());
|
||||
return lqw;
|
||||
}
|
||||
|
||||
|
@ -41,18 +41,18 @@ public class TbCommunityServiceImpl implements ITbCommunityService {
|
||||
private final ITbRoomService roomService;
|
||||
|
||||
@Override
|
||||
public List<TreeNode<String>> tree(Integer level, String tenantId) {
|
||||
public List<TreeNode<Long>> tree(Integer level, String tenantId) {
|
||||
// 默认加载社区树
|
||||
List<TbCommunityVo> tbCommunityVos = queryByTenantId(tenantId);
|
||||
if (tbCommunityVos == null || tbCommunityVos.isEmpty()) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
List<TreeNode<String>> community = new ArrayList<>(tbCommunityVos.stream().map(item -> {
|
||||
TreeNode<String> node = new TreeNode<>();
|
||||
List<TreeNode<Long>> community = new ArrayList<>(tbCommunityVos.stream().map(item -> {
|
||||
TreeNode<Long> node = new TreeNode<>();
|
||||
node.setChildren(new ArrayList<>());
|
||||
node.setCode(item.getCommunityCode());
|
||||
node.setCode(item.getId());
|
||||
node.setLabel(item.getCommunityName());
|
||||
node.setParentCode("");
|
||||
node.setParentCode(0L);
|
||||
node.setLevel(1);
|
||||
return node;
|
||||
}).toList());
|
||||
@ -62,12 +62,12 @@ public class TbCommunityServiceImpl implements ITbCommunityService {
|
||||
if (level >= 2) {
|
||||
List<TbBuildingVo> vos = buildingService.queryByTenantId(tenantId);
|
||||
if (vos != null && !vos.isEmpty()) {
|
||||
List<TreeNode<String>> list = vos.stream().map(item -> {
|
||||
TreeNode<String> node = new TreeNode<>();
|
||||
List<TreeNode<Long>> list = vos.stream().map(item -> {
|
||||
TreeNode<Long> node = new TreeNode<>();
|
||||
node.setChildren(new ArrayList<>());
|
||||
node.setCode(item.getBuildingCode());
|
||||
node.setCode(item.getId());
|
||||
node.setLabel(item.getBuildingName());
|
||||
node.setParentCode(item.getCommunityCode());
|
||||
node.setParentCode(item.getCommunityId());
|
||||
node.setLevel(2);
|
||||
return node;
|
||||
}).toList();
|
||||
@ -77,12 +77,12 @@ public class TbCommunityServiceImpl implements ITbCommunityService {
|
||||
if (level >= 3) {
|
||||
List<TbUnitVo> vos = unitService.queryByTenantId(tenantId);
|
||||
if (vos != null && !vos.isEmpty()) {
|
||||
List<TreeNode<String>> list = vos.stream().map(item -> {
|
||||
TreeNode<String> node = new TreeNode<>();
|
||||
List<TreeNode<Long>> list = vos.stream().map(item -> {
|
||||
TreeNode<Long> node = new TreeNode<>();
|
||||
node.setChildren(new ArrayList<>());
|
||||
node.setCode(item.getUnitCode());
|
||||
node.setCode(item.getId());
|
||||
node.setLabel(item.getUnitName());
|
||||
node.setParentCode(item.getBuildingCode());
|
||||
node.setParentCode(item.getBuildingId());
|
||||
node.setLevel(3);
|
||||
return node;
|
||||
}).toList();
|
||||
@ -92,12 +92,12 @@ public class TbCommunityServiceImpl implements ITbCommunityService {
|
||||
if (level >= 4) {
|
||||
List<TbFloorVo> vos = floorService.queryByTenantId(tenantId);
|
||||
if (vos != null && !vos.isEmpty()) {
|
||||
List<TreeNode<String>> list = vos.stream().map(item -> {
|
||||
TreeNode<String> node = new TreeNode<>();
|
||||
List<TreeNode<Long>> list = vos.stream().map(item -> {
|
||||
TreeNode<Long> node = new TreeNode<>();
|
||||
node.setChildren(new ArrayList<>());
|
||||
node.setCode(item.getFloorCode());
|
||||
node.setCode(item.getId());
|
||||
node.setLabel(item.getFloorName());
|
||||
node.setParentCode(item.getUnitCode());
|
||||
node.setParentCode(item.getUnitId());
|
||||
node.setLevel(4);
|
||||
return node;
|
||||
}).toList();
|
||||
@ -108,19 +108,19 @@ public class TbCommunityServiceImpl implements ITbCommunityService {
|
||||
if (level >= 5) {
|
||||
List<TbRoomVo> vos = roomService.queryByTenantId(tenantId);
|
||||
if (vos != null && !vos.isEmpty()) {
|
||||
List<TreeNode<String>> list = vos.stream().map(item -> {
|
||||
TreeNode<String> node = new TreeNode<>();
|
||||
List<TreeNode<Long>> list = vos.stream().map(item -> {
|
||||
TreeNode<Long> node = new TreeNode<>();
|
||||
node.setChildren(new ArrayList<>());
|
||||
node.setCode(item.getRoomCode());
|
||||
node.setCode(item.getId());
|
||||
node.setLabel(item.getRoomNumber());
|
||||
node.setParentCode(item.getFloorCode());
|
||||
node.setParentCode(item.getFloorId());
|
||||
node.setLevel(5);
|
||||
return node;
|
||||
}).toList();
|
||||
community.addAll(list);
|
||||
}
|
||||
}
|
||||
return TreeUtils.build(community, "");
|
||||
return TreeUtils.build(community, 0L);
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -172,7 +172,6 @@ public class TbCommunityServiceImpl implements ITbCommunityService {
|
||||
LambdaQueryWrapper<TbCommunity> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(TbCommunity::getId);
|
||||
lqw.like(StringUtils.isNotBlank(bo.getCommunityName()), TbCommunity::getCommunityName, bo.getCommunityName());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getCommunityCode()), TbCommunity::getCommunityCode, bo.getCommunityCode());
|
||||
lqw.eq(bo.getCommunityType() != null, TbCommunity::getCommunityType, bo.getCommunityType());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getProvince()), TbCommunity::getProvince, bo.getProvince());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getCity()), TbCommunity::getCity, bo.getCity());
|
||||
|
@ -74,10 +74,9 @@ public class TbFloorServiceImpl implements ITbFloorService {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<TbFloor> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(TbFloor::getId);
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getUnitCode()), TbFloor::getUnitCode, bo.getUnitCode());
|
||||
lqw.eq(bo.getFloorCode() != null, TbFloor::getFloorCode, bo.getFloorCode());
|
||||
lqw.like(StringUtils.isNotBlank(bo.getFloorName()), TbFloor::getFloorName, bo.getFloorName());
|
||||
lqw.eq(bo.getFloorNumber() != null, TbFloor::getFloorNumber, bo.getFloorNumber());
|
||||
lqw.eq(bo.getUnitId() != null, TbFloor::getUnitId, bo.getUnitId());
|
||||
lqw.eq(bo.getFloorType() != null, TbFloor::getFloorType, bo.getFloorType());
|
||||
lqw.eq(bo.getRoomCount() != null, TbFloor::getRoomCount, bo.getRoomCount());
|
||||
lqw.eq(bo.getFloorHeight() != null, TbFloor::getFloorHeight, bo.getFloorHeight());
|
||||
|
@ -74,10 +74,9 @@ public class TbRoomServiceImpl implements ITbRoomService {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<TbRoom> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(TbRoom::getId);
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getFloorCode()), TbRoom::getFloorCode, bo.getFloorCode());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getRoomCode()), TbRoom::getRoomCode, bo.getRoomCode());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getRoomNumber()), TbRoom::getRoomNumber, bo.getRoomNumber());
|
||||
lqw.eq(bo.getRoomType() != null, TbRoom::getRoomType, bo.getRoomType());
|
||||
lqw.eq(bo.getFloorId() != null, TbRoom::getFloorId, bo.getFloorId());
|
||||
lqw.eq(bo.getArea() != null, TbRoom::getArea, bo.getArea());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getLayout()), TbRoom::getLayout, bo.getLayout());
|
||||
lqw.eq(bo.getOrientation() != null, TbRoom::getOrientation, bo.getOrientation());
|
||||
|
@ -74,10 +74,9 @@ public class TbUnitServiceImpl implements ITbUnitService {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<TbUnit> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(TbUnit::getId);
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getBuildingCode()), TbUnit::getBuildingCode, bo.getBuildingCode());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getUnitCode()), TbUnit::getUnitCode, bo.getUnitCode());
|
||||
lqw.like(StringUtils.isNotBlank(bo.getUnitName()), TbUnit::getUnitName, bo.getUnitName());
|
||||
lqw.eq(bo.getFloorCount() != null, TbUnit::getFloorCount, bo.getFloorCount());
|
||||
lqw.eq(bo.getBuildingId() != null, TbUnit::getBuildingId, bo.getBuildingId());
|
||||
lqw.eq(bo.getHouseholdCount() != null, TbUnit::getHouseholdCount, bo.getHouseholdCount());
|
||||
lqw.eq(bo.getStairCount() != null, TbUnit::getStairCount, bo.getStairCount());
|
||||
return lqw;
|
||||
|
Loading…
Reference in New Issue
Block a user