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

Access all data when calculating summary per column #5754

Closed
hanastasov opened this issue Sep 10, 2019 · 2 comments · Fixed by #5976
Closed

Access all data when calculating summary per column #5754

hanastasov opened this issue Sep 10, 2019 · 2 comments · Fixed by #5976
Assignees
Labels
grid: general grid: summaries 🧰 feature-request ✅ status: resolved Applies to issues that have pending PRs resolving them, or PRs that have already merged.

Comments

@hanastasov
Copy link
Contributor

hanastasov commented Sep 10, 2019

Is your feature request related to a problem? Please describe.

Depending on a business logic, a value from column X may be needed to calculate summaries for column Y. For example, lets define a custom summary:

class MySummary extends IgxNumberSummaryOperand {
    operate(data?: any[]): IgxSummaryResult[] {
        // data only contains the data for the corresponding column Y
        // some would like to access value from column X for the given record
        return result;
    }
}

Describe the solution you'd like

When the operate method is called, have the option to access other fields data as well.

Describe alternatives you've considered

A complete manual calculating of sumamries that is rendered inside the grid footer. Makes no use of igxGrid Summaries

@amitmoondra
Copy link

Very important feature and would be really helpful if implemented early.

@zdrawku
Copy link
Contributor

zdrawku commented Sep 25, 2019

Hello @amitmoondra, thank you for your comment, we are reviewing our feature requests constantly and if one is approved @radomirchev is prioritizing it for further development. For the time being, I can provide you an alternative solution to this requirement by using igx-grid-footer.

The sample is demonstrating how to access the data and manipulate it as you want or use the summary operands to perform calculations on it.

@radomirchev radomirchev added this to To Do in 19M10 Sprint 1 Oct 9, 2019
@zdrawku zdrawku added the 🛠️ status: in-development Issues and PRs with active development on them label Oct 9, 2019
@radomirchev radomirchev moved this from To Do to Development in 19M10 Sprint 1 Oct 11, 2019
@ddincheva ddincheva added ✅ status: resolved Applies to issues that have pending PRs resolving them, or PRs that have already merged. and removed 🛠️ status: in-development Issues and PRs with active development on them labels Oct 11, 2019
@radomirchev radomirchev moved this from Development to Validation in 19M10 Sprint 1 Oct 15, 2019
@radomirchev radomirchev added this to Milestone 10 (Due by DEC 2019) in ROADMAP 2019 Oct 17, 2019
@radomirchev radomirchev moved this from Validation to Done in 19M10 Sprint 1 Oct 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
grid: general grid: summaries 🧰 feature-request ✅ status: resolved Applies to issues that have pending PRs resolving them, or PRs that have already merged.
Projects
ROADMAP 2019
Milestone 10 (Due by DEC 2019)
Development

Successfully merging a pull request may close this issue.

5 participants