From 3d071264423e0850ec07720b1b6273ea4873f0bd Mon Sep 17 00:00:00 2001 From: liuzx Date: Thu, 24 Mar 2022 16:41:37 +0800 Subject: [PATCH 1/2] fix-bug --- models/attachment.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/models/attachment.go b/models/attachment.go index c7d058651..a3fc6fa01 100755 --- a/models/attachment.go +++ b/models/attachment.go @@ -571,8 +571,8 @@ func Attachments(opts *AttachmentsOptions) ([]*AttachmentInfo, int64, error) { } if opts.JustNeedZipFile { - var DecompressState []int - DecompressState = append(DecompressState, 1, 2, 3) + var DecompressState []int32 + DecompressState = append(DecompressState, DecompressStateDone, DecompressStateIng, DecompressStateFailed) cond = cond.And( builder.In("attachment.decompress_state", DecompressState), ) From a353c43e10c4508432bc723e97a6dcdd093a7633 Mon Sep 17 00:00:00 2001 From: liuzx Date: Fri, 25 Mar 2022 09:59:18 +0800 Subject: [PATCH 2/2] fix-1734 --- routers/repo/dataset.go | 2 -- 1 file changed, 2 deletions(-) diff --git a/routers/repo/dataset.go b/routers/repo/dataset.go index 11bd99149..d23722372 100755 --- a/routers/repo/dataset.go +++ b/routers/repo/dataset.go @@ -308,7 +308,6 @@ func CurrentRepoDataset(ctx *context.Context) { return } datasetIDs = append(datasetIDs, dataset.ID) - uploaderID := ctx.User.ID datasets, count, err := models.Attachments(&models.AttachmentsOptions{ ListOptions: models.ListOptions{ Page: page, @@ -317,7 +316,6 @@ func CurrentRepoDataset(ctx *context.Context) { Keyword: keyword, NeedDatasetIDs: true, DatasetIDs: datasetIDs, - UploaderID: uploaderID, Type: cloudbrainType, NeedIsPrivate: false, JustNeedZipFile: true,