Refactoring user search to allow search/filter by custom fields

Note: We are moving the topics of this forum and it will be deleted at some point

Publish your own request for comments/change or patches for the next version of phpBB. Discuss the contributions and proposals of others. Upcoming releases are 3.2/Rhea and 3.3.
Lucifer4o
Registered User
Posts: 23
Joined: Wed Dec 11, 2013 6:50 pm

Refactoring user search to allow search/filter by custom fields

Post by Lucifer4o » Sun Apr 20, 2014 7:45 am

Hello all,

As phpBB is moving profile fields to custom fields I think it will be nice if we do the user search allow searching/filtering users per custom profile fields.

This will require new option in ACP when defining the custom field (example Searchable - > yes/no), this means new field in DB schema.

Other requirements are changing the user search/filter part of the members.php.

This will allow easier filtering of users, not only by the defined now fields.

Regards.

User avatar
BioLogIn
Registered User
Posts: 28
Joined: Mon Dec 10, 2012 6:55 pm

Re: Refactoring user search to allow search/filter by custom fields

Post by BioLogIn » Sun Apr 20, 2014 12:00 pm

Huge +1 for obvious reasons - as far as I remember, dev team already plans to make all profile fields custom, and at least for contact fields search is really a welcome addition.

Lucifer4o
Registered User
Posts: 23
Joined: Wed Dec 11, 2013 6:50 pm

Re: Refactoring user search to allow search/filter by custom fields

Post by Lucifer4o » Sun Apr 20, 2014 12:12 pm

Basic stuff is good - you can filter by custom field data ... now I'm working on the search/filter form ... I think I'll have some working basics to tomorrow.

Just a question for devs - where should I add changes to the DB?

Migration?

User avatar
nickvergessen
Former Team Member
Posts: 733
Joined: Sun Oct 07, 2007 11:54 am
Location: Stuttgart, Germany
Contact:

Re: Refactoring user search to allow search/filter by custom fields

Post by nickvergessen » Sun Apr 20, 2014 12:17 pm

It would be migrations, however this should not be an option. If the field is displayed, it should be searchable and sortable
Member of the Development-TeamNo Support via PM

Lucifer4o
Registered User
Posts: 23
Joined: Wed Dec 11, 2013 6:50 pm

Re: Refactoring user search to allow search/filter by custom fields

Post by Lucifer4o » Sun Apr 20, 2014 12:25 pm

That is even better. Then I will have a PR in a day or two.

For the development purposes I use the display in memberlist.

Is this good?

User avatar
PayBas
Registered User
Posts: 305
Joined: Tue Jul 29, 2008 6:08 pm
Contact:

Re: Refactoring user search to allow search/filter by custom fields

Post by PayBas » Sun Apr 20, 2014 1:06 pm

Lucifer4o wrote:That is even better. Then I will have a PR in a day or two.

For the development purposes I use the display in memberlist.

Is this good?
Seems right to me.

Lucifer4o
Registered User
Posts: 23
Joined: Wed Dec 11, 2013 6:50 pm

Re: Refactoring user search to allow search/filter by custom fields

Post by Lucifer4o » Sun Apr 20, 2014 2:34 pm

I seem to be at an impasse ...

Should I include the boolean fields ... and if yes ... how to stop them from doing logical damage ...

And one more thing - should the URL be searchable?

Lucifer4o
Registered User
Posts: 23
Joined: Wed Dec 11, 2013 6:50 pm

Re: Refactoring user search to allow search/filter by custom fields

Post by Lucifer4o » Mon Apr 21, 2014 12:12 pm

First PR sent ... it has some more work to be done ...

Just wanted to use TRAVIS because it works locally.

I still have to make it work with dates ...

User avatar
keith10456
Registered User
Posts: 523
Joined: Sat Apr 22, 2006 10:29 pm
Contact:

Re: Refactoring user search to allow search/filter by custom fields

Post by keith10456 » Mon Apr 21, 2014 9:31 pm

This is really good news!

@ Lucifer4o - Thanks for working on it ;-)

Lucifer4o
Registered User
Posts: 23
Joined: Wed Dec 11, 2013 6:50 pm

Re: Refactoring user search to allow search/filter by custom fields

Post by Lucifer4o » Tue Apr 22, 2014 10:27 am

MEH ... no problem. This is something I need, but I am glad that it will be useful for all of you.

Post Reply