Fixed resulting warnings and fixed a small bug with the timeLimit drop-down box. It would not retain its value on subsequent pages if 'no Limit' was selected as an option.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Enabled warnings. Corrected all resulting warnings by initializing variables.
Some fixes and enhancements possibly related to Bug: 1153 - Existing B_address now shows in the resulting email. Birthdate now appears in the email using the System's default format. If the patron changes data in the form data took place the FIELD name now appears as uppercase in the resulting email.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
This adds to the interface and code the ability to set the reserve date when
requesting a hold.
Resubmit. Sorry, I formatted it from the wrong branch.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
the system preference mylibraryfirst is exported by Auth containing the logged
in users branchcode. It is also exported as the value of the syspref by
opac-user.pl. The effect is that when mylibraryfirst is on and the user
logged in the text label for the OPAC quick search instead of displaying
'Search (in [branchcode] only)' shows 'Search (in 1 only)'. Other user pages
are uneffected.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Adds the tag parameter to the RSS feed link if the results of a query are retrieved from a tag in opac.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
Displays the Branch name and Category description along with their codes in Suggestion Management.
Also since I joined to the branches table the 'map' function in opac-suggestions.pl to retrieve the branchname was no longer necessary.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
If a user views suggestions of another user, syspref (OPACViewOthersSuggestions), a selection check box for deletion appeared next to all of the suggested titles whether the logged-in user owned them or not. - fixed
Also fixes the "Clear all" and "Select all" links which appeared for anonymouse users, if AnonSuggestions is turned on.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Copies the logic of catalogue/search.pl to fix the expanded search option in opac. When expanded search is the default, it was impossible to go to the "fewer" options.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
If the advancedSearchTypes = CCODE, the code descriptions are not alphabetized, as opposed to itemtypes, which are alphabetized.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Adds the author and added author fields to the email that is sent from the shopping cart. This makes the data sent via email consistent with the data that is viewed in the basket.
There is still a problem with author authority records other than 100 tags appearing correctly in the shopping cart.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
The intent of kohaspsuggest is very confused. It wanted to simultaneously
log every search query, and get spelling suggestions from a totally different
database_host:db_user:db_password:database. The implementation seems
never have really made it into 3.0, however, since the only trace of the
tables it wants to query are in misc/migration_tools/22_to_30/phrase_log.sql
The job misc/spellcheck_suggest/make_spellcheck_suggest.pl does not even
target the same remote DB as the syspref tells the search code to do. Instead, it hits the
local DB and, not finding the tables that have no way of existing in a 3.0
install, it CREATES its own tables spontaneously, using MyISAM storage, no less.
This script should be drastically overhauled, or more likely just removed.
Other fixes:
Commented out unconditional warn!
Also reduced bizarre whitespace amounts in catalogue/search.pl and
fixed warning as recommended by perl -wc:
Scalar value @newresults[0] better written as $newresults[0]
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
this patch make the script not reloading the parent if the user add a biblio in a already existing shelf(useless).
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Cleaned up toggle variable in opac-readingrecord.pl and tmpl. Used __odd__ variable instead.
Missed </TMPL_UNLESS> in previous patch.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
My earlier patch (using the new syspref OPACShowCheckoutName mistakenly
displayed the Koha borrower number instead of the patron barcode number
in the OPAC display; this revises the script/template to use barcode.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Revision to previous patch for bug 3317. Removes the EXPR command from opac-basket.tmpl, which was polluting the apache logs.
NTS: Don't use EXPR.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This is available only on the masthead search box in the OPAC.
User has to enter a word in english and press space or return to transliterate the word. The destination language can be selected from a drop down list. User can temporarily turn on/off the feature by using "ctrl +g".
A system preference - GoogleIndicTransliteration can be used to turn on this feature.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
* test for NO_MORE_RENEWALS now does expect
that hash key will always exist
* removed unconditional warn
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
~ vestigial broken scripts and templates removed
~ meaningless dependencies removed
~ Focus handling issues resolved for cross-browsers
~ Timeout only invoked for non-first screen. This keeps the refresh from
flooding the logs continuously for no purpose.
~ two halves of "validuser" conditional linked in TMPL
~ elsif's used for $op conditionals
The focus should now appear on the "Return to Account Summary" button during errors.
The user can scan anything (w/ carriage return) and get back to the first screen.
Also, special functionality is added for the magic barcode "__KOHA_NEW_CIRC__".
This effectively ends the patron session and logs them out so the next patron can begin.
The purpose is for patrons to avoid having to use a keyboard at all, if libraries
print and have this special barcode available for patrons at the SCO station.
Enhancement was requested by Plano Independent School District.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
An Amazon ItemLookup response can sometimes have
more than one Item element, where the ones after
the first appear to be cross references to items
that have the same ISBN. Changed parsing so that
those responses are no longer treated like pseudohashes.
This fixes the following crash:
[error] detail.pl: Pseudo-hashes are deprecated at /catalogue/detail.pl line
213., referer: /cgi-bin/koha/catalogue/detail.pl
Which may lead to a nasty:
[error] Out of memory!, referer: /cgi-bin/koha/catalogue/detail.pl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Define and use a new module, C4::Form::MessagingPreferences,
to handle displaying and processing the messaging preferences
form. This change reduces code duplication between OPAC
and staff.
Signed-off-by: Daniel Sweeney <daniel.sweeney@liblime.com>
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Moved the messaging preferences form to a new
include, messaging-preference-form.inc, so that
it can be used to set messaging prefs both for a
patron and for a patron category.
Signed-off-by: Daniel Sweeney <daniel.sweeney@liblime.com>
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Improves Koha's unAPI support as follows:
* The implementation no longer depends on there being
an accessible Zebra or SRW server. Instead, responses
are created by running the bib MARCXML through local
stylesheets.
* unAPI now works for all bibs, not just ones that have
an ISBN. The ID format is changed from koha:isbn:ISBN
to koha:biblionumber:BIBNUM.
* unAPI now correctly advertises the formats it supports.
* This implementation now passes validation testing at
http://validator.unapi.info/ .
* MODS3 support now works correctly. As a consequence, this
patch fixes bug 2432 (Zotero support when using the XSLT
OPAC stylesheets).
TODO: as additonal XSLT stylesheets are created to convert
UNIMARC bibs to additional formats, the stylesheet map
in opac/unapi should be updated.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Removed opac/opac-dictionary.pl and catalogue/dictionary.pl,
which were not in use and not linked to from any active
template files. According to Henri, the functionality that
these scripts implemented hasn't been working since 2.2.
Also removed C4::Search::findseealso(), which was used
only by the two scripts.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
* turn on warnings
* fix problem where the top level of the classification
hiearchy wasn't displayed, instead pointing to
the link to the Wiki page with instructions on
how to set up the feature.
* fix XHTML validation errors
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This adds two new C4 modules, C4::Service and ::Output::JSONStream, and
makes important modifications to C4::Output. The first two are a basic
framework for JSON-based AJAX services and a simple JSON output wrapper,
respectively. C4::Output has been slightly refactored, with a new
function, output_with_http_headers, that supports different
content-types. output_html_with_http_headers still exists, and the three
pages affected by this change have been refactored to support it.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
this patch do a lot of things :
* Add the function GetCOinSBiblio in C4::Biblio, return the COinS value that must be put in a span title
This will be usefull for OpenURL support.
* Replace the span in opac-detail, and put the var get from GetCOinSBiblio
* Fix an <img> tag that wasn't autoclosed
* Add the COinS in search result
* Full COinS support of UNIMARC, the MARC21 support should be improved to provide all kind of document types
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
The optional description element of an Identify response
can't just be a string. Identify.description is a container
for one or more elements; see http://www.openarchives.org/OAI/2.0/guidelines.htm
For now, simply commenting it out.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
If the items.location field was NULL, then the current
SQL query would produce no results. I have turned this
into a conditional block that removes the location condition
in the query if the location is not specified.
In addition, there was a small change to opac-detail.tmpl
that changed Library to Shelves when the shelf browser was
open. This removes a potential redundant Library Library
display if Library is contained in the starting_homebranch.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Fixed opac-search.pl for correct test of expanded options and
to pass variable for MARC21 to advanced search screen.
Added Publication Date Range search to advanced search screen
Removed obsolete item type code section from advanced search screen
(wasn't displaying anyway because expanded options wasn't working,
superceded by site-specific item type searches).
Changed wording on Additional Content Types pulldown to make clear
it's limited to Books/Printed Materials -- this is basing off the
008 positions 24-27, but the options (and those positions) are only
valid for Book material types. Other material types have different
008 settings in those positions.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Added support for the Syndetics AV summary and AV profile
data elements. The AV summary is displayed in the description
tab if present, while the AV profile is displayed as
a link off of the OPAC bib details page.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
If SearchMyLibraryFirst is on, and the user is logged in, then have
their branch selected in the Location And Availability drop-down.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This patch modifies how AWS is called. AWS is now called
depending on syspref. It works completly for OPAC; it
has to be refined for intranet.
For OPAC:
* If OPACAmazonReviews is set, AWS EditorialReview and
Reviews (users) are grabed.
* If OPACAmazonSimilarItems is set, AWS Similarities info
are grabed.
* If nothing is asked, AWS is not called anymore,
sparing server bandwidth.
For intranet:
It works as it used to work. AWS is called if AmazonEnabled
is set whatever how other syspref are set.
TODO:
* Add a AmazonReviews syspref
* Request Amazon content depending on AmazonSimilarities
and AmazonReviews syspref
DOCUMENTATION:
It should be explained that Amazon services related syspref
have two levels:
* AmazonEnable / OPACAmazonEnable
* Other: OPACAmazonReviews (new), OPACAmazonSimilarProduct,
OPACAmazonCover
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Before starting to edit opac/opac-detail.pl, I added 'use warnings' and
eliminated all of the warnings that I could get it to produce. I also
extracted two lines that prepared an amazon ISBN into a function. They
were causing a few warnings and might as well be extracted. They should
probably be moved to a module somewhere since these two lines are copied
all over our code.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Intended for corporate or special sites which require the name of the person
who has checked out an item to show in the OPAC. Most libraries will want
to leave this turned off!
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Ensure that emails sent from lists and the cart in the
OPAC have the correct quoted-printable encoding. Otherwise,
if there is an equals sign followed by one or two characters
that look like hexadecimal digits in body of the email, the
results can look mangled in some email clients.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This patch modify the way to transfer the different args, don't use the form arrays.
And use a GET form instead of POST(we are getting datas, sending nothing).
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
* Use of uninitialized value in pattern match (m//) at C4/Biblio.pm line 1305
(displaying MARC21 856s that don't have $3)
* Use of uninitialized value in multiplication (*) at catalogue/detail.pl line 243.
(attemping to calculate average Amazon rating if no Amazon info
is available)
* opac-detail.pl: Use of uninitialized value in length at C4/External/Amazon.pm line 90
(attempting to calculate length of $isbn if it happens to be undef)
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
GetItemsInfo() returns a count_reserves variable which may be "Waiting" or "Reserved," but opac-detail.pl didn't include a check for these possibilities. This patch has opac-detail.tmpl output "On hold" in either case.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
this patch extract the generator of ISBD view in a C4 function, because it's used in intranet AND in OPAC but with 2 separate codes.
Now it's more reusable.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
With this patch:
* On Amazon book cover, 'search inside' text is not displayed
anymore because it's not translatable.
* Link the image to local Amazon web site 'search inside' service.
Based on AmazonLocale syspref.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Allows specification of how many issues of a subscription to display
at a global and subscription-specific level. Also adds a link to the
detail page to a specific subscription.
Signed-off-by: Daniel Sweeney <daniel.sweeney@liblime.com>
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Added a "Tag" button in the toolbar area of the results
page. This activates an inline form that allows the user
to enter a tag that can then be applied to all currently
selected items.
In addition, a "Tag" link has been added to both the List and
Cart pages that provides the same functionality in those contexts.
In these two cases, the a per-item states appears below the
bibliographic information for each item.
Status that applies to the overall operation, such as failing to
provide a tag, will be shown in an alert dialog box.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This OAI server has those characteristics:
* It doesn't use C4::OAI anymore.
* It uses HTTP::OAI library which is easily expandable.
* XML result is not build anymore directly but using
XML::SAX::Writer. It should solve encoding and XML related issues.
* It returns two formats: oai_dc and marcxml.
* DC is generated from biblioitems.marcxml by applying XSLT
(MARC21slim2OAIDC.xsl or UNIMARCslim2OAIDC.xsl).
* It uses the same tokens as previous OAI server (thanks Philippe
Jaillon).
* There is no more sets (it wasn't operational in previous version).
Add two new dependencies:
* HTTP::OAI
* XML::SAX::Writer
available as a Debian package: libxml-sax-writer-perl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
www.babeltheque.com is a LibraryThings for Libraries equivalent.
This patch enables this service on OPAC.
* Replace previous patch in order to apply onto last master HEAD
and solve conflicts induced by last pushed pateches:
1bb9f76e66
* Modify kohaversion.pl
* It uses v3.01.00.016 slot.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This patch just transform the script to set the field title as "--" if it was already shown.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Removed irrelevant and unused variables dealing with branches.
Also pulled default branch from userenv when not specified as a param.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This caused a warning from C4::Dates on every execution, since the value
passed to format_date was undefined. Now we reference the correct field
and check for a populated value before trying to reformat it.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This patch resolves a number of problems related to Enhanced Content:
1. Previously, there was no syspref for controlling whether or not to display
Amazon.com cover images apart from other content. This had the side effect
of preventing use of amazon.com content alongside use of another provider's
images. This patch introduces AmazonCoverImages and OPACAmazonCoverImages,
and changes the name of AmazonContent to AmazonEnabled.
So, for instance, you can now enable OPACAmazonSimilarItems yet utilize
SyndeticsCoverImages for displaying those similar items.
NOTE TO DOCUMENTATION TEAM: please update references to AmazonContent
and OPACAmazonContent to comply with the above.
2. Fixes some semantically incorrect uses of AmazonContent (now OPACAmazonEnabled)
on the OPAC side.
3. Resolves once and for all, the normalization of ISBN,UPC,EAN and OCLC numbers
for all enhanced content elements; These elements can be normalized using the
new functions in C4::Koha; I've replaced use of the various previously used
variables $xisbn,$norm_isbn,$clean_isbn, etc with $isbn, and the template
variable normalized_isbn.
We finally have a single, consistant place to retrieve normalize values for
these fields given a particular record.
4. Adds Syndetics attribution statements to display of all Syndetics content
'enhanced content provide by Syndetics' or 'Enhanced Description from Syndetics'
5. Adds an option to view the large cover image on the detail page on the OPAC
when using SyndeticsCoverImages; this option is controlled by a new system
preference: SyndeticsCoverImageSize which has two values: MC (medium) LC (large)
6. Adds UPC and OCLC numbers for Syndetics enhanced content queries especially
helpful for finding enhanced content for DVD and Music materials
7. Adds capability to display Syndetics images to opac-user for checkouts and overdues
8. Updates to systempreferences.sql, and updatedatabase.pl database revision 015
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This patch also includes a new function to retrieve the index
page from Syndetics and parse it for available content prior to
retrieving content; this is done to speed up syndetics content
by not retrieving content that doesn't exist for an item. However,
Syndetics continues to be a very slow service compared to Amazon.com
and other enhanced content services
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
The display sorted by code, resulting in nonsensical order
for the users, who don't know or see the codes. Note,
this data should come from GetBranchesLoop, when that
function is availabled (from a separate patch).
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This patch only fix a "security" failure that permit a user to renew his loan using directly the opac-renew.pl url.
Now, we check that opacrenewalallowed is set to on to permit the renewal in opac.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Updated the results, cart, and shelf pages to include a button
or link to initiate a hold request based on checked items.
Updated the request CGI scripts to handle multiple biblio items.
Updated the reserve confirmation page to display multiple items,
with an optional list of copies for each one.
Turned on warnings in opac/opac-reserve.pl and fixed resulting
warnings.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Speed up bib search and OPAC bib display, especially
when the XSLT OPAC results and details display sysprefs are
ON, by passing an existing MARC::Record object to three
functions:
C4::Biblio::get_biblio_authorised_values()
C4::XSLT::XSLTParse4Display()
C4::XSLT::transformMARCXML4XSLT (internal)
These functions previously fetched the bib from the
database, incurring the cost of DB retrieval and MARCXML
parsing even though client code already had a
MARC::Record object available.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>