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

72-fix/pivot-table-ui-sum_aggregation-issue #73

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Nitinyadav237
Copy link
Contributor

@Nitinyadav237 Nitinyadav237 commented Apr 26, 2024

I have solved #72 UI problem showing previous value and sum aggregation issue

Description:
Resolved the UI issue displaying previous values by implementing unique keys that assist React in identifying changes, additions, or removals effectively.
Additionally, addressed the sum aggregation problem by explicitly converting 'value.column' to float.

Pivot_1_solved.mp4

Copy link

ellipsis-dev bot commented Apr 26, 2024

Your free trial has expired. To continue using Ellipsis, sign up at https://app.ellipsis.dev for $20/developer/month. If you have any questions, reach us at help@ellipsis.dev

@@ -239,7 +241,7 @@ export default function PivotTable({ id }: { id: number }) {
{columns.map((column) => renderColumnBlock(column))}
</div>
</div>
<div className="h-72 overflow-auto">
<div className="h-72 overflow-auto" key={JSON.stringify(gridData)}>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we use a better key than stringifying gridata? this is not performant at all

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

@ramonverse Is it okay to use uuidv4() or should I use a different method?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

keys should be consistent between re-renders. Do a bit of research on this topic and update your PR :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants