提交 9a5b8eda 编写于 作者: Z zwZjut 提交者: lenboo

fix switchVersion error (#6783) (#6784)

Co-authored-by: Nhonghuo.zw <honghuo.zw@alibaba-inc.com>
Co-authored-by: NKirs <acm_master@163.com>
上级 652b9230
......@@ -282,10 +282,11 @@ public class TaskDefinitionServiceImpl extends BaseServiceImpl implements TaskDe
putMsg(result, Status.TASK_DEFINE_NOT_EXIST, taskCode);
return result;
}
TaskDefinitionLog taskDefinitionLog = taskDefinitionLogMapper.queryByDefinitionCodeAndVersion(taskCode, version);
taskDefinitionLog.setUserId(loginUser.getId());
taskDefinitionLog.setUpdateTime(new Date());
int switchVersion = taskDefinitionMapper.updateById(taskDefinitionLog);
TaskDefinitionLog taskDefinitionUpdate = taskDefinitionLogMapper.queryByDefinitionCodeAndVersion(taskCode, version);
taskDefinitionUpdate.setUserId(loginUser.getId());
taskDefinitionUpdate.setUpdateTime(new Date());
taskDefinitionUpdate.setId(taskDefinition.getId());
int switchVersion = taskDefinitionMapper.updateById(taskDefinitionUpdate);
if (switchVersion > 0) {
result.put(Constants.DATA_LIST, taskCode);
putMsg(result, Status.SUCCESS);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册