https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=38987

Andreas Roussos <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
           Assignee|[email protected] |[email protected]
                   |ity.org                     |

--- Comment #2 from Andreas Roussos <[email protected]> ---
Analysis of the Bug:

Clicking on one of the '+ Choose' buttons actually calls the
doauth() function, defined in

koha-tmpl/intranet-tmpl/prog/en/modules/authorities/searchresultlist-auth.tt:

143         function doauth(authid, index, repet){
144             [% IF source == 'auth' %]
145                 var e = document.getElementById("relationship");
146                 var relationship = e.options[e.selectedIndex].value;
147
148                 jumpfull('blinddetail-biblio-search.pl?authid=' + authid +
'&index=' + index + '&repet=' + repet + '&relationship=' + relationship);
149             [% ELSE %]
150                 jumpfull('blinddetail-biblio-search.pl?authid=' + authid +
'&index=' + index + '&repet=' + repet);
151             [% END %]
152         }

As per the code above, whenever authority-to-authority linking
takes place (source == 'auth'), `e` is the JavaScript variable
assigned to the object/HTML element with an id attribute equal
to 'relationship'. This refers to the 'Special relationship'
dropdown menu that allows you to select a relationship code
before picking an authority with the '+ Choose' button.

Commit a605c070c7 (from Bug 31470) introduced a change to
koha-tmpl/intranet-tmpl/prog/en/includes/auth-finder-search.inc
which renamed the id attribute of the 'Special relationship'
<select> element from 'relationship' to 'special_relationship'.

Therefore the fix for this Bug is trivial, and involves just
a change in the `getElementById()` call. Additionally, to avoid
any confusion regarding the variable name (AIUI `e` is often
used for Event objects), I'm suggesting we rename it to `elem`
(short for 'element').

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[email protected]
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to