|
|
@@ -479,19 +479,18 @@ public class BizClinicRoomServiceImpl implements IBizClinicRoomService {
|
|
|
BizAiAgentParamVO result = new BizAiAgentParamVO();
|
|
|
result.setAppId(aLiYunProperties.getAppId());
|
|
|
result.setApiKey(aLiYunProperties.getApiKey());
|
|
|
-// BizClinicRoomPO clinicRoom = baseRepository.selectById(source.getClinicId());
|
|
|
-// if(ObjectUtil.isNull(clinicRoom)){
|
|
|
-// throw new ServiceException(TRExcCode.SYSTEM_ERROR_B0001, "手术信息不存在");
|
|
|
-// }
|
|
|
- BizClinicRoomPO clinicRoom=new BizClinicRoomPO();
|
|
|
+ BizClinicRoomPO clinicRoom = baseRepository.selectById(source.getClinicId());
|
|
|
+ if(ObjectUtil.isNull(clinicRoom)){
|
|
|
+ throw new ServiceException(TRExcCode.SYSTEM_ERROR_B0001, "手术信息不存在");
|
|
|
+ }
|
|
|
if(StrUtil.isNotEmpty(clinicRoom.getMemoryId())){
|
|
|
result.setMemoryId(clinicRoom.getMemoryId());
|
|
|
}else {
|
|
|
try{
|
|
|
String memoryId = aLiYunService.createMemory();
|
|
|
result.setMemoryId(memoryId);
|
|
|
-// clinicRoom.setMemoryId(memoryId);
|
|
|
-// baseRepository.updateById(clinicRoom);
|
|
|
+ clinicRoom.setMemoryId(memoryId);
|
|
|
+ baseRepository.updateById(clinicRoom);
|
|
|
}catch (Exception e){
|
|
|
|
|
|
}
|