|
|
|
@@ -993,7 +993,7 @@ func RegisterRoutes(m *macaron.Macaron) { |
|
|
|
m.Get("", reqRepoCloudBrainReader, repo.CloudBrainShow) |
|
|
|
}) |
|
|
|
m.Group("/:jobid", func() { |
|
|
|
m.Get("/debug", reqWechatBind,cloudbrain.AdminOrJobCreaterRight, repo.CloudBrainDebug) |
|
|
|
m.Get("/debug", reqWechatBind, cloudbrain.AdminOrJobCreaterRight, repo.CloudBrainDebug) |
|
|
|
m.Post("/commit_image", cloudbrain.AdminOrJobCreaterRight, bindIgnErr(auth.CommitImageCloudBrainForm{}), repo.CloudBrainCommitImage) |
|
|
|
m.Post("/stop", cloudbrain.AdminOrOwnerOrJobCreaterRight, repo.CloudBrainStop) |
|
|
|
m.Post("/del", cloudbrain.AdminOrOwnerOrJobCreaterRight, repo.CloudBrainDel) |
|
|
|
@@ -1064,8 +1064,8 @@ func RegisterRoutes(m *macaron.Macaron) { |
|
|
|
m.Post("/:action", reqRepoCloudBrainWriter, repo.NotebookManage) |
|
|
|
m.Post("/del", cloudbrain.AdminOrOwnerOrJobCreaterRight, repo.NotebookDel) |
|
|
|
}) |
|
|
|
m.Get("/create", reqRepoCloudBrainWriter, repo.NotebookNew) |
|
|
|
m.Post("/create", reqRepoCloudBrainWriter, bindIgnErr(auth.CreateModelArtsNotebookForm{}), repo.Notebook2Create) |
|
|
|
m.Get("/create", reqWechatBind, reqRepoCloudBrainWriter, repo.NotebookNew) |
|
|
|
m.Post("/create", reqWechatBind, reqRepoCloudBrainWriter, bindIgnErr(auth.CreateModelArtsNotebookForm{}), repo.Notebook2Create) |
|
|
|
}) |
|
|
|
|
|
|
|
m.Group("/train-job", func() { |
|
|
|
@@ -1075,8 +1075,8 @@ func RegisterRoutes(m *macaron.Macaron) { |
|
|
|
m.Post("/stop", cloudbrain.AdminOrOwnerOrJobCreaterRight, repo.TrainJobStop) |
|
|
|
m.Post("/del", cloudbrain.AdminOrOwnerOrJobCreaterRight, repo.TrainJobDel) |
|
|
|
m.Get("/model_download", cloudbrain.AdminOrJobCreaterRight, repo.ModelDownload) |
|
|
|
m.Get("/create_version", cloudbrain.AdminOrJobCreaterRight, repo.TrainJobNewVersion) |
|
|
|
m.Post("/create_version", cloudbrain.AdminOrJobCreaterRight, bindIgnErr(auth.CreateModelArtsTrainJobForm{}), repo.TrainJobCreateVersion) |
|
|
|
m.Get("/create_version", reqWechatBind, cloudbrain.AdminOrJobCreaterRight, repo.TrainJobNewVersion) |
|
|
|
m.Post("/create_version", reqWechatBind, cloudbrain.AdminOrJobCreaterRight, bindIgnErr(auth.CreateModelArtsTrainJobForm{}), repo.TrainJobCreateVersion) |
|
|
|
}) |
|
|
|
m.Get("/create", reqWechatBind, reqRepoCloudBrainWriter, repo.TrainJobNew) |
|
|
|
m.Post("/create", reqWechatBind, reqRepoCloudBrainWriter, bindIgnErr(auth.CreateModelArtsTrainJobForm{}), repo.TrainJobCreate) |
|
|
|
|