-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Drawing items not retaining the image when the form is closed and reopened #32
Comments
@MartijnR - We are seeing failed calls to retrieve signature, draw, and annotate item files. As seen in this screenshot, other files are loading when the form is opened but there is no successful call visible for them. So, it seems like the drawing items are trying to load their existing files in an unexpected manner. |
forgotten to include |
Please check if signature file is submitted successfully (and available) in the OC interface. And if so, if it fails to load even if it was submitted successfully. |
@MartijnR - The failed request is like: But the instance attachment is being sent like: |
I cannot reproduce this with curl \
--user changed: \
-d "\
server_url=https://enketo-aggregate.appspot.com&\
form_id=vitals&\
instance=
<demo-vitals-grid-v9>
<page2>
<media_yn>1</media_yn>
<pic_sig>img1.png</pic_sig>
<pic>img2.png</pic>
<pic_comment>{\"queries\":[], \"logs\":[{\"type\":\"audit\", \"comment\":\"Value changed
from \\\"img1.png\\\" to \\\"img2.png\\\"\", \"date_time\":\"2019-03-02 04:00:00
+06:00\"}]}</pic_comment>
</page2>
</demo-vitals-grid-v9>&\
instance_id=b&\
instance_attachments[img1.png]=https://github.com/enketo/enketo-express/raw/master/public/images/icon_180x180.png&\
instance_attachments[img2.png]=https://github.com/enketo/enketo-express/raw/master/public/images/offline-enabled.png&\
ecid=a\
" \
http://localhost:8005/oc/api/v1/instance/note The signature loads correctly in 6.2.2. The media serving code does not appear to have been changed since Sep 16th, 2022 (4.1.2). The /submission response for the record is: {
"instance": "\n<demo-vitals-grid-v9>\n <page2>\n <media_yn>1</media_yn>\n <pic_sig>img1.png</pic_sig>\n <pic>img2.png</pic>\n <pic_comment>{\"queries\":[], \"logs\":[{\"type\":\"audit\", \"comment\":\"Value changed\n from \\\"img1.png\\\" to \\\"img2.png\\\"\", \"date_time\":\"2019-03-02 04:00:00\n 06:00\"}]}</pic_comment>\n </page2>\n</demo-vitals-grid-v9>",
"instanceAttachments": {
"img1.png": "/media/get/1/b/img1.png",
"img2.png": "/media/get/1/b/img2.png"
}
}
However, the failed request URL shown in the previous comment indicates something goes wrong on the client. next steps:
|
The images are being loaded in the latest deployment. We need to test further to confirm it is working as expected. We'll remove the label and add a comment if it looks like further work is needed. |
Describe the bug
Drawing widget items with an appearance of "signature", "draw", or "annotate" do not continue to show the drawn signature after the form is closed and reopened.
To Reproduce
Open a form defined to have an item of type image and appearance signature
Fill in a drawn signature image
Close the form
Reopen the form
Signature drawing item is empty
The text was updated successfully, but these errors were encountered: