Release 1: Align Snapshot and Live Onyx data types
We'll begin by aligning the snapshot and live Onyx data types. Each of the keys below will be addressed in individual issues that will be worked on in parallel by external contributors. Here's the plan to deprecate each key in Search* types in favor of those in onyx/types/
SearchTransaction > transactionType
- In App, create a new function
getTransactionType, which will:
- If
transaction.comment.customUnit.name === 'Distance', return distance
- If
transaction.comment.customUnit.name === 'Per Diem International', return perDiem
- If
cardList[transaction.cardID].cardName === '__CASH__', return cash
- Otherwise return
card
- Remove transactionType
- Run
npm run typecheck. Fix any errors by replacing the calls to transaction.transactionType with getTransactionType
- In Auth, remove these lines from the query
Parent Issue: https://github.com/Expensify/Expensify/issues/563552
Release 1: Align Snapshot and Live Onyx data types
We'll begin by aligning the snapshot and live Onyx data types. Each of the keys below will be addressed in individual issues that will be worked on in parallel by external contributors. Here's the plan to deprecate each key in Search* types in favor of those in onyx/types/
SearchTransaction > transactionType
getTransactionType, which will:transaction.comment.customUnit.name === 'Distance', returndistancetransaction.comment.customUnit.name === 'Per Diem International', returnperDiemcardList[transaction.cardID].cardName === '__CASH__', returncashcardnpm run typecheck. Fix any errors by replacing the calls totransaction.transactionTypewithgetTransactionTypeParent Issue: https://github.com/Expensify/Expensify/issues/563552