调整借调查询不出部门资产bug

This commit is contained in:
aikai 2024-08-21 14:16:05 +08:00
parent 58b61cd336
commit 253f750664
2 changed files with 20 additions and 2 deletions

View File

@ -22,12 +22,18 @@ public class DeptAssetsPageReqVO extends PageParam {
@Schema(description = "资产id", example = "15660")
private Long assetsId;
@Schema(description = "资产类型id", example = "5169")
private Long typeId;
@Schema(description = "资产状态 -1无状态 0空闲 1使用中 2维修 3损坏 (资产类型按单件时候有意义)", example = "2")
private Integer status;
@Schema(description = "库存")
private Integer stock;
@Schema(description = "是否过滤库存 0否 1是")
private Integer filterStockFlag;
@Schema(description = "创建时间")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] createTime;
@ -35,4 +41,4 @@ public class DeptAssetsPageReqVO extends PageParam {
@Schema(description = "资产名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "15660")
@ExcelProperty("资产名称")
private String assetsName;
}
}

View File

@ -55,6 +55,12 @@
<if test="vo.deptId != null">
and a.dept_id = #{vo.deptId}
</if>
<if test="vo.filterStockFlag != null and vo.filterStockFlag == 1">
and a.stock > 0
</if>
<if test="vo.typeId != null">
and b.type_id = #{vo.typeId}
</if>
<if test="vo.assetsId != null">
and a.assets_id = #{vo.assetsId}
</if>
@ -84,6 +90,12 @@
<if test="vo.deptId != null">
and a.dept_id = #{vo.deptId}
</if>
<if test="vo.filterStockFlag != null and vo.filterStockFlag == 1">
and a.stock > 0
</if>
<if test="vo.typeId != null">
and b.type_id = #{vo.typeId}
</if>
<if test="vo.assetsId != null">
and a.assets_id = #{vo.assetsId}
</if>
@ -95,4 +107,4 @@
</if>
</where>
</select>
</mapper>
</mapper>