Skip to content

Commit

Permalink
update the orm query (#553)
Browse files Browse the repository at this point in the history
  • Loading branch information
Hrishabh17 authored Sep 18, 2024
1 parent c723285 commit 1210207
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions apps/sage_intacct/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -1008,10 +1008,10 @@ def create_journal_entry_lineitems(expense_group: ExpenseGroup, configuration: C
employee_id = None

if settings.BRAND_ID == 'fyle':
entity = EmployeeMapping.objects.get(
entity = EmployeeMapping.objects.filter(
source_employee__value=description.get('employee_email'),
workspace_id=expense_group.workspace_id
)
).first()

employee_id = entity.destination_employee.destination_id if entity and entity.destination_employee and employee_mapping_setting == 'EMPLOYEE' else None

Expand Down

0 comments on commit 1210207

Please sign in to comment.