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

[Custom donor table] the hook should have the donor list #6090

Open
Genevieve-K opened this issue Nov 9, 2021 · 0 comments
Open

[Custom donor table] the hook should have the donor list #6090

Genevieve-K opened this issue Nov 9, 2021 · 0 comments
Labels
keep-fresh "Keep Fresh" issues should not be marked as stale. type: enhancement An improvement to existing user-facing functionality

Comments

@Genevieve-K
Copy link
Contributor

User Story

As a developer, I want to add a column in the donor table in the admin interface.

Details

class-donor-table.php file:
I can add a colum title with give_list_donors_columns filter, and add data with give_donors_column_query_data filter .
But I don't know the real donor list;
lines 433-435:
// Get donor query. $args = $this->get_donor_query(); $donors = Give()->donors->get_donors( $args );
I don't have access to the method get_donor_query(). I tried to define a class which extends the Give_Donor_List_Table class, but it's too difficult to define it when the Give_Donor_List_Table class is defined and the filter is not yet applied.

Suggestion: add the variable donors to the filter:

line 459 return apply_filters( 'give_donors_column_query_data', $data, $donors );

@Genevieve-K Genevieve-K added the type: enhancement An improvement to existing user-facing functionality label Nov 9, 2021
@kjohnson kjohnson added the keep-fresh "Keep Fresh" issues should not be marked as stale. label Oct 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
keep-fresh "Keep Fresh" issues should not be marked as stale. type: enhancement An improvement to existing user-facing functionality
Projects
None yet
Development

No branches or pull requests

2 participants