From 819e1755f1000d1fc792eb7e9fc310aea58eca29 Mon Sep 17 00:00:00 2001 From: wangjr Date: Mon, 16 May 2022 15:27:32 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9bug=20=E7=82=B9=E5=87=BB?= =?UTF-8?q?=E6=8E=A8=E8=8D=90=E7=BB=84=E7=BB=87=E5=8D=A1=E7=89=87console?= =?UTF-8?q?=E6=9C=89Uncaught=20TypeError?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- templates/org/home.tmpl | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/templates/org/home.tmpl b/templates/org/home.tmpl index b929407ed..26f5ba186 100755 --- a/templates/org/home.tmpl +++ b/templates/org/home.tmpl @@ -39,7 +39,6 @@ {{end}} {{end}} - {{if .OrgTopics}} @@ -168,7 +167,10 @@ document.getElementById("icon_btn").innerHTML="   {{.i18n.Tr "org.unfold"}}" } } - isShowIconBtn() - iscontinueStatus() + + if ({{.OrgTopics}}.length>0){ + isShowIconBtn() + iscontinueStatus() + } \ No newline at end of file From 616e914be44ff49cfbd8e5bc2bbf82b1e4ceff8b Mon Sep 17 00:00:00 2001 From: ychao_1983 Date: Tue, 17 May 2022 10:20:36 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/cloudbrain/cloudbrain.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/modules/cloudbrain/cloudbrain.go b/modules/cloudbrain/cloudbrain.go index 3dee3a3fa..214897789 100755 --- a/modules/cloudbrain/cloudbrain.go +++ b/modules/cloudbrain/cloudbrain.go @@ -1,10 +1,12 @@ package cloudbrain import ( - "code.gitea.io/gitea/modules/timeutil" "encoding/json" "errors" "strconv" + "strings" + + "code.gitea.io/gitea/modules/timeutil" "code.gitea.io/gitea/modules/storage" @@ -188,7 +190,7 @@ func AdminOrImageCreaterRight(ctx *context.Context) { func GenerateTask(ctx *context.Context, displayJobName, jobName, image, command, uuid, codePath, modelPath, benchmarkPath, snn4imagenetPath, brainScorePath, jobType, gpuQueue, description, branchName, bootFile, params string, benchmarkTypeID, benchmarkChildTypeID, resourceSpecId int) error { - + image = strings.TrimSpace(image) dataActualPath := setting.Attachment.Minio.RealPath + setting.Attachment.Minio.Bucket + "/" + setting.Attachment.Minio.BasePath +