Skip to content
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

Review-only Mode Is Causing item data Submissions #24

Open
eprager412 opened this issue Dec 1, 2023 · 2 comments
Open

Review-only Mode Is Causing item data Submissions #24

eprager412 opened this issue Dec 1, 2023 · 2 comments
Assignees
Milestone

Comments

@eprager412
Copy link

eprager412 commented Dec 1, 2023

Describe the bug
When you submit a data signature on a multi page form, and open the form to view after completing, the signature data will be resubmitted as a new .png file without the user interacting with it at all.

To Reproduce
Steps to reproduce:

  1. Open attached form in mode /single/full/participant/
    simplesignature.txt

  2. Sketch a value in the '####Signature" item

  3. Click away and ensure the value submits successfully

  4. Complete the record

  5. Open the form in review-only mode with the instance from above with view /edit/fs/dn/c/i/

Expected behavior
No saved changes and only 1 .png file.

Actual behavior:
The form immediately initiates a submission for the signature item and then shows "All changes saved" message. Since the form is opened in review-only mode there should be no item data submissions at all. There also should be no submissions for the signature item without the user interacting with it even if the form were opened in edit mode.

Screenshots
Note the signature shown in the screenshots was a full name and now is a zoomed in version of the left hand corner of the original. That is logged as #25 .

image (53) (2)

2023-11-30_14-03-53

2023-11-30_14-04-03

@pbowen-oc pbowen-oc added this to the Next milestone Dec 1, 2023
@pbowen-oc pbowen-oc changed the title View Mode Is Causing Data Submission Review-only Mode Is Causing item data Submissions Dec 1, 2023
@MartijnR
Copy link
Member

MartijnR commented Dec 6, 2023

likely same as #25. To investigate

@MartijnR
Copy link
Member

MartijnR commented Dec 12, 2023

curl --user enketorules: -d \
    "server_url=http://localhost:3000&form_id=simplesignature&ecid=1&instance_id=a&instance=\
    <data xmlns:OpenClinica=\"http://openclinica.com/odm\" xmlns:enk=\"http://enketo.org/xforms\" xmlns:jr=\"http://openrosa.org/javarosa\" xmlns:oc=\"http://openclinica.org/xforms\" xmlns:orx=\"http://openrosa.org/xforms\" id=\"simplesignature\" version=\"BTest2\">\
    <group_zt8fu31_002>\
        <Patient_Signature_002_001>signature-14_12_44.png</Patient_Signature_002_001>\
    </group_zt8fu31_002>\
    <group_ar1jd35>\
        <note/>\
    </group_ar1jd35>\
    <meta>\
        <instanceID>uuid:376611b3-1506-4c11-b21a-3a246f6574f2</instanceID>\
    </meta>\
    </data>\
    &instance_attachments[signature-14_12_44.png]=http://localhost:3000/form/simplesignature/media/signature-14_12_44.png" \
http://localhost:8005/oc/api/v1/instance/note/c

I was able to reproduce this.

@MartijnR MartijnR transferred this issue from OpenClinica/enketo-express-oc May 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants