mirror of
https://github.com/hcengineering/platform.git
synced 2026-09-12 04:37:44 +02:00
TSK-1002 Fix extra attachments (#2863)
Signed-off-by: Denis Bykhov <bykhov.denis@gmail.com>
This commit is contained in:
@@ -234,7 +234,9 @@
|
||||
promises.push(deleteAttachment(p))
|
||||
})
|
||||
await Promise.all(promises)
|
||||
saveDraft()
|
||||
removeDraft(false)
|
||||
newAttachments.clear()
|
||||
removedAttachments.clear()
|
||||
}
|
||||
|
||||
$: if (attachments.size || newAttachments.size || removedAttachments.size) {
|
||||
|
||||
@@ -112,15 +112,7 @@
|
||||
}
|
||||
|
||||
if (Object.keys(updates).length > 0) {
|
||||
await client.updateCollection(
|
||||
issue._class,
|
||||
issue.space,
|
||||
issue._id,
|
||||
issue.attachedTo,
|
||||
issue.attachedToClass,
|
||||
issue.collection,
|
||||
updates
|
||||
)
|
||||
await client.update(issue, updates)
|
||||
saved = true
|
||||
setTimeout(() => {
|
||||
saved = false
|
||||
@@ -190,7 +182,6 @@
|
||||
_class={tracker.class.Issue}
|
||||
space={issue.space}
|
||||
alwaysEdit
|
||||
shouldSaveDraft={true}
|
||||
on:attached={save}
|
||||
on:detached={save}
|
||||
showButtons
|
||||
|
||||
Reference in New Issue
Block a user