|
|
@ -217,15 +217,15 @@ public class TaskDeliverService implements ITaskDeliverService { |
|
|
|
//将文件信息与交付物绑定,添加记录deliverPostLog
|
|
|
|
if (CollectionUtil.isNotEmpty(uploadDeliver.getFileInfo())) { |
|
|
|
for (DeliverDto.FileInfo fileInfo : uploadDeliver.getFileInfo()) { |
|
|
|
SysCommitedFile file = commitedFileDao.selectByPrimaryKey(fileInfo.getId()); |
|
|
|
if(ObjectUtil.isNull(file)){ |
|
|
|
throw new BaseException(CodeEnum.NOT_DELIVER_FILE); |
|
|
|
} |
|
|
|
// SysCommitedFile file = commitedFileDao.selectByPrimaryKey(fileInfo.getId());
|
|
|
|
// if(ObjectUtil.isNull(file)){
|
|
|
|
// throw new BaseException(CodeEnum.NOT_DELIVER_FILE);
|
|
|
|
// }
|
|
|
|
ProTaskDeliverPostLog deliverPostLog = new ProTaskDeliverPostLog(); |
|
|
|
deliverPostLog.setId(snowflake.nextId()); |
|
|
|
deliverPostLog.setDeliverId(uploadDeliver.getDeliverId()); |
|
|
|
deliverPostLog.setTaskSubTimeId(subTimeId); |
|
|
|
deliverPostLog.setFileId(file.getId()); |
|
|
|
deliverPostLog.setFileId(fileInfo.getId()); |
|
|
|
deliverPostLog.setUserId(currentUserId); |
|
|
|
deliverPostLog.setDescription(uploadDeliver.getDescription()); |
|
|
|
deliverPostLog.setTime(now); |
|
|
@ -302,9 +302,9 @@ public class TaskDeliverService implements ITaskDeliverService { |
|
|
|
inMessage.setData(JacksonUtil.beanToJson(uploadMessage)); |
|
|
|
rabbitTemplate.convertAndSend(RabbitMQConfig.MESSAGE_QUEUE_NAME, |
|
|
|
JacksonUtil.beanToJson(inMessage) ); |
|
|
|
// //用智能助手发送消息
|
|
|
|
// SysProject project = sysProjectDao.selectByPrimaryKey(taskDetail.getProjectId());
|
|
|
|
// robotService.addDeliverRobotSend(currentUserId,taskDeliver.getName(),subTimeId, project);
|
|
|
|
//用智能助手发送消息
|
|
|
|
SysProject project = sysProjectDao.selectByPrimaryKey(taskDetail.getProjectId()); |
|
|
|
robotService.addDeliverRobotSend(currentUserId,taskDeliver.getName(),subTimeId, project); |
|
|
|
|
|
|
|
//返回
|
|
|
|
List<ProjectVo.DeliverInfo> deliverInfoList = taskDeliverDao.selectByDeliverId(uploadDeliver.getDeliverId()); |
|
|
@ -469,11 +469,14 @@ public class TaskDeliverService implements ITaskDeliverService { |
|
|
|
filePath.setDeleteTime(filePath.getUpdateTime().getTime()); |
|
|
|
} |
|
|
|
// TODO 修改文件路径为可下载路径
|
|
|
|
List<String> a = new ArrayList<>(); |
|
|
|
a.add(filePath.getFileId().toString()); |
|
|
|
|
|
|
|
if(StrUtil.isNotEmpty(filePath.getUrl())) { |
|
|
|
// filePath.setUrl(WebConstant.TEST_URL_BASE + filePath.getUrl());
|
|
|
|
filePath.setUrl(PropUtil.imgDomain + "/" + filePath.getUrl()); |
|
|
|
} |
|
|
|
|
|
|
|
// if(StrUtil.isNotEmpty(filePath.getUrl())) {
|
|
|
|
//// filePath.setUrl(WebConstant.TEST_URL_BASE + filePath.getUrl());
|
|
|
|
// filePath.setUrl(PropUtil.imgDomain + "/" + filePath.getUrl());
|
|
|
|
// }
|
|
|
|
if (ObjectUtil.isNotNull(filePath.getUploaderId())) { |
|
|
|
//添加上传人的姓名信息
|
|
|
|
ProMember member = proMemberService.selectByUserId(filePath.getUploaderId(), task.getProjectId()); |
|
|
|