[Koha-bugs] [Bug 33849] Duplicate patron warning resets borrowers branch if different than logged in user's branch

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Tue Sep 19 08:18:48 CEST 2023


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

--- Comment #2 from Emmi Takkinen <emmi.takkinen at koha-suomi.fi> ---
  (In reply to Emmi Takkinen from comment #1)
> For some reason $op isn't set as "duplicate" (as it should if I understand
> this correctly). So this condition isn't filled
> 
Actually, $op shouldn't be "duplicate". It's "duplicate" if patron is added
with "Duplicate" button.

> if (defined ($data{'branchcode'}) and ( $op eq 'modify' || $op eq
> 'duplicate' || ( $op eq 'add' && $category->category_type eq 'C' ) )) {
>     $userbranch = $data{'branchcode'};
> }
> 
> and logged in users branchcode is used instead of selected branchcode.

Why to we to this ( $op eq 'add' && $category->category_type eq 'C' )?
Shouldn't we use existing branchcode for all patron categorytypes, not only for
"C"? And now when I think about this, shouldn't we use existing branchcode no
matter what value $op has?

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


More information about the Koha-bugs mailing list