Commit graph

526 commits

Author SHA1 Message Date
Jonathan Druart
0f3f61e756 Bug 7986: Export issues for patron
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>
2012-09-13 17:58:30 +02:00
Srdjan
86c2c4626d bug_5911: Transport Cost Matrix
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>
2012-09-12 14:49:25 +02:00
fbb7803601 Bug 8498 - can't specify an hour when specifying due date
With hourly loans Koha can make items due specific hours,
but if you have the specify due date box on the checkout
screen you can't enter an hour/minute. It will always default
to 23:59.

* Add jquery timepicker plugin
* Update jquery ui to include timepicker prerequisite slider
* Set timepicker's default time to 23:59, remove the hard
  coded 23:59 setting from circulation.pl
* Resize input fields such that the entire date and time are
  visible.

Signed-off-by: Marc Veron <veron@veron.ch>
Works as expected, input field displays entire date and time.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-08-31 22:44:26 +02:00
4a139b51c5 Bug 8419 - Suspended holds appear on the daily holds queue
Suspended holds are showing up in both the holds queue and holds to pull reports.

This patch adds to the sql queries such that any hold that is suspended
is not selected.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-08-31 17:56:46 +02:00
Adrien Saurat
2fea7f0137 Bug 8477: Displays home/holding branches on return page
Signed-off-by: Mirko Tietgen <5p4m@gmx.de>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-08-02 17:38:47 +02:00
Kyle M Hall
217fef5749 BugFix - ReturnToShelvingCart
If the ReturnToShelvingCart syspref is on, and something needs to go in transit,
the shelving cart setting is overriding the transit.

What seems to be happening is this:
  * Item is checked in, and flagged as needing to go in transit from A to B.
  * Item is immediately flagged as shelving cart, though.  Current display says both shelving cart and in transit.
  * After the cart-to-shelf script runs, item comes out of transit and
    shows as being available at the destination library, although it hasn't
    arrived yet and no one has manually checked it in.

http://bugs.koha-community.org/show_bug.cgi?id=3701

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-07-24 15:05:23 +02:00
Paul Poulain
612b12f41b Merge remote-tracking branch 'origin/new/bug_8251' 2012-07-16 13:46:31 +02:00
9d4e241ada Bug 8251 - Follow up, use 'day' instead of 'days' for Datetime::truncate
As noted in comment #4 by Jonathan Druart, this should be fixed in every call
to DateTie::truncate function. This patch does exactly that.

julian_m tested that truncate( to => 'days' ) didn't actually do anything, so
it is understandable that this 'fix' might introduce new bugs as we might have
'fixed' at a higher libs level this issue.

'minutes' is used in truncate function too, so fixing.

Signed-off-by: Dobrica Pavlinusic <dpavlin@rot13.org>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-07-16 13:45:45 +02:00
Paul Poulain
0923e96cb4 Revert "Bug 7444: Update circ/circulation.pl to use KohaDates TT Plugin"
This reverts commit 186cfa5cb0.
2012-06-29 17:17:47 +02:00
3768602ae7 Bug 8043 - today's checkouts are in Previous checkouts in circulation.pl
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-06-20 23:25:31 +02:00
Ian Walls
186cfa5cb0 Bug 7444: Update circ/circulation.pl to use KohaDates TT Plugin
Removes all date formatting done in circ/circulation, and sets any/all date
outputs to iso format.  The formatting of dates is now handled in the template
using the KohaDates plugin.

This allows use to remove a dependency on C4/Dates.pm from the script.

This patch also removes the usage of C4/Overdues/CheckBorrowerDebarred.  Since
borrowers.debarred is returned by GetMemberDetails, it doesn't make sense to
include another module to run another MySQL query just to fetch the date again.

To Test:

1. View the checkout page for a patron with materials checked out today and in days past, as
well as items on reserve.
2. View a patron who is nearing their expiry date
3. Renew a patron
4. Renew a material from the checkout page using the renewal date selector
5. Attempt to checkout a book to a patron that is on hold for someone else
6. Attempt to checkout a book that is currently checked out
7. View a debarred patron

In all cases, any dates displayed should be in syspref format

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-06-11 18:02:26 +02:00
81edc91f37 Bug 8004 - Items on Hold Lose Transfer After Being Scanned Twice
When a hold is placed on an item where the pickup location is
different than the holding library, Koha initiates a branch
transfer for that item to fill that hold when items is run through
the returns system.

If the item is then run through returns a second time, the system is
supposed to close that transfer as a 'wrongtransfer', and open a new
transfer with the same from and to branches as the original.

The problem is that the original transfer is closed, but the new
transfer is not created. This is because at some point, someone
replaced the template variable WrongTransfer, which had previously
contained the branchcode for the library to transfer to, with the
full name of the library instead ( I assume to make a look nicer ).

Solved by removing the line that was changing the variable contents
from the branchcode to the branch name, and adding a new TT filter,
KohaBranchName that functions in the same way as KohaDates, except
it takes a branchcode and returns the branch name for the given
branchcode.

The consequence of this, is the the name of the library is passed to updateWrongTransfer instead of the branchcode, causing the failure.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-06-11 15:53:57 +02:00
Dobrica Pavlinusic
7c9e80536b Bug 8178 - circ/circulation.pl under plack duplicates checkout rows
Bug 7851 introduced our scoping for vairables, unfortunatly it has
side-effect that checkout rows accumulate on page reloads instead
of being initialized to empty array (which this patch fixes)

This also fixes %renew_failed initialization on each request.

Test scenario:
1. start intranet under plack
2. open /cgi-bin/koha/circ/circulation.pl and reload page few time
   confirming that rows gets duplicated
3. apply patch and reload page to verify that it works

Signed-off-by: Alex Arnaud <alex.arnaud@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-06-10 13:02:05 +02:00
5e43e2f93d Bug 7951 - Suspending holds needs a system preference
Adds system preferences SuspendHoldsIntranet and SuspendHoldsOpac.

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
2012-06-09 18:45:57 +02:00
2aff4b467b Bug 8167 - Add syspref allow a choice of blocking, non-blocking, or do nothing when issuing lost items.
Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Works as advertised.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-06-09 16:21:05 +02:00
ef0cf7b9a6 Bug 7747 - Replace YUI autocomplete with jQueryUI
In order to facilitate a more painless process for converting
to jQueryUI I will submit separate patches for various "widgets,"
starting with Autocomplete.

This patch replaces all instances of YUI autocomplete with
a jQueryUI version. The patch includes an up-to-date version
of jQuery and jQueryUI libraries.

The patch also moves some markup in instances where it should
have been removed in favor of a different include.

To test, find the various autocomplete instances and confirm
that they are working:

 - Circulation search header autocomplete
 - Overdues patron attribute authorized value filter (must
   have patron attributes enabled, and a patron attribute
   defined which uses authorized values.
 - Authorities search plugin. Edit a MARC record and use
   an authorities plugin link to do a search for authority
   records.

Incomplete: There is a YUI autocomplete instance in a UNIMARC
plugin (unimarc_field_210c_bis.tt) which I couldn't figure out
how to test, even on a sandbox set up with UNIMARC. I could use
help with a follow-up.

http://bugs.koha-community.org/show_bug.cgi?id=7447
Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Passes all tests outlined, is quite pretty.

Passes t xt

Signed-off-by: Ian Walls <koha.sekjal@gmail.com>
2012-05-31 18:07:55 +02:00
Srdjan
722ca127dd bug_8056: sorted out slip print calls
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
preference works as expected.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Tested that CircAutoPrintQuickSlip clear the screen still works well
2012-05-28 13:52:39 +02:00
de63880d08 Bug 8077 - overdues with fines won't run
When I try to run the overdues with fines report I get the following:
Software error:
Undefined subroutine &main::dt_from_string called at
kohaclone/circ/branchoverdues.pl line 116.

Fixed by add a use line for Koha::DateUtils to branchoverdues.pl

Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-05-21 18:29:26 +02:00
Katrin Fischer
3e82127fb8 Bug 2034: Removing unused scripts billig.pl/billing.tt
- Scripts are currently not linked from anywhere in the templates
- Functionality can also be achieved with a custom report
- There are unresolved problems with the sql in the existig scripts

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-04-12 18:09:54 +02:00
Colin Campbell
e7971380e8 Bug 2505 : Switch on warnings in circ/returns.pl
Removed a compile time warning caused by a void context
in a bit of too clever obscure code

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-04-10 11:30:30 +02:00
d1dc3c0c2e Bug 7641 - Add ability to suspend reserves - Followup
* Switch from C4::Dates to $KohaDates
  * Fix 'Resume All Suspended All Requests'
  * Change button text to follow capitalization rules
  * Change 'requests' to 'holds'

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-04-06 17:23:10 +02:00
Katrin Fischer
45b26ffe98 Bug 7482: overdues report downloads without names
This patch is an alternate patch for the bug. Instead of having
one column 'name' for a concatenated first and last name it
adds 2 separate columns to the exported csv file.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-04-04 17:39:36 +02:00
Dobrica Pavlinusic
53a7fb7ba3 Bug 7851 - circ/circulation.pl plack scoping
Errors:

Variable "$totalprice" is not available at /srv/koha/circ/circulation.pl line 448.
Variable "%renew_failed" is not available at /srv/koha/circ/circulation.pl line 456.
Variable "$todaysdate" is not available at /srv/koha/circ/circulation.pl line 458.
Variable "@todaysissues" is not available at /srv/koha/circ/circulation.pl line 459.
Variable "@relissues" is not available at /srv/koha/circ/circulation.pl line 459.
Variable "@previousissues" is not available at /srv/koha/circ/circulation.pl line 461.
Variable "@relprevissues" is not available at /srv/koha/circ/circulation.pl line 461.

Test scenario:
1. go to circulation page
2. verify errors in console output of plack
3. apply patch
4. reload and verify that errors are gone

Signed-off-by: Alex Arnaud <alex.arnaud@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-04-03 18:14:19 +02:00
f446b3d03d Bug 7641: Suspend Reserves
Adds the ability to suspend reserves. The new system preference
AutoResumeSuspendedHolds enables the ability to set a date for
a suspended hold to automatically be resumed.

When a hold is suspended, it will continue to increase in priority
as the holds above it are fulfilled. If the first holds in line
to be filled are suspended, the first non-suspened hold in line
will be used when an item can fulfill a hold that has been placed.

http://bugs.koha-community.org/show_bug.cgi?id=7641
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>

Tested with the preference on and off:
1. placed several holds in the staff client
2. suspended some with a date
3. suspended some without a date
4. triggered hold message by checking in for hold with suspensions
5. the suspended hold was skipped as it should be
6. tested suspending holds in the OPAC w and w/out dates
7. ran the cron to clear suspensions with dates

All the above tests worked as expected. Signing off.
2012-03-29 14:37:49 +02:00
Chris Cormack
0c40ff9f98 Merge remote-tracking branch 'kc/master' into merged_5549
Fixed conflicts

Conflicts:
	catalogue/moredetail.pl
	installer/data/mysql/updatedatabase.pl
	koha-tmpl/intranet-tmpl/prog/en/modules/admin/smart-rules.tt
2012-03-22 09:36:55 +13:00
Ian Walls
28309bc61e Bug 5549 Followup: fix suspension in days
ISO dates were being compared with DateTime objects, and DateTime::Durations
with integers.  This patch reimplements the _FixFineDaysOnReturn subroutine
to use the new hourly loans functionality.

Also moves date formatting of patron debar date out of circ/returns.pl and into
KohaDates on the template

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
2012-03-22 09:31:11 +13:00
root
22aa99917f Bug 5549 : fixed undefined subroutine format_date in circ/returns.pl by adding full path of C4::Dates::format_date()
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
2012-03-22 09:29:36 +13:00
Adrien Saurat
b38aec8aae Bug 7434: Display of issue number for serials in overdues
items.enumchron is now displayed when not null

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-03-20 13:42:55 +01:00
Elliott Davis
49c35ba38e Bug 5549 : fixed datetime issue so time is shown in output for circulation.pl and moremember.pl 2012-03-20 13:41:25 +13:00
Colin Campbell
1d90d1c0c6 Bug 5549 : use DateUtils routine for formatting sql date
Also cleanup modules list to reflect those
actually used
2012-03-20 13:26:51 +13:00
Colin Campbell
1d62ea2c9f Bug 5549 : Fix 'specify due date'
If due date is set generate a proper DateTime object
for issue procesing
2012-03-20 13:26:24 +13:00
Colin Campbell
bc866c25f4 Bug 5549 : returns calling wrong format routine on date
We don't have an orm yet
2012-03-20 13:25:56 +13:00
Colin Campbell
791fe1bbd7 Bug 5549 : circ/returns needs to import DateUtils 2012-03-20 13:25:16 +13:00
Colin Campbell
4913d3a1d7 Bug 5549 : Fix a couple of date issues from testing 2012-03-20 13:22:12 +13:00
Colin Campbell
3ad68c640c Bug 5549 : Format date with hh:mm in branchoverdues
Also removed am unused date string
2012-03-20 12:35:22 +13:00
Colin Campbell
48c8ac992a Bug 5549 : overdues display should be hours mins aware 2012-03-20 12:33:52 +13:00
Colin Campbell
99eccc18ed Bug 5549 : Handle datetimes on return 2012-03-20 12:32:13 +13:00
Colin Campbell
00bf7cc774 Bug 5549 : Get basic 24 Hr loan working 2012-03-20 12:13:34 +13:00
Colin Campbell
b7b6a8e388 Bug 5549 : Due Date calculation in issue needs to be HH:MM aware 2012-03-20 12:12:09 +13:00
Srdjan Jankovic
a9ded4fa00 bug_7001: Issue and Reserve slips are notices.
Branches can have their own version of notices - added branchcode to
letter table.
Support html notices - added is_html to letter table.
Support for borrower attributes in templates.
GetPreparedletter() is the interface for compiling letters (notices).
Sysprefs for notice and slips stylesheets
Added TRANSFERSLIP to the letters

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-03-09 10:11:20 +01:00
Alex Arnaud
e67fbd1c7c Bug 6086 - adding a dynamic filter to pending holds
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
2012-03-08 18:14:09 +01:00
8b171f693d bug 6039: Cancel All waiting holds button - Addendum: Add redirect to refresh list after canceling all holds.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-02-27 15:43:15 +01:00
Srdjan Jankovic
b17653355c bug 6039: Cancel All waiting holds button
TransferWhenCancelAllWaitingHolds syspref

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
2012-02-27 15:43:12 +01:00
b420247f2d bug_7467: Printing Transfer Slips for transfers that do not have holds - Addendum: Use for automatic transfers as well.
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-02-27 14:57:13 +01:00
Srdjan Jankovic
f771cc8e26 bug_7467: Printing Transfer Slips for transfers that do not have holds
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
2012-02-27 14:57:10 +01:00
Srdjan Jankovic
8b80b315c3 bug_7201: Holds reports: add copynumber and enumchron
Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Data is there and correct - very helpful patch, thanks!
passes prove t xt t/db_dependent in line with current master failures.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-02-17 10:54:56 +01:00
Aleksa Vujicic
3982d97af3 Bug 6964 - 'Add child' function should be dependant on system preference 'borrowerRelationship'
The 'Add Child' button is not shown if 'borrowerRelationship' is empty.

System preference description changed.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-02-02 11:36:05 +01:00
Adrien Saurat
74984f5cf3 Bug 7266: flags debarred, suspended, gonenoaddress in overdue
This patch makes these flags functionnal.

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-01-17 18:03:37 +01:00
Chris Cormack
a9e080a6fb Bug 7278 : Additional Materials
Part 2: This patch shows the message at checkout and checkin

How to test:
* Add a note in cataloguing
* Check it displays at checkout and checkin
* Check items without a note don't display anything

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
2012-01-10 22:41:50 +01:00
bc92dda8c4 Fix for Bug 7077 - Add system pref to control behavior of submitting empty barcode field
Adds a new system preference, CircAutoPrintQuickSlip:

When an empty an empty barcode field is submitted in circulation
[ clear the screen | open a print quick slip window ].

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>

Fixed a merge conflict with the updatedatabase.pl

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Another merge conflict resolved. Marked as Passed QA.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-01-06 17:34:10 +01:00