In the module folder open fapi_multiselect.js and in the click functions starting on line 84 change them to the following:

    $wrapper.find('ul li a:eq(0)').click(function(event) {
      event.preventDefault();
      $leftSelect.moveSelectionTo($rightSelect);
      updateMainSelect();
    });

    // Moves selection if remove is clicked to selected box
    $wrapper.find('ul li a:eq(1)').click(function(event) {
    	event.preventDefault();
      $rightSelect.moveSelectionTo($leftSelect);
      updateMainSelect();
    });

This will prevent the default action on the click on the "a" tag.

Thanks

James

Comments

szadok’s picture

+1
Like the suggestion

ryan.merritt’s picture

Excellent suggestion, took a minute of looking at it to understand as well, thank you :)

thehong’s picture

Commited. Thanks.

thehong’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

WorldFallz’s picture

fyi this commit caused an error. The commit left out 'event' from .click(function(event)) both calls. Patch attached in #1863284: js error: event is not defined.

WorldFallz’s picture

Issue summary: View changes

added code tags