Add missing key

This commit is contained in:
PCoder 2021-11-22 19:51:39 +05:30
parent 0f3497ce28
commit 926b650556

View file

@ -409,7 +409,7 @@ def handle_object_dict(object_dict, model_name):
object_dict['organization_id'] = int(float(object_dict['organization_id'])) object_dict['organization_id'] = int(float(object_dict['organization_id']))
if 'status' in object_dict: if 'status' in object_dict:
print('Getting status of %s' % object_dict['status']) print('Getting status of %s' % object_dict['status'])
object_dict['status'] = PeopleStatus.objects.get(int(object_dict['status'])) object_dict['status'] = PeopleStatus.objects.get(id=int(object_dict['status']))
for i in ['news_letter', 'birds', 'mammals', 'reptiles', 'amphibians', 'fish', 'insects', for i in ['news_letter', 'birds', 'mammals', 'reptiles', 'amphibians', 'fish', 'insects',
'molluscs', 'crustaceans', 'arachnids', 'angiosperms', 'gymnosperms', 'fungi', 'molluscs', 'crustaceans', 'arachnids', 'angiosperms', 'gymnosperms', 'fungi',
'algae', 'microbes', 'biological_field_sampling', 'data_mining', 'remote_sensing', 'algae', 'microbes', 'biological_field_sampling', 'data_mining', 'remote_sensing',