Open reidelkins opened 1 year ago
⚡ Sweep Free Trial: I used GPT-4 to create this ticket. You have 5 GPT-4 tickets left. For more GPT-4 tickets, visit our payment portal.To get Sweep to recreate this ticket, leave a comment prefixed with "sweep:" or edit the issue.
I found the following snippets in your repository. I will now analyze these snippets and come up with a plan.
I also found the following external resources that might be helpful:
From looking through the relevant snippets, I decided to make the following modifications:
File Path | Proposed Changes |
---|---|
frontend/src/components/CustomerData.js |
In the handleRequestSort function, add a case for serviceTitanLifetimeRevenue to sort the table based on this field. |
frontend/src/sections/dashboard/client/ClientListHead.js |
Add a TableSortLabel for the serviceTitanLifetimeRevenue field to allow users to sort by this field. |
I have created a plan for writing the pull request. I am now working my plan and coding the required changes to address this issue. Here is the planned pull request:
Allow sorting by lifetime value on customer data page
sweep/sort-by-lifetime-value
Description
This PR addresses the issue #170 by allowing sorting based on the
serviceTitanLifetimeRevenue
field in the table infrontend/src/components/CustomerData.js
.Summary of Changes
- Modified
frontend/src/components/CustomerData.js
to include sorting functionality for theserviceTitanLifetimeRevenue
field in thehandleRequestSort
function.- Updated
frontend/src/sections/@dashboard/client/ClientListHead.js
to include aTableSortLabel
for theserviceTitanLifetimeRevenue
field to allow users to sort by this field.Please review and merge this PR at your earliest convenience. Thank you!
I have finished coding the issue. I am now reviewing it for completeness.
Success! 🚀
To recreate the pull request, leave a comment prefixed with "sweep:" or edit the issue. Join Our Discord
In the table in frontend/src/components/CustomerData.js allow for sorting based on serviceTitanLifetimeRevenue. Other relevant files might be frontend/src/sections/@dashboard/client/ClientListHead.js, frontend/src/sections/@dashboard/client/CustomerDataFilter.js, and frontend/src/sections/@dashboard/client/ClientListToolbar.js