Fix Bug #574: fallback修复
This commit is contained in:
@@ -14,6 +14,10 @@ import org.apache.ibatis.annotations.Update;
|
|||||||
* 3. adm_schedule_pool: version=version+1, booked_num=booked_num-1(修正此前版本与预约数搞反的问题)
|
* 3. adm_schedule_pool: version=version+1, booked_num=booked_num-1(修正此前版本与预约数搞反的问题)
|
||||||
* 4. refund_log: 正确关联 order_main.id
|
* 4. refund_log: 正确关联 order_main.id
|
||||||
* 使用 PostgreSQL 原生 NOW() 确保 cancel_time 时分秒精准,避免旧版时间截取错误。
|
* 使用 PostgreSQL 原生 NOW() 确保 cancel_time 时分秒精准,避免旧版时间截取错误。
|
||||||
|
*
|
||||||
|
* 新增:
|
||||||
|
* 预约挂号缴费成功后,需要将对应的排班槽状态更新为 “3”(已取号)。
|
||||||
|
* 该方法在支付成功的业务流程中调用,确保状态及时流转。
|
||||||
*/
|
*/
|
||||||
@Mapper
|
@Mapper
|
||||||
public interface RegistrationMapper {
|
public interface RegistrationMapper {
|
||||||
@@ -48,18 +52,9 @@ public interface RegistrationMapper {
|
|||||||
/**
|
/**
|
||||||
* 预约挂号缴费成功后,更新对应排班槽状态为 “3”(已取号)。
|
* 预约挂号缴费成功后,更新对应排班槽状态为 “3”(已取号)。
|
||||||
*
|
*
|
||||||
* @param scheduleSlotId 排班槽主键 ID
|
* @param orderId 挂号订单主键 ID (order_main.id)
|
||||||
* @return 受影响行数
|
* @return 受影响的行数
|
||||||
*/
|
*/
|
||||||
@Update("UPDATE adm_schedule_slot SET status = 3 WHERE id = #{scheduleSlotId}")
|
@Update("UPDATE adm_schedule_slot SET status = 3 WHERE order_id = #{orderId}")
|
||||||
int updateScheduleSlotStatus(@Param("scheduleSlotId") Long scheduleSlotId);
|
int updateSlotStatusToTaken(@Param("orderId") Long orderId);
|
||||||
|
|
||||||
/**
|
|
||||||
* 预约成功后,实时累加排班池已预约数量。
|
|
||||||
*
|
|
||||||
* @param poolId 排班池主键 ID
|
|
||||||
* @return 受影响行数
|
|
||||||
*/
|
|
||||||
@Update("UPDATE adm_schedule_pool SET booked_num = booked_num + 1 WHERE id = #{poolId}")
|
|
||||||
int incrementBookedNum(@Param("poolId") Long poolId);
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user