|
@@ -43,9 +43,6 @@ func (srv TaskService) CreateTaskByProject(transactionContext application.Transa |
|
@@ -43,9 +43,6 @@ func (srv TaskService) CreateTaskByProject(transactionContext application.Transa |
43
|
taskRepo := factory.CreateTaskRepository(map[string]interface{}{
|
43
|
taskRepo := factory.CreateTaskRepository(map[string]interface{}{
|
44
|
"transactionContext": transactionContext,
|
44
|
"transactionContext": transactionContext,
|
45
|
})
|
45
|
})
|
46
|
- // taskStageRepo := factory.CreateTaskStageRepository(map[string]interface{}{
|
|
|
47
|
- // "transactionContext": transactionContext,
|
|
|
48
|
- // })
|
|
|
49
|
cnt, _, err := taskRepo.Find(map[string]interface{}{
|
46
|
cnt, _, err := taskRepo.Find(map[string]interface{}{
|
50
|
"name": param.Name,
|
47
|
"name": param.Name,
|
51
|
"leaderId": strconv.Itoa(param.LeaderId),
|
48
|
"leaderId": strconv.Itoa(param.LeaderId),
|
|
@@ -106,10 +103,6 @@ func (srv TaskService) CreateTaskByProject(transactionContext application.Transa |
|
@@ -106,10 +103,6 @@ func (srv TaskService) CreateTaskByProject(transactionContext application.Transa |
106
|
return application.ThrowError(application.INTERNAL_SERVER_ERROR, "创建任务失败:"+err.Error())
|
103
|
return application.ThrowError(application.INTERNAL_SERVER_ERROR, "创建任务失败:"+err.Error())
|
107
|
}
|
104
|
}
|
108
|
newTaskStage := []*domain.TaskStage{}
|
105
|
newTaskStage := []*domain.TaskStage{}
|
109
|
- // err = taskStageRepo.Save(newTaskStage)
|
|
|
110
|
- // if err != nil {
|
|
|
111
|
- // return application.ThrowError(application.INTERNAL_SERVER_ERROR, "创建任务失败:"+err.Error())
|
|
|
112
|
- // }
|
|
|
113
|
//记录待执行的里程碑
|
106
|
//记录待执行的里程碑
|
114
|
newTask.SetCurrentStage(newTaskStage)
|
107
|
newTask.SetCurrentStage(newTaskStage)
|
115
|
err = taskRepo.Save(&newTask)
|
108
|
err = taskRepo.Save(&newTask)
|