jump to details if only 1 result found

Is there a way to jump right to the details view if a search only returns one item?
or from my search form, when the auto complete is used to find that exact record, to jump straight to that detail view?
 
I sure would appreciate some help tackling this. is a pretty big useability flaw.. the easiest way for fabrik to handle this, is to have an option setting to go straight to detail if only one result returned..
Maybe create a jump-to drop down for some autocomplete function. as an alternative?
 
I wouldn't consider it a flaw, but a feature request. If you google and get one result does it take you to the site, if you search in windows does it open the file? No, you get the single result shown, to my mind that should definitely be the expected behaviour.
You could achieve this with a small piece of js code so say your list id is 1, add a file: components/com_fabrik/js/list_1.js:

JavaScript:
requirejs(['fab/fabrik', 'fab/list'], function () {
var list = Fabrik.getBlock('list_1');
var ids = list.getRowIds();
if (ids.length === 1) {
var row = list.getRow(ids[0]);
document.location = row.fabrik_view_url;
}
});
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top