Can koha admin generate patron-card without making a batch (Tools › Patron
card creator)?

I was looking for a feature that administrator can generate the patron-card
directly from Patron detail page.

During my code browsing I found two files 'print.pl' and 'create-pdf.pl' in
'patroncards' folder. Good thing was there was already a GET parameter
'borrower_number' (@borrower_numbers) that seem to be used to generate the
PDF for a list of borrower.

So, I think there is/was a feature from where i could chose a list of
patrons without making a Batch.

This code also seem to have a bug!

I didn't find any online browse-able code therefore a snip-it from
create-pdf.pl is here:

    grep {
        push(@{$items}, {*item_number* => $_});
    } @borrower_numbers;

'item_number' itself is not used anywhere. 'browser_number' is used to
retrieved this data.

foreach my $item (@{$items}) {
    if ($item) {
        my $borrower_number = $item->{'*borrower_number*'};

When I replaced second with the first one, it stared to generate the pdf
local URL to test:
http://waqar/cgi-bin/koha/patroncards/print.pl?borrower_number=19

--
Thanks & Best Regards,
Waqar Azeem
_______________________________________________
Koha-devel mailing list
[email protected]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to