Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
In privatemsg 6.x-1.3 username autocomplete works only from the beginning of the username. So, if I write "fabio" I do match username "Fabio Varesano" while if I write "varesano" it doesn't match it.
The following patch add support for this.
What do you think?
Comment | File | Size | Author |
---|---|---|---|
privatemsg_autocomplete_username_not_only_from_beginning.patch | 645 bytes | fax8 | |
Comments
Comment #1
BerdirNot sure, one problem is that %string% is quite slow (will be an issue if you have many users).
I am also not sure if it is actually better UX, because while your example is valid, there are also many valid counter examples, if you start typing something like "Sa", you will probably not see names starting with "Sa.." as suggestions but a bunch of totally different names (sorted alphabetically).
So, I'm not sure. Maybe something like "LIKE 'Sa%' OR LIKE '% Sa'", basically, only looking for names that somehow start (first/lastname) with the string we are searching for.
Ideas?
Anyway, no new features or changes are added to the 6.x-1.x branch. The patch probably doesn't apply against 6.x-2.x.
Comment #2
Berdirprivatemsg_autocomplete_username_not_only_from_beginning.patch queued for re-testing.
Comment #4
BerdirOk, the patch applies but doesn't work anymore as the tests expect it to.
Comment #5
oadaeh CreditAttribution: oadaeh as a volunteer commentedThis issue is being closed because it is against a branch for a version of Drupal that is no longer supported.
If you feel that this issue is still valid, feel free to re-open and update it (and any possible patch) to work with the 7.x-1.x branch (bug fixes only) or the 7.x-2.x branch.
Thank you.