Sorry for that, but Django has utils.datastructures.DotExpandedDict. Here is part of this document:
>>> d = DotExpandedDict({'person.1.firstname': ['Simon'], \ 'person.1.lastname': ['Willison'], \ 'person.2.firstname': ['Adrian'], \ 'person.2.lastname': ['Holovaty']}) >>> d {'person': {'1': {'lastname': ['Willison'], 'firstname': ['Simon']}, '2': {'lastname': ['Holovaty'], 'firstname': ['Adrian']}}}
The only difference is the use of periods instead of brackets. I think that now it is conceptually replaced by prefix forms in form sets, but the class remains in the code base.
gzy Jan 20 2018-11-11T00: 00Z
source share