Changed so that the presence of an on-order item (items.notforloan =- -1)
permits a title-level hold request to be made. Prior to this patch,
if all of the items linked to the bib were on-order, no title-level
request was permitted.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
1. restores a check to itemtype.notforloan to set the norequests flag
2. changes improper boolean OR with AND for checking conditions of setting norequests
3. displays 'Not for loan' for item-level itypes when the itemtype is set to notforloan
4. restores items.notforloan values < 0 allowing holds (ordered items for instance)
We still need a notforhold flag set at the itemtype, and items level
Adding code to refresh "Lists" button lists display in OPAC masthead.inc
Adding javascript to force refresh of parent window to update "Lists" button menu
Adding query limits and ability to specify row count and offset in queries related to Virtualshelves.
Also added the ability to return total record counts for specified virtualshelves.
Adding C4::VirtualShelves::GetRecentShelves which returns a list of the most recently modified shelves for
a given set of parameters. This allows the user to be offered active private and open lists to add books
to in drop down menus while also allowing drop down menus to be limited to a reasonable length.
This also limits the shelves stored in the user's session to a fixed number. A further enhancement might
be to add a syspref to enable a staff member to define the limit. Currently it is hardcoded at 10 per
list type (private/public-open).
Adding pagination to list/shelf related screens
Moving refresh shelves code into C4::VirtualShelves::RefreshShelvesSummary and tidying up a bit
Correcting several inconsistancies in the shelves templates as well as handling shelf management on
the intranet side correctly.
Correcting "Add To:" drop-down list to show only lists the patron has permission to add to
Correcting a few C4::VirtualShelves::GetShelvesSummary API calls
Modifications for template consistancy
Breaking up a 1367 char line of javascript in opac-results.tmpl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
a default installation:
1. Re-names several of the item fields to make more sense to catalogers and patrons
2. Remove links Non-public note from items.paidfor
3. Changes Non-public note to be hidden in the OPAC view
Fixes issues with the 'hidden' field in the framework, specifically:
1. the editor obeys the rules of possible values for hidden (>4, or <-4)
2. the OPAC MARC display obeys the rules of positive values meaning 'hidden in OPAC'
3. the staff MARC display now obeys the rules specified in the hidden values description
GetMemberDetails() returns only one hashref now,
not two. In all cases where the caller was
expecting two output values, the $flags return
was ignored anyway.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
If item is in transit, show that status in the OPAC
user's hold list rather than "waiting to be pulled".
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
The following statuses are now displayed correctly in the
bib details page in the OPAC:
* In transit
* Damaged
* Not for loan
Prior to this patch, items of these statuses displayed
as available.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
Standardized table layout with colspan=2 for Title header,
the first being the icon or jacket image. Discovered a bug
when I fixed the "toggle/highlight" code to work (using loop
context var __odd__), namely that the highlight styling overrides
the red overdue styling. Commented out that conditional with a
FIXME.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
Fixed rules for determining whether an item is
available for an item-level hold request. Create a
new function in C4::Reserves, IsAvailableForItemRequest(),
that checks whether an item is potentially available for
an item-level hold request.
An item is considered available if:
* it is not lost AND,
* it is not marked not for loan AND,
* it is not withdrawn AND,
* it is not damaged (unless the AllowHoldsOnDamagedItems syspref is ON), AND
* it is not on loan (unless the AllowOnShelfHolds syspref is ON)
Preventing a hold request on withdrawn items is bug 1739, as is
the new preference on whether to allow holds on damaged items.
Removing the condition that an item cannot be requested if
it has already been requested by another patron is the topic of bug 1710.
Note that this patch does not change the behavior where if
independent branches is on and the canreservefromotherbranches
syspref is off, a staff operator is prevented from placing
an item-level hold request on an item from a different branch.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
opac-mymessages.pl and opac-mymessages.tmpl generate an RSS feed of a patron's messages from the message_queue.
Some more methods in C4::Letters to let us pluck out the right entries in the queue.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
This patch allows patrons to update their messaging preferences. This
includes methods in C4::Members to manage patron messaging preferences.
added cgi script to allow patron to edit their messaging preferences
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
NOTE: This patch introduces code which generates an anonymous session when a patron first browses to OPAC.
This anonymous session contains a minimal amount of information including the results of a query to discover
all public lists/shevles. When the user logs in, the anonymous session is cleared and a new session created
for that user.
kohabug 1875 - fix error when editing a patron record
C4::Auth::checkauth was not distinguishing between a
'userid' input from an OPAC or staff login form and
a 'userid' input from (e.g.,) the patron editor.
Consequently, adding or editing a patron record would
result in Koha trying to log in as the new patron.
To resolve this, added a hidden input to all login
forms, 'koha_login_context', to explicitly signal
when a login is occurring. The value of this input
can be 'opac', 'intranet', or 'sco' - the value is
not used at present, but may be of use later.
C4::Auth - added debug flag to two warns
kohabug 1875 - create anonymous sessions only for OPAC
No need to create an anonymous session for the intranet.
set yuipath correct for login pages
When preparing the template parameters for a login form,
C4::Auth was overriding the value of yuipath set
by C4::Output::gettemplate(), thus causing 404 errors
if the 'yuipath' syspref was set to 'local'.
kohabug 1875 - avoid warns viewing lists anonymously
During an anonymous OPAC session, the $loggedinuser variable
is not set. As the undefined value causes warns in
C4::VirtualShelves::Page::shelfpage, for the purpose of the
shelfpage call the loggedinuser is set to -1, which should
not correspond to any real borrower number.
This is admittedly a hack to avoid digging through all
of C4::VirtualShelves to deal with lists viewed anonymously.
kohabug 1875 Refactoring of &ModShelf to avoid overwriting list owner needlessly
kohabug 1875 Avoid warning if can't find owner of shelf
Since virtualshelves.owner is not a true FK of borrowersnumber.number,
set ownername to '' if can't find the patron
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
The issue was that the index for itemtype is different depending
on whether you're using item-level or bib-level itemtypes. This
patch detects the system choice and sets the index properly
For documentation, please indicate that as part of profiling,
staff can refer to the AdvancedSearchTypes system preference to
choose where to draw the advanced search 'Types' from. Currently
this is implemented as a choice, between itemtypes and ccodes,
but it's been designed to work with any authorised value so long
as an index exists for searching by that authorised value.
By default, and if this syspref doesn't exist, it will pull from
itemtypes as before.
In any MARC record display in the OPAC or staff client
that displays the MARC tag numbers, the indicators are
now displayed as well, following the tag number. If an
indicator is a blank, it is displayed as '#'.
Add a function to C4::Koha, display_marc_indicators(), to
generate this display form of the indicators.
Refactoring note: the four scripts changed in this commit
have a lot of duplicate code that could be merged into
a MARC displayer class.
Documentation notes: screenshots of tagged MARC record
displays should be updated.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
In OPAC, when cart is sent by email, the email contains an attachement:
an ISO2709 file with cart biblio records. Most users don't have a clue
what to do with this file.
This patch modifies opac-sendbasket.tmpl to clarify what the attachment is.
It also fix a bug in opac-sendbasket.pl which wasn't reading the template
section containing information about the basket:
Here is your cart, sent from the Koha Online Catalog... foo
It may be necessary to verify that template text is in 'valid' English...
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
The AddStatement op is an archaism from 2.2 that
has not been used in the templates for at least a
year.
No documentation changes.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
Because of some copy-and-paste work, it was possible to
construct an OPAC URL that would attempt to call DelAuthority
on a selected authority record. This is perhaps taking
patron contributations to library metadata a bit too far.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
Currently, the heading sort order is a required parameter, but was
not supplied to the template or used in the search results. As
a result of this patch, clicking a link to view another page
of the authority search results will now work.
Outstanding issue not addressed by this patch: when searching
authorities in both the staff interface and the OPAC, choosing
sort order "none" results in a crash.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
OPAC search RSS and ATOM feeds now have the correct
Content-type sent - "application/rss+xml" and "application/atom+xml",
respectively.
As part of this patch, added an optional fourth parameter
to C4::Output::output_html_with_http_headers to specify
the content type. If that parameter is now supplied, or if
the value of the parameter does not contain at least a "/",
the default type of "text/html" is returned.
No documentation changes.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
Fix several validation errors in RSS and Atom feeds
generated from the OPAC:
- add missing guid to RSS elements
- add missing feed ID and element ID to Atom elements
- reflect OPACBaseURL changes
- fix atom:link self links
- add HTML escaping to fields comming from bib record
- set default timestamp for Atom updated elements
Issues identified but not solved in this patch:
- setting Atom updated element for each bib (presumably
from biblio.timestamp)
- possible problems performing paging of Atom feed
Based on successful validation of feeds by feedvalidatory.org,
it is expected that feeds should now work in IE7 and IE6.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
Calculate OPACBaseURL from the
CGI environment variables instead of using the
system preference. As a result of this patch,
it should be possible to change the hostname,
protocol, or port of the OPAC without having to
reset a system preference.
Also added a FIXME to opac/unapi - the URL of
the SRU/W server has no necessary relationship
to the URL of the OPAC.
Once this patch is confirmed, the syspref can
be removed.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
But that is a separate bug from whether they display or not.
Also added basic error handling if biblionumber is not received, or
if biblionumber is bad, since that otherwise crashes the page.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
I agree that opac-suggestions.tmpl modification is Not required any longer.
But still, the modification in opac-suggestions.pl is really necessary.
If you donot do that, ppl are presented with ALL suggestions and not
their suggestions by default, which is not what My Suggestions suggests.
Note: we CANNOT rely on window.close in onSubmit or $().submit to close our popups.
On a relatively slow connection with a relatively large POST, commonly the close finishes
*before* the POST completes, as reported with our New Zealand clients. Despite success in
trivial cases, this should be obvious, since the event is necessarily before the submission.
It also assumes success and prevents any kind of error feedback. Other popups are likely
to exhibit this same defective behavior.
Some FIXME's outstanding: need to allow users to delete their own comments,
need to enforce and feedback on max comment length.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
Note, all Tags js will live under KOHA.Tags namespace.
See opac-tags.pl perldoc for AJAX/JSON examples. The capability is already
there to be very web-servicey, even moreso than the current OPAC implementation
will utilize.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>