Compare commits

..

No commits in common. "0f9fb5828126834aad5f97f8ce47e8cc1d8440f5" and "fcf04d8ad257e66484119cbac99808883a89d8f9" have entirely different histories.

3 changed files with 11 additions and 28 deletions

View File

@ -1,6 +1,5 @@
package cn.iocoder.yudao.module.custom.controller.admin;
import cn.hutool.core.collection.CollectionUtil;
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
import cn.iocoder.yudao.module.custom.entity.CustomerMain;
import cn.iocoder.yudao.module.custom.service.CustomerCarService;
@ -24,7 +23,6 @@ import javax.validation.Valid;
import java.util.List;
import static cn.iocoder.yudao.common.BaseConstants.*;
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception0;
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
/**
@ -192,13 +190,11 @@ public class CustomerMainController {
@PostMapping("/getByNameAndMobile")
@Operation(summary = "根据姓名和电话查询单条记录")
public CommonResult<?> getByNameAndMobile(@Valid @RequestBody CustomerMain customerMain) {
List<CustomerMain> list = customerMainService.list(new LambdaQueryWrapper<CustomerMain>().and(item -> {
CustomerMain one = customerMainService.getOne(new LambdaQueryWrapper<CustomerMain>().and(item -> {
item.eq(CustomerMain::getCusName, customerMain.getCusName())
.eq(CustomerMain::getPhoneNumber, customerMain.getPhoneNumber());
}));
if (CollectionUtil.isNotEmpty(list)) {
return success(list.get(0));
}
throw exception0(500, "系统异常");
return success(one);
}
}

View File

@ -491,15 +491,13 @@ public class DlRepairTicketsServiceImpl extends ServiceImpl<DlRepairTicketsMappe
repairOrderInfo.setPayType(repairTicketsRespVO.getPayType());
// 更新工单
// 在这里把工单的状态更新为已完成---需要判断如果是线上支付需要在支付回调更新----有点问题
if (repairTicketsRespVO.getPayType().equals("01")){
// 线上支付需要在回调中去更新状态工单状态和订单状态
}else {
// 线下支付和签单挂账才是直接结束工单和订单
// 更新工单
// 在这里把工单的状态更新为已完成---需要判断如果是线上支付需要在支付回调更新
if (!repairTicketsRespVO.getPayType().equals("01")) {
// 不在这儿结束
// repairTicketsRespVO.setIsFinish("1");
baseMapper.updateById(repairTicketsRespVO);
// 更新订单
} else {
// 线下结账和签单挂账直接算已支付
repairOrderInfo.setPayTime(LocalDateTime.now());
repairOrderInfo.setOrderStatus("1");
}
@ -1523,11 +1521,6 @@ public class DlRepairTicketsServiceImpl extends ServiceImpl<DlRepairTicketsMappe
.set(DlRepairTickets::getTicketsStatus, TicketsStatusEnum.NO_PAY.getCode())
.eq(DlRepairTickets::getId, noticeCusVO.getId())
);
// 这里如果是拨打电话通知的就不走下面的逻辑了判断条件是看name是不是就是客户的名字
if (noticeCusVO.getName().equals(tickets.getUserName())){
repairRecordsService.saveRepairRecord(noticeCusVO.getId(), null, RecordTypeEnum.TZQC.getCode(), tickets.getAdviserName() + "电话通知客户取车", null);
return;
}
CustomerMain cus = customerService.getById(tickets.getUserId());
// 维修项目
List<DictDataRespDTO> repairType = dictDataApi.getDictDataList(DICT_REPAIR_TYPE);

View File

@ -169,17 +169,11 @@
</select>
<select id="getTicketsPage" resultMap="BaseResultMap">
<include refid="Base_SQL"/>
-- 已结算的
<if test="map.ticketsStatus != null and map.ticketsStatus != '' and map.ticketsStatus == '02'">
and drt.tickets_status in ('08', #{map.ticketsStatus})
</if>
-- 已作废的
<if test="map.ticketsStatus != null and map.ticketsStatus != '' and map.ticketsStatus == '03'">
<if test="map.ticketsStatus != null and map.ticketsStatus != '' and map.ticketsStatus != '01'">
and drt.tickets_status = #{map.ticketsStatus}
</if>
-- 待结算的
<if test="map.ticketsStatus != null and map.ticketsStatus != '' and map.ticketsStatus == '01'">
and (drt.tickets_status = #{map.ticketsStatus})
and (drt.tickets_status = #{map.ticketsStatus} or drt.tickets_status = '06')
</if>
<if test="map.ticketNo != null and map.ticketNo != ''">
and (