Do not crash if the patron does not exist.
Test plan:
Access circ/circulation.pl?borrowernumber=42424242
you should get an error without this patch
With this patch, you will get an empty patron detail page (should be
fixed in another patch, but this behavior exists for a while)
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
Can't call method "guarantor" on an undefined value at
/home/koha/src/circ/circulation.pl line 588.
at /home/koha/src/circ/circulation.pl line 673
Introduced by bug 15656
Test plan:
Just trigger circ/circulation.pl
Signed-off-by: Jacek Ablewicz <abl@biblos.pk.edu.pl>
Triggered circ/circulation.pl - nothing exploded, and error is gone
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
Note:
QA question: Does the Koha::Patron->siblings method should return undef
if there is no guarantor?
It would avoid the weird != undef, = $borrowernumber conditions.
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
To retrieve a patron image, we can call Koha::Patron::Images->find or
Koha::Patrons->find->image
Both will return a Koha::Patron::Image object.
Test plan:
1/ From the patron/member module, open all tabs on the left (Checkouts,
detail, fines, etc.)
The image should be correctly displayed.
2/ At the OPAC, on the patron details page (opac-memberentry.pl) the
image should be displayed as well.
3/ Same on the sco module.
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
The 'borrower' should not be used anymore, especially for new code.
This patch move files and rename variables newly pushed (i.e. in the Koha
namespace).
Test plan:
1/
git grep Koha::Borrower
should not return code in use.
2/
Prove the different modified test files
3/ Do some clicks in the member^Wpatron module to be sure there is not
an obvious error.
Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as described. Tested with Circulation, Members/Patrons, Discharge,
Restrictions modules and the must common functionalities
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jesse Weaver <jweaver@bywatersolutions.com>
This subroutine just retrieved the messages given some parameters.
Some job should not have been done in this subroutine.
It was called only 3 times, in circ/circulation.pl and opac-user.pl.
Basically it was used to retrieved the message to displaye for a given
patron ($borrowernumber) at the OPAC (B) or Staff (L).
For the 3 calls, the 2 parameters $borrowernumber and $type
(message_type) were passed, the "%" trick at the beginning of the
subroutine was useless.
Moreover, the date formatting should be done on the TT side, not in
subroutine.
The can_delete flag was set if the branchcode given in parameter was the
same as the one of the message. This has been delegated to the template.
Indeed the can_delete was not valid, since it must depend on the
AllowAllMessageDeletion pref.
The test is now:
IF message.branchcode == branch OR
Koha.Preference('AllowAllMessageDeletion'')
There is not specific test plan for this patch, the changes have already
been tested in previous patches.
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
The DeleteMessage just deleted and logged if needed.
This is now be done by Koha::Patron::Message->delete.
Test plan:
1/ Go on the "check out" page of a patron
2/ Delete some messages
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
The AddMessage subroutine just
1. checked if all the parameters were passed
2. inserted the message in the DB
3. logged the action if needed
These 3 jobs are now done by the overloaded store method of
Koha::Patron::Message.
Test plan:
1/ Go on the "check out" page of a patron
2/ Add different new messages
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
If ExpireReservesMaxPickUpDelay is enabled, the "holds over" tab becomes
useless. It would be nice if the "holds over" tab would display
*tomorrow's* "holds over" so the librarian can see what will be
automatically canceled over night.
Test Plan:
1) Apply this patch
2) Enable ExpireReservesMaxPickUpDelay
3) Note the "holds over" list now displays holds that will have been
waiting more than the number of days defined in ReservesMaxPickUpDelay
as of tomorrow.
Signed-off-by: Jason Burds <JBurds@dubuque.lib.ia.us>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
This patch adds the dateaccessioned column fro an item to the display on
returns.pl. The column is added with a CSS class for easy selection.
To test:
Check in some items
Note date accessioned is not shown
Apply patch
Refresh page
Check in some items
See the added column 'Date acquired'
Sponsored by: North Central Regional Library (ncrl.org)
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
Test Plan:
1) Apply this patch
2) Go to circulation.pl
3) Ensure you can still override renewal limits with pref enabled
4) Ensure you can not override renewal limits with pref disabled
5) Go to moremember.pl
6) Repeat steps 3-4
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
This subroutine is no longer used in this script.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
If you have a patron category with a hard renewal date, the enrolllment
period will be zero. You cannot calculate the renewal date as is done
in the script currently.
Even more, the renewaldate template var is not even used.
Test plan:
[1] Verify that checkin/checkout works as expected.
[2] Git grep on renewaldate
[3] Check the code in circulation.pl for "$renew"
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
If a librarian enters a barcode that does not match an item in the
database, a 500 error will be displayed instead of the "No item with
barcode" message.
Test Plan:
1) Enter an invalid barcode on returns.pl
2) Note the 500 error
3) Apply this patch
4) Repeat setp 1
5) Note the "No item with barcode" message
Signed-off-by: Aleisha <aleishaamohia@hotmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
Bug 14821 removed the items which were not checked out, but some
libraries considered it as a bug.
So let's add a new pref to control this behavior.
Test plan:
0/ Execute the updatedb entry and set ShowAllCheckins to "Do not show"
(default)
1/ Check an item in.
If the item was not checked out, it won't be listed
2/ Turn the pref to "Show"
3/ Check an item in
If the item was not checked out, it should be listed
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
This patch mainly replaces C4::ItemType->all with
Koha::ItemTypes->search.
Test plan:
At the places where the C4::ItemType module was used, confirm there is
no regression:
- acqui/neworderempty.pl
- catalogue/itemsearch.pl
- admin/item_circulation_alerts.pl
and the 2 cataloguing plugins:
- marc21_linking_section.pl
- unimarc_field_4XX.pl
QA step:
prove t/db_dependent/HoldsQueue.t should return green
Note that the tests were buggy.
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
This patch allows to put a hold on an item that is already checked out or reserved.
To test:
- Check out an item A
- Put a hold on an item B
- Verify that the staff user has permission to put holds
- Check out item A to a patron X
- Try to checkout item A to a patron Y
- Verify that you see underneath the buttons for Checkin/Checkout a link
with following text: "Click here to place hold for [Patron X' name]"
- Verify that the link is stylable (div class circ-scheckoutplacehold)
- Verify that the link takes you to the page to place a hold on this biblio
for patron Y
- Do the same for item B and verify that it works for reserved items as well.
- Repeat steps above for a patron who has restrictions, verify that the link
does not appear
- Log in with a staff member who has no permission to place holds
- Repeat steps above for a patron without restrictions, verify that the link
does not appear.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
This patch fixes translatability issues on checkin page, due to sentence splitting by html tags at
several places and ambiguous word 'to'.
Additionally, fix message related to syspref AllowReturnToBranch set to 'only the library where the
item is checked out from' (it wrongly displays the home library instead of the holding library),
and streamline the display of similar messages to look more consistent.
To test:
- Apply patch
- Go to Home > Circulation > Check in
- Do check ins with different expected results / messages
- Verify that the messages are meaningful and display nicely
- Play with items checked out / checked in at different branches (home branch, holding branch, other
branch) and different settings for syspref 'AllowREturnToBranch' and verify that the messages display
properly (with correct home rsp. holding branch)
- Carfully review code changes.
Signed-off-by: Aleisha <aleishaamohia@hotmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
To reproduce the bug:
- Go to Home > Circulation > Checkouts > [a patron]
- Enter 0 (zero) in barcode field and hit Enter
Result:
Software error
Can't use string ("1") as a HASH ref while "strict refs" in use
at /usr/share/kohaclone/circ/circulation.pl line 473
To test:
- Apply patch
- Repeat steps above
- Verify that the sofware error is gone and that you get a
message as with other invalid barcodes.
- Test with other values: '00', '000', existing barcode,
and a barcode that does not exist
- Test with empty barcode (for printing slip)
- Search for regressions
This patch implements Jonathan's solution (see comment #15)
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
have changed the code which strips the white space to only remove the leading and trailing white space instead
To Test-
1- go to circulation -> transfer
2- attempt to tranfer an item where the barcode has a space in the middle of it
3- it should fail
4- apply patch
5- try again
6- it should work
NOTE: I purposefully added: die "($barcode)";
Before, all spaces were removed.
' white space ' became '(whitespace)'
After, only external spaces were remove
' white space ' became '(white space)'
Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
Same fix as previous patch, but for item types.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
The patches from bug 12152 broke the display on the pending reserves/
holds to pull report when items from multiple branches and with
multiple locations were displayed. The table cells were left empty.
To test:
- Add a record with at least 2 items from different locations and
holdingbranches
- Open the 'holds to pull' report
- Verify all branches and locations show with their correct
description
Signed-off-by: Natasha <tasham_8@hotmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
To verify: Got to circ/circulation.pl and try to renew an item.
Result: Can't call method "single" without a package or
object reference at /usr/share/kohaclone/circ/renew.pl
line 57
To test:
- Apply patch
- Try to renew items that are or are not checked out. Error
no longer occurs.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
In C4::Circulation::CanBookBeIssued, $borrower->{flags} is called and
should be populated by GetMemberDetails
It fixes the following error on checking out:
Can't use string ("1900156") as a HASH ref while "strict refs" in use at
/home/koha/src/C4/Circulation.pm line 813.
Note: Error occurs with patrons with staff permissions, not with 'normal' patrons.
Error is fixed with this patch.
Signed-off-by: Marc Véron <veron@veron.ch>
Test plan:
1) Apply the patch
2) Type into search form patron's name & check his date of birth in
autocompletion
3) Go to intranet/cgi-bin/koha/members/member.pl & submit
a search with more than one result .. now should in the table appear
patron's date of birth
4) Try show/hide columns section if it works correctly for date of birth
5) Go to intranet/cgi-bin/koha/admin/columns_settings.pl -> go to
patrons section & check there is dateofbirth & it's functionality
Signed-off-by: Frederic Demians <f.demians@tamil.fr>
Works as described. Syspref dateformat respected. Column dateofbirth
configurable, but mandatory on autocompletion search result.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Same as previously.
For these files it's a bit less obvious.
To make sure these changes won't introduce any regression, check that
the variable returned by GetMember is never used to get something
else than a borrower fields.
The 'flags' should not be get neither.
For opac-user.tt it's different, other keys are got but there are defined
in the pl script.
On the way:
- 'showname' is removed (never used)
- fix scope var issue in opac-user.tt (BORROWER_INF.OPACPatronDetails vs
OPACPatronDetails)
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Test plan:
- Make sure that you have a patron A with waiting holds and a patron B
without waiting holds
- Go to the checkout page for patron A (Home > Circulation > Checkouts
> ...)
- At the right, there is a title "Waiting holds:" and a list of
holds waiting
- Go to the checkout page for patron B
=> Without this patch "Waiting holds:" is displayed
Sign-off on Jonathan's patch
Signed-off-by: Marc Véron <veron@veron.ch>
http://bugs.koha-community.org/show_bug.cgi?id=14324
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
The file intranet-tmpl/prog/en/modules/circ/branchtransfers.tt contains two
ambiguous words 'to' and a sentence splitted up by html tags, leading to weird
translations. Example in German: "Sie können keine Exemplare aus itemtype
transferieren BK für: Airfield"
To test:
- Apply patch
- Set up transfer policies for item types and collection codes in
Home > Administration > Set library checkin and transfer policy
Make sure that you have rules that deny and others that allow transfers
- Verify that syspref 'UseBranchTransferLimits' is set to 'Enforce'
- Set 'BranchTransferLimitTypes' to 'item type'
- Go to Home > Circulation > Transfers
- Transfer an item that is allowed for item type
- Verify that the table of transferred items displays information
about Item type, Collection code and Destination
- Transfer an item that is not allowed for the item type
- Verify that the information about not allowing the transfer displays
properly and is meaningfull
- Set 'BranchTransferLimitTypes' to 'collection code'
- Repeat the transfer steps above for allowed / not allowed collection code
(Amended to add ids to table and 8 columns, see comment #2)
(Amended for comment #5)
Followup for comment #8
Signed-off-by: Frédéric Demians <f.demians@tamil.fr>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
This patch removes stats.pl and stats.tt from system.
To test:
- Verify that both files are not used and that the only reference in
koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation-home.tt
is commented out.
- Apply patch
- Verify that the files are deleted and the reference is removed.
- git grep 'stats.pl', verify that there are no more references to
this file.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
See the following commit for more info on this script:
commit 60105bd692
Date: Tue Jul 8 20:02:34 2008 -0500
fix for 2008: Daily reconciliation report broken
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
When canceling a hold from the holds over tab, you are redirected back to the holds waiting tab. Instead, we should the librarian should continue to see the list of holds past the waiting length.
Test Plan:
1) Apply this patch
2) Cancel a hold from the "Holds over" tab on circ/waitingreserves.pl
3) Note you are redirected back to the holds over tab
Signed-off-by: Tom Misilo <misilot@fit.edu>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
When navigating the tabs in the patron account, for 2 tabs the
patron category description is missing above the tabs.
To test:
- Go to a patron account in staff
- Click through the tabs
- Verify that for Checkouts and Fines the category description
is missing above the tabs
- Apply patch
- Verify the description is now shown
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
The nonpublic note for items is not displayed in the staff client. It
should be displayed in the following areas:
1) Checkouts (circulation.pl)
2) Checkins (returns.pl)
3) Record details ( moredetail.pl )
Test Plan:
1) Ensure your non-public note field is mapped to the
items.itemnotes_nonpublic database column
2) Edit an item, add a test nonpublic note
3) Check out the item, verify the note is visible in the checkouts table
4) Check in the item, verify the note is visible in the checkins table
5) View the item details, verify the note is visible and editable
if your account has the rights to edit items
Followed test plan, works as expected.
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This patch removes 1 remaining / stray occurence of C4::Dates from
circ/returns.pl
To test:
- Apply patch
- Go to Home > Circulation > Check in
- Verfiy that check-ins with overriding return dates work as before.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
To test:
1. On a branch up to date with master: apply the patch.
2. Try to check out items both with and without holds.
(The decreaseLoanHighHolds function should be configured and kick in when testing an item.
3. Expected results are:
The due date date field should be cleared after checkout if "Remember for session"
is not selected. If it is selected then the chosen date should stay in the field even
if the warning about reduced loan time for an item with too many holds is displayed.
Also the correct due dates are shown in the table after a checkout.
Known limitation: Does not work too well when jumping between different parts
of the system as it relies on the values sent to the circulation.pl script.
Sponsored-by: Halland County Library
Refactored to both fix specific issue where date is changed
and still have the old behaviour with date kept intact.
Rebase
Remove code whitespace cleanup
Remove one more code whitespace cleanup
Removed duplicate tag
Refactored stickyduedate session parameter
Fix datefield set by highholds if blanc
Signed-off-by: Nicole Engard <nengard@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch set replaces and extends Koha's current sound options.
This is implemented be removing the existing sound system, and
re-engineering using a table of selector/sound combinations such that
the highest precedence selector that is found in the DOM will trigger
and audio alert. The existing audio behaviors are implemented as a set
of default audio alerts.
Test Plan:
1) Apply this patch set
2) Run updatedatabase.pl
3) Enable the AudioAlerts system preference
4) Test existing sounds
5) Enter the new alerts editor in the admin section
6) Add a new audo alert with the following selector:
"body:contains('Check in message')",
choose any sound alert you wish, make sure it's not one of the 3
sounds already used! Make this selector precedence 1
4) Browse to the checkins page, you should hear the default sound
5) Attempt to return an invalid barcode, you should hear your custom sound!
Signed-off-by: Nick Clemens <nick@quecheelibrary.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
On the checkin page, the table is always filled with info of the scanned
barcode, even if the checkin has failed.
When the checkin fails, there is already an error displayed, so there is
no need to keep a row for fails.
Test plan:
Confirm that the failed checkins don't appear anymore in the checkin
table.
- checkin an item which is not issued;
- BlockReturnOfWithdrawnItems is set and item is withdrawn;
- Not returned at the right place;
- privacy=2 and AnonymousPatron not correctly set;
Before this patch this behavior existed only for bad barcode.
Signed-off-by: Frederic Demians <f.demians@tamil.fr>
I confirm that the checkin table hasn't to be populated with info on items
which haven't been checked in.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Follow up to fix QA issues from comment #15
...and amended for comment #18
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Patch to remove deprectated C4::Dates from:
- circ/circulation.pl
- C4/Circulation.pm
- koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt
To test:
- Apply patch
- Go to the checkout site (Home > Circulation > Checkouts)
- Verify that data displays properly (including for users with a card
that expires in the near future, see syspref 'NotifyBorrowerDeparture')
- Search for regressions
- prove -v t/db_dependent/Circulation.t
(Amended following comment #9 / #11 25.10.2015 /mv)
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Corrected enddate (subtraction in the revised code must be an addition).
Replaced hardcoded 2 days by a constant.
Renamed the constant TWO_DAYS to PULL_INTERVAL.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Tested all three date formats.
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch uses Koha::DateUtils instead of C4::Dates and Date::Calc. It
also sent DateTime objects to the template, which use the TT plugin to
display them.
If an invalid dates is entered, the default date is picked.
Test plan:
1/ Go to Home > Circulation > Holds to pull
2/ Verify that the the filter and the list behave as before
3/ Enter invalid dates and confirm that you do not get a software error
Counter patch works as expected and is a much cleaner solution.
Signed-off-by: Marc Veron <veron@veron.ch>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
The patrons search used by the checkout tab and the autocomplete is not
the same as the "search patrons" tab.
The main difference is the "contain" vs "start with".
So that if you have a patron with a patron with a surname "foo bar" and
you search for "foo bar", the autocomplete and the result of a search by
the checkout tab will search for "foo%" or "bar%" which won't return the
patron you are search for.
This patch replaces both autocomplete and checkout tab searches with a
"contain" search. The search will be "%foo%" or "%bar%".
Note that on big DB, this can cause unexpected results.
Test plan:
Create a patron with a surname "foo bar"
Search for "bar" using the checkout tab.
You should see the patron in the autocomplete result and the result page
after submitting the search form.
Followed test plan, works as expected.
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
The introduced syspref was defined before we added new guidelines
for them. This patch puts them in sync with current standards. It also
splits them into:
- A big on/off switch (BatchCheckouts)
- Patron category filter (BatchCheckoutsValidCategories)
The latter is expected to go away if we move this into a boolean column
on the 'categories' table, which seems a better approach. I'm filling a
new bug for this last comment.
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This is a squash of the following patches:
Bug 11759: (follow-up) Prevent access to the batch checkout if not allowed
If a user pass '&batch=1' to the url, he was allowed to access to the
batch checkout page even if the patron is not in an authorised
category.
This patch also fixes the link to "Batch check out" from the "Details"
tab (cf changes in circ-menu.inc).
Bug 11759: FIX Javascript error
The following JS error occurred:
ReferenceError: MSG_ADD_MESSAGE is not defined
The circulation.js file is useless and should not be included.
Bug 11759: FIX the alert message if an item is on hold.
If an item is on hold, the hold is not cancelled.
This patch corrects the message displayed in this case.
Bug 11759: FIX issue list is empty
The issue list is empty after checking an item out to a patron without
existing checkout.
To reproduce:
- Search for a patron without checkout.
- Check an item out using the "normal" checkout.
- Verify the checkout list contain the checkout.
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
This patch is the main patch.
It adds:
- the new template circ/circulation_batch_checkouts.tt
- the change into circ/circulation.pl
=== Why this feature is useful for some libraries? ===
Currently Koha does not allow to checkout several items at once to a
user. This can cause a waste of time when a user want to checkout more
than 10 items.
This development has been asked to have statistics on in-house use.
Every night, a librarian will enter a barcode list (from a file or a
scanner : the librarian scans the barcode of the documents that users
let on the tables). Barcodes will be added to a statistics patron in
order to count the number of items consulted.
The development has been expanded to cover another need: some special
libraries (BDP for "Bibliotheque departementale de pret": "Loan Regional
Library").
These libraries loan items to smaller libraries (municipal). The number
of items could be very important and the current way offered by Koha is
not adequate.
=== Test plan ===
0/ Apply all patches and execute the DB change entry.
1/ Verify you are abble to do some checkouts (with confirmations,
errors).
= Statistics way =
2/ Create a statistical patron (e.g. category code STATS).
3/ Update the batch_checkouts pref with the category code (STATS).
4/ Go on the member page and verify the new "Batch check out" tab
appears (and only for this user).
5/ Check some items out on the new page using the textarea or a file.
6/ Verify the table contains the item's information and the
"Information" column contains "Local use recorded".
= Real checkouts =
7/ Create a non statistical patron and update the pref.
8/ Check some items out on the new page using the textarea or a file.
9/ Verify the information in the table is consistent.
10/ Verify item without confirmation needed or impossible alert is
checked out.
11/ If the logged in user has the "force_checkout" permission, all
checkouts with a "confirmation needed" message can be done.
If the logged in user does not have it, there is no way to force the
checkout.
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch does not introduce any changes.
It prepares the circulation script to accept several barcodes in
parameter.
A loop is done on all barcodes (until now, only 1) to generate a
structure to sent to the template.
At the end, only the first generated data is sent.
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
If an item is due today 23:59 and the filter is from yesterday
to today, the overdue won't appear on the list.
Test plan:
Be sure you have an item due on DATE 23:59
Search for overdues from DATE-1 to DATE
Without this patch, the item won't appear.
With this patch, it will.
Regression test: test the CSV download.
Note: On the way, this patch remove the deps to C4::Dates
(which was the original goal of the bug report).
Issue reproduced, it's resolved with this patch.
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Same as previous patch for calls in pl scripts.
Test plan:
- delete an entry of your search history from intranet and opac
- with IndependentBranches=OFF, go on the waiting holds and confirm that the
link next to 'Holds awaiting pickup for your library on' is correct.
- search for items, the pagination should work correctly
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Note that the previous patch was wrong, the start date defaulted to yesterday,
the original behavior is to default to last year.
This patch removes some unecessary variable declarations and tests.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch removes C4::Dates from circ/reserveratios.pl
To test:
- Make sure you have many holds for biblios with not so much items (e.g. 5 holds, 1 item)
or follow hint below
- Go to Home > Circulation > Hold ratios
- Verify that everything works the same without an dwith patch
Hint: To get a big table you can set 'Hod ratio' in the filter to 0.1 (default value is 3).
This was will trigger biblios with less holds than items.
Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as advertised. Tested with dateformat syspref, datepiker Ok
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch set adds the ability to defined independent quotas for on-site
checkouts.
This will be done using the circulation rules matrix where a new column
“Current on-site checkouts allow” will be added.
This feature is going to use the same method as the existing fields maxissueqty
("Current checkouts allowed"), the new fields will be added to the
different tables (see the "DB changes" patch) and will be named
maxonsiteissueqty (for consistency).
In order to keep the existing behavior and to let more flexibility,
a new system preference is added (ConsiderOnSiteCheckoutsAsNormalCheckouts).
This syspref will let the liberty to the library to decide if an on-site
checkout should be considered as a "normal" checkout or not.
To keep the existing behavior, the syspref will be disabled (i.e. an on-site
checkout is considered as a normal checkout) and the number of on-site
checkouts will be the same as the number of checkout (maxissueqty ==
maxonsiteissueqty).
Technically:
There are only very few tests for the Circulation module, and the 2
subroutines impacted by this patch set were not tested at all.
It is necessary to introduce non-regression tests for this area.
The 2 subroutines are: C4::Circulation::GetBranchBorrowerCircRule
and C4::Circulation::TooMany (only called by
C4::Circulation::CanBookBeIssued, so we will take the liberty to change
the prototype to raise a better warning to the end user).
Test plan:
I. Confirm there is no regression and the existing behavior is kept
0/ Let the syspref disabled
1/ Set a rule to limit to 2 the number of checkouts allowed
2/ Do a normal checkout
3/ Do an on-site checkout
4/ Try to checkout (on-site or normal) an item again.
You should not be allowed.
II. Test the new feature - pref disabled
0/ Let the syspref disabled
1/ Set a rule to limit to 2 the number of checkouts allowed and to 1
the number of on-site checkouts allowed.
2/ Do an on-site checkout
3/ Try to do another one, you should not be allowed to do it.
4/ A normal checkout should pass successfully
Note that it does not make sense to have the number of on-site checkouts
alowed > number of checkouts allowed.
III. Test the new feature - pref enabled
0/ Enable the syspref
Now an on-site checkout is *not* counted as a normal checkout.
This means you can have the number of on-site checkouts > number of
checkouts allowed.
1/ Set the values you want for the 2 types of checkouts (normal vs
on-site).
2/ Even if a patron has reached the maximum of checkouts allowed, he
will be allowed to do a on-site checkout (vice versa).
IV. Stress the developper
Using the different configurations available in the circulation matrix,
try to find one where the checkout is allowed and not should be.
Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Nicolas Legrand <nicolas.legrand@bulac.fr>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
The KohaDates plugin does that, it's not necessary to split the output.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch removes deprecated C4::Dates from circ/bookcount.pl
To test:
- Search for biblio with an item that has been checked out several
times and that has been transferred
- In left navigation click on 'Items'
- In list of items click on 'View item's checkout history'
- Verify that dates in 'Date arrived at current library' and in
column 'Last seen' display properly.
Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as advertised
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
From bug 7981:
GetBranchItemRule expects an itemtype, a scalar.
Here $itemtype is a hashref returned by C4::ItemType->get.
So $itemtype->{itemtype} should be passed.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Test plan: See Bugzilla.
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
On the checkin and checkout page, the checkin will fail if the patron
has requested the privacy and the AnonymousPatron is not correctly set.
This patch adds a warning message on both pages.
Test plan:
0/ Be sure you don't have any patron with privacy=2 (Never)
1/ Set OPACPrivacy, not AnonymousPatron
2/ Go on the checkin, you should a warning (same as before this patch).
3/ Set the privacy=2 for a patron
4/ Go on the circulation page, a warning should appear (for this
specific patron)
5/ Check an item out to this patron
6/ Check the item in on the checkin page.
The item is not checked in and you get a specific message for this
patron.
Confirm other/correct situations don't trigger the messages.
Followed test plan. Works as expected.
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Test plan:
1. Ensure that ExpireReservesMaxPickUpDelayCharge is set to 0.
2. Place a hold (doesn't matter whether it's a bib/item-level hold),
then confirm the hold by checking it in.
3. Check in the item again, and hit Cancel.
4. The reserve in question should be cancelled.
5. Repeat steps 2-4 twice, once after setting
ExpireReservesMaxPickUpDelayCharge to a nonzero value and again
after clicking the "Forgive fees for manually expired holds"
checkbox.
A fine should only be applied when the syspref is enabled and the
checkbox is not checked. Also, the checkbox should only appear after
enabling the syspref. And finally, the checkbox should remember whether
it is checked across multiple checkins, same as the "Forgive overdue
charges" and "Book drop mode" checkboxes.
Signed-off-by: Jason Burds <jburds@dubuque.lib.ia.us>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Amended patch: Removed 2 debugging lines.
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
This is the original patch for bug 12892 and replaces the older style of
fetching the holds data with Koha Objects. It will be used as a
foundation for future features.
Test Plan:
1) Apply this patch
2) Create a hold, set to waiting
3) Browse to circulation.pl for that patron
4) Note you see the list of waiting holds
5) Switch your logged in branch to a different branch
6) Note the "Waiting at" line is no longer emphasized.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Cathi Wiggins <CWIGGINS@ci.arcadia.ca.us>
Signed-off-by: Megan Wianecki <mwianecki@mplmain.mtpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
The first error is caused by the fact that
$messages->{'IsPermanent'} is undefined.
The second error is caused by querying the CGI
parameter 'barcode' inside a function call. This is not required.
There is a variable $barcode set with the parameter. Changed to
use the variable.
TEST PLAN
----------
1) Test first patch.
2) Clear the log
3) Put in a barcode which is not checked out.
4) Check the log.
-- should be two errors. One about a hash,
the other will only be detectable under Debian 8.
5) Apply this second patch
6) Clear the log
7) Put in a barcode which is not checked out.
8) Check the log.
-- should be empty.
9) run koha qa test tools
Signed-off-by: Indranil Das Gupta (L2C2 Technologies) <indradg@gmail.com>
Signed-off-by: Nick Clemens <nick@quecheelibrary.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Test plan
=========
1/ check out an item and then check it back in.
1/ check the logs after the check-in to see the warns from
returns.pl line 623 of :
(a) Use of uninitialized value $holdingBranch
(b) Use of uninitialized value $collectionBranch
2/ apply patch
3/ check out and check-in again. no warns are recorded this time.
NOTE: Under Debian Jessie, there are other messages.
Additionally, this only corrects the line 623 ones.
Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Nick Clemens <nick@quecheelibrary.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
This patch adds a "Don't Check Out and Print Slip" button to the dialog that appears
when trying to checkout a reserved item.
Test case :
* Put a hold on an item for User A.
* Try to check out it item with User B.
* The "Please confirm checkout" box should appear. The "Don't Check Out and Print Slip" button should appear in this box.
* Click on the "Don't Check Out and Print Slip" button.
* A print popup will appear
Signed-off-by: Nick <Nick@quechelibrary.org>
Followed test plan, works as expected.
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
On moremember, the button is displayed for Organisations.
To be consistent, it should be displayed on the circulation page too.
Signed-off-by: Jonathan Druart <jonathan.druart@koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Patch makes several small changes to the template for the
'Transfers to receive page'
1) Show the branch name instead of the branchcode in the
table of incoming transfers.
If there is a hold connected with the transfer:
2) Show the patron's name as 'surname, firstname'
intead of 'surname firstname'
3) Restore broken feature: Show a mailto: link with a
generated subject of 'Hold: <title>'.
The mailto: feature actually existed in the templates, but
was broken to a misnamed database column. I made some small
changes to make the subject translatable (see bug 8330).
To test:
- Create a transfer by placing a hold with pickup at another library
- Craete a transfer manually
- Go to the circulation > transfers to receive
- Check the changes explained above, compare before and after
- Check the mailto: link works as expected
Bonus: Check the Hold: bit in the subject is really translatable now.
Signed-off-by: Nick Clemens <nick@quecheelibrary.org>
Signed-off-by: Jonathan Druart <jonathan.druart@koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
The parameter was lost in previous commit.
Signed-off-by: Jonathan Druart <jonathan.druart@koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Note that homebranchname is never used in the template.
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Jonathan Druart <jonathan.druart@koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
This patch removes HomeOrHoldingBranchReturn syspref and makes circ/returns.pl respect branch
circulation rules from C4::Circulation::GetBranchItemRule. Also transfer slip notice should reflect this.
Default should always be to return item to home branch.
Test plan:
- make sure syspref 'AutomaticItemReturn' is set to 'false'
- unset 'Default checkout, hold and return policy' or set 'Return policy' to 'Item returns home'
- checkout an item and do a checkin from different branch than items homebranch
- verify that you're prompted with a transfer message to item's home branch and that print slip matches
- set 'Return policy' to 'Item returns to issuing library'
- do a checkout and a checkin from branch different than item's home branch
- verify that you're not prompted with a transfer message and that holding library is your current branch
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Follow-up:
- Added 3 tests in t/db_dependent/Circulation_Branches.t to test AddReturn
policies
- Removed HomeOrHoldingBranchReturn from sysprefs.sql
- Added notice on removing syspref in updatedatabase
QA edits:
- removed trailing whitespace in tests
- moved branchname lookup from returns.pl to template
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Jonathan Druart <jonathan.druart@koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Test Plan:
1) Apply this patch
2) Renew an item via circ/renew.pl
3) Note the branch code of your logged in library is set as the
branch in the generated statistic line
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Tested pre and post patch, now branch is saved
No errors
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
(Introduced by bug 13601)
Test plan
=========
1/ enable 'OnSiteCheckouts' pref under Circulation Preferences
2/ go to the checkouts page and try to issue an item to any user.
3/ when the item barcode entry form shows, select the 'On-site
checkout' checkbox
4/ the default date due should show as today with 00:00 as HH:MM
5/ apply the patch
6/ repeat steps 2 - 3. The default date due should show today's
date with 23:59 as HH:MM.
7/ run koha-qa.pl -c 1 -v 2
Remarks: Testing result match expected test plan output. The QA tests
pass with "OK" for the commit.
Technical note: There is a confusion with iso and sql date formats at
some places in the code.
A better way should be provided (later) to fix globally the mismatch
between these 2 formats.
What happened before this patch: the DateTime was cast to a string and
the template received "YYYY-MM-DDTHH:MM:SS" which is an iso formatted
date. BUT this format is not managed by Koha::DateUtils::output_pref
("iso" and "sql" are considered as indentical which is wrong).
As I did not estimated the problem (how big it is) I prefer to fix it
easily (and dirty) for now.
Signed-off-by: Indranil Das Gupta (L2C2 Technologies) <indradg@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
The script that returns data for the patron autocomplete does not use C4::Members::Search. Instead it uses bespoke code that does not behave like the traditional search and is very limited in how it can search.
If, for example, I search for "Kyle Hall" in the standard search, I would get "Kyle Hall" back as a result. For the autocomplete search, I will not.
This script should use C4::Members::Search to provide better searching and to keep the code base DRY.
Test Plan:
1) Enable the system preference CircAutocompl
2) Create a user with the first name "Test" and the surname "User"
3) Perform a checkout autocomplete search for "Test User"
4) Note you do not get the user as a result
5) Apply this patch
6) Try different combinations of "Test" and "User" such as
Test User
User Test
U Test
Test U
etc.
7) Note these searches now work
Works as expected.
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch displays the address information in the left column of the patron's pages using the new system preference.
The address is formatted in member-display-address-style-us.inc and member-display-address-style-de.inc
To test:
- Apply patch on top of 1st and 2nd patch
- Select 'German style' in system preference 'addressformat' in I18N/L10N
- Verify that the address information displays properly in the left column of all patron's pages.
- Verify that the address displays properly in the main area of moremember.pl as well (Note: In right column, Alternate address /contact are not yet touched))
- Switch system preference to US style, repeat checks
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
AMending without changes to put this patch at the end of the patch list / Marc
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
The biblionumber is sent to the template as 'itembiblionumber' at 1 place, the template get the 'biblionumber' variable.
I don't understand why but the easy way is to sent the variable twice.
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
The problem has been well described by Kyle and Nicole on bug 7255
description and comment 1.
With this counter patch, I suggest to popup AFTER the return has been
confirmed. This will remove the race condition and avoid to pass
itemnumber to the pl file as in the patch submitted by Olli.
Only the borrowernumber and biblionumber are needed (transfer and op are
never used by circ/hold-transfer-slip.pl).
Test plan:
It is very hard to know all cases (at least 6) where the popup is
displayed. Try at least to get the hold and the transfer confirmation
messages.
You should get the popup if you click on "print slip" button.
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Signed-off-by: Chris Nighswonger <cnighswonger@foundations.edu>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
http://bugs.koha-community.org/show_bug.cgi?id=9987
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
It seems that many librarians find it disconcerting to have no feedback
with the new checkouts table. It seems that many of them wait for it to
fully load, check to verify the item was checked out, and only then
check out the next item.
To help alleviate this issue, we can have the checkouts page give
feedback about the item that was just checked out.
Test Plan:
1) Apply this patch
2) Check an item out
3) Note the message "$title ($barcode) due on $date_due"
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
This works well and fixes a very problematic issue with the new AJAX
circ. I will be submitting a follow-up which I think is an improvement
to the display.
Signed-off-by: Jason Burds <jburds@dubuque.lib.ia.us>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch uses the same method as bug 13894.
Important note: This will modify the UI.
The patron list will now be displayed in a table (instead of a select).
Test plan:
1/ Search for a patron using the checkout tab
2/ The patron list should appear correctly
Test with different type of search (returns 0, 1, 1+ results).
No behavior changes should be observed.
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
works as expected
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Using the autocomplete feature in the patron search, if one value is
missing (i.e. country), it will be replaced with 'null'.
The default value should be an empty string.
Test plan:
0/ Enable the patron autocomplete feature
1/ Create a patron without value for country, address, zipcode, city
2/ Go on the circ home page
3/ Search for this patron. The country should not have been replaced by
"null".
Signed-off-by: Nicolas Legrand <nicolas.legrand@bulac.fr>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
The pref AddPatronLists does not work as expected if 'generic' is
selected.
Indeed a patron should be linked to a valid patron category (see the
constraint borrowers_ibfk_1 in the DB structure).
Test plan:
0/ Confirm that the AddPatronLists does not work as expected if you choose
the generic patron types.
1/ Delete all you patron categories and check that the interface invites
you to create one.
2/ Confirm that you are able to create a patron and to link it to a patron
category you have created.
I could not verify step 1/, because at least one Patron category
can not be deleted (Staff, since I'm logged in as a Staff patron
and you can not delete categories that are in use).
Tested 0/ and 2/
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes QA script and tests.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Test Plan:
- Create an overdue item.
- Navigate to overdue circulation report (Home -> Circulation -> Overdues)
- Notice there is no card number showing in the Patron column.
- Apply patch.
- Refresh page.
- Notice there is a card number showing in the Patron column.
Signed-off-by: Justin <justinvos@live.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
The circulation page has a new entry: a link to a list of the pending
in-house use.
Bug 10860 introduces a new way for managing in-house uses.
This patch adds a new page (from the circulation home page) to list all
pending in-house uses.
Test plan:
Go on the circulation home page and click on the in-house use link.
Verify all your in-house uses are listed and information are consistent.
Bug 11201: Display lib instead of AV code
This patch assumes that items.location is linked the the LOC
authorised values.
Signed-off-by: Nicole <nicole@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
To get rid of SQLHelper, we should not use this C4::Members::Search anymore.
Test plan:
0/ Enable the CircAutocompl pref
1/ Go on the circulation home page, or the reserve page
2/ Search for a patron and wait for the autocompletion box
3/ Confirm there is no regression
Works as expected.
Signed-off-by: Marc Veron <veron@veron.ch>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This will remove the restriction that forces the due date for
an on-site checkout to the end of the current day.
It will still suggest the end of the day, but you will be able
to change the date to whatever you want using the datepicker
widget.
To test:
Before applying the patch:
- Turn on OnSiteCheckouts and OnSiteCheckoutsForce
system preferences
- Check the on-site use checkbox and try to set due date
manually, it should not be possible
- Check out the item and check the due date is set to the
end of today
- Put a restriction on your patron account and repeat steps,
the item checked out should again have a due date at the
end of the day
> There should be no way to be able to check out an item
with a 'custom' due date
Apply the patch:
- Repeat steps from above, check out
- on-site use without a restriction on your account
- without changing the due date
- with a due date picked with the datepicker
- on-site use with a restriction on your account
... see above
- no on-site use but with a specified due date
- no on-site use, not specifying a due date
- Turn off SpecifyDueDate
- on-site use with and without restriction should
set the due date automatically to the end of the date
now, altering the due date should not be possible.
Signed-off-by: Nicole Engard <nengard@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Added small patch to allow barcode as input in TransferSlip routine, mostly
to allow generating transfer slips where only barcode is present (aka.
javascript).
Test plan:
1) find book with <barcode> and <itemnumber>
2) generate transferslips with both:
transfer-slip.pl?transferitem=<itemnumber>3967925&branchcode=MPL&op=slip
transfer-slip.pl?barcode=<barcode>&branchcode=MPL&op=slip
and verify that the generated slips match.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Edit:
- Added tests in t/db_dependent/Circulation_transfers.t
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Passes tests and QA script.
Works with both itemnumber or barcode as described.
Tested printing transfer slips with the URL examples given
and in the UI.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
It seems odd that only the holding libraries are listed on the holds
ratios report, we should add the home libraries as well.
Test Plan:
1) Apply this patch
2) Run the hold ratios report
3) Note the new home libraries column
Signed-off-by: Heather Braum <hbraum@nekls.org>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
The holds ratio report ignores ordered items. This could cause a library
to inadvertently order more copies of a title than they actually need.
An option should be added to count ordered items ( i.e. any negative
notforloan value ).
Test Plan:
1) Apply this patch
2) Create a record with two items, one regular, one ordered.
3) Place 3 holds on the item
4) Run the reserve ratios report, by default you should see this record
5) Check the new 'include ordered' checkbox, rerun the report
6) Note that record is no longer displayed
Signed-off-by: Heather Braum <hbraum@nekls.org>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
One day late patrons were restricted even with dropbox mode activated
1) Check in the calendar (Tools/Calendar), that the
previous days you are about to use as date due are
really entered as opening day (never know).
2) Add a suspension in the suspension days parameter
of the circulation rules (Administration/Circulation
and fine rules) to the MOST specific category of
borrower and MOST specific type of document among the
existing rules of the LOGGED IN Site(cf explications
in the circ-rules page).
3) Choose a borrower using the search by category and an
item through the advanced search using the limit by type.
4) Checkout the item selecting the previous opening date
in the Specify-due-date box.
5) Click on Circulation in the upper menu, then on Checkin
and check the Book drop mode. The Book drop date showed
should be the previous opening date.
6) Check in the item : you can see that the patron is restricted
7) apply the patch
8) Redo 1 to 5 : Now, you can see that the patron is not restricted.
9) If you redo the test with two day late, you will see that
the patron is not restricted : that's ok because his
restriction of one day is already finished.
10) If you redo the test with more than two day late, you see
that the patron restriction is, as expected, one day shorter
than it were if the item had been returned without dropbox mode.
Signed-off-by: Nick Clemens <nick@quecheelibrary.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 9811 removes useful code.
Actually the AddPatronLists pref is not sent to the template from
members/member.pl.
To fix this issue, we can use the existing not clean way, or compare the
syspref value directly in the template. This second solution is
implemented in this patch.
Test plan:
1/ Set the AddPatronLists pref to 'specific'
2/ On the patron home page (members/members-home/pl), the patron search
result page (members/member.pl after launching a search) and on the
checkouts page/patron search result (circ/circulation.pl after searching
a patron using the check out), verify that the patron category list is
the specific ones.
3/ Test there are no regression with the AddPatronLists pref set to
'general'.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Works as described and fixes the problem.
Note: I am not sure if AddPatronLists makes sense -
if you set it to general patron types, it still preselects the
wrong category type (tried organization, a child patron category
was selected). Also the name is confusiong nowadays with the
Patron list feature.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
According to the manual, "Items will stay in the PROC location until
they are checked in".
This is not the actual behavior. Right now items will only change from
PROC to CART, and that is only if InProcessingToShelvingCart is enabled.
Some libraries want to use the PROC to permanent location feature,
without using the CART.
Additionally, the location is only removed if using returns.pl, but
that is not what the manual says either. What if the library uses
SIP2 devices for handling returns? This should be taken into
account.
Test Plan:
1) Apply this patch
2) Set an item's current location to PROC, and it's permananet location
to a different location.
3) Check the item in any way you wish
4) Note the shelving location is updated to the permanent location
5) prove t/db_dependent/Circulation/Returns.t
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
I tested this with items which had items.location set to 'PROC' and
items.permanent_location set to NULL, '', and a real value, and it
worked correctly in all cases. I tested with check-ins from returns.pl
and from the table of checkouts in circulation and the PROC location was
correctly removed in both cases.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Works as described, passes tests and QA script.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch adds a better check in message for patrons with indefinite restriction.
To test:
Check out an item to a patron.
Add a manual restriction without expiry date to that patron.
Check in the item.
Without patch, the checkin message reads:
Reminder: Patron was earlier restricted until 9999-12-31
Apply patch and repeat steps above.
The message should now read:
Reminder: Patron has a restriction (no expiry date)
NOTE: Changed wording at two places following Owen's suggestion. New: "Patron
has an indefinite restriction"
Signed-off-by: Frederic Demians <f.demians@tamil.fr>
Thanks Marc for catching this case. I was thinking like you that the wording
sounded strange while playing with bug 13242. Merge the original patch and the
followup, containing a better wording, thanks to Owen comment.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Works as described, no problems found.
Passes tests and QA script.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
If you have the SpecifyDueDate preference disabled and check something
out as an on-site checkout the due date seems to follow the default
circulation rule rather than restricted the checkout to that day.
Test plan:
0/ Disable SpecifyDueDate and enable OnSiteCheckouts
1/ Check an item out to a patron and check the 'On-site checkout'
checkbox
2/ Verify (screen and DB) that the due date is correct (today 23:59)
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Works as described, passes tests and QA script.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch makes some minor updates to the output of the holds awaiting
pickup report. To test you should have several holds which are marked as
"waiting," including some which have been waiting longer than the number
of days specified in the ReservesMaxPickUpDelay system preference.
- Go to Circulation -> Holds awaiting pickup
- In both the "waiting" and "over" tabs, confirm that titles display any
associated subtitle
- Confirm that library name is shown instead of library code
- Confirm that the patron name mailto: link works correctly
Signed-off-by: Frederic Demians <f.demians@tamil.fr>
Works as described: subtitle displayes (if mapping defined), library name
instead of code, and email as clickable mailto.
Remark 1: As for bug 13083, subtitle display is not as good in UNIMARC than in
MARC21, since subtitle is not separated from title by ':'.
Remark 2: 'subtitle' field is retrieved from a field mapping. Taking a look at
C4::Biblio::GetRecordValue, one see that the fieldmapping is directly queried.
There isn't any caching system, like for frameworks.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Works as described and passes tests and QA script.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Trusting the sign off on the other page, I only tested the QA changes
Signed-off-by: Cindy Murdock Ames <cmurdock@ccfls.org>
Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Test Plan:
In "Tools" -> "Rotating Collections" -> "Add/Remove items":
When adding item barcodes to the collection, the input field
<input type="text" id="barcode" name="barcode">
should become active
automatically so it is easy to add multiple barcodes rapidly without touching the
mouse or keyboard.
Enter-press is dealt by the barcode reader so automatic form submittal should be handled
by the barcode reader.
In "Rotating collections" -> "Transfer Collection":
When the collection is initially transferred, items are set to trasfer correctly.
When the collection is transferred while items are still being transferred, the transfer
destination library doesn't change from the original one.
The holding library changes for all items in the collection to the destination library on
retransfers as well.
This is tricky if a user accidentally places the wrong destination.
When I try to checkin these items to their new retransfer location, I get the following messages:
-"This item is part of a rotating collection and needs to be transferred to <original transfer destination>"
-"Please return Valkoinen ihmissyj / to <original transfer destination>"
-"Print slip or Cancel transfer"
When I checkin a Item to a arbitrary branch, I get the following messages:
"This item is part of a rotating collection and needs to be transferred to <retransfer destination>"
"Please return Valkoinen ihmissyj / to <original trasfer destination>"
Bug 8836 - Resurrect Rotating Collections - QA Followup
Bug 8836 - Resurrect Rotating Collections - Followup 2 - Perltidy rotating collections scripts
Bug 8836 - Resurrect Rotating Collections - Followup 3
* Fix bad TT Tag
* Fix bad sql query
* Fix capitalization ( HTML4 )
* Allow a rotating collection's location to keep AutomaticItemReturn
from sending it back to the branch of origin
* Fix bad query
Bug 8836 - Resurrect Rotating Collections - Followup 4 - Autofocus on barcode field
Bug 8836 - Resurrect Rotating Collections - Followup 5 - Don't transfer issued and waiting items
Items in a rotating collection are automatcially transferred when a
collection is transferred. This is a problem for currently checked out
items and items on hold marked as "Waiting".
This patch resolves this issue by skipping the transfer for those items.
When the items are then returned, the librarian will be alerted to
transfer the item to the library currently holding that rotating
collection.
Bug 8836 - Resurrect Rotating Collections - Followup 5 - Link collections.colBranchcode to branches.branchcode
Signed-off-by: jmbroust <jean-manuel.broust@univ-lyon2.fr>
Signed-off-by: Cindy Murdock Ames <cmurdock@ccfls.org>
http://bugs.koha-community.org/show_bug.cgi?id=8835
Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Bug 11703 breaks the checkouts export feature.
To reproduce: Fill the ExportWithCsvProfile pref and go on the
circ/circulation.pl page. The export column appears, but not the export
button.
Test plan:
Go on the checkout list (circ/circulation.pl and members/moremember.pl)
and verify the export column and the export button appears.
If you click on the button, a file should be generated.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This doesn't depend on anything other patch.
1. Create a reservation for a Borrower with pickup branch
2. Check-in the corresponding Item in the pickup branch and confirm the hold
for the Borrower
3. Go to circ/circulation.pl for the Borrower and verify that the reservation
is "Waiting for pickup"
4. In the Borrower -> Check Out -tab (circ/circulation.pl) on the right of the
big "Checking out to borrowername" should be a notification about holds ready
for pickup.
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Rafal Kopaczka <rkk0@poczta.onet.pl>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script, restores the old code and behaviour.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Fixing some simple display issues caused by missing/misnamed
variables, probably consequence of the renaming before.
Amended test plan:
- Make sure that if OnSiteCheckoutsForce is set, you can
still perform onsite checkouts and only those.
- Check the detail page in staff says *currently in local use by*
for an on-site checked out item
- Check the detail page in OPAC with OPACShowCheckoutName active
for the same.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch implements the In-House Use feature for Koha.
It adds:
- 2 new sysprefs:
'In-House Use' to enable/disable this feature
'In-House Use Forced' to enable/disable the feature for *all* users.
- 2 new columns issues.inhouse_use and old_issues.inhouse_use
- Datatable on the circulation history pages (readingrec) at the OPAC
and the intranet.
A new checkbox in the Circulation tab. If checked, the issue become a
in-house use (in the statistics and issues tables).
When you check it, the due date changes to the today date.
The syspref "In-House Use Force" allows to force the in-house use to
permit the checkout even if the borrower is debarred or others problems.
In the issue table, a new string (in red) marks the issue as "in-house use".
The circulation history contains 3 tabs : "all", "checkout" and
"in-house use" (OPAC and intranet).
The cronjob script:
If AutomaticItemReturn if off, a library would like not to do a transit
operation manually. This script (to launch each night) do returns
for a specific branches.
Test plan:
1/ Execute the updatedatabase entry
2/ Enable the 'In-House Use' pref.
3/ Checkout a biblio for a patron and check the 'in-house use' checkbox.
4/ Check that the due date is the today date (with 23:59) and is not modifiable.
5/ Click on the check out button and check that the new check out
appears in the table bellow with the "(In-house use)" string.
6/ Go on the circulation history pages (readingrec and opac-readingrec)
and try the 3 tabs. In the last one, your last checkout should appear.
7/ Check in.
8/ Check readingrec pages.
9/ Choose a debarred patron and check that you cannot checkout a biblio
for him.
10/ Switch on the 'In-House Use Forced' pref
11/ You are now allowed to checkout a biblio for the debarred patron.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Only allow $force_allow=1 if the logged in user has permissions.
TEST PLAN
---------
Attempt to intentionally override the checkout by passing an
appropriately handcrafted URL.
-- Regardless of the force_allow value, it should be not allowed
for those lacking the force_checkout permission.
NOTE: I didn't test this. I figured Marc Veron could do that. :)
(Sorry, couldn't easily get git bz to work with the accent)
Signed-off-by: Nick Clemens <nick@quecheelibrary.org>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Add a button to temporarily override patron debarment.
To test:
1) Go to patron check out page
2) If patron has been debarred (eg. due to having fees),
there is no way to check out to that patron.
3) Apply patch
4) A debarred patron check out page now has a button for
"Override debarment temporarily" - clicking on it
should allow checking out to that patron.
Signed-off-by: Aleisha <aleishaamohia@hotmail.com>
Rebased because patch did not apply
Signed-off-by: Aleisha <aleishaamohia@hotmail.com>
Signed-off-by: Nick Clemens <nick@quecheelibrary.org>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Tested with/without force_checkout and superlibrarian permission.
Also checked crafting a URL is no longer working.
No regressions found.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch adds the new renewal errors 'auto_renew' and 'auto_too_soon'
to the renewal interface.
To test:
1) Issue two items:
- one with automatic renewal and no value for "No renewal before"
- another with automatic renewal and a value for "No renewal before"
2) Try to renew:
Home > Circulation > Renew
3) Confirm there are error messages explaining that the items have been
scheduled for automatic renewal and that one of the renewals is also
premature.
4) If global syspref AllowRenewalLimitOverride is set to "Allow" you
should be given the option to override.
Sponsored-by: Hochschule für Gesundheit (hsg), Germany
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch adds a checkbox for "Automatic renewal" to the checkout page.
CanBookBeRenewed is modified to include two new errors:
- auto_renew (renewal shouldn't be done manually)
- auto_too_soon (renewal is premature and shouldn't be done manually)
To test:
1) Add or edit an issuing rule with "Automatic renewal" and another
one without it.
2) Issue at least three items:
- automatic renewal by issuing rule
- automatic renewal by Checkbox on the checkout page
- no automatic renewal
3) Test the following steps for both:
Home > Circulation > Checkouts
Home > Patrons > Patron details
4) Confirm that issues with automatic renewal cannot be renewed manually,
even if there are still renewals left and it's not too soon to renew.
5) Confirm that "Scheduled for automatic renewal" and the remaining
renewals are displayed. If no renewals are left "Not renewable" should
be displayed.
6) Confirm that issues without automatic renewal behave as usual.
Sponsored-by: Hochschule für Gesundheit (hsg), Germany
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Modified:
circ/waitingreservers.pl - added GetFirstValidEmailAddress
Testing:
I Apply the patch
0) Put an item in hold for pickup;
1) In Circulation -> Holds awaiting pickup, validate email (column Patron);
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Works as described and will use the first valid email address.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch removes the only instance in this file
To test:
1. Apply the patch
2. Search for patrons on staff CheckOut,
use a string that gives multiple results
3. Results are displayed on a select,
that was replaced.
4. Check for regressions: select a patron and press 'Select',
or do double click on a patron name, verify you go
to patron's checkout tab.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Differences between circ-menu.tt and circ-menu.inc always crop up when a
new menu item is added--usually only to circ-menu.inc as happened with
Bug 9261.
Other sidebar differences are present due to differences in the patron
data passed by various patron-related script to their templates. This
patch also irons out some of these inconsistencies.
To test, apply the patch and check out to a patron whose record has more
than just basic data: othername, country, patron attributes, street
number, road types, etc. View the following pages and compare the patron
data and visible tabs to confirm that they match:
circ/circulation.pl?borrowernumber=X
members/boraccount.pl?borrowernumber=X
members/files.pl?borrowernumber=X
members/mancredit.pl?borrowernumber=X
members/maninvoice.pl?borrowernumber=X
members/member-flags.pl?member=X
members/member-password.pl?member=X
members/moremember.pl?borrowernumber=X
members/notices.pl?borrowernumber=X
members/pay.pl?borrowernumber=X
members/paycollect.pl?borrowernumber=X
members/purchase-suggestions.pl?borrowernumber=X
members/readingrec.pl?borrowernumber=X
members/routing-lists.pl?borrowernumber=X
members/statistics.pl?borrowernumber=X
tools/viewlog.pl?do_it=1&modules=MEMBERS&modules=circulation&src=circ&object=X
The only difference I've found which is not fixed by this patch is the
display of extended patron attributes in the sidebar of moremember.pl.
This is a piecemeal fix for a problem which really deserves a
centralized solution, but at least it gets us back to consistency for
the moment.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Going through all tabs shows consistency is back. A mid term solution should
implement this in a centralized way. Great job Owen!
No koha-qa errors btw.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Since we switched to Template Toolkit we don't need to stick with the
sufix we used for HTML::Template::Pro.
This patch changes the occurences of '.tmpl' in favour of '.tt'.
To test:
- Apply the patch
- Install koha, and verify that every page can be accesed
Regards
To+
P.S. a followup will remove the glue code.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Steetnumber is not included in the addess in the hold alert add the
field to those displayed
To test this, place a hold on an item that is on-loan, having first made
sure that the requesting user has a value in the street number field of
his address. Check the item in, and an alert should appear giving the
name and address of the requesting user. This address should include the
contents of the street number address field.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
I was able to confirm three of the four template changes for the
following cases:
- Item placed on hold for a patron at the current library, not waiting
- Item placed on hold for a patron at the current library, already
waiting
- Item placed on hold for a patron at another library, not waiting
I don't know how to trigger the case [% IF ( diffbranch ) %].
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes QA script and tests.
Note: Maybe sample slip templates should also include street number?
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch modifies staff printslip.tt to take into account
caller. Also fixes similar problem on opac printslip.tt
To test:
staff
1. Print hold transfer slip
2. Print transfer slip
3. Print member slip
opac
4. Print self checkout slip
5. Update translation files, check new strings are present
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch rewrites transfer slip code to make some
strings translatable.
Also simplifies some code and parameters.
To test:
1) Produce a transfer slip, no changes must be noted.
2) Update PO file, new strings
msgid "%s %s%s%sNo hold found%s %s %s "
msgid "%s%s%sNo hold found%s "
msgid "Koha › Circulation › Transfers"
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
When a patron has many checked out items, circulation.pl can take a very
long time to load ( on the order of minutes in some cases ). This is
primarily due to the processing of the previous checkouts list. If we
convert to this table to a datatable that fetches its data via ajax, we
can make circulation.pl far more responsive. The same should be done
with relative's checkouts as well.
Test Plan:
1) Apply this patch
2) Observe that the checkouts and relatives' checkouts tables
are now loaded asynchronously
3) Observe and verify the renew and return actions are now
ajax based and function in a manner equivilent to how they
used to.
This bug had quite a few followups, so I squashed all of them into one
change so that code is easier to follow. Original commit messages are below:
Bug 11703 - Use the ajax datatables on patron details page
Bug 11703 - Convert holds tables to ajax datatables
Bug 11703 [QA Followup 1] - Center bProcessing message over table
Bug 11703 [QA Followup 2] - Remove icons from checkout and clear buttons
Bug 11703 [QA Followup 3] - Remove references to UseTablesortForCirc
Bug 11703 [QA Followup 4] - Add back in Today's checkouts/Previous checkouts rows
Bug 11703 [QA Followup 5]
Bug 11703 [QA Followup 6] - Move strings to an include file for translation purposes
Bug 11703 [QA Followup 7] - Fix issues spotted by koha-qa.pl
Bug 11703 [QA Followup 8] - Speed up api/checkouts.pl as much as possible
Bug 11703 [QA Followup 9] - Move scripts from api directory to svc directory
Bug 11703 [QA Followup 10] - Fix errors caused by rebase
Bug 11703 [QA Followup 11] - Prevent multiple fetchs from ajax source
Bug 11703 [QA Followup 12] - Fix problem detected by koha-qa.pl
Bug 11703 [QA Followup 13] - Removed uneccessary data from renewal box during renewal
Bug 11703 [QA Followup 14] - Fix table column span
Signed-off-by: Dobrica Pavlinusic <dpavlin@rot13.org>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script.
Test plan on bug report:
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11703#c98
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org>
Display, at check in, a reminder of an already existing suspension date
even if the returned document is not late.
Test plan :
1) Apply the patch
2) Go to a borrower checkout page and checkout some documents with
different passed duedate using "Specify due date" function. Checkout out
one with the default duedate.
3) Check in the document with the bigger delay :
You will get the message : 'X is now restricted until ...'
4) Check in one of the document with a smaller delay :
You'll get a different message : 'Reminder : Patron was earlier
restricted until...'.
5) Check in the document which is not late :
You 'll get the same message as the previous one
Signed-off-by: JMBroust <jean-manuel.broust@univ-lyon2.fr>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This enhancement introduces a possibility to place orders
from hold ratios list:
- new option "Add order to basket" -> "From titles w/ highest hold ratios";
(user gets redirected from acqusition to "hold ratios" list in circulation)
- "N to order" in "Items needed" column now becomes a link - when clicked,
user gets redirected back to acquisition, directly to order form for
a choosen title (suggested quantity "N to order" is being preserved)
- in the "Items needed" column, there is an additional indication if
there are any pending (not yet received) orders for a given title
This solution is not exactly ideal.. most important drawback: to use
it librarian needs both acquisition & circulation priviledges; if not
having both - new options will not show / wouldn't be active. But it
requires relatively small amount of changes in the code.
To test:
- apply patch,
- test new functions (try to place some orders using an newly added
option, examine resulting order records etc.)
- check modified hold ratios list for possible problems (for user
with only circulation priviledges, additional information regarding
pending orders should be still visible, but not the link
to order form)
- ensure the two following existing options for adding orders to basket
("From an existing record", "From a new (empty) record") a still working
properly.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Minor edit in signoff: Changed "w/" to "with"
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
This works nicely in my tests, neat new addition.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch ensures that the note displayed when checking in a loan
to a restricted patron (and setting the return date) is displayed
whether or not the circulation staffer has chosen the make the return
date override sticky.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
- new TT plugin for Borrowers, that at present supplies
a method for determining if the patron is restricted
- setting the default value of SpecifyReturnDate to false
during upgrade to avoid an unwelcome surprise
- validate the return date on the client side before
allowing the form to be submitted.
Signed-off-by: Petter Goksoyr Asen <boutrosboutrosboutros@gmail.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Sometimes libraries need to backdate returns further back in time than
Koha's dropbox mode will allow. The returns backdating will check in an
item as if it had been returned on the specified date, and will reduce
any fine accordingly.
This feature is activated by a new system preference, SpecifyReturnDate.
Test Plan:
1) Apply this patch
2) Check out an item, and backdate the due date by 1 month or so
* This issue needs to generate a fine
3) Run fines.pl to generate the fine
4) Browse to returns.pl
5) Specify a return date of the day after the specified due date
6) Check the borrowers issue history, you should see the backdated
return date, rather than today's date
7) Check the fine, it should be reduced to a fine for a single day
overdue, rather than the previous larger fine.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Barbara Knibbs <BKnibbs@farmingtonlibraries.org>
Signed-off-by: Petter Goksoyr Asen <boutrosboutrosboutros@gmail.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Works as described, passes tests and QA script.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
C4::Context->userenv() won't return a valid value until the
user session set up, e.g., via get_template_and_user(). Consequently,
the change introduced by a previous commit for bug 11182 ended
up making it appear that when checking an item that fills a hold
that it always needs to be transferred.
This patch fixes the regression and moves the "no-branch-set" check
to where it belongs.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
To reproduce:
- On top of the previous patches, if you enable the
itemBarcodeFallbackSearch syspref and do a search for a term that
returns at least one result, there will be warnings for each result
without items attached.
To test:
- In the checkout form enter a term that should return results (some of
them without items attached)
=> There are warnings on the logs regarding a split of undef variable
- Apply the patch
- Repeat the first step
=> No warnings
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
TEST PLAN
---------
1) Log into staff client
2) Koha administration
3) Global system preferences
4) Circulation
5) Make sure FineNotifyAtCheckin is set to Notify.
6) Check out tab
7) Type patron's name and click 'Submit'
8) Select patron if required
9) Check out an item, but set the due date to be overdue.
10) Check in the overdue item.
11) Check the error log
$ cat ~/koha-dev/var/log/koha-error_log
NOTE: only the warnings from lines 269 and 540 in returns.pl
are the ones to note.
12) Apply this patch
13) Repeat steps 6 through 11, there should no new
warnings related to lines 269 or 540 from returns.pl.
Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This deals with the warning when Circulation system preference
'WaitingNotifyAtCheckin' is set to 'Notify' and an overdue item
is checked in.
TEST PLAN
---------
0) Feel free to backup your koha-error_log file, and then toast it.
$ echo > ~/koha-dev/var/log/koha-error_log
1) Log into staff client
2) Koha administration
3) Global system preferences
4) Circulation
5) Make sure WaitingNotifyAtCheckin is set to Notify.
6) Check out tab
7) Type patron's name
8) Select patron if required
9) Check out an item, but set the due date to be overdue.
10) Check in the overdue item.
11) Check the error log
$ cat ~/koha-dev/var/log/koha-error_log | grep 284
NOTE: the returns.pl one that will be fixed by this.
12) Apply this patch
13) Repeat steps 6 through 7, there should no new line 284 entries.
Signed-off-by: Jesse Weaver <pianohacker@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
TEST PLAN
---------
1) Log into staff client
2) Click 'Circulation'
3) Click 'Check out'
4a) Type a patron name, click 'Submit'
4b) If necessary, select which one, and click 'Select'
5) Check the error logs, new warnings
6) Apply patch
7) Click 'Circulation'
8) Click 'Check out'
9a) Type a patron name, click 'Submit'
9b) If necessary, select which one, and click 'Select'
10) Check the error logs, no new warnings
11) Click the 'Restrictions' tab
12) Click 'Add manual restriction'
13) Add a dummy restriction
14) Click the 'Restrictions' tab
15) Click 'Remove'
16) Click 'OK'
17) Confirm that no additional error log entries were added
and adding/deleting restrictions hasn't broken.
Signed-off-by: Jesse Weaver <pianohacker@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
The holds to pull report could be improved by improving sorting on the
title and date columns. This patch adds "anti-the" sorting to the title
column and "title-string" sorting to the date column.
Date formatting of another variable has been moved to the template for
formatting using KohaDates.
The patch includes other corrections for HTML validity.
To test, apply the patch and view the holds to pull report.
- Sorting by date should work correctly regardless of dateformat system
preference setting.
- Sorting of the title columns should correctly ignore articles.
- Formatting of the "Reported on" date should be correct.
Revision incorporates the corrections made by Bug 12127 and converts
those changes to use class-based sorting.
Signed-off-by: David Cook <dcook@prosentient.com.au>
The patch works as described. Thanks for including and improving the
changes from Bug 12127, Owen!
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes QA script and tests.
No regressions found, works as advertised.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Test Plan:
1) Add a manual restriction to a patron and wait until the
expiration date of the restriction has passed. This can be
simulated by modifying borrowers.debarred for a borrower and
setting the date in the past.
2) Try to check out an item to that patron
3) Note you cannot
4) Apply this patch
5) Repeat step 2
6) Note you can now check out items the patron
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
The 'notes' column has been removed from the pending holds and hold
ratios reports as they were not displaying in the first place.
1.apply patch
2.verify that both reports work
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch adds a step to verify that an operator has the writeoff
permission before allowing them to forgive overdue fines during
checkin, which was possible if the operator manually added an
"exemptfines" URL parameter.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 10649 introduced a new include file for adding DataTables-related
JavaScript assets. This patch adds use of this include file to all
circ-related pages which use DataTables.
Apply the patch and test the following pages to confirm that table
sorting works correctly:
- Circulation
- The UseTablesortForCirc system preference must be enabled.
- Check out to a patron with existing checkouts. Choose a patron who
is a guarantor to another patron with checkouts in order to test the
relatives' checkouts table.
- The checkouts and relatives' checkouts tables have been modified to
exclude articles when sorting of titles.
- Hold ratios - The title column has been configured to exclude articles
from sorting
- Transfer to receive
- Holds queue
- The title column has been configured to exclude articles when
sorting
- The date column has been modified to use the title-string filter for
sorting. An unformatted date is now passed from C4::HoldsQueue.pm to
the template, where the KohaDates filter is used for formatting.
Sorting is based on the unformatted date.
- Holds awaiting pickup
- The "available since" column has been configured for sorting on an
unformatted date. waitingreserves.pl now passes the unformatted
date to the template, and formatting is done using the KohaDates
filter.
- The title column has been configured to exclude articles when
sorting.
Edit: Rebased on current master following commit of Bug 11605
Signed-off-by: A. Sassmannshausen <alex.sassmannshausen@ptfs-europe.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch ensures that the new staff interface for renewals
recognizes when premature renewals are requested. If the
AllowRenewalLimitOverride system preference is enabled, staff members
are able to override the block:
To test:
[1] Set up a loan policy with a "no renewal before" value and
check out an item.
[2] In the renewal page, verify that attempting to renew the loan
results in an error forbidding the renew.
[3] If AllowRenewalLimitOverride is enabled, the operator should
also be given the option to override the block.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch modifies CanBookBeRenewed, so that based on
issuingrules.norenewalbefore a new error "too_soon" can be returned.
Also adds a new subroutine GetSoonestRenewDate.
To test:
1) Create an issuing rule with "No renewal before" set to value X
and "Unit" set to days.
2) Test the following steps for both:
Home > Patron > Patron details
Home > Circulation > Checkouts
3) On the checkout page, test for today's issues as well as previous
issues. (Check something out on one day and something else on the
next day, then do the testing.)
4) Confirm that items can't be renewed if current date is more than
X days before due date.
5) Confirm that the date and time of the soonest possible renewal are
displayed in the format specified by global sysprefs "dateformat"
and "TimeFormat".
6) Confirm that items can be renewed if "No renewal before" is
undefined or current date is X or less days before due date.
7) Confirm that if the number of allowed renewals is exceeded
"Not renewable" is displayed, no matter what "No renewal before"
is set to.
8) Test the same things with "Unit" set to hours.
Sponsored-by: Hochschule für Gesundheit (hsg), Germany
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
This patch removes some dead code concerning the handling of patrons
that are members of other, institutional patrons. This code did not
work; removing it clears the field if somebody wants to do a better
implementation of such relationships between patrons.
This patch:
[1] Removes the memberofinstitution system preference.
[2] Removes the following routines:
C4::Members::get_institutions()
C4::Members::add_member_orgs() (and removing this routine
removes a reference to a borrowers_to_borrowers table that
does not exist).
There should be no changes whatsoever to system functionality with this
patch (with the trivial exception of the absence of the
memberofinstitution system preference).
Test plan:
[1] Look at the code and use grep, git grep, etc. verify this patch
does not remove something in use.
[2] Verify that there are no regressions upon adding or editing
a patron record.
[3] Verify that the memberofinstitution system preference has been
removed
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
The report also known as "Overdues with fines"
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
All tests pass, this adds data to the Patron column on the
overdues with fines report to show the patron's cardnumber
and phone number.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
This works as described and passes all tests and QA script.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch makes Koha <-> Zebra use MARCXML for the serialization when
using DOM, and USMARC for GRS-1.
* The following functions are modified to set the Zebra record syntax
according to the current sysprefs and configuration:
- C4::Context->Zconn
- C4::Context-_new_Zconn
* A new function 'new_record_from_zebra' is introduced, which checks the
context we are in, and creates the MARC::Record object using the right
constructor.
The following packages get touched to make use of the new function:
- C4::Search
- C4::AuthoritiesMarc
and the same happens to the UI scripts that make use of them (both in
the OPAC and STAFF interfaces).
* Calls to the unsafe ZOOM::Record->render()[1] method are removed.
Due to this last change the code for building facets was rewritten. And
for performance on the facets creation I pushed higher version
dependencies for MARC::File::XML and MARC::Record (we rely on
MARC::Field->as_string).
* Calls to MARC::Record->new_from_xml and MARC::Record->new_from_usmarc
are wrapped with eval for catching problems [2].
* As of bug 3087, UNIMARC uses the 'unimarc' record syntax. this case is
correctly handled.
* As of bug 7818 misc/migration_tools/rebuild_zebra.pl behaves like:
- bib_index_mode (defaults to 'grs1' if not specified)
- auth_index_mode (defaults to 'dom')
here we do exactly the same.
To test:
- prove t/db_dependent/Search.t should pass.
- Searching should remain functional.
- Indexing and searching for a big record should work (that's what the
unit tests do).
- Test an index scan search (on the staff interface):
Search > More options > Check "Scan indexes".
- Enable 'itemBarcodeFallbackSearch' and try to circulate any word, it
shouldn't break.
- Searching for a biblio in a new subscription shouldn't break.
- Running bulkmarcimport.pl shouldn't break.
- And so on... for the rest of the .pl files.
[1] http://search.cpan.org/~mirk/Net-Z3950-ZOOM/lib/ZOOM.pod#render()
[2] a record that cannot be parsed by MARC::Record is simply skipped (bug 10684)
Sponsored-by: Universidad Nacional de Cordoba
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Currently road types are stored in a specific table in DB. Moreover, an
admin page is present in order to manage them.
This patch proposes to remove this table and this page in favour of a
new authorised value category 'ROADTYPE'.
This patch:
- adds a new AV category 'ROADTYPE' (created from the roadtype table
content).
- remove the roadtype table.
- remove the .pl and .tt file admin/roadtype
- remove the 2 routines C4::Members::GetRoadTypes and
C4::Members::GetRoadTypeDetails
Test plan:
1/ Execute the updatedatabase entry and verify existing roadtypes are
now stored in the AV 'ROADTYPE'.
2/ Verify you can add/update a streettype for patrons.
3/ Verify on following pages the streettype is displayed in patron
information (top left):
circ/circulation.pl
members/memberentry.pl
members/moremember.pl
members/routing-lists.pl
Signed-off-by: Sophie Meynieux <sophie.meynieux@biblibre.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch adds the renewal count to the 'Check out' and "Details' tabs
of the patron record.
This information already exists in the OPAC view of the patron record.
Since librarians might be serving patrons in person who want to know
this information without looking it up online, it makes sense to show
it in the staff client.
There may also be times where librarians want to see how many renewals
a patron has left, how many they've used already, etc. when making other
decisions.
_TEST PLAN_
Before applying:
1) Go to "Check out" with a patron that has some check outs before today
2) Add some check outs for today
*Ensure that all issues are for items that can be renewed*
3) Note that the Renew column just says '0' followed by a check box
4) Check the 'Detail' tab. It should say the same.
Apply the patch.
5) View the "Details" and "Check out" tabs again
6) Note that the renewal count now appears in the form resembling:
5 of 5 renewals remaining
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
All tests pass
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Before bug 9788 the alldates parameter of GetReservesFromItemnumber was
actually not used in the codebase.
The first patch of bug 9788 did change that and passed true by default.
But a closer look revealed that we do not really need it.
The parameter is removed by this patch; the SQL statement is slightly
adjusted: if reservedate<=now or a waitingdate is filled for the
requested itemnumber, GetReservesFromItemnumber will return the reserve.
This includes so-called future waits: a future hold that has been confirmed
ahead of time with pref ConfirmFutureHolds > 0 days.
Note that future item-level holds are not really interesting to return; this
just corresponds to original behavior. Future next-available holds are not
in view at all; they do not contain an item number.
Test plan:
Actually, the test plan of the first patch is valid. But for completeness I
repeat it here:
[1] Enable future holds and set ConfirmFutureHolds to 2 days.
[2] Place a future next-available hold for 2 days ahead.
[3] Check item status on catalogue detail. Available? That is fine.
[4] Confirm the future hold by checking it in. ('future wait')
[5] Look at item status again on catalogue detail. Must be Waiting now.
[6] Switch to OPAC and login as another opac user. Goto Place a hold.
[7] Check item status with item level hold info. Is it waiting?
[8] Try to place hold in staff, check item level status again. Waiting?
[9] Make a transfer for the item. Switch branch. Check hold status on
Transfers to receive.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch makes GetReservesFromItemnumber also returns the waiting
date and removes some repeated code.
Improves item status display on catalogue detail, when placing a hold at
opac-reserve and in staff, and on transfers to receive form.
This patch builds on work from reports 9367 and 9761.
Test plan:
Place a future next-av. hold (enable future holds prefs), say 2 days ahead.
Check item status on catalogue detail. Nothing to see.
Enable ConfirmFutureHolds by inserting a number of days, say 2.
Confirm earlier hold by checking it in. Look at item status again on detail.
Switch to other opac user. Try to place a hold again. Check item status with
item level hold info. Try to place hold in staff, check item level status.
Make a transfer for that item. Switch branch. Look at transfers to receive.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
The method of checking the logged in user for superlibrarian privileges
is obtuse ( $userenv && $userenv->{flags} % 2 != 1 ) to say the least.
The codebase is littered with these lines, with no explanation given. It
would be much better if we had one subroutine that returned a boolean
value to tell us if the logged in user is a superlibrarian or not.
Test Plan:
1) Apply this patch
2) Verify superlibrarian behavior remains unchanged
Signed-off-by: Joel Sasse <jsasse@plumcreeklibrary.net>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Comments on second patch.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
If you want to filter results on the tags management page by the
reviewer you have to know their borrowernumber. It would be better to be
able to search by name, but in the meantime this patch adds an
autocomplete widget to the form field so that you can do a name search
and populate the field with the borrowernumber.
To test you must have approved or rejected tags. From the tags review
page (tags/review.pl), view all, approved, or rejected tags. Type a name
in the "reviewer" form field in the left sidebar filter. You should get
an autocomplete dropdown with names matching your search. When you
select one the form field should be populated by the borrowernumber.
Signed-off-by: David Cook <dcook@prosentient.com.au>
Patch works as described. I'm not sure whether or not it would be better
to be able to search by name, as that would involve either choosing
between names after applying the filter or showing any possible matches,
so this seems fine.
--
Owen and I did observe that we were able to cause AJAX errors while
using this autocomplete, but we are not 100% sure how we caused the error.
In my case, I was able to occasionally cause it by typing in a name
then backspacing rapidly. The ajaxError method is attached to every
element in the DOM (yikes) so it's tough to say what exactly is the
source of the error (which is signalled by a pop-up window that can be
cancelled).
The error is quite rare so I don't think it's necessarily a problem
for us.
One idea that Owen had was to remove the current error message, which
is very unhelpful and replace it with an error like "Something went
wrong. Try again."
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch adds a more extensible and flexible debarments system to Koha. The fields
borrowers.debarred and borrowers.debarredcomment are retained for compatibility and
speed.
This system supports having debarments for multiple reasons. There are currently
three types of debarments:
OVERDUES - Generated by overdue_notices.pl if the notice should debar a patron
SUSPENSION - A punative debarment generated on checkin via an issuing rule
MANUAL - A debarment created manually by a librarian
OVERDUE debarments are cleared automatically when all overdue items have been returned,
if the new system preference AutoRemoveOverduesRestrictions is enabled. It is disabled
by default to retain current default functionality.
Whenever a borrowers debarments are modified, the system updates the borrowers debarment
fields with the highest expiration from all the borrowers debarments, and concatenates
the comments from the debarments together.
Test plan:
1) Apply patch
2) Run updatedatabase.pl
3) Verify the borrower_debarments table has been created and
populated with the pre-existing debarments
4) Run t/db_dependent/Borrower_Debarments.t
5) Manually debar a patron, with an expiration date
6) Verify the patron cannot be issued to
7) Add another manual debarment with a different expiration date
8) Verify the 'restricted' message lists the date farthest into the future
9) Add another manual debarment with no expiration date
10) Verify the borrower is now debarred indefinitely
11) Delete the indefinite debarment
12) Verify the debarment message lists an expiration date dagain
13) Enable the new system preference AutoRemoveOverduesRestrictions
14) Set an overdue notice to debar after 1 day of being overdue
15) Check out an item to a patron and backdate the due date to yesterday
16) Run overdue_notices.pl
17) Verify the OVERDUES debarment was created
18) Return the item
19) Verify the OVERDUES debarment was removed
20) Disable AutoRemoveOverduesRestrictions
21) Repeat steps 15 though 18, verify the OVERDUES debarment was *not* removed
22) Add issuing rules so that an overdue item causes a temporary debarment
23) Check out an item to a patron and backdate the due date by a year
24) Return the item
25) Verify the SUSPENSION debarment was added to the patron
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Adds a new Template Toolkit filter EncodeUTF8 to encode strings
to utf8 for correct display of diactritics.
Adds the new JavaScript function removeFocus() to staff-global.js
Use this function to remove the focus from any element for
repeated scanning actions on errors so the librarian doesn't
continue scanning and miss the error.
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This works as described - you have to actually look at the
error and pick what you want to do or confirm it. I think
maybe tying the action to a shortcut (c = confirm or similar)
would be nice, so you can get away with only using the keyboard.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch adds a renewal tool that functions similar to the returns where a
librarian can continuously scan items for renewal. This script blocks
renewals that are impossible, and allow the same renewal overrides
as circulation.pl
Test plan:
1) Apply the patches for bug 8798
2) Apply this patch
3) Browse to /cgi-bin/koha/circ/renew.pl
4) Enter an invalid barcode, you should get an error message
5) Enter a valid, but not checked out barcode, you should get an error
message.
6) Enter a valid barcode that is checkout out and should be renewable,
you should get a success message.
7) Enable AllowRenewalLimitOverride
8) Enter a barcode for an item that has been renewed too many times
9) You should get a warning which you can override.
10) Disable AllowRenewalLimitOverride
11) Repeat steap 8
12) You should get a blocking error message
11) Enter a barcode for an item with unfilled holds on it,
you should get an overridable warning
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Passes all tests and QA script, some issues have been
addressed in follow-ups.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Test Plan:
1) Apply this patch
2) Run updatedatabase.pl
3) Enable patronimages
4) Verify patron images are still displaying correctly
5) Test deleting a patron image
6) Test adding a patron image from moremember.pl
7) Test adding a patron image from tools/picture-upload.pl
Signed-off-by: Srdjan <srdjan@catalyst.net.nz>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Address the following issues:
1/ Address minor qa issues with the templates:
FAIL koha-tmpl/intranet-tmpl/prog/en/modules/circ/offline-mf.tt
FAIL forbidden patterns
forbidden pattern: intranet-tmpl should certainly
replaced with [% interface %] (line 24)
[etc.]
OK tt_valid
OK valid_template
FAIL koha-tmpl/intranet-tmpl/prog/en/modules/circ/offline.tt
FAIL forbidden patterns
forbidden pattern: intranet-tmpl should certainly
replaced with [% interface %] (line 509)
[etc.]
FAIL tt_valid
lines 5, 5
2/ Run perltidy on new scripts
3/ download.pl returns data.finished = 1 if number of returned
data < 5000 (avoids 1 ajax call)
4/ Replace qq{} around sql queries with q{}
Also, a race condition existed that resulted in pending transactions
only getting deleted from the local database in certain circumstances
(fast connections under Chrome, mostly). This patch fixes that so that
successfully-uploaded transactions are always deleted.
This patch also addresses Jonathan's suggestion:
3/ add a message on check in (currently the input becomes empty but the
user is not informed).
... and Magnus's suggestion about moving the Synchronize link to the
right on the homepage.
Also, this addresses the further issues Jonathan noted:
- The tab of checkouts always shows "*0* Checkouts"
- If I am not well-educated, I click on the "Check out" link on the
offline home page, I enter a barcode, click on "Check out" and I get a
js error (without user message): "TypeError: curpatron is undefined"
(with chromium I get: Numeric transaction modes are deprecated in
IDBDatabase.transaction. Use "readonly" or "readwrite").
- There is a "border-right" css rule on the h5.patron-title. It is
display when there is no patron selected) [really minor!].
- tables are displayed even if there is no data
- The "Clear screen" link (X) points to an old script:
circ/offline-circulation.pl
- There is a warning when clicking on the "Synchronize" link when the
user is offline, but not for the "Pending offline circulation actions"
link.
- Still exists:
> The "Checked in item." message text never disappear (even if I go on the
> offline home page (circ/offline.pl#offline-home)).
Finally, this patch adds a link to the Pending offline operations page
on the synchronize page for easier navigation.
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch adds an HTML5-based offline mode to Koha's existing
circulation module, allowing librarians to check out items using a
basically familiar interface. The feature will be implemented using
the Application Cache and IndexedDB features of the HTML5 specification,
both of which are fully supported on Firefox 10+ and Chrome 23+, with
limited support going back to Firefox 4 and Chrome 11. The basic
workflow enabled by this patch is as follows:
Part 1: While connected to the Internet
1. Enable offline functionality by turning on the
"AllowOfflineCirculation" system preference.
2. Sync the offline circulation database on the computer that will be
used for offline circulation by following the "Offline circulation
interface" link on the Circulation home page, choosing "Synchronize (must be online)",
and clicking the "Download records" button. This process may take a while.
3. Bookmark /cgi-bin/koha/circ/offline.pl (the page you are currently
on) for easy access when offline.
Part 2: While disconnected from the Internet
4. Navigate to /cgi-bin/koha/circ/offline.pl using the bookmark you
created while online.
5. Start checking books in by scanning the barcode of an item that has
been returned into the box in the "Check in" tab.
6. Scan the barcodes of any additional items that have been returned.
7. Start checking out books to a patron by scanning the patron's barcode
in the box in the "Check out" tab.
8. Set a due date (the "Remember for session" box will be checked by
default, since circulation rules are not computed during offline
transactions and therefore a due date must be specified by the
librarian).
9. Scan an item barcode (if you did not set a due date, it will prompt
you) to check the item out to the patron.
10. If a patron has a fine you can see the total amount (current to when
the offline module was synced), and record a payment. Unlike when in
online mode, there will be no breakdown of what item(s) fines are
for, and you will only be able to record the payment amount and not
associate it with a particular item.
Part 3: While connected to the Internet
11. Click the "Synchronize" link and choose "Upload transactions" to
upload the transactions recorded during the offline circulation
session.
12. Navigate to /cgi-bin/koha/offline_circ/list.pl (there will be a
link from the Offline circulation page) and review the
transactions, as described in the documentation for the Firefox
Offline circulation plugin:
http://wiki.koha-community.org/wiki/Offline_circulation_firefox_plugin
RM note: the IndexedDB jQuery plugin bundled with this patch is
copyright 2012 by Parashuram Narasimhan and other contributors and is
licensed under the MIT license. The home page for the plugin is
http://nparashuram.com/jquery-indexeddb/.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Comment: Works very well, no koha-qa errors
Test with Firefox 24.0
1) did some checkouts pre sync
2) synchronize database (Download)
3) go offline
4) Proceed to checkin some items from patron
5) Proceed to checkout items to patrons, setting date
6) Proceed to checkout to expired patron, warning appears
7) go online
8) Upload records
9) go to review transacctions and proceed
10) verified on patrons that checkin/out are done
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Description:
A new pref ConfirmFutureHolds is added. When confirming a hold at checkin time,
the number of days in this pref is taken into account when looking for reserves.
Note that this pref does not interfere with renewing, issuing or transferring
a book. For report Holds to pull, the default end date is calculated with this
new preference.
The use of ConfirmFutureHolds is useful only when future holds are allowed.
Test plan:
1) Enable future holds. Add a number of days into ConfirmFutureHolds.
2) Place a future hold within this number of days.
3) Run holds to pull report. Check default startdate and enddate.
4) Check this book in. Can you confirm the hold? Do not confirm.
5) Issue the book to another patron. You should not see a warning.
6) Renew the book for this patron via opac or staff. No warning either.
7) Check in again. Warning pops up again.
8) Transfer book. Switch branch. Check in. Hold found pops up. Do not confirm.
9) Back to first branch. Check in (with popup). Remove the hold. Add new future
hold past the number of days. Check in (no warn).
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch adds a new column to item types. Text in this column is
displayed as a warning when an item of the given type is checked in.
The type of message can also be chosen, affecting how the message is
displayed.
Use case: Items that are on inter-library loan can have a separate
item type, and when items of this type are checked in a message
saying something like "ILL! Remember to return it to the owning
library!" can be displayed.
To test:
- Apply the patch
- Go to Home > Administration > Item types administration
- Check that there is a new column, called "Check in message"
- Edit an item type and add a check in message
- Check that the check in message you added is displayed in the table
- Check in an item with an item type that has a check in message
- Check that the message is displayed
- Repeat the steps above, but select "Alert" instead of the default
"Message" as the "Check in message type". Check that the message
is displayed in a yellow alert box, not a blue message box.
- Check in an item with an item type that does *not* have a check
in message, and make sure no false messages are displayed
- Create a new item type from scratch and check that it works
the way it is supposed to
- Run the tests in t/ItemType.t, which are updated by this patch
This patch also removes backticks around column names in the
itemtypes table in installer/data/mysql/kohastructure.sql
UPDATE 2013-07-22
- Rebased on current master (no changes)
- Added "AFTER summary" to the SQL statement in updatedatabase.pl
- Added another placeholder on line 170 of admin/itemtypes.pl
Thanks Katrin!
UPDATE 2013-07-29
- Make this message independent of all other messages - thanks Owen!
- Make it possible to choose the type of message ("alert" or
"message")
Sponsored-by: Kultur i Halland - Regionbibliotek
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Fixed some tabs to make the QA script happy.
All old and new tests pass.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch updates the wthdrawn field in items and deleteditems to be
withdrawn instead. No functional changes are made.
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Comment: Save for translation files (that will be fixed on next release),
only occurrence of wthdrawn is on updatedatabase.pl
No koha-qa errors.
This touch many files, and I did not test everything,
but all seems normal. I think that any problem could
be fixed later.
Perhaps both entries in updatedatabase.pl could be joined
into one, but thats for QA.
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
I noticed this template used a hidden span to allow correct sorting of
titles--a relic of the previous table sorting plugin. I have removed
that and added an improved DataTables configuration.
To test apply the patch and view the transfers to receive report for a
library which has multiple transfers to receive. Sorting should work
correctly on all columns, including correct date sorting regardless of
dateformat system preference. Title sorting should correctly exclude
articles.
Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and works nicely.
Tested with different date formats.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Test plan:
- Add a staff user foo in a library A
- Add a staff user bar in a library B
- log in as foo and try to search 'bar'
- Switch on (Prevent) the syspref IndependentBranches
- the search returns no result
- log in as a superlibrarian
- Check that you are allowed to search all patrons.
Signed-off-by: Srdjan <srdjan@catalyst.net.nz>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Passes koha-qa.pl, works as advertised.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch adds subtitles (from Keyword to MARC mapping) to the
following tables on the checkout page:
- Checkouts
- Previous checkouts
- Relative's checkouts
- Relative's previous checkouts
- Holds
Additionally it suppresses the appearence of the superfluous word "by"
in cases where the biblio has no author.
Test scenario:
--------------
1)
Make sure that you have one or more fields mapped to subtitle in:
Home . Administration . Keyword to MARC mapping
(e.g. 245 b)
2)
Test the checkout page with patrons having
- current checkouts (today)
- previous checkouts
- relatives (e.g. kids) with current /previous checkouts
- holds on items
- holds on biblios
...with items having:
- title, subtitle, author
- title, no subtitle, author
- title, subtitle, no author
- title, no subtitle, no author
3)
Do the same on patron's detail page
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
All tests pass
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
When issuing a book, some libraries want to issue by title or other details.
This patch adds a systempreference and code that allows it.
To test:
1) scan a patron card or enter a surname to start checking out;
2) enter title or other keywords;
3) the circulation screen should display a warning allowing to choose between copies.
Signed-off-by: MJ Ray <mjr@phonecoop.coop>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch switches from using a combination of
biblionumber/borrowernumber to using reserve_id where possible.
Test Plan:
1) Apply patch
2) Run t/db_dependent/Holds.t
Signed-off-by: Maxime Pelletier <maxime.pelletier@libeo.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
When viewing the list of a patron's holds on the circulation page or the
patron detail page the table of holds doesn't display the holds
expiration date, if present. This patch adds display of the hold
expiration date.
To test, place a hold for a patron and set an expiration date for it.
View the patron's existing holds on both circulation.pl and
moremember.pl. The expiration date you chose should appear in the table
of information about existing holds.
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
works great
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Test Plan:
1) Enable IndependantBranches
2) Apply this patch
3) Run updatedatabase.pl
4) Verify that the system preference still functions correctly
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
JS is a requirement for the staff client, so the sort link on header is
useless.
Test plan:
Check that there is no regression (sort, data, etc.) on the hold ratios
table.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Tested on top of patch for bug 9459.
All tests and QA script pass.
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
The circulation page, when the UseTablesortForCirc preference is
enabled, uses the old tablesorter plugin. It should use DataTables
instead.
This patch removes references to the tablesorter plugin and makes these
changes to enable use of DataTables:
- Pass two new unformatted date variables to the template from
circulation.pl so that sorting can be performed on this data.
- Add DataTables configurations for the table of checkouts and the
table of relatives' checkouts.
- Add a new plugin to the main DataTables configuration script to allow
sorting on data embedded in a <span>'s 'title' attribute.
- Add <span>s to each table with a title attribute containing the
unformatted date data which DataTables needs to perform correct
sorting. This eliminates the need for a special sorting algorithm to
accomodate various date and datetime formatting options.
- Set a template variable for checking whether circ exports are enabled.
This reduces repetition. DataTables configuration changes based on how
many columns are present.
To test, load the circulation page for patrons who match various
conditions:
- Having only checkouts from today
- Having checkouts from today and previous days
- Having checkouts only from previous days
- Having relatives who have checkouts (from today, from previous days,
from both)
Test these situations with UseTablesortForCirc enabled and disabled.
Test these situations with circ exports enabled or disabled (with
ExportRemoveFields filled or empty, for instance).
Sorting should work correctly on all columns with the dateformat
preference set to any option.
All other circulation functions should work normally.
Revision adds missing include for table footer when there are previous
checkouts and removes from empty table header cells which were
messing up auto-detection of numeric data. The global CSS for table
borders has been tightened up to improve handling of alternating row
colors in DataTables-sorted tables.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
All tests and QA script pass.
Note: Don't forget it's the checkout tab and to turn on the
preference to allow sorting there.
Also, while checkouts sorts dates correctly, sorting on the
details tabs was not always correct in my tests.
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
To test
1. Log in to the staff client. Note your logged in library.
2. Navigate to Circulation -> Holds queue.
3. Select a holds queue report for a library other than your own.
4. From the holds queue report page, click the "Check out" tab and
enter the card number of a patron who has holds.
5. On the circulation page for that patron, click the "Holds" tab.
6. Click one of the titles in the list of holds.
Your logged in branch will now match the library you chose for the
holds queue report.
Alternate sequence:
4. From the holds queue report page, click the "Check out" tab and
do a non-exact search (search which will return more than one result)
for a patron who has holds.
5. Choose the correct patron from the list of results.
Your logged in branch will now match the library you chose for
the holds queue report.
Apply the patch and repeat, this time it should not change your logged
in branch
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Weird bug, the patch works for me.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Good catch. All tests and QA script pass.
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Adds decoding for patron name.
Test plan:
Go to Circulation.
Enter a name with a diacritic.
Find that patron or get a message with the name you entered without converted
characters.
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
The routing list tab displays on patron pages even if the RoutingSerials
preference is OFF. Display of the tab should be conditional on that pref
being turned on.
This patch adds a check for the RoutingSerials preference to the menu
include files and amends the affected scripts to make the variable
available on the pages where those includes are used.
To test, view the following pages with RoutingSerials both on and off.
The routing list tab should be shown and hidden accordingly:
- Circulation
- Patron details
- Patron fines
- Pay fines
- Pay amount/selected (click from the Pay fines page)
- Create manual invoice
- Create manual credit
- Patron circulation history
- Patron modification log
- Patron notices
- Patron routing lists
- Patron statistics
- Patron files
- Patron permissions
- Set patron password
- "Can't delete patron" page (try to delete a patron with checkouts).
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Touches a lot of files, but only a tiny change in each, works well.
Could perhaps be set in C4/Auth instead, but that's no reason not to
sign off
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
All tests and QA script pass.
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
When renewing a patron from the patron details page, ensure that
the "Patron's account has been renewed until XXX" is actually
displayed.
This patch introduces a was_renewed CGI and template parameter
to clarify the intent of the relevent template sections.
To test:
- Before applying the patch, renew a patron from the patron
details page and verify that you don't see the renewal confirmation.
- After applying the patch, renew the patron from the details page
and verify that the "Patron's account has been renewed until XXX"
message shows up.
- Renew the patron from the checkout page and verify that the confirmation
message shows up.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Message now displays for both tabs.
Fixed tab to make QA script pass.
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
This patch corrects several uninitialized value errors.
Test plan:
- Go to check out page
- Check that issues and old issues are in different tables
- Check that author is diplayed if exists
- Check that patron address is displayed if exists
- Perform a checkout
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
This patch adds in overdues.pl filters on item home branch and holding branch.
Test plan :
Play with item home branch and holding branch filters and check
it filters well results.
Signed-off-by: Melia Meggs <melia@bywatersolutions.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Filters are added to the list of overdues in the circulation module.
All tests and QA script pass.
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
When trying to checkout an item that is not for loan (due to
items.notforloan value or because itemtype is not for loan), you get a
confirmation or blocking message (depending on AllowNotForLoanOverride
syspref).
This message tells "Item is normally not for loan".
This patch adds some informations :
if itemtype is not for loan, tells "Item type is normally not for loan".
if item is not for loan due to items.notforloan value, adds notforloan
description to message.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Works as advertised: Not for loan authorized value is correctly shown.
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
This patch rewrites the GetReserveStatus routine in order to take in
parameter the itemnumber and/or the biblionumber.
In some places, the C4::Reserves::CheckReserves routine is called when
we just want to get the status of the reserve. In these cases, the
C4::Reserves::GetReserveStatus is now called.
This routine executes 1 sql query (or 2 max).
Test plan:
Check that there is no regression on the different pages where reserves
are used. The different status will be the same than before applying
this patch.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
This patch adds a new user permission overdues_report for the circulation module, and requires this permission to run the overdue items
report, rather than requiring full reports permissions.
Test plan :
With a user with permissions circulate_remaining_permissions :
- Add overdues_report permission to user
- Go to circulation home
=> you see "Overdues" link
- Clik on it
=> you are allowed to access and use this page
- Remove overdues_report permission to user
- Go to circulation home
=> you do not see "Overdues" link
- Edit URL : <server>/cgi-bin/koha/circ/overdue.pl
=> you are not allowed to access this page
- Go to main page
=> you don't have access to reports module
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Fridolyn SOMERS <fridolyn.somers@biblibre.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
When checking out from a patron page, a notice "Holds waiting" appears
if a biblio (on hold) is waiting for this borrower.
This patch adds the call number information to this warning.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Nice little improvement, thanks.
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Test plan : * chose an item reserved by multiple patrons.
* return the item and confirm reservation =>
item is waiting to be picked up
* run circ/pendingreserves.pl
=> without patch, this item is shown in the list
=> with the patch, only really available items are show.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Works according to test plan. The title with one waiting item appeared
in pending holds report before the patch, doesn't appear after the
patch.
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Added RentalsInNoissueCharges and ManInvlsInNoissueCharges sys prefs
Created C4::Members::cwGetMemberAccountBallance()
* A wrapper for GetMemberAccountRecords that gives info on non-issue and
other charges
* Other charges are:
'Res'
'Rent' if RentalsInNoissueCharges is Mo
authorised_values MANUAL_INV if ManInvlsInNoissueCharges is No
C4::Members::GetMemberAccountRecords() changes:
* Dropped input param $date, it is not used
Use split charges in C4::Circulation::CanBookBeIssued() and
C4::Members::patronflags(). That way only fines decide whether an item
can be issued, and not other non-fine charges
Signed-off-by: Marc Veron <veron@veron.ch>
Rebased (updatedatabase.pl)
ManInvInNoissueCharges and RentalsInNoissueCharges ar both included by default (= behaviour as before)
All variants tested: Both included, none included, manual invoice included, rentals included.
Works fine, blocks/does not blok as appropirate, messages appear as expected.
[Oct 12, 2012 marcelr:] Amended for updatedatabase.pl
Signed-off-by: M. de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
- the dateformat value is send to all templates (from
C4::Auth::get_template_and_user)
- remove all assignment of dateformat in all .pl files
- the DHTMLcalendar_dateformat variable is unused
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Fixed conflicts:
- opac/sco/sco-main.pl
- reports/acquisitions_stats.pl
- tools/cleanborrowers.pl
All tests pass, perlcritic problems appeared in some files
before and after these patches were applied.
Checked sorting in following pages:
- acqui/addorderiso2709.tt - list of staged imports in acq
- acqui/histsearch.tt - sorting of dates in acq search result list
- acqui/invoices.tt - billing date in list of invoices in acq
- acqui/lateorders.tt - list of late orders in acq
- acqui/ordered.tt - ordered titles and estimated costs for a fund
- acqui/parcels.tt - receive shipment page
- acqui/spent.tt - received titles and actual costs for a fund
...
- serials-search.tt - subscription search result list
...
- opac/sco/sco-main.tt - due dates in list of checked out items
- reports/acquisitions-stats.tt - date searches, display of dates
- tools/cleanborrowers.tt
- tools.holidays.tt - different views of dates library is closed,
adding dates
Checked dates display according to system preference everywhere and
searching, entering dates etc. still worked as expected.
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
This patch removes the text of a message from the script
to the template. The lastmove sub now returns either the date
or 0, and the template displays the "no transfers" message
if the date doesn't exist.
To test, view the circulation history for items which
do and do not have a transfer history. A date should be displayed
for items which have a transfer history. A messages should
be displayed for those which do not.
This patch also adds a <span> around the text "Never" which
was not getting picked up by the translation script. To test
this change, run "perl translate update <lang>" from misc/translator,
then check if the string shows up in the po file. (Thanks kf!)
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
The transfer page is only useful when the system
preference "IndependantBranches" is Off of when the user
is a superlibrarian. Otherwise it can be hidden.
Signed-off-by: Melia Meggs <melia@test.bywatersolutions.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
All tests and perlcritic pass.
TEST PLAN :
It's about testing the display of the "Transfer" link on "circulation-home.pl".
The link needs to appear if IndependantBranches is off or if the user is a superlibrarian.
1) IndependantBranches = Off, user is superlibrarian : link appears
2) IndependantBranches = Off, user is not superlibrarian : link appears
3) IndependantBranches = On, user is superlibrarian : link appears
4) IndependantBranches = On, user is not superlibrarian : link does not appear
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Right now when you return an item that was lost the patron's card is
credited with the lost fee, but not all libraries refund lost fees
and sometimes the fee is refunded after the patron has paid for it,
causing all kinds of financial issues.
Adds the syspref RefundLostItemFeeOnReturn to control whether
returning a lost item refunds the fee charged for losing that
item. Enabled by default to maintain Koha's current functionality.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Passed-QA-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Simply by logging in, clicking Circulation, clicking the
'Check out' link, error log entries were generated.
This patch ensures $findborrower, $barcode, and $print are all
initialized by adding "|| q{}" onto their initializations.
This reduces the silent error log entries generated.
As this patch would overlap with bug 8826 in the initialization
of hashes to prevent other error logs, those changes are in this
patch. Applying this patch without having applied the patch for
bug 8826.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Passed-QA-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Before applying the patch I removed the [% IF %] from
around the markup which is removed by this patch. A table
of title and patron information appeared which I don't
remember ever seeing before. This tells me it's really
unused.
After applying the patch I performed some check-ins on both
checked out items and items which were on hold. All operations
completed normally.
Passed-QA-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Changed:
our %renew_failed = {};
To:
our %renew_failed = ();
This prevents an error log about Reference found where
even-sized list expected.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Installed DataTime version 0.53, verified the error occurs.
Applied patch, verified patch removes the error.
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Currently, when you click "Holds to pull" from the Circulation menu, the only thing that you see is a white screen and a side navigation bar that says "Refine Results".
Since there appear to be no results to refine, the holds to pull list appears completely empty. Staff have to know to click "Submit" on the "Refine Results" form to get anything.
I propose that we have the "run_report" flag set to ON for the initial load. The report uses the default 2 days mentioned in the "Refine Results" form, so there is continuity across the board.
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Currently, Koha creates a default value of 2 days ago (-2) for the start date of the Holds to pull List. This system preference allows users to specify their own default start date for this list, since users might not want to have to manually change the date all the time when they already know the set date period they want to view.
The system preference value is specified as a positive integer, which is then passed as a negative integer in the handler script. This saves users from having to include a qualifer to the sys pref value.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Adds a system preference BlockReturnOfWithdrawnItems to control
whether or not Koha should allow a withdrawn item to be returned
or not.
Also fixes the behavior where Koha will attempt to use a withdrawn
item to fill a hold.
Test Plan:
1) Set BlockReturnOfWithdrawnItems to "Block" ( this is the default )
2) Check an item out to a patron
3) Mark item as withdrawn
4) Attempt to return the item, you should still see the item on the
borrower's record
5) Set BlockReturnOfWithdrawnItems to "Don't Block"
6) Attempt to return the item, you should see the item is no longer
on the borrower's record.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
In the circulation page, you can now export (as csv or iso2709) a list
of items which are currently checked out by a borrower.
3 export types:
- iso2709 with items: Export the items list in iso2709 format with item
informations.
- iso2709 without items: Export the items list in iso2709 format without
item informations.
- CSV: Export the items list based on a csv profil.
2 new system preferences:
- DontExportFields: a list of fields not to be export
- CsvProfileForExport: The Csv profile name used for the csv export
Test plan:
- Fill the CsvProfileForExport syspref
- go on the borrower circulation page containing checkouts
- Select one or more items and export them to the 3 different formats.
- check if the result file is what you expected
- Test there is no regression with the export authority
- Test there is no regression using tools/export.pl with the command
line interface
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Create transport_cost table, added UseTransportCostMatrix syspref.
transport_cost table contains branch to branch transfer
costs. These are used for filling inter-branch hold transfers.
Moved GetHoldsQueueItems() from .pl to HoldsQueue.pm
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>