Skip to content

fix: upload signatures through the uploadUri link - #163

Merged
christian2denker merged 1 commit into
mainfrom
fix/signature-upload-uri
Sep 24, 2026
Merged

christian2denker merged 1 commit into
mainfrom
fix/signature-upload-uri

Conversation

@christian2denker

@christian2denker christian2denker commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Problem

A signature is a SignatureDataEntity, not an AttachmentDataEntity. ApptiveGridClient only looked at AttachmentDataEntity when it

  • looked up the uploadUri link of the field an attachment belongs to (_uploadUriLink), and
  • wrote the url the server assigned back into the form data (_applyAttachmentReplacements).

So when a form offers a uploadUri link, the signature file was uploaded to the location the server assigned, while the submitted signature still pointed at the url the client had generated in createAttachment, where no file exists. A uploadUri link on the signature field itself was ignored.

Fix

  • _uploadUriLink also matches a SignatureDataEntity that holds the attachment, so the field link is preferred over the form link as for attachment fields.
  • _applyAttachmentReplacements also replaces the value of a SignatureDataEntity.

Tests

Three new tests in test/api_client_upload_uri_test.dart:

  • the server uri is stored in the signature
  • the link of the signature field is preferred over the one of the form
  • a link on the signature field alone is enough (no configuration request)

dart analyze --fatal-infos is clean, all tests pass, and no line of apptive_grid_client.dart is uncovered.

Not in this PR

The upload target stays requested with {'type': 'public'} for every attachment, signatures included. That is intended.

🤖 Generated with Claude Code

A signature is a SignatureDataEntity, not an AttachmentDataEntity, so the
upload ignored the uploadUri link of its field and never wrote the url the
server assigned back into the signature. With a uploadUri link on the form,
the file went to the server location while the submitted signature pointed
at the url the client had generated, where no file exists.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added the p:core Changes to apptive_grid_core label Sep 24, 2026
@christian2denker
christian2denker merged commit 162dc42 into main Sep 24, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

p:core Changes to apptive_grid_core

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant