From f829bd5f800b37be1f7c707c5f070c6152f0d665 Mon Sep 17 00:00:00 2001 From: zouap Date: Tue, 8 Nov 2022 14:21:39 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: zouap --- routers/repo/attachment.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/routers/repo/attachment.go b/routers/repo/attachment.go index b65b6cfce..de1869f1f 100755 --- a/routers/repo/attachment.go +++ b/routers/repo/attachment.go @@ -682,6 +682,7 @@ func GetSuccessChunks(ctx *context.Context) { bucketName := setting.Bucket storage.ObsCopyFile(bucketName, srcObjectName, bucketName, destObjectName) } + UpdateModelSize(modeluuid) ctx.JSON(200, map[string]string{ "uuid": fileChunk.UUID, "uploaded": strconv.Itoa(fileChunk.IsUploaded), @@ -690,6 +691,7 @@ func GetSuccessChunks(ctx *context.Context) { "attachID": strconv.Itoa(int(attachID)), "fileName": attach.Name, }) + return } else { model, err := models.QueryModelById(dbmodeluuid) if err == nil { @@ -705,6 +707,7 @@ func GetSuccessChunks(ctx *context.Context) { "fileName": attach.Name, "modelName": modelname, }) + return } } else { dataset, err := models.GetDatasetByID(attach.DatasetID)