django select data from database code example
Example: get data from database html select option django
<select name="food_status">
{% for id, choice in order.FoodStatus %}
<option value="{{ id }}"{% if order.food_status == id %} selected="selected"{% endif %}>{{ choice }}</option>
{% endfor %}
</select>
https://stackoverflow.com/questions/56196937/select-data-from-drop-down-list-and-save-it-to-database-in-django