Browse Source

代码优化

tags/v1.21.12.1^2
ychao_1983 4 years ago
parent
commit
a355fc9415
1 changed files with 2 additions and 5 deletions
  1. +2
    -5
      routers/repo/modelarts.go

+ 2
- 5
routers/repo/modelarts.go View File

@@ -69,11 +69,8 @@ func NotebookIndex(ctx *context.Context) {
}

for i, task := range ciTasks {
if task.Status == string(models.JobRunning) {
ciTasks[i].CanDebug = cloudbrain.CanCreateOrDebugJob(ctx)
} else {
ciTasks[i].CanDebug = false
}

ciTasks[i].CanDebug = cloudbrain.CanCreateOrDebugJob(ctx)
ciTasks[i].CanDel = cloudbrain.CanDeleteJob(ctx, &task.Cloudbrain)
}



Loading…
Cancel
Save