Browse Source

Merge pull request '国际化修改及下载日志文件出错的问题修改。' (#2747) from zouap into V20220830

Reviewed-on: https://git.openi.org.cn/OpenI/aiforge/pulls/2747
Reviewed-by: lewis <747342561@qq.com>
tags/v1.22.8.2^2
lewis 3 years ago
parent
commit
ae1bd3dbfe
3 changed files with 4 additions and 3 deletions
  1. +1
    -1
      options/locale/locale_en-US.ini
  2. +2
    -1
      routers/api/v1/repo/cloudbrain.go
  3. +1
    -1
      templates/repo/cloudbrain/trainjob/show.tmpl

+ 1
- 1
options/locale/locale_en-US.ini View File

@@ -259,7 +259,7 @@ page_dev_yunlao_desc3=China computing power network (C²NET) phase I can realize
page_dev_yunlao_desc4=Developers can freely select the corresponding computing resources according to the use needs, and can test the adaptability, performance, stability, etc. of the model in different hardware environments.
page_dev_yunlao_desc5=If your model requires more computing resources, you can also apply for it separately.
page_dev_yunlao_apply=Apply Separately
c2net_title=C²NET
c2net_title=China Computing Network
c2net_desc=The artificial intelligence computing power network promotion alliance has access to 11 intelligent computing centers, with a total scale of 1924p.
c2net_center=Center
search=Search


+ 2
- 1
routers/api/v1/repo/cloudbrain.go View File

@@ -378,6 +378,7 @@ func CloudbrainDownloadLogFile(ctx *context.Context) {
ctx.ServerError(err.Error(), err)
return
}

prefix := "/" + setting.CBCodePathPrefix + job.JobName + "/model"
files, err := storage.GetOneLevelAllObjectUnderDirMinio(setting.Attachment.Minio.Bucket, prefix, "")
if err != nil {
@@ -398,7 +399,7 @@ func CloudbrainDownloadLogFile(ctx *context.Context) {
ctx.ServerError("Get minio get SignedUrl failed", err)
return
}
http.Redirect(ctx.Resp, ctx.Req.Request, url, http.StatusMovedPermanently)
http.Redirect(ctx.Resp, ctx.Req.Request, url, http.StatusTemporaryRedirect)
}
}



+ 1
- 1
templates/repo/cloudbrain/trainjob/show.tmpl View File

@@ -499,7 +499,7 @@
<div>
<a id="{{.VersionName}}-log-down"
class='{{if $.canDownload}}ti-download-file{{else}}disabled{{end}}'
href="/api/v1/repos/{{$.RepoRelPath}}/cloudbrain/train-job/{{.JobID}}/download_log_file">
href="/api/v1/repos/{{$.RepoRelPath}}/cloudbrain/{{.ID}}/download_log_file">
<i class="ri-download-cloud-2-line"></i>
<span style="margin-left: 0.3rem;">{{$.i18n.Tr "repo.modelarts.download_log"}}</span>
</a>


Loading…
Cancel
Save