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

Comment Post to Integration settings #431

Merged
merged 1 commit into from
Feb 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
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
3 changes: 2 additions & 1 deletion apps/workspaces/apis/advanced_settings/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,8 @@ def update(self, instance, validated):
if instance.onboarding_state == 'ADVANCED_CONFIGURATION':
instance.onboarding_state = 'COMPLETE'
instance.save()
AdvancedConfigurationsTriggers.post_to_integration_settings(instance.id, True)
# Commenting this for now, will uncomment once we expose to UI
# AdvancedConfigurationsTriggers.post_to_integration_settings(instance.id, True)

return instance

Expand Down
30 changes: 16 additions & 14 deletions scripts/python/fill-accounting-export-summary.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,23 +52,25 @@
error_type = 'ACCOUNTING_INTEGRATION_ERROR' if task_log.sage_intacct_errors else 'MAPPING'
url = '{}/workspaces/main/dashboard'.format(settings.INTACCT_INTEGRATION_APP_URL)
else:
export_id = expense_group.response_logs['url_id']
url = 'https://www-p02.intacct.com/ia/acct/ur.phtml?.r={export_id}'.format(
export_id=export_id
)
if expense_group.response_logs and 'url_id' in expense_group.response_logs:
export_id = expense_group.response_logs['url_id']
url = 'https://www-p02.intacct.com/ia/acct/ur.phtml?.r={export_id}'.format(
export_id=export_id
)
for expense in expense_group.expenses.filter(accounting_export_summary__state__isnull=True):
expense_to_be_updated.append(
Expense(
id=expense.id,
accounting_export_summary=get_updated_accounting_export_summary(
expense.expense_id,
state,
error_type,
url,
False
if url:
expense_to_be_updated.append(
Expense(
id=expense.id,
accounting_export_summary=get_updated_accounting_export_summary(
expense.expense_id,
state,
error_type,
url,
False
)
)
)
)
print('Updating {} expenses in batches of 50'.format(len(expense_to_be_updated)))
__bulk_update_expenses(expense_to_be_updated)

Expand Down
Loading