Bug 12454: Can't add new patron categories

To test:
- Add a new patron category
- After saving, the new patron category won't show up in the list
- Apply patch
- Try to add a new patron category again
- It should now save correctly and show up in the list of patron
  categories.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12226: (regression tests) Check_Userid should always consider the DB user not unique

Some improvements on t/db_dependent/Members.t and specifically regression
tests for bug 12226

Regards
To+

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12226 - A user with the database username/userid can access staff with full permissions

This patch implements 2 suggestions on comment #3

- Prevents creation of a new user with same userid
of database user

- When checking password, if userid matches database user,
only check against pass on config file

To test:
1. Create a new user with same login as database user
any password different from real db user
2. Check that you can login on staff using this user/pass
and you are superlibrarian

3. Apply the patch

4. Login again using new pass, it must fail
5. Login again using db pass, you are now superuser,
but system does not warn you :( No problem, that's
for having one borrower with that login
6. Delete user with same login as db user
7. Try to create one again as in 1, system must return
an error of duplicate login!

8. Check for no regressions on user/pass authentication

Resubmited, has an error

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script.
This works nicely and as described.
Also editing the former 'superuser' will force you to
change the userid in order to save any other change.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 9093 - 008 forgetting what material type was chosen

This patch adds material type checking to the MARC21 008 tag editor,
based on value from the leader. That is, the 008 tag editor
will choose an initial material type based on the leader 06
(and if necessary the leader 07 position)

_TEST PLAN_
1) Create a new record or open an existing bib record
2) Change position 6 from its current value (probably "a") to
"c" or "e" or "g" or "m" or "p". (See the end of this message
for a comprehensive list of 06 values to try.)
3) Open the 008 tag editor
4) Note that it still says BKS even though it should say "MU"
or "MP" or "VM" or "CF" or "MX".

5) Apply the patch

6) Repeat steps 2 and 3.
7) Note that the 008 tag editor now shows the correct material
type based on the leader.

8) For more comprehensive checking, try switching position 6
back to "a" and changing position 7 to "b" instead of "m".
9) Note that it will switch from "BKS" to "CR".
10) Fin

Comprehensive mapping:

Field 008/18-34 Configuration
If Leader/06 = a and Leader/07 = a, c, d, or m: Books
If Leader/06 = a and Leader/07 = b, i, or s: Continuing Resources
If Leader/06 = t: Books
If Leader/06 = c, d, i, or j: Music
If Leader/06 = e, or f: Maps
If Leader/06 = g, k, o, or r: Visual Materials
If Leader/06 = m: Computer Files
If Leader/06 = p: Mixed Materials
http://www.loc.gov/marc/bibliographic/bdleader.html

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Work as described, nice job.
koha-qa complains for a tab char, removed on followup.
Mode change on TT file (+x), removed.
No other errors

NOTE: It would be desirable to update LEADER values
to reflect changes on 008.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Awesome work David.
Bug 12434: Fix Typo in Smart Rules Help

This patch fixes a typos in the help file on the circ and
fine rules.

To test:

Visit admin > circ and fine rules
Click help in the top right
Confirm that period is not spelled peiod

Signed-off-by: David Cook <dcook@prosentient.com.au>

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 7143: Release team 3.18

See http://wiki.koha-community.org/wiki/Roles_for_3.18

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>

No errors.
Order is alphabetical?

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12458 - Holidays calendar has wrong colors for weekly and yearly repeatable

In Tools / Calendar, the colors in the calendar for weekly and yearly repeatable are different from the color of the "Key" legend.

This patch sets the colors used in the "Key" legend to the cells if calendar.

Test plan :
- Go to Tools/Calendar
- Add a weekly repeatable holiday
- Check its color in calendar is the same as the text "Holiday repeating weekly"
=> Without this patch, it's green instead of yellow
- Add a yearly repeatable holiday
- Check its color in calendar is the same as the text "Holiday repeating yearly"
=> Without this patch, it's yellow instead of orange
- Check the color of others holydays types are OK

Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
I'd like to see today's date a clearly different color from the
weekly repeated holiday, because now they're close in color.
But this patch does exactly what it says and should so I'm signing
off.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Legend, headings and calendar colors now match.
No problems found.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12255 - Amazon cover images have useless image alt text in bootstrap

"item-thumbnail" is not a useful alt text for an Amazon book cover
image. Better would be the link's title text, "View on Amazon.com." This
patch makes this correction. (Rather than "View at Amazon.com" which
doesn't sound correct to me).

To test you must have the OPACAmazonCoverImages system preference
enabled. Log in to the OPAC and view your list of checked-out titles.
The alt text for cover images should be "View on Amazon.com." Test in
both prog and Bootstrap.

NOTE: You'll need one to be overdue in order to trigger both
      cases. Examine the HTML for both tabs in the person details
      page.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
This fixed the cover alt texts for Amazon covers in the patron
account for checkouts, overdues and holds.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12299: Translate marc21_relatorterms.sql into Italian

To test:
- Apply this patch.
- Reset your DB (DROP DATABASE, CREATE DATABASE -- whatever method you
  prefer)
- Install it-IT templates on command line
- Run the webinstaller using it-IT
- Follow the steps and choose all under 'opzionali'
=> SUCCESS: no errors
=> Sign this
=> Extra: see the authorised value 'RELTERMS' and check if you like the
   translation

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Tested loading file.
Two errors fixed:
a) duplicate line ... ('RELTERMS','con', 'Conservatore')
b) missing semicolon ...  ('RELTERMS','voc','Cantante')

With that file loads Ok
No koha-qa errors

Ooops, forget the fix. Resubmited

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Adds an optional SQL file to the Italian installer - works as expected.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Removed BOM from file.
Bug 12261: Staff client next/previous links lead to unknown record

When using Staff client next/previous links after a search :
If the current record is the last of the results, clicking on "next"
will lead to the page of an unknown record with message :

The record you requested does not exist (NaN).

To test:
1) Do an intranet catalog search that has more than 1 results.
2) Click on the last search result and then click the "Next"-button from
   the top-left navigation.
3) Confirm that you get thrown to a page with the message: "The record
   you requested does not exist (NaN).".
4) Apply patch.
5) Repeat steps 1 - 2.
6) Confirm that the navigation button for "Next" is greyed out.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

This patch fixes the problem with last result in both single pages of
search results and multiple pages of search results.

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12379: remove double use of plugin KohaDates

The file catalog/detail.tt uses twice the plugin KohaDates, one can be removed

test plan: verify there is no regression about the dates on the biblio detail page

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
No problem with dates, no errors.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
No regressions found. Congratulations on your first patch Yohann!

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12367 - Import patrons still says "MD5 hash"

The password hashing algorithm was changed in Bug 9611,
but on Tools > Import patrons, in the text on the right
hand side, it still says:

"'password' should be stored in plaintext, and will be
converted to a MD5 hash"

This has no practical effect, of course, but to someone
evaluating Koha it might give the false impression that
password security is lower than it really is.

To test:
- Look at Tools > Import patrons and verify that it says
  "a MD5 hash"
- Also look at the help page and see the same text
- Apply the patch
- Check that both the tool and the help now says
  "a Bcrypt hash"

I'll do a patch for the docs too.

Signed-off-by: David Cook <dcook@prosentient.com.au>

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 11021: Suppress unneeded fields in unimarc_complet default Framework

First patch, for "complete" framework, used by academic libray
900, 901, 910, 918, 920,950,960,970,980,987 fields were useless. I removed them.
I kept only the fields mentionned in Sudoc documentation http://documentation.abes.fr/sudoc/formats/loc/index.htm
916 field is not cited in that page, but it belongs to Sudoc format.

I kept also 2 fields specific to Electre in 2013 :
902 niveau de lecture (Electre)
903  indexation (Electre)

I also added to the name of the 9XX fields I kept the mention (Sudoc) / (Electre) / (Koha), so it could be easier for librarians to know what is the purpose and the origin of each field

I don't make an updatedatabase, because some libraries could still be using these fields for good or bad reasons.

To test :
1) take a fresh Koha with unimarc marcflavor
2) in web installer, select french language, unimarc marflavor and "Grilles de catalogage complètes".
3) check default framework in Administration > MARC Frameworks : it should be without 900,901,910,918,920,950,970,980,987

Signed-off-by: Gaetan Boisson <gaetan.boisson@biblibre.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>