This commit is contained in:
Vinjor 2025-01-10 10:25:35 +08:00
parent 3949466a11
commit 7259ae143e
2 changed files with 8 additions and 7 deletions

View File

@ -610,7 +610,7 @@ public class DlRepairTicketsServiceImpl extends ServiceImpl<DlRepairTicketsMappe
// 更新订单状态
RepairOrderInfo one = repairOrderInfoService.getOne(new LambdaQueryWrapper<RepairOrderInfo>().eq(RepairOrderInfo::getGoodsId, repairTicketsRespVO.getId()));
if (ObjectUtil.isEmpty(one)) {
throw exception0(500, "系统异常");
throw exception0(500, "未找到该笔订单");
}
RepairOrderInfo repairOrderInfo = new RepairOrderInfo();
repairOrderInfo.setId(one.getId());
@ -622,7 +622,7 @@ public class DlRepairTicketsServiceImpl extends ServiceImpl<DlRepairTicketsMappe
// 线上支付需要在回调中去更新状态工单状态和订单状态
}else {
// 线下支付和签单挂账才是直接结束工单和订单
// 线下支付和签单挂账等其他支付方式才是直接结束工单和订单
DlRepairTickets repairTickets = this.getById(repairTicketsRespVO.getId());
if("1".equals(repairTickets.getIsHandover())){
//已交车已结算那么工单状态改为 已完成
@ -630,12 +630,13 @@ public class DlRepairTicketsServiceImpl extends ServiceImpl<DlRepairTicketsMappe
//工单结束
repairTicketsRespVO.setIsFinish("1");
}
// 更新工单
baseMapper.updateById(repairTicketsRespVO);
// 更新订单
// 设置订单支付时间和支付结果
repairOrderInfo.setPayTime(LocalDateTime.now());
repairOrderInfo.setOrderStatus("1");
}
// 更新工单
baseMapper.updateById(repairTicketsRespVO);
//更新订单
repairOrderInfoService.updateById(repairOrderInfo);
// 记录日志
repairRecordsService.saveRepairRecord(one.getGoodsId(), null, RecordTypeEnum.JS.getCode(), "线下支付结算", null);

View File

@ -178,8 +178,8 @@
billing_remark,
handle_name,
handle_mobile,
nextInspection_date,
insuranceExpiry_date,
next_inspection_date,
insurance_expiry_date,
insurance_type,
jiaoqiang,
shangye