[Koha-bugs] [Bug 31492] Patron image upload fails on first attempt with CSRF failure
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Mon Jan 9 13:08:03 CET 2023
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31492
Nick Clemens <nick at bywatersolutions.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Depends on| |20809
CC| |nick at bywatersolutions.com
--- Comment #5 from Nick Clemens <nick at bywatersolutions.com> ---
I suspect the issue is from bug 20809, members-menu.js:
+ $(".edit-patronimage").on("click", function(e){
+ e.preventDefault();
+ var borrowernumber = $(this).data("borrowernumber");
+ $.get("/cgi-bin/koha/members/moremember.pl", { borrowernumber :
borrowernumber }, function( data ){
+ var image_form = $(data).find("#picture-upload");
+ image_form.show().find(".cancel").remove();
+ $("#patronImageEdit .modal-body").html( image_form );
+ });
+ var modalTitle = $(this).attr("title");
+ $("#patronImageEdit .modal-title").text(modalTitle);
+ $("#patronImageEdit").modal("show");
+ });
It looks like we are fetching the form via JS, maybe is causing the CSRF
mismatch?
Referenced Bugs:
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20809
[Bug 20809] Link patron image to patron image add/edit form
--
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
More information about the Koha-bugs
mailing list