Browse Source

提交上传数据集的通知信息

Signed-off-by: zouap <zouap@pcl.ac.cn>
pull/1530/head
zouap 3 years ago
parent
commit
9c46022164
1 changed files with 3 additions and 3 deletions
  1. +3
    -3
      routers/repo/attachment.go

+ 3
- 3
routers/repo/attachment.go View File

@@ -845,8 +845,9 @@ func CompleteMultipart(ctx *context.Context) {
ctx.Error(500, fmt.Sprintf("InsertAttachment: %v", err))
return
}

notification.NotifyUploadAttachment(ctx.User, ctx.Repo.Repository, attachment)
dataset, _ := models.GetDatasetByID(attachment.DatasetID)
repository, _ := models.GetRepositoryByID(dataset.RepoID)
notification.NotifyUploadAttachment(ctx.User, repository, attachment)

if attachment.DatasetID != 0 {
if isCanDecompress(attachment.Name) {
@@ -867,7 +868,6 @@ func CompleteMultipart(ctx *context.Context) {
labelmsg.SendDecompressAttachToLabelOBS(string(attachjson))
}
} else {
dataset, _ := models.GetDatasetByID(attachment.DatasetID)
var labelMap map[string]string
labelMap = make(map[string]string)
labelMap["UUID"] = uuid


Loading…
Cancel
Save