In the patron module, the list under 'Add to patron list' is not in alphabetical order
test plan 1. Go to Tools > Patron lists 2. Create a new patron list 3. Add 10 patrons in a random order (not in alphabetical nor in cardnumber sequence) 4. Go back to Tools > Patron lists management page 5. Find your list, click on "Action" and select "Print patron cards" 6. Check the cards order in the pdf --> notice these cards aren't in alphabetical order. Unfortunately, Koha sort them by the "patron_list_patron_id" order which it isn't always logical.
Created attachment 155468 [details] Bug 32742: Patron's lists option are not in alphabetical order This patch add sorting feature to the patron card lists export option To test 1. Go to Tools > Patron lists 2. Create a new patron list 3. Add 10 patrons in a random order (not in alphabetical nor in cardnumber sequence) 4. Go back to Tools > Patron lists management page 5. Find your list, click on 'Action' and select 'Print patron cards' 6. Check the cards order in the pdf --> notice these cards aren't in alphabetical order. 7. Apply the patch 8. Repeat step 4, 5 9. Fill the «Order by» field and submit 10. Check the cards order in the pdf --> notice the cards are now ordered.
Created attachment 155469 [details] [review] Bug 32742: Patron's lists option are not in alphabetical order This patch add sorting feature to the patron card lists export option To test 1. Go to Tools > Patron lists 2. Create a new patron list 3. Add 10 patrons in a random order (not in alphabetical nor in cardnumber sequence) 4. Go back to Tools > Patron lists management page 5. Find your list, click on 'Action' and select 'Print patron cards' 6. Check the cards order in the pdf --> notice these cards aren't in alphabetical order. 7. Apply the patch 8. Repeat step 4, 5 9. Fill the «Order by» field and submit 10. Check the cards order in the pdf --> notice the cards are now ordered.
Created attachment 155572 [details] [review] Bug 32742: Patron's lists option are not in alphabetical order This patch add sorting feature to the patron card lists export option To test 1. Go to Tools > Patron lists 2. Create a new patron list 3. Add 10 patrons in a random order (not in alphabetical nor in cardnumber sequence) 4. Go back to Tools > Patron lists management page 5. Find your list, click on 'Action' and select 'Print patron cards' 6. Check the cards order in the pdf --> notice these cards aren't in alphabetical order. 7. Apply the patch 8. Repeat step 4, 5 9. Fill the «Order by» field and submit 10. Check the cards order in the pdf --> notice the cards are now ordered. Signed-off-by: Émily-Rose Francoeur <emily-rose.francoeur@inLibro.com>
I am running out of time here, so please fix these yourself: 1) Please perltidy: OK koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/print.tt WARN patroncards/create-pdf.pl WARN tidiness The file is less tidy than before (bad/messy lines before: 181, now: 183) WARN patroncards/print.pl WARN tidiness The file is less tidy than before (bad/messy lines before: 88, now: 90) 2) I feel like the Order by should be the last option in the form, going together with the "start with" option, instead of being the first in the form. 3) This should also be available when printing the patron cards from the patron card creator. Since the code for sorting is in patroncards/create-pdf.pl, I believe this would not require much more than a template change and it would give us nice consistency. 4) I think that if you change nothing the order will still be the order added ot the list - is this correct? (just a question, nothing to fix here)