Question T13025
Visible to All Users

Error with uploaded documents. [urgent]

created 2 years ago (modified 2 years ago)

urgent

survey definition :

JSON
{ "title": "File upload", "logoPosition": "right", "pages": [ { "name": "page1", "elements": [ { "type": "panel", "name": "panel1", "elements": [ { "type": "text", "name": "uhid", "title": "Patient ID ", "isRequired": true }, { "type": "text", "name": "patient_name", "startWithNewLine": false, "title": "Initials", "description": "Enter the patient initials or first few letters of the name", "isRequired": true }, { "type": "text", "name": "age", "startWithNewLine": false, "title": "Age (years)", "description": "Please enter a whole number.", "isRequired": true, "inputType": "number" }, { "type": "radiogroup", "name": "gender", "startWithNewLine": false, "title": "Gender", "description": "Please select one.", "isRequired": true, "choices": [ { "value": "item1", "text": "Male" }, { "value": "Item2", "text": "Female" } ] }, { "type": "radiogroup", "name": "eligibility", "visibleIf": "{uhid} notempty", "title": "Eligibility", "defaultValue": "continue", "readOnly": true, "choices": [ "continue", "terminate" ] } ], "title": "Patient Registration" } ], "title": "Patient Registration", "description": "Enter the details of the patient to be enrolled in this study. You will be able to move ahead to the main form only for eligible patients as per the inclusion criteria" }, { "name": "page2", "elements": [ { "type": "text", "name": "user" }, { "type": "file", "name": "question1", "title": "test upload", "storeDataAsText": false } ] } ], "triggers": [ { "type": "runexpression" } ], "widthMode": "responsive"}

survey data:

JSON
{ "age": 34, "uhid": "multi 09 may", "gender": "item1", "pageNo": 1, "question1": [ { "name": "patient_form_data_202304262342-(553279).csv", "type": "", "content": "da1a74ea-3d6a-40de-8257-cc122daac8f3" }, { "name": "patient_form_data_202304262329-(804409).json", "type": "", "content": "b093d108-c12e-41b4-8a4c-65901c018d25" } ], "eligibility": "continue", "patient_name": "vinod", "SurveyComplete": false, "eligibilityStatus": true}

version: 1.9.86 (survey-angular-ui)

getting bellow error:
Clipboard-File-1.png

note: error is occuring when updated from version 1.9.66 to 1.9.86.
using survey.mergeData() to assign the data.
added all three event handlers, i.e. onUploadFiles, onDownloadFile, onClearFiles.

Show previous comments (22)

    Hi,
    I confirm that an image preview appears correctly in v1.9.88: https://codesandbox.io/s/surveyjs-angular-forked-k607t4?file=/src/app/components/survey.component.ts.

    JSON
    "survey-angular-ui": "1.9.88", "survey-core": "1.9.88"

    Clipboard-File-1.png

    Would you please share a problematic demo for research?

      that preview thing is my code issue. but now i am facing one more issue with survey-pdf. you can find the example below,

      https://codesandbox.io/s/surveyjs-angular-forked-h1cze3

      click on the complete after uploading document.

        Hello,
        Thank you for the update. As your recent issue relates to another library, I created a separate ticket on your behalf: T13152: Issue with Survey PDF Generator. We placed it in our processing queue and will process it shortly.