✊🏿 Black Lives Matter. Please consider donating to Black Girls Code today.
⚡️ Concerned about the grid? Kyle Baranko teaches how to predicting peak loads using XGBoost. Register for the August webinar!

Default value of a dropdown list in a table column

I have created a table with a column that has a dropdown list (column dropdown). I find that unless I select a value in a row, the cell for that column/row remains empty.

Is there a way to set a default value of the dropdown ? It can be the same value for all rows in the column.

I could have set the default values in the data element of table defintion, however, I am using a database. I am using the ‘id’ (integer) of the database table as the dropdown values and the ‘type’ (string) of the database table as dropdown labels. So that makes setting the default dropdown values in the data element a bit tricky.

dropdown = {‘customer_type_id’:{‘options’:[{‘label’:row.type, ‘value’:row.id} for row in customer_types]} }

Did you find any solution ? @user123

@waminos, its been a long time since that post. I cannot remember what I did, sorry :thinking: