Skip to content

Commit

Permalink
Adding iexact in mapping creation (#10)
Browse files Browse the repository at this point in the history
  • Loading branch information
Shwetabhk authored Feb 25, 2021
1 parent 3ef4608 commit d6abfdd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions fyle_accounting_mappings/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,9 +193,9 @@ def create_or_update_mapping(source_type: str, destination_type: str,

mapping, _ = Mapping.objects.update_or_create(
source_type=source_type,
source=ExpenseAttribute.objects.get(
attribute_type=source_type, value=source_value, workspace_id=workspace_id
) if source_value else None,
source=ExpenseAttribute.objects.filter(
attribute_type=source_type, value__iexact=source_value, workspace_id=workspace_id
).first() if source_value else None,
destination_type=destination_type,
workspace=Workspace.objects.get(pk=workspace_id),
defaults={
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

setuptools.setup(
name='fyle-accounting-mappings',
version='0.9.0',
version='0.10.0',
author='Shwetabh Kumar',
author_email='[email protected]',
description='Django application to store the fyle accounting mappings in a generic manner',
Expand Down

0 comments on commit d6abfdd

Please sign in to comment.