def get_all_items(obj):
if hasattr(obj, '<STR_LIT>'):<EOL><INDENT>items = []<EOL>for key in obj:<EOL><INDENT>for value in obj.getlist(key):<EOL><INDENT>items.append((key, value))<EOL><DEDENT><DEDENT>return items<EOL><DEDENT>else:<EOL><INDENT>return obj.items()<EOL><DEDENT>
dict.items() but with a separate row for each value in a MultiValueDict