I’m building different forms with Vue and gravity forms. Everything has been working well so far. However, right now I would like to us the list field to submit different inputs programmatically but I’ve been failing to do so.
This is my field right now:
"fields": [
{
"type": "list",
"id": 4,
"formId": 3,
"label": "Available Days & Time",
"adminLabel": "",
"isRequired": false,
"size": "large",
"errorMessage": "",
"visibility": "visible",
"inputs": null,
"description": "",
"allowsPrepopulate": false,
"inputMask": false,
"inputMaskValue": "",
"inputMaskIsCustom": false,
"maxLength": "",
"inputType": "",
"labelPlacement": "",
"descriptionPlacement": "",
"subLabelPlacement": "",
"placeholder": "",
"cssClass": "",
"inputName": "",
"noDuplicates": false,
"defaultValue": "",
"enableAutocomplete": false,
"autocompleteAttribute": "",
"choices": [
{
"text": "Day",
"value": "Day",
"isSelected": false,
"price": ""
},
{
"text": "Hours",
"value": "Hours",
"isSelected": false,
"price": ""
}
],
"conditionalLogic": "",
"maxRows": 0,
"enableColumns": true,
"productField": "",
"layoutGridColumnSpan": 12,
"enableEnhancedUI": 0,
"layoutGroupId": "b07de714",
"multipleFiles": false,
"maxFiles": "",
"calculationFormula": "",
"calculationRounding": "",
"enableCalculation": "",
"disableQuantity": false,
"displayAllCategories": false,
"useRichTextEditor": false,
"checkboxLabel": "",
"errors": [],
"pageNumber": 1,
"fields": ""
}
],
Is a list field that supports 2 values, one is day and the other hour.
I tried sending the next JSON:
{
"input_4_1": "Monday",
"input_4_2": "8-10AM, 10-12AM"
}
and this is the response:
{
"is_valid": false,
"validation_messages": {
"4": "At least one field must be filled out"
},
"page_number": 1,
"source_page_number": 1
}
How should I compose my request to be able to submit multiple values?