[Koha-bugs] [Bug 29937] New: class close, close the full windows

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Tue Jan 25 12:03:18 CET 2022


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

            Bug ID: 29937
           Summary: class close, close the full windows
 Change sponsored?: ---
           Product: Koha
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P5 - low
         Component: OPAC
          Assignee: oleonard at myacpl.org
          Reporter: hagud at orex.es
        QA Contact: testopia at bugs.koha-community.org

Good morning we have found something it could be an issue or not.. ;)

https://github.com/Koha-Community/Koha/blob/master/koha-tmpl/opac-tmpl/bootstrap/js/script.js#L40

$(document).ready(function(){
    $(".close").click(function(){
        window.close();
    });

the issue is basically that we assign a class $('.close') to do window.close()


We do have that handler bound to the class close, which can be considered a bit
loose in scope and lead to clashes.

We have added a js on mainuserblock with .close, and when it clicks, close the
full browser tab ;), of course we can change the class, but I think it is
something to consider if change that code ;)

cheers

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list