Browse Source

新增:区域二级

zyh
小久哥 3 years ago
parent
commit
4cead507ae
  1. 5
      zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/controller/admin/area/vo/AreaBaseVO.java
  2. 2
      zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/controller/admin/area/vo/AreaExcelVO.java
  3. 2
      zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/controller/admin/area/vo/AreaExportReqVO.java
  4. 2
      zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/controller/admin/area/vo/AreaPageReqVO.java
  5. 2
      zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/controller/admin/area/vo/AreaRespVO.java
  6. 2
      zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/dal/dataobject/area/AreaDO.java
  7. 2
      zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/dal/mysql/area/AreaMapper.java

5
zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/controller/admin/area/vo/AreaBaseVO.java

@ -12,7 +12,12 @@ import javax.validation.constraints.*;
@Data
public class AreaBaseVO {
private Long id;
@ApiModelProperty(value = "")
private String name;
private Long parentId;
}

2
zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/controller/admin/area/vo/AreaExcelVO.java

@ -20,6 +20,8 @@ public class AreaExcelVO {
@ExcelProperty("")
private String name;
private Long parentId;
@ExcelProperty("")
private Date createTime;

2
zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/controller/admin/area/vo/AreaExportReqVO.java

@ -15,6 +15,8 @@ public class AreaExportReqVO {
@ApiModelProperty(value = "")
private String name;
private Long parentId;
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
@ApiModelProperty(value = "开始")
private Date beginCreateTime;

2
zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/controller/admin/area/vo/AreaPageReqVO.java

@ -17,6 +17,8 @@ public class AreaPageReqVO extends PageParam {
@ApiModelProperty(value = "")
private String name;
private Long parentId;
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
@ApiModelProperty(value = "开始")
private Date beginCreateTime;

2
zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/controller/admin/area/vo/AreaRespVO.java

@ -13,6 +13,8 @@ public class AreaRespVO extends AreaBaseVO {
@ApiModelProperty(value = "", required = true)
private Long id;
private Long parentId;
@ApiModelProperty(value = "")
private Date createTime;

2
zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/dal/dataobject/area/AreaDO.java

@ -29,4 +29,6 @@ public class AreaDO extends BaseDO {
*/
private String name;
private Long parentId;
}

2
zsw-farm/zsw-farm-impl/src/main/java/cn/iocoder/yudao/module/farm/dal/mysql/area/AreaMapper.java

@ -20,6 +20,7 @@ public interface AreaMapper extends BaseMapperX<AreaDO> {
default PageResult<AreaDO> selectPage(AreaPageReqVO reqVO) {
return selectPage(reqVO, new LambdaQueryWrapperX<AreaDO>()
.likeIfPresent(AreaDO::getName, reqVO.getName())
.eqIfPresent(AreaDO::getParentId, reqVO.getParentId())
.betweenIfPresent(AreaDO::getCreateTime, reqVO.getBeginCreateTime(), reqVO.getEndCreateTime())
.orderByDesc(AreaDO::getId));
}
@ -27,6 +28,7 @@ public interface AreaMapper extends BaseMapperX<AreaDO> {
default List<AreaDO> selectList(AreaExportReqVO reqVO) {
return selectList(new LambdaQueryWrapperX<AreaDO>()
.likeIfPresent(AreaDO::getName, reqVO.getName())
.eqIfPresent(AreaDO::getParentId, reqVO.getParentId())
.betweenIfPresent(AreaDO::getCreateTime, reqVO.getBeginCreateTime(), reqVO.getEndCreateTime())
.orderByDesc(AreaDO::getId));
}

Loading…
Cancel
Save