Reputation: 212
I have a sample PDF file and tried uploading it by converting it to JSON. It shows the upload is progressing. But I couldn't see my form. I have checked my JSON and is valid. Please help.
Below is my sample json
{ "forms": [{ "title": "sample pdf upload", "display": "form", "type": "form", "name": "sample pdf upload", "path": "sample pdf upload", "tags": [ "common" ], "pages": [{ "pageNo": 1, "trimBoxOriginX": 0.0, "trimBoxOriginY": 0.0, "trimBoxWidth": 595.2755737304688, "trimBoxHeight": 841.8897705078125, "txtRns": [{ "leftX": 208.4706, "bottomY": 67.3442, "rightX": 405.8626, "topY": 52.3362, "baseLineY": 63.9842, "fontId": 1, "text": "Sample Fillable PDF Form" }, { "leftX": 51.52, "bottomY": 87.0426, "rightX": 565.0849, "topY": 75.7866, "baseLineY": 84.5226, "fontId": 2, "text": "Fillable PDF forms can be customised to your needs. They allow form recipients to fill out " }, { "leftX": 51.5177, "bottomY": 100.4482, "rightX": 459.0569, "topY": 89.1922, "baseLineY": 97.9282, "fontId": 2, "text": "information on screen like a web page form, then print, save or email the results." }, { "leftX": 57.189, "bottomY": 149.4049, "rightX": 136.557, "topY": 138.1489, "baseLineY": 146.8849, "fontId": 3, "text": "Fillable Fields" }, { "leftX": 57.189, "bottomY": 169.2474, "rightX": 89.193, "topY": 157.9914, "baseLineY": 166.7274, "fontId": 2, "text": "Name" }, { "leftX": 395.9291, "bottomY": 169.2474, "rightX": 424.6091, "topY": 157.9914, "baseLineY": 166.7274, "fontId": 2, "text": "Date " }, { "leftX": 425.838, "bottomY": 169.4618, "rightX": 432.51, "topY": 157.4618, "baseLineY": 166.5317, "fontId": 4, "text": "1" }, { "leftX": 463.838, "bottomY": 169.5808, "rightX": 483.182, "topY": 157.5808, "baseLineY": 166.6507, "fontId": 4, "text": "Jan" }, { "leftX": 509.904, "bottomY": 169.5618, "rightX": 536.5923, "topY": 157.5618, "baseLineY": 166.6317, "fontId": 4, "text": "2012" }, { "leftX": 57.189, "bottomY": 186.2552, "rightX": 101.205, "topY": 174.9992, "baseLineY": 183.7352, "fontId": 2, "text": "Address" }, { "leftX": 57.189, "bottomY": 285.6365, "rightX": 317.0465, "topY": 274.3805, "baseLineY": 283.1165, "fontId": 3, "text": "Tick Boxes (multiple options can be selected)" }, { "leftX": 57.189, "bottomY": 305.479, "rightX": 241.257, "topY": 294.223, "baseLineY": 302.959, "fontId": 2, "text": "What are your favourite activities? " }, { "leftX": 57.189, "bottomY": 318.8849, "rightX": 118.557, "topY": 307.6289, "baseLineY": 316.3649, "fontId": 2, "text": " Reading " }, { "leftX": 57.189, "bottomY": 332.2908, "rightX": 116.0851, "topY": 321.0348, "baseLineY": 329.7708, "fontId": 2, "text": " Walking " }, { "leftX": 57.1887, "bottomY": 345.6966, "rightX": 105.2007, "topY": 334.4406, "baseLineY": 343.1766, "fontId": 2, "text": " Music " }, { "leftX": 57.1887, "bottomY": 359.1026, "rightX": 107.2167, "topY": 347.8466, "baseLineY": 356.5826, "fontId": 2, "text": " Other: " }, { "leftX": 57.189, "bottomY": 454.2137, "rightX": 332.565, "topY": 442.9577, "baseLineY": 451.6937, "fontId": 3, "text": "Radio Buttons (only one option can be selected)" }, { "leftX": 57.189, "bottomY": 474.0563, "rightX": 223.245, "topY": 462.8003, "baseLineY": 471.5363, "fontId": 2, "text": "What is your favourite activity? " }, { "leftX": 57.189, "bottomY": 487.4619, "rightX": 118.557, "topY": 476.2059, "baseLineY": 484.9419, "fontId": 2, "text": " Reading " }, { "leftX": 57.189, "bottomY": 500.8675, "rightX": 116.0851, "topY": 489.6115, "baseLineY": 498.3475, "fontId": 2, "text": " Walking " }, { "leftX": 57.1887, "bottomY": 514.2734, "rightX": 105.2007, "topY": 503.0174, "baseLineY": 511.7534, "fontId": 2, "text": " Music " }, { "leftX": 57.1887, "bottomY": 527.6793, "rightX": 107.2167, "topY": 516.4233, "baseLineY": 525.1593, "fontId": 2, "text": " Other: " }, { "leftX": 57.189, "bottomY": 622.7907, "rightX": 257.865, "topY": 611.5347, "baseLineY": 620.2707, "fontId": 3, "text": "Buttons (to prompt certain actions)" }, { "leftX": 57.189, "bottomY": 642.6332, "rightX": 386.0129, "topY": 631.3772, "baseLineY": 640.1132, "fontId": 2, "text": "These buttons can be printable or visible only when onscreen." }, { "leftX": 67.2136, "bottomY": 701.4379, "rightX": 91.8856, "topY": 689.4379, "baseLineY": 698.5078, "fontId": 4, "text": "Print" }, { "leftX": 146.296, "bottomY": 701.4379, "rightX": 173.6441, "topY": 689.4379, "baseLineY": 698.5078, "fontId": 4, "text": "Save" }, { "leftX": 429.8151, "bottomY": 808.3642, "rightX": 562.5142, "topY": 797.1082, "baseLineY": 805.8442, "fontId": 2, "text": "www.worldofprinting.com" } ], "txtChars": null }], "fontSpecs": [{ "id": 1, "fontFamily": "ArialMT,Bold", "fontSize": 16.0, "italic": false, "bold": true, "color": "#171615" }, { "id": 2, "fontFamily": "ArialMT", "fontSize": 12.0, "italic": false, "bold": false, "color": "#171615" }, { "id": 3, "fontFamily": "ArialMT,Bold", "fontSize": 12.0, "italic": false, "bold": true, "color": "#171615" }, { "id": 4, "fontFamily": "Arial", "fontSize": 12.0, "italic": false, "bold": false, "color": "#000000" } ]
}]
}
Upvotes: 1
Views: 51
Reputation: 1182
The Sample form Json syntax seems Wrong for the opensource formsflow.ai. The Open source form.io Package Doesn't support Pdf forms. Also, the upload Sample Json Should Include the "components" key which is missing in the above Form Definition.
Upvotes: 1