Hello,
I’m struggeling with the API. I’m using Python (Django Framework) for my contact form. In this form is a multiple choice checkbox which I want to match to the drop-down field in monday.com.
Now I have to iterate through the list in the dictionary “data_dict”. Does anyone have an idea how to do this?
This is my vars dictionary from the API:
vars = {
'myItemName': data_dict['nachname'] + ", " + data_dict['vorname'],
'columnVals': json.dumps({
'status': {'label': 'Neu'},
'e_mail': {'email': data_dict['email'], 'text': data_dict['email']},
'telefon': {'phone': str(data_dict['telefon']), 'countryShortName': 'CH'},
'text9': data_dict['plz'],
'drop_down': {'labels': [data_dict['person']]},
'drop_down5': {'labels': [data_dict['beruf']]},
'drop_down59': {'labels': [data_dict['prio'][0]]},
'drop_down7': {'labels': [data_dict['alter']]},
})
}
As it is now just the first item would be passed in to the ‘drop_down59’ field. But there should be multiple items if not empty.
Kind regards,
Klemens