Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add masked corporate card number and employee name #673

Merged
merged 5 commits into from
Nov 26, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions apps/fyle/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ class Expense(models.Model):
custom_properties = JSONField(null=True)
is_skipped = models.BooleanField(null=True, default=False, help_text='Expense is skipped or not')
accounting_export_summary = JSONField(default=dict)
masked_corporate_card_number = models.CharField(max_length=255, help_text='Masked Corporate Card Number', null=True)
anishfyle marked this conversation as resolved.
Show resolved Hide resolved
previous_export_state = models.CharField(max_length=255, help_text='Previous export state', null=True)
workspace = models.ForeignKey(
Workspace, on_delete=models.PROTECT, help_text='To which workspace this expense belongs to', null=True
Expand Down
2 changes: 2 additions & 0 deletions apps/netsuite/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,8 @@ def get_expense_purpose(lineitem, category, configuration) -> str:

details = {
'employee_email': lineitem.employee_email,
'employee_name': lineitem.employee_name,
'card_number': '{0}'.format(lineitem.masked_corporate_card_number) if lineitem.masked_corporate_card_number else '',
'merchant': '{0}'.format(lineitem.vendor) if lineitem.vendor else '',
'category': '{0}'.format(category) if lineitem.category else '',
'purpose': '{0}'.format(lineitem.purpose) if lineitem.purpose else '',
Expand Down
Loading