服务顾问通知客户取车前,判断项目价格、配件价格是否已填写
This commit is contained in:
parent
01c781478e
commit
5da4a45e7d
@ -336,6 +336,19 @@ public class DlRepairTicketsController {
|
|||||||
return CommonResult.ok();
|
return CommonResult.ok();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 判断是否工单子表的任何一个类目没有价格或价格为0
|
||||||
|
*
|
||||||
|
* @param id 工单ID
|
||||||
|
* @author 小李
|
||||||
|
* @date 15:00 2024/11/16
|
||||||
|
**/
|
||||||
|
@GetMapping("/hasPrice")
|
||||||
|
@Operation(summary = "判断是否工单子表的任何一个类目没有价格或价格为0")
|
||||||
|
public CommonResult<?> hasPrice(@RequestParam("id")String id){
|
||||||
|
return success(dlRepairTicketsService.hasPrice(id));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增工单子项
|
* 新增工单子项
|
||||||
*
|
*
|
||||||
|
@ -243,4 +243,13 @@ public interface DlRepairTicketsService extends IService<DlRepairTickets> {
|
|||||||
* @param respVO
|
* @param respVO
|
||||||
**/
|
**/
|
||||||
void overOrder(DlRepairTicketsRespVO respVO);
|
void overOrder(DlRepairTicketsRespVO respVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 判断是否工单子表的任何一个类目没有价格或价格为0
|
||||||
|
*
|
||||||
|
* @param id 工单ID
|
||||||
|
* @author 小李
|
||||||
|
* @date 15:00 2024/11/16
|
||||||
|
**/
|
||||||
|
Boolean hasPrice(String id);
|
||||||
}
|
}
|
||||||
|
@ -222,7 +222,6 @@ public class DlRepairTicketsServiceImpl extends ServiceImpl<DlRepairTicketsMappe
|
|||||||
// });
|
// });
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// 门店信息
|
// 门店信息
|
||||||
Long deptId = SecurityFrameworkUtils.getLoginUserDeptId();
|
Long deptId = SecurityFrameworkUtils.getLoginUserDeptId();
|
||||||
DeptRespDTO dept = deptApi.getDept(deptId);
|
DeptRespDTO dept = deptApi.getDept(deptId);
|
||||||
@ -1025,11 +1024,12 @@ public class DlRepairTicketsServiceImpl extends ServiceImpl<DlRepairTicketsMappe
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 指派施工,施工项目中不包含选中人员处理
|
* 指派施工,施工项目中不包含选中人员处理
|
||||||
* @author PQZ
|
*
|
||||||
* @date 16:30 2024/11/13
|
|
||||||
* @param ticketId 工单id
|
* @param ticketId 工单id
|
||||||
* @param nowRepairId 当前处理人id
|
* @param nowRepairId 当前处理人id
|
||||||
* @param nowRepairName 当前处理人名称
|
* @param nowRepairName 当前处理人名称
|
||||||
|
* @author PQZ
|
||||||
|
* @date 16:30 2024/11/13
|
||||||
**/
|
**/
|
||||||
private void setTicketItem(String ticketId, Long nowRepairId, String nowRepairName) {
|
private void setTicketItem(String ticketId, Long nowRepairId, String nowRepairName) {
|
||||||
//查询所有维修工
|
//查询所有维修工
|
||||||
@ -1468,6 +1468,29 @@ public class DlRepairTicketsServiceImpl extends ServiceImpl<DlRepairTicketsMappe
|
|||||||
repairRecordsService.saveRepairRecord(noticeCusVO.getId(), null, RecordTypeEnum.TZQC.getCode(), recordStr, null);
|
repairRecordsService.saveRepairRecord(noticeCusVO.getId(), null, RecordTypeEnum.TZQC.getCode(), recordStr, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 判断是否工单子表的任何一个类目没有价格或价格为0
|
||||||
|
*
|
||||||
|
* @param id 工单ID
|
||||||
|
* @author 小李
|
||||||
|
* @date 15:00 2024/11/16
|
||||||
|
**/
|
||||||
|
@Override
|
||||||
|
public Boolean hasPrice(String id) {
|
||||||
|
List<DlRepairTitem> titems = titemService.list(new LambdaQueryWrapper<DlRepairTitem>().in(DlRepairTitem::getTicketId, id));
|
||||||
|
for (DlRepairTitem item : titems) {
|
||||||
|
// 如果有为空的,直接报错
|
||||||
|
if (ObjectUtil.isEmpty(item.getItemPrice())) {
|
||||||
|
throw exception0(500, "工单中有项目或配件没有设置价格,请服务顾问填写项目价格,仓库填写配件价格");
|
||||||
|
}
|
||||||
|
// 如果有为0的,那就提示,让操作人选择
|
||||||
|
if (item.getItemPrice().equals(new BigDecimal("0.00"))){
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 重新计算工单的一些数值,子表也要重新计算
|
* 重新计算工单的一些数值,子表也要重新计算
|
||||||
*
|
*
|
||||||
|
Loading…
Reference in New Issue
Block a user