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

NOJIRA : dont_use_natural_sort and idno_sort #1540

Open
gautiermichelin opened this issue Mar 5, 2024 · 1 comment
Open

NOJIRA : dont_use_natural_sort and idno_sort #1540

gautiermichelin opened this issue Mar 5, 2024 · 1 comment

Comments

@gautiermichelin
Copy link
Contributor

Hi CA team,

We found an issue when enabling dont_use_natural_sort inside search.conf.

Inside BaseFindEngine, R 518 :

				$vn_sort_mode = SORT_FLAG_CASE;
				if (!$o_conf->get('dont_use_natural_sort')) { $vn_sort_mode |= SORT_NATURAL; } else { $vn_sort_mode |= SORT_STRING; }
				
				ksort($va_sort_buffer, $vn_sort_mode);

This disable the purpose of idno_sort, arranging 2012.0.12 between 2012.0.1 and 2012.0.2.

Would you edit the comment of search.conf for this row ?

# This is usually what is wanted, but for some languages (Eg. Spanish) it can return odd results and it may be desirable to disable it. Note that it would disable idno_sorting and sort idnos alphabetically.

I didn't send a pull request because I don't now if my phrasing of it is side-effect. Maybe natural ksort should not be used when sorting by idnos, but can't answer that.

Best,

Gautier

@collectiveaccess
Copy link
Owner

What version is this from? It's not in dev/php8.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants