Bug 12801 - Unit Test

Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12801: Use the branchcode to cache holidays

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12724: Show RDA tag 264 on OPAC Detail XSLT view

This patch adds selected information from tag 264 to the Publisher line
on the OPAC detail XSLT view (MARC21). This includes a label, and the
subfields abc.

If Publication tag 260 exists, it adds information. If tag 260 does not exist,
it creates a 'publisher' line. (NOTE: Probably, both fields will not both be
present, but this patch can deal with that..)

Instead of showing all 264 tags, it picks the preferred one based on the
following rules (using both indicators; see LOC description):
[1] Try to select a Publisher -- Latest. Pick first one.
[2] Else try to select a Publisher. Pick the last one.
[3] Else try to select an other one (Producer, Manufacturer, ..) with Latest.
    Pick the first one of that.
[4] Otherwise: Pick the last 264 tag.

Test plan:
[1] Add one 260 and multiple 264 tags to your record.
[2] Check display in OPAC detail XSLT.
[3] Change some indicators, subfields of the 264s.
[4] Check display again, following the above rules.
    Go back to step 3 a couple of times.
[5] Remove tag 260. Check display again.

Followed test plan. Patch behaves as expected.
Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12726: Show RDA tag 264 on OPAC Results XSLT view (MARC21)

This patch adds the same information to the Publisher line of OPAC Results
as bug 12724 did on OPAC Detail.
To accomplish this and reduce repeated code, two XSLT routines (named
templates) are moved from OPACDetail to MARC21slimUtils.

Test plan (see also bug 12742 and the rules mentioned there):
[1] Add tag 260 and some 264s to your MARC21 record.
[2] Check the display of OPAC Details. Should not have changed.
[3] Now check also the display of this record in OPAC Results.
[4] Change some indicators in the record. Check OPAC Results again.

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
On top of 12724, no change on detail, more data on results.
No koha-qa errors

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Change moves display logic to Utils, 260 will display as
before and 264 will only display if there is no 260.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12725: Show RDA tag 264 on Intranet Results and Detail XSLT view (MARC21)

As bugs 12724 and 12726 did on OPAC, this patch adds similar changes to
Intranet Results and Details XSLT view. It shows information from tag 264 on
the Publisher line of Intranet Results and Detail.

Test plan (see also bug 12742 and the rules mentioned there):
[1] Add tag 260 and some 264s to your MARC21 record.
[2] Check the display of Intranet Results.
[3] Check the display of Intranet Detail.

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Results and detail show 264. I added 2 but only shows the second,
is that right?

[Reply from marcel:] Yes. Based on the rules described, it picks the most
'appropriate' 264.

Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12296: make search box customisable with OpacCustomSearch

This allows the search box to be replaced by some custom HTML, useful
when you're needing to integrate with some other search system, and
don't want to maintain a template change across upgrades.

Test plan:
* Install patch
* Look at the OPAC, see that nothing has changed.
* Change the OpacCustomSearch syspref to something like <h1>Zuul</h1>
* Look at the OPAC again, you can no longer search, there is only Zuul.

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

Works as advertised. Seems like it would be really easy to screw up your
OPAC with this feature, but since we already offer other easy ways to
screw up your OPAC I guess this fits in.

New patch changes: removed the bootstrap code, changed the entry in
syspref.sql

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Works as described, passes QA script and tests.
The feature has some limitations, described on the bug.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12296: (QA followup) remove rebasing leftover

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12296: DBRev 3.17.00.028

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12424 - ddc sorting of call numbers truncates long Cutter parts

This patch increases the cn_sort field length to 255 chars.

Modified:

C4/ClassSortRoutine.pm                    - change the hardcoded cn_sort length to 255
installer/data/mysql/kohastructure.sql    - alter tables items and deleteditems,
                                            biblioitems and deletedbiblioitems
installer/data/mysql/updatedatabase.pl    - alter tables items and deleteditems,
                                            biblioitems and deletedbiblioitems

Testing:

Before applying the patch:
0) Select an item
1) Edit the item selected
2) Change "Full call number" option to 530 F435_1996 v2p1
3) Save changes
4) Valide 530_000000000000000_F435_1996_ (table items - cn_sort column).

After applying the patch:
5) Edit again the item selected in 0
3) Save changes
4) Valide 530_000000000000000_F435_1996_V2P1 (table items - cn_sort column).

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes tests and QA script.
Works as described.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12424: DBRev 3.17.00.029

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 13027: Typo RoutlingListNote

Trivial patch adjusts two occurrences of this typo in two installer sql
files.

Signed-off-by: Chris <chris@bigballofwax.co.nz>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Typo in sysprefs.sql is only in the description, so fixing
this without a database update seems ok.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12862: Staff client tweaks related to obsolete language="javascript"

As a result, this patch removed the deprecated tag from the
intranet templates.

And since there was just 1 other tiny error in the same template
file, the checked="checked" was removed from a text box.

TEST PLAN
---------
1) Install the HTML Validator 0.9.5.8 for FireFox.
2) Open Intranet to Home -> Tools -> News
3) View Page Source
   -- you'll notice the message about language="javascript" being
      one of the error messages.
4) Click Edit beside one of the news items.
5) View Page Source
   -- you'll notice the message about language="javascript" being
      one of the error messages.
6) Apply patch
7) Repeat steps 2 to 5 without "language="javascript" related
   error messages.
8) Run koha QA test tools.

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12862: OPAC bootstrap - clean up language="javascript"

There was a <script language="javascript"> tag.
It was cleaned up to be <script type="text/javascript">.
Also, the div was being chopped because the script was
in the middle of the div. Moving it to head solved the issues.

This is difficult to test, since the printslip is triggered
when you click Finish.

TEST PLAN
---------
 1) Home -> Koha administration -> Global system parameters -> OPAC
 2) Set the OPAC system preference 'opacthemes' to 'bootstrap'.
 3) Start the self-checkout client (/cgi-bin/koha/sco/sco-main.pl)
 4) Log in.
 5) Check something out.
 6) Change the address url text box to
    .../cgi-bin/koha/sco/printslip.pl?borrowernumber=##&amp;print=qslip
    Where ## is your borrower number which just checked something out.
 7) Click Cancel on the print dialogue
 8) View Page Source
    -- The HTML validation plugin will point out multiple errors.
 9) Apply patch
10) Refresh page
11) View Page Source
    -- Much happier validation results.

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>