mirror of
https://gitee.com/hhyykk/ipms-sjy.git
synced 2025-08-16 03:01:53 +08:00
拼团记录(APP):新增一个取消拼团的接口
This commit is contained in:
@@ -47,4 +47,9 @@ public class TradeOrderApiImpl implements TradeOrderApi {
|
||||
tradeOrderUpdateService.updateOrderCombinationInfo(orderId, activityId, combinationRecordId, headId);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void cancelPaidOrder(Long userId, Long orderId) {
|
||||
tradeOrderUpdateService.cancelPaidOrder(userId, orderId);
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -180,4 +180,12 @@ public interface TradeOrderUpdateService {
|
||||
*/
|
||||
void updateOrderCombinationInfo(Long orderId, Long activityId, Long combinationRecordId, Long headId);
|
||||
|
||||
/**
|
||||
* 取消支付订单
|
||||
*
|
||||
* @param userId 用户编号
|
||||
* @param orderId 订单编号
|
||||
*/
|
||||
void cancelPaidOrder(Long userId, Long orderId);
|
||||
|
||||
}
|
||||
|
@@ -918,6 +918,17 @@ public class TradeOrderUpdateServiceImpl implements TradeOrderUpdateService {
|
||||
.setCombinationRecordId(combinationRecordId).setCombinationHeadId(headId));
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void cancelPaidOrder(Long userId, Long orderId) {
|
||||
TradeOrderDO order = tradeOrderMapper.selectOrderByIdAndUserId(orderId, userId);
|
||||
if (order == null) {
|
||||
throw exception(ORDER_NOT_FOUND);
|
||||
}
|
||||
|
||||
cancelOrder0(order, TradeOrderCancelTypeEnum.MEMBER_CANCEL);
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建单个订单的评论
|
||||
*
|
||||
|
Reference in New Issue
Block a user