Enhance memberlist csv column filtering#517
Draft
mathieuhays wants to merge 1 commit intostrangerstudios:devfrom
Draft
Enhance memberlist csv column filtering#517mathieuhays wants to merge 1 commit intostrangerstudios:devfrom
mathieuhays wants to merge 1 commit intostrangerstudios:devfrom
Conversation
Collaborator
|
This is super cool, but won't make the 1.9.4 release. I do want to take a deeper look at this before the next release for potential inclusion. I hope it's not too much trouble for you to repatch your site if you are using this already. |
Contributor
|
We'll need to update the branch on mathieuhays:csv-header-enhancement with the latest from our current dev branch to move forward here. The changes in the PR look pretty good, I'd only suggest a few tweaks for new hooks (hook docs info which I can help with after PR is refreshed) and possibly a couple of code formatting things. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements #481.
I've changed the way the columns array works. I've added the heading as the key (as you mentioned @strangerstudios) and I also added the ability to specify a callback which enabled me to include columns like "expires" or "joined" as filterable columns.
$extra_columnsare merged with$default_columnssince the behaviour is now similar.pmpro_members_list_csv_headingstill works but will break if someone tries to add/remove columns using this filter.I've done some tests and we can now remove and/or re-order columns using
pmpro_members_list_csv_default_columns. Actually it's now easier to remove/re-order columns because we are using the heading as the key.I haven't managed to test the use-case for "oldmembers".