feat(system模块lease): 租赁管理增加停用功能,停用后不参与出租率计算

- LEASE 表新增 status 字段(1=启用,0=停用)
- Lease/LeasePO/LeaseDO/LeaseDTO 新增 status 字段
- LeaseMapper.xml 增加 status 查询字段与过滤条件
- 新增 LeaseApi.updateStatus 接口(PUT /updateStatus/{leaseIds}/{status})
- 出租率计算(shipperLeaseDetails)过滤 status=1,停用租赁不再生成出租率数据
一个SQL文件,增加了一个字段,在测试和生产环境都需要执行
对应需求:仓库出租率 - 租赁管理增加停用功能
This commit is contained in:
rcx
2026-08-11 18:03:09 +08:00
parent 8b4e785de3
commit 6a84abf6dd
9 changed files with 157 additions and 2 deletions
@@ -35,6 +35,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="updateBy" column="update_by" />
<result property="updateByName" column="update_by_name" />
<result property="delFlag" column="del_flag" />
<result property="status" column="status" />
</resultMap>
@@ -68,7 +69,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
a.bill_time,
a.salesman_name,
a.settlement_currency,
a.salesman_id
a.salesman_id,
a.status
from lease a
LEFT JOIN warehouse w ON a.warehouse_id = w.warehouse_id AND w.del_flag = 1
</sql>
@@ -136,6 +138,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
AND a.start_date &lt;= #{time}
AND a.end_date &gt;= #{time}
</if>
<!-- 停用状态过滤:status 不为空时按状态过滤 -->
<if test="status != null">
AND a.status = #{status}
</if>
<!-- 删除标记 -->
<choose>
<when test="delFlag != null"> and a.del_flag = #{delFlag} </when>