更新10.8

This commit is contained in:
许允枞 2024-10-08 11:17:08 +08:00
parent cd15a2cf0b
commit aadf0ddd5f

View File

@ -472,6 +472,7 @@ public class FleetInfoServiceImpl extends ServiceImpl<FleetInfoMapper, FleetInfo
*/
@Override
public int refundFleet(String orderId) {
AccountInfo nowAccountInfo = TokenUtil.getNowAccountInfo();
//通过订单id查询订单信息
AllOrderInfo allOrderInfo = allOrderInfoMapper.selectOne(new LambdaQueryWrapper<AllOrderInfo>()
.eq(AllOrderInfo::getId, orderId));
@ -497,6 +498,11 @@ public class FleetInfoServiceImpl extends ServiceImpl<FleetInfoMapper, FleetInfo
fleetInfo.setGiveAmount(fleetInfo.getGiveAmount() + (refundMoney * give));
//将退款金额修改回去
baseMapper.updateById(fleetInfo);
//将车队订单表改为退款
fleetConsumeRecord.setOrderStatus("refund");
fleetConsumeRecord.setUpdateTime(DateUtil.date());
fleetConsumeRecord.setUpdateBy(nowAccountInfo.getStaffId().toString());
return fleetConsumeRecordMapper.updateById(fleetConsumeRecord);
}
return 0;
}