is it possible to increase the number of visible entries (default 10)
in an autocomplete list?
I found it, the number of visible entries in the autocomplete lists is
set in the /vendor/yui/autocomplete/autocomplete.js file. But make
sure to change it also in the autocomplete-min.js file because the
autocomplete-min.js file is the one that is actually used by Ica-AtoM.
Hi Jesus,
I read the whole thread and I couldnt get it to work. I need to change
the max results of subjectAccessPoints, placeAccessPoints and
nameAccessPoints, all of them showed in this URL: /index.php/;add/isad
I added a line in js/autocomplete.js, exactly at the same place where
you added it in your example. I configured it to multiple values (e.g.
20), all of them > 10.
I configured the nine "autocompleteAction.class.php" files I've found,
replacing "$request->limit = sfConfig::get('app_hits_per_page');" by,
e.g., "$request->limit = 20 ". I already know it's not necesary to
change all of them, but I did it anyway.
I even tried changing the original file "/vendor/yui/autocomplete/
autocomplete-min.js":
YAHOO.widget.AutoComplete.prototype.maxResultsDisplayed = 20;
I also changed "global_settings_hits_per_page" to 20... but... got
nothing but 10 results.
I deleted the cache a thousend times, I refreshed my browser time and
time again and... I'm still getting 10 results top. I'm my database I
have much more "places", "subjects" and "names" than 10...
Thanks for your help.
> On Thu, Jan 26, 2012 at 1:54 AM, django boonman <dja...@ejbdesignery.nl>
>
> wrote:
> > I found it, the number of visible entries in the autocomplete lists is
> > set in the /vendor/yui/autocomplete/autocomplete.js file. But make
> > sure to change it also in the autocomplete-min.js file because the
> > autocomplete-min.js file is the one that is actually used by Ica-AtoM.
>
> I am sorry but that what you are saying is very wrong. The vendor files are
> not intended to be modified.
>
> If you want to redefine the default value for the property
> maxResultsDisplayed, you should do that in our project file
> js/autocomplete.js.
>
> In this example I set the value to 12345:
>
> Index: js/autocomplete.js
> ===================================================================
> --- js/autocomplete.js (revision 10587)
> +++ js/autocomplete.js (working copy)
> @@ -167,6 +167,9 @@
> autoComplete.minQueryLength = 0;
>
> + // ...
> + autoComplete.maxResultsDisplayed = 12345;
> +
> // Give user chance to type something, one second may
> still
> // be too little,
>
> --
> Jesús García Crespo,
> Software Engineer, Artefactual Systems Inc.http://www.artefactual.com| +1.604.527.2056