Skip to content

GitHub Issue 915: Bulk edit doesn't completely remove attachments for sources#7543

Merged
XingY merged 7 commits intodevelopfrom
fb_attachmentDIB
Apr 8, 2026
Merged

GitHub Issue 915: Bulk edit doesn't completely remove attachments for sources#7543
XingY merged 7 commits intodevelopfrom
fb_attachmentDIB

Conversation

@XingY
Copy link
Copy Markdown
Contributor

@XingY XingY commented Apr 3, 2026

Rationale

Attachment data iterator handles attachment insert when a value is provided for attachment column. However, it's not removing existing attachments.

Related Pull Requests

Changes

  • Remove existing attachment is new attachment value is blank or null
  • Remove existing attachment if new attachment is different from existing
  • Also use getDetails for ExistingRecord if the data type has attachment columns

@XingY XingY requested a review from labkey-susanh April 3, 2026 17:21
attachmentFiles.add(attachmentFile);
}

if ((null == attachmentFiles || attachmentFiles.isEmpty()) && oldAttachments.isEmpty())
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could simplify here by initializing attachmentFiles to an empty list.

@XingY XingY merged commit e7b83e8 into develop Apr 8, 2026
10 checks passed
@XingY XingY deleted the fb_attachmentDIB branch April 8, 2026 01:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants