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
We already support multiple levels of tags on policies in Expensify and within our workspaces. Our current code assumes you have a single tag list. We need to update it to juggle the potential for multiple tags. Thankfully, from there, the rest of the framework is already in place. We will do this by:
Adjusting the routes for tags to incorporate the tag index (discussion). This means adjusting the current routes for editing/selecting tags in the following way:
Then for the tag we send to the API, we create a string of all tags, by order of index, delimited by colons, like so tag1:tag2:tag3. The Expensify API already understands this format.
For displaying the tag, for instance when we have the tag key from getTransactionDetails, we should split the tag by the colon delimiter and display each in it's corresponding index.
We'll need to create a method that translates a tag index to a tag name. This would correspond to the order a tag appears in the policyTags_ OnyxKey:
For any "Modified Expense" message, anytime we change a single tag level, we'll just display the entire colon-delimited tag, like we do on OldDot:
Manual Test Steps
In OldDot, create a policy with multiple tags. One can do this by following the instructions here, and using the following csv with multiple tag levels: independentTags.csv
Create a new workspace request
Make sure you see a row rendered for each tag in the workspace
Make sure that selection works for each row, and that the appropriate list of tags show for the appropriate level.
Save the request, make sure that the tags save properly on the expense
Open the recently saved request, make sure that the saved tag selections show up in the correct rows.
Edit the request, again make sure that the selections work the same as when you created the expense, and save properly.
Part of the Wave 6: Tags project
Main issue: #32828
Doc section: N/A (Orignal tags doc is here: https://docs.google.com/document/d/1eXGKhdUP98f6RUVYpRzxLi49El9Rizeqq-EYjrF24tU/edit)
Project: [#whatsnext] Wave 06 - Collect Submitters
Feature Description
We already support multiple levels of tags on policies in Expensify and within our workspaces. Our current code assumes you have a single tag list. We need to update it to juggle the potential for multiple tags. Thankfully, from there, the rest of the framework is already in place. We will do this by:
${iouType}/new/tag/${reportID}->${iouType}/new/tag/0/${reportID}create/${iouType}/tag/${transactionID}/${reportID}/->create/${iouType}/tag/0/${transactionID}/${reportID}/r/:threadReportID/edit/:field->r/:threadReportID/edit/:field/0tag1:tag2:tag3. The Expensify API already understands this format.tagkey fromgetTransactionDetails, we should split the tag by the colon delimiter and display each in it's corresponding index.policyTags_OnyxKey:Manual Test Steps
independentTags.csv
cc @amyevans @rezkiy37 @waterim @puneetlath
Upwork Automation - Do Not Edit