Commit graph

561 commits

Author SHA1 Message Date
225a700705 Bug 10221 - hold expiration doesn't show on patron's list of holds
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>
2013-06-07 08:48:34 -07:00
b00ec06968 Bug 10080 - Change system pref IndependantBranches to IndependentBranches
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>
2013-05-22 07:58:23 -07:00
Galen Charlton
16753c750d Revert "Bug 6554 Followup for circulation patron search"
This reverts commit f257944d10.

Rolling back bug 6554 work until we have more comprehensive tests.
2013-04-29 15:17:39 -07:00
Jonathan Druart
91155470ba Bug 9984: Remove server-side sort on the hold ratios table
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>
2013-04-21 20:44:01 -04:00
ec9fc2fce4 Bug 9887 [Revised] Use DataTables on circulation page
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 &nbsp; 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>
2013-04-15 09:10:09 -04:00
Chris Cormack
a10aeb1b0d Bug 9591 : Set Library changes after viewing Holds Queue >> reserves item
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>
2013-04-15 08:36:07 -04:00
f257944d10 Bug 6554 Followup for circulation patron search
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>
2013-04-01 18:51:50 -04:00
a4e804fceb Bug 9917 - Routing list tab on patron account should depend on syspref/permission
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>
2013-03-31 08:52:35 -04:00
Galen Charlton
259163d1d7 Bug 9406: ensure confirmation of patron renewal is displayed
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>
2013-03-30 21:22:00 -04:00
Fridolyn SOMERS
779106dfde Bug 9720 : uninitialized value warnings in circulation
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>
2013-03-29 22:59:26 -04:00
Fridolyn SOMERS
429e7c3c75 Bug 9604: filter overdues with homebranch and holdingbranch
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>
2013-03-22 22:05:38 -04:00
Fridolyn SOMERS
6cec57901a Bug 9423: Add notforloan value to issue confirmation or blocking message
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>
2013-03-19 22:22:23 -04:00
Jonathan Druart
fad1f44d42 Bug 9367: Code optimization: CheckReserves is too often called
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>
2013-03-16 11:49:43 -04:00
a0c44ab17c Bug 6898 - circulation librarians can't run overdues without reports permissions
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>
2013-03-13 08:14:18 -04:00
Adrien Saurat
8bae2c9916 Bug 9332: Display call number in "Holds waiting" notice
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>
2013-02-08 09:23:51 -05:00
Sophie Meynieux
a0b885c98c Bug 9320 Pending reserves report should not show waiting items
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>
2013-02-08 09:02:53 -05:00
Srdjan
1b4a266915 Bug 7243: Be selective when summing up charges for blocking issues
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>
2013-01-24 09:12:59 -05:00
Jonathan Druart
a469663d7b Bug 9108: Followup: send the dateformat value from C4::Auth
- 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>
2013-01-17 21:59:30 -05:00
Jonathan Druart
23e1fd69f5 Bug 9140: Followup removes the useless variable $message
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>
2012-12-22 16:02:55 -05:00
533c9bc657 Bug 9140 - Untranslatable strings in item circulation history
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>
2012-12-22 16:02:54 -05:00
Adrien Saurat
c101f779e5 Bug 8781: hiding of transfer page when it's useless
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>
2012-12-02 09:27:20 -05:00
ca11d0ba29 Bug 7189 - preference to control if returning lost items gives refund
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>
2012-11-30 08:01:41 -05:00
Jared Camins-Esakov
2512581533 Merge branch 'bug_8758' into 3.12-master 2012-11-23 11:44:55 -05:00
Mark Tompsett
37efde57d2 Bug 8880 - Uninitialized variables trigger error log entries
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>
2012-11-20 07:18:03 -05:00
Jonathan Druart
99ad10712e Bug 8758: Remove useless code in circ/returns.pl
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>
2012-11-05 12:12:58 -05:00
5011479de3 Bug 8826 - Initialization of hash triggers error log entries - Followup
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
2012-11-02 12:11:52 -04:00
Mark Tompsett
bf4a7bd65c Bug 8826 - Initialization of hash triggers error log entries.
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>
2012-11-02 12:11:51 -04:00
b81bb697a4 Bug 8213 - "Cancel All" button on holds over tab cancels both holds over and holds waiting
Signed-off-by: Melia Meggs <melia@test.bywatersolutions.com>
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
2012-10-25 18:21:35 +02:00
MJ Ray
fffcf9b9d3 circ/circulation.pl: force issuedate to a string to fix bug 8738
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>
2012-10-05 17:37:48 +02:00
0812280104 Bug 8454 - Holds to Pull : Show pull list on load. Otherwise, it looks like the pull list is empty.
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>
2012-10-03 15:56:23 +02:00
Paul Poulain
529bb9c2a4 Bug 8585 follow-up Passing syspref to template
Passing the syspref HoldsToPullStartDate to get the number of days displayed on the screen
(instead of "two" that was hardcoded)

Also s/tab/4 spaces/g
2012-10-03 15:28:43 +02:00
762ce7abe6 Bug 8585 : Add System Preference to specify Holds to Pull List Start Date
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>
2012-10-03 15:18:40 +02:00
7a7e018ed3 Bug 3387 - WITHDRAWN items shouldn't check in
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>
2012-10-01 17:07:53 +02:00
bf61215e9e Bug 6151 - Followup - Change 'itemnumber' to 'barcode'
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
2012-09-17 19:19:16 +02:00
7cbb0debf5 Bug 6151 - Followup - Display message for failed returns on circulation.pl when returning via issues table.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
2012-09-17 19:19:13 +02:00
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