You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
During review for the detailed design, we decided we should support offline pattern B when manually exporting reports here. To implement that we need to
Create an optimistic EXPORTINTEGRATION action in our Report.exportToIntegration and Report.markAsManuallyExported actions
The text should say started exporting this report to {integration}...
Pass the optimisticReportActionID to both Report_Export and MarkAsExported APIs
Use the ID to create the action in Auth
Auth will queue updates for the report action with the final text: exported this report to {integration}. [View out-of-pocket expenses].
On failure
create the INTEGRATIONSMESSAGE action with the error message like normal (using a different ID)
delete the optimistic action on the frontend using failureData
Manual Test Steps
Sucessful offline export
Submit an expense report
Log in as the workspace admin
Approve the report
Go offline
3-dot menu > Export > Quickbooks Online
Verify a semi-transparent started exporting this report to QuickBooks Online... message shows
Go online
Verify the action becomes fully opaque
Wait a few seconds
Verify the action updates to exported this report to QuickBooks Online. [View out-of-pocket expenses].
Failed offline export
Prerequisites
Add a chart of account (category) to QBO that you can delete later
Steps
Create a report with an expense
Categorize the expense using the new QBO category
Submit it
Log in as the workspace admin and approve the report
Log into QBO and deactivate the chart of account for the category (Menu > Transactions > Chart of accounts > {account} menu > Make inactive)
Go offline in NewDot
Export the report to QBO (3-dot menu > Export > Quickbooks Online)
Verify a semi-transparent started exporting this report to QuickBooks Online... message shows
Go online
Verify the action becomes fully opaque
Wait a few seconds
Verify a report export error message is added the report
Automated Tests
Verify optimisticData for the INTEGRATIONSMESSAGE is merged for both Report.exportToIntegration and Report.markAsManuallyExported actions
Part of QBO Export and Error Handling in NewDot
Doc section: https://docs.google.com/document/d/1aQl-AK_F6IqszWYG2aEllTsD5x3h4b8Zu0XEG0LuQ08/edit#heading=h.xw0s9oqvo44s
Project: [#whatsnext] #wave-collect
Feature Description
During review for the detailed design, we decided we should support offline pattern B when manually exporting reports here. To implement that we need to
EXPORTINTEGRATIONaction in ourReport.exportToIntegrationandReport.markAsManuallyExportedactionsstarted exporting this report to {integration}...optimisticReportActionIDto bothReport_ExportandMarkAsExportedAPIsexported this report to {integration}. [View out-of-pocket expenses].INTEGRATIONSMESSAGEaction with the error message like normal (using a different ID)failureDataManual Test Steps
Sucessful offline export
started exporting this report to QuickBooks Online...message showsexported this report to QuickBooks Online. [View out-of-pocket expenses].Failed offline export
Prerequisites
Steps
started exporting this report to QuickBooks Online...message showsAutomated Tests
INTEGRATIONSMESSAGEis merged for bothReport.exportToIntegrationandReport.markAsManuallyExportedactionsIssue Owner
Current Issue Owner: @dylanexpensify