ord_dict['2015-06-20'] = {}
ord_dict['2015-06-20']['a'] = '1'
ord_dict['2015-06-20']['b'] = '2'
ord_dict['2015-06-21'] = {}
ord_dict['2015-06-21']['a'] = '10'
ord_dict['2015-06-21']['b'] = '20'
return render(request, 'main.html', {'context': ord_dict})
How to render an ordered dictionary in django templates?