Jesse Weaver [Tue, 6 Oct 2015 22:00:49 +0000 (16:00 -0600)]
Bug 11559: (QA followup) switch to new delimiter, fix minor issues
This followup introduces a major change; instead of subfields starting
with '$<code><space>', they now start with '‡<code>'. The double-cross
character can be typed with Ctrl-D.
It also fixes the following:
* Add UUID.pm dependency
* Remove debugging call
* Fix toLocaleFormat error reported by Nick Clemens
* Ignore subfields that are marked as unrepeatable/mandatory AND
ignored (tab is -1)
* Mention lack of support for UNIMARC/NORMARC fixed fields in system
preferences screen
* Confirm when user creates new record and current record is modified
* Perform better when importing gigantic record dump
* Show "Edit" instead of "Import" and allow direct editing for local
catalog records in search screen
* Add "Keyboard shortcuts" help button to toolbar
Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Bug 11559: (followup) Prevent saving item tags, fix other issues
This fixes the following issues:
* Spaces are now allowed in indicators
* Shift-Enter is available to insert a newline if needed
* Item tags, if present, will prevent saving (as they are not correctly
processed by the backend)
* biblionumber tags (999 in MARC21) will be stripped before the record
is saved to Koha, to prevent their modification
Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
This fixes the following issues:
* ISO2709 import fails for Unicode
* Import only works with .mrc/.xml extensions
* MARC21 widgets not translatable
* Macro UI broken
* Uppercase subfield codes forbidden
* Tag with no valid subfields shows as error but tries to save
Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Jesse Weaver [Tue, 23 Jun 2015 22:24:17 +0000 (16:24 -0600)]
Bug 11559: (followup) Fill in default values, fix redirect and UNIMARC
This fixes the following issues:
* Help for UNIMARC tags broken
* MARC21 resources loaded when in UNIMARC
* Clicking on "advanced editor" in basic editor fails
* Shift-Tab goes to the beginning of a fixed-field widget rather
than the end
Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Jesse Weaver [Tue, 23 Jun 2015 22:24:17 +0000 (16:24 -0600)]
Bug 11559: (followup) Fix keyboard control bugs, make labels clickable
This fixes the following issues:
* Labels of search server checkboxes cannot be clicked
* Quick search fields cannot be focused
* Search results cannot be scrolled with a keyboard
Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Jesse Weaver [Mon, 15 Jun 2015 21:09:27 +0000 (17:09 -0400)]
Bug 11559: Rancor: advanced cataloging interface
Full test plan is posted on bug. Test plan for system preference:
1. Apply patch, clear cookies.
2. Go to "Cataloging."
3. Add new record, verify that basic editor is used.
4. Navigate to existing record, click on "Edit record", verify that
basic editor is used.
5. Inside basic editor, verify that no button appears to switch to the
advanced editor.
6. Enable the "EnableAdvancedCatalogingEditor" syspref.
7. Repeat above steps, should still go to basic editor, but button
should appear to switch to the advanced editor; click it.
8. Now, adding new records and editing existing records should go to
the advanced editor.
Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jesse Weaver [Mon, 15 Jun 2015 21:06:19 +0000 (17:06 -0400)]
Bug 11559: New libraries for Rancor
Adds the following JS libraries:
* CodeMirror - extensible text editor
* FileSaver - shim for saving files
* require - dependency resolver and module loader
Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jesse Weaver [Mon, 15 Jun 2015 20:57:46 +0000 (16:57 -0400)]
Bug 11559: Supporting changes for Rancor
* Extends login screen to pass along #hash
* Adds JSONP support to C4::Service
* Extends humanmsg to allow per-message classes
* Adds proper charset to results of svc/bib
Test plan:
1. C4/Auth.pm and .../intranet/.../auth.tt: verify that login/usage
works as expected, despite the change to pass on the fragment (...#blah)
from the URL.
2. C4/Service.pm and humanmsg.js: verify that editing system
preferences (the main user of these modules) works correctly despite
updates.
3. svc/bib: verify that records can be correctly downloaded with the
change of character set. This can be done in a Firebug/Chrome Devtools
console by running `$.get('/cgi-bin/koha/svc/bib/1')` and inspecting the
results (possibly replacing 1 with a different valid biblionumber).
Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Bug 14734: Enhance 264 display in OPAC and Staff XSLT.
Makes 264 repeatable, prefer 264 over 260. If 264/ind1=3 is present in the
record the xslt uses ind1 to determine latest 264, if no ind1=3 then all
264 fields are displayed.
Test Plan:
1) Apply this patch
2) Ensure you are using the default XSLT setting for the staff and opac record details
3) Find or create a record with multiple MARC tags 264
4) Perform a search that would show the record in the search results.
5) Review results for correct 264 display.
6) Click title to review record details.
Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as advertised. 260 not showed when 264 exists, tested with multiple
records. If ind1=3 is present shows the current/latest data
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 27 Oct 2015 14:29:29 +0000 (14:29 +0000)]
Bug 15069: Update items_search_fields.authorised_values_category to varchar(32)
This is a follow-up for bug 13379.
items_search_fields.authorised_values_category is now a varchar(32) but
the updatedatabase.pl did not modify it (changed only on
kohastructure.sql)
Test plan:
SHOW CREATE TABLE items_search_fields
before and after this patch.
items_search_fields.authorised_values_category should be a varchar(32)
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Mon, 23 Sep 2013 11:34:19 +0000 (13:34 +0200)]
Bug 10933: The PurgeSearchHistory should be merge into the C4::Search::History module
Since bug 10803 adds a C4::Search::History module, the
PurgeSearchHistory routine should be moved.
Test plan:
- run misc/cronjobs/cleanup_database.pl with the searchhistory param and
verify behavior is the same as before applying this patch.
- run prove t/Search/History.t
Signed-off-by: Joonas Kylmälä <j.kylmala@gmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Marc Véron [Fri, 9 Oct 2015 21:11:22 +0000 (23:11 +0200)]
Bug 14996: Remove C4::Dates from tags/review.pl
This patch removes C4::Dates from file tags/review.pl
To test:
- Create some tags
- Go to Home > Tools > Tags
- Verify that dates display properly
- Verify that the date filter works as before
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch fix an expected test result.
Also changes a comparison for the return value to 'delete'
layout sub, in case of success it returns 'undef' and triggers
the message 'use of uninitialized value $del_results ...'
To test:
1) Whitout this patch
prove t/db_dependent/Labels/t_Layout.t
fails.
Also note the message
"Use of uninitialized value $del_results in string ne at t/db_dependent/Labels/t_Layout.t line 110."
for using the return value of delete layout (undef on success!)
2) Apply the patch
3) Test pass and no more message
Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch removes 2 types of warnings when
creating Labels
a) Using '0' as filling char is not to the like of prStrWidth
On C4/Creators/Layout.pm
b) A RM followup from Galen on Bug 8375 to C4/Creators/PDF.pm
makes impossible to find properly a font :(
(http://git.koha-community.org/gitweb/?p=koha.git;a=commit;h=f7ef93e758850e991091e7268b8d1b1453082df4)
on C4/Labels/Label.pm
To test:
Pre patch
1) Go to Tools > Labels
2) Create a new layout, name ABC, type 'Barcode/Biblio'
3) Create a new batch, add 2 items
4) Export as PDF using the new layout
5) Look at logs, you will find something like
a) label-create-pdf.pl: Use of uninitialized value $strwidth in numeric lt (<) at /home/bgkriegel/kohaclone/C4/Creators/Layout.pm line 233., referer: http://staffdev.koha-community.org.ar/cgi-bin/koha/labels/label-print.pl
(Only one of this kind)
b) Two related lines similar to this examples
label-create-pdf.pl: Use of uninitialized value in -e at /home/bgkriegel/kohaclone/C4/Creators/PDF.pm line 226., referer: http://staffdev.koha-community.org.ar/cgi-bin/koha/labels/label-print.pl
label-create-pdf.pl: ERROR in koha-conf.xml -- missing <font type="Ft1">/path/to/font.ttf</font> at /home/bgkriegel/kohaclone/C4/Creators/PDF.pm line 229., referer: http://staffdev.koha-community.org.ar/cgi-bin/koha/labels/label-print.pl
(many many lines x number of items on batch)
6) Apply the patch
7) Export the same PDF, no more warnings
8) Bonus 1: change main font to Courier and Helvetica
and check results
9) Bonus 2: check using arabic records
Many hours to find :(
Easy to fix
Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Marc Véron [Sun, 4 Oct 2015 16:25:46 +0000 (18:25 +0200)]
Bug 14949: Remove C4::Dates from admin/smart-rules.pl and admin/categorie.pl
Bug to remove C4::Dates from
- admin/smart-rules.pl
- admin/categorie.pl
To test:
- Apply patch
- Go to Home > Administration > Circulation and fine rules (smart-rules.pl)
- Edit or add a rule
- Verify that 'Hard due date' displays and saves fine
- Go to Home > Administration > Patron categories
- Edit or add a category
- Verify that 'Until date' displays and saves fine
Note: The date picker does not warn about wrong date formats as e.g. while
editing patrons, but that is not in the scope of this bug
Signed-off-by: Joonas Kylmälä <j.kylmala@gmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Marc Véron [Sat, 10 Oct 2015 08:03:51 +0000 (10:03 +0200)]
Bug 14997: Remove C4::Dates from tools (import / export)
This patch removes C4::Dates from:
- tools/export.pl
- tools/import_borrowers.pl
Note: For testing, both need preparation without patch, see below.
To test export:
- Without patch applied, go to
Home > Tools > Export data > Export bibliographic records
- Define Start date / End date for Accession dates
- Export bibliographic records as 'without-patch.mrc'
- Do the same with patch, export as 'with-patch.mrc
- Compare the files, they should be the same
To test Import patrons:
- Without patch
- Go to Home > Tools > Import patrons
- Create a patron category like 'TEST' (useful for filtering...)
- Prepare a file with some patrons with category TEST to import.
Fill date of birth, enrolment date, expiry date with values
formatted in syspref format, in iso format and garbage
- Import
- Review the imported patrons (search for category TEST)
- With patch: Change cardnumber and names in import file
- Import
- Review again and compare with results from previous import.
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Kyle M Hall [Mon, 28 Sep 2015 14:36:28 +0000 (10:36 -0400)]
Bug 14915: Use Font Awesome instead of Glyphicons for the staff intranet
We should be using Font Awesome for our icons instead of Glyphicons, for
the reasons discussed on bug 13696.
Test Plan:
1) Apply this patch
2) Note all Glyphicons have been replaced with FA icons in the staff intranet
3) git grep "icon-" ./koha-tmpl/intranet-tmpl/prog/en/modules/
should give no results
4) git grep "icon-" ./koha-tmpl/intranet-tmpl/prog/en/includes/
should give no results
Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
We need a follow-up to cover the files changes since this
patch was written. Especially to cover the changes in the
label creator modules. Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Kyle M Hall [Mon, 28 Sep 2015 15:41:44 +0000 (11:41 -0400)]
Bug 13696: (QA followup) Add Font Awesome license to the about page
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Kyle M Hall [Wed, 11 Feb 2015 12:24:24 +0000 (07:24 -0500)]
Bug 13696: Add support for Font Awesome icons in Koha
Font Awesome is similar to Glyphicons included in Twitter Bootstrap,
except better in every way and more Free.
Test Plan:
1) Apply this patch
2) Edit the template for a page, and add a Font Awesome tag to it,
examples can be found here:
http://fortawesome.github.io/Font-Awesome/examples/
3) Reload the page and verify the icon displays.
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Marc Véron [Thu, 8 Oct 2015 17:34:56 +0000 (19:34 +0200)]
Bug 14982: Remove C4::Dates from guided report wizard and dictionary
This patch removes C4::Dates from files:
- reports/guided_reports.pl
- reports/dictionary.pl
- C4/Reports/Guided.pm
To test:
- Go to Home > Reports > Guided reports wizard
- Then go to 'View Dictionary' (menue at teh left)
- Click 'New definition' and step through
- In step 2. select e.g. borrowers
- In step 3 select a date field
- In step 4, select date range and test start / end dates
- In step 5, verify that dates display properly
- Save and verify that dates are insertet properly in sql definition
- Go back to Home > Reports > Guided reports wizard
- Step through the wizard and verify that it works as before.
http://bugs.koha-community.org/show_bug.cgi?id=14982 Signed-off-by: Josef Moravec <josef.moravec@gmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
To test:
- Go to Home > Reports
- Verify that following reports work as before:
- Other > Average loan time
- Statistic wizards
- Acquisitions
- Patrons
- Circulation
- Serials
- Holds
Signed-off-by: Josef Moravec <josef.moravec@gmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Magnus Enger [Tue, 15 Sep 2015 08:24:44 +0000 (10:24 +0200)]
Bug 14824: Fix sorting of Norwegian vowels
Currently, Norwegian vowels are not sorted correctly, even when
you have chosen "nb" as the ZEBRA_LANGUAGE during installation.
To test:
- Make sure you have three records with titles that begin with ÆØÅ
respectively
- Do a search that turns up those three records and some others, and
sort the results by title, bot ascending and descending.
- Verify that ÆØÅ is shown in some weird order.
- Edit your sort-string-utf.chr* so it is in line with the current
patch. It should include these two lines:
lowercase {0-9}{a-z}æøå
uppercase {0-9}{A-Z}ÆØÅ
- Restart Zebra and reindex all the records, e.g.:
$ sudo koha-restart-zebra <instancename>
$ sudo koha-rebuild-zebra -f -v <instancename>
- Do the search again, make sure you order by title and check that
ÆØÅ are sorted in the order of 1. Æ 2. Ø 3. Å, and after all other
characters
* = If you are on a gitified install, you need to edit this file:
/etc/koha/zebradb/lang_defs/<your ZEBRA_LANGUAGE>/sort-string-utf.chr
NOT the file in your git clone (yeah, i wasted some time there...)
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Mon, 26 Oct 2015 13:59:06 +0000 (13:59 +0000)]
Bug 14778: Make Search.t pass - replace SHOW COLUMNS
For an unkown reason, when executed from a test file, the 'SHOW COLUMNS'
statement does not return anything.
We need to retrieve the column list from the DBIx::Class resultset.
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 20 Oct 2015 14:42:53 +0000 (15:42 +0100)]
Bug 14778: Remove t/Acquisition/Invoices.t
Using Test::DBIx::Class now, we cannot do what we did in this file with DBD::Mock.
Since the Invoice[s] subroutines are already tested in
t/db_dependent/Acquisition/Invoices.t there is no special needs to have
these ones.
Instead of loosing 2 hours on this file, I would prefer to remove it.
Feel free to provide a counter patch.
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 20 Oct 2015 14:37:40 +0000 (15:37 +0100)]
Bug 14778: Mock the dbh for t/db_dependent/Search.t
No need to mock the items' columns (?)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 20 Oct 2015 13:45:11 +0000 (14:45 +0100)]
Bug 14778: Make Barcodes_ValueBuilder.t db dependent
The get_barcode subroutines call very mysql specific functions and it's
not possible to easily use fixtures here.
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 20 Oct 2015 13:21:45 +0000 (14:21 +0100)]
Bug 14778: Install fixtures for t/SocialData.t
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 20 Oct 2015 13:10:18 +0000 (14:10 +0100)]
Bug 14778: Install fixtures for t/Members_AttributeTypes.t
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 20 Oct 2015 12:52:37 +0000 (13:52 +0100)]
Bug 14778: Install fixtures for t/Matcher.t
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 20 Oct 2015 12:46:46 +0000 (13:46 +0100)]
Bug 14778: Install fixtures for t/Letters.t
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 20 Oct 2015 12:02:15 +0000 (13:02 +0100)]
Bug 14778: Install fixtures for t/Koha.t
Warning: This patch modifies a module!
What's the need of the binary function here?
The data are case insensitive, so no need to use this mysql function.
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 20 Oct 2015 11:48:37 +0000 (12:48 +0100)]
Bug 14778: Install fixtures for t/ItemType.t
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 20 Oct 2015 11:44:55 +0000 (12:44 +0100)]
Bug 14778: Install fixtures for t/Images.t
Note that this tests file were completely buggy before.
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Thu, 15 Oct 2015 15:05:14 +0000 (16:05 +0100)]
Bug 14778: Install fixtures for t/Biblio.t
Note that it already passed before
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Thu, 15 Oct 2015 15:44:32 +0000 (16:44 +0100)]
Bug 14778: Install fixtures for t/Calendar.t
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Tue, 20 Oct 2015 10:48:00 +0000 (11:48 +0100)]
Bug 14778: Use mock_dbh where it should be used
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Thu, 8 Oct 2015 10:40:43 +0000 (11:40 +0100)]
Bug 14778: Example - Replace DBI::Mock with Test::DBIx::Class - Sitemapper.t
We can use Test::DBIx::Class to install fixtures before our tests.
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Thu, 8 Oct 2015 10:40:19 +0000 (11:40 +0100)]
Bug 14778: Set PrintError as it was before
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Thu, 8 Oct 2015 10:39:41 +0000 (11:39 +0100)]
Bug 14778: Make the installer test pass - use DBI missing
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Thu, 8 Oct 2015 10:39:19 +0000 (11:39 +0100)]
Bug 14778: Make 3 tests pass
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Fri, 4 Sep 2015 11:23:44 +0000 (12:23 +0100)]
Bug 14778: Make sure the dbh returned is checked by DBIC
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Thu, 3 Sep 2015 14:11:21 +0000 (15:11 +0100)]
Bug 14778: Get rid of DBIx::Connector
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Marcel de Rooy [Fri, 23 Oct 2015 06:47:58 +0000 (08:47 +0200)]
Bug 14918: [QA Follow-up] Correct enddate and use constant
Corrected enddate (subtraction in the revised code must be an addition).
Replaced hardcoded 2 days by a constant.
Renamed the constant TWO_DAYS to PULL_INTERVAL.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Tested all three date formats. Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Thu, 1 Oct 2015 09:08:56 +0000 (10:08 +0100)]
Bug 14918: Remove C4::Dates from circ/pendingreserves.pl
This patch uses Koha::DateUtils instead of C4::Dates and Date::Calc. It
also sent DateTime objects to the template, which use the TT plugin to
display them.
If an invalid dates is entered, the default date is picked.
Test plan:
1/ Go to Home > Circulation > Holds to pull
2/ Verify that the the filter and the list behave as before
3/ Enter invalid dates and confirm that you do not get a software error
Counter patch works as expected and is a much cleaner solution. Signed-off-by: Marc Veron <veron@veron.ch> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Marc Véron [Tue, 20 Oct 2015 16:53:12 +0000 (18:53 +0200)]
Bug 14776: Remove 'selfcheck' patron related links from and add language selector to SCO header
The SCO screen displays patron related menu items in it's header (Link to the account and "Logout").
This makes no sense since the patron that is logged in is the 'selfcheck' user as defined in syspref AutoSelfCheckId.
Additionally, the language menue is missing when the syspref OpacLangSelectorMode is set to 'top' or to 'both'.
To test:
- Apply on top of Bug 15039
- Set AutoSelfCheck sysprefs as appropriate
- Set OpacLangSelectorMode to 'top' or 'both'
- Go to SCO page
- Verify that the language menue does not display in the header
- Enter a card number to check out (this logs in the SCO user)
- Verify that you get text similar to "Welcome, checkout" with a link to the sco user's account in the OPAC and a 'Logout' link
- Apply patch
- Verify that the language menu appears and the SCO user's information disappears.
- Verify, that the language menu displays / does not display with combinations of:
- opaclanguagedisplay (Allow)
- opaclanguages ( > 1 language selected)
- OpacLangSelectorMode (top or both)
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Wed, 21 Oct 2015 13:08:05 +0000 (14:08 +0100)]
Bug 15037: Correctly check the patron categories on displaying the Batch checkout tab
When checking for the patron categories allowed to use the batch
checkout, the comparison should be strict (eq).
Test plan:
0/ Do not apply this patch
1/ Create 2 patron categories ST and S
2/ Enable BatchCheckouts and define BatchCheckoutsValidCategories = S
3/ Create 2 patrons, 1 in the ST category and the other one in S
4/ On the patron detail page, you should see the "batch checkout" tab
for both patron
5/ Apply this patch
6/ The tab should only be displayed for the patron S
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Tested using an 'S' patron and allowing 'ST' patrons only, worked as expected.
Also tried setting &batch=1 to force it to show the batch page, and it says
I'm not allowed to do batch checkouts for that patron. Great!
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Thu, 8 Oct 2015 16:19:47 +0000 (17:19 +0100)]
Bug 14981: Remove ethnicity occurrences from sample patrons file
Bug 10020 has removed these columns, the should be removed from the
patron sample file.
Test plan:
Insert the files updated by this patch into a fresh DB, you shouldn't
get any error.
Signed-off-by: Frederic Demians <f.demians@tamil.fr>
Before applying the patch, I was able to notice the error when loading the
patron sample SQL file to a DB. With the patch, it's solved.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Marcel de Rooy [Wed, 21 Oct 2015 11:02:31 +0000 (13:02 +0200)]
Bug 14674: [QA Follow-up] Typos and textual adjustment
This patch does:
[1] Resolve error [koha-create: line 294: local: `=upload21': not a valid
identifier] by replacing $instance by instance.
[2] Resolved typo for 'specify'.
[3] Resolve error: [sed: -e expression #26, char 20: unknown option to `s']
by replacing the slash in the sed line by a #. This makes sed not
stumble over the slashes in the upload path.
[4] Added the aspect of permanent storage in the wording (as opposed to
the storage of temporary uploads in /tmp or similar).
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Verified that koha-create now inserts the right path in koha-conf.xml.
Verified that koha-create-dirs created the new uploads directory.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Bug 14674: koha-create should populate upload_path
This patch makes koha-create and koha-create-dirs aware of the new upload_path
configuration entry.
It defaults to /var/lib/koha/<instance>/uploads as proposed by Robin but lets the
user specify its own directory, using the --upload-path option switch that is
added by this patch.
koha-create-dirs is tweaked so it also creates this new directory.
The docs are updated accordingly.
To test:
- Apply the patch, have a packages setup (either by grabbing the relevant files [1]
or by creating your own package).
- Run koha-create --create-db instance
=> SUCCESS: /var/lib/koha/instance/uploads directory is created
=> SUCCESS: /etc/koha/sites/instance/koha-config.xml has upload_path set correctly
- Create a new instance using the --upload-path making it point to whatever you want
=> SUCCESS: koha-conf.xml points to your chosen path
- Sign off :-D
Regards
Sponsored-by: Universidad Nacional de Cordoba Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Does not work in its current state. Needs a follow-up.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Jonathan Druart [Fri, 23 Oct 2015 08:32:18 +0000 (09:32 +0100)]
Bug 15052: Add diagnostic for the TestBuilder tests
Sometimes t/db_dependent/TestBuilder.t fails with 'TestBuilder can
create a entry for every sources' but we don't know which ones have
failed.
Test plan:
Create the following file: Koha/Schema/Result/Test.pm
package Koha::Schema::Result::Test;
use base 'DBIx::Class::Core';
__PACKAGE__->table("test");
1;
If you don't have a table named 'test' in your DB,
prove t/db_dependent/TestBuilder.t
should return a failure, but without any explanation.
With this patch you should get a diag and know what's wrong.
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Kyle M Hall [Fri, 16 Jan 2015 14:07:48 +0000 (09:07 -0500)]
Bug 13590: Add ability to charge fines at start of charge period
Right now, Koha only charges fines at the end of a given charge period.
For example, let us assume a circulation rule has a charge period of one
week ( 7 days ) and a fine of $5. This means that an item can be overdue
for 6 days without accruing a fine. Koha should allow circulation rules
to be configured to place the charge at the start of the end of the
charge period so the library can decide when the fine should accrue.
Test Plan:
1) Apply this patch
2) Run updatedatabase.pl
3) prove t/db_dependent/Circulation_Issuingrule.t
4) prove t/db_dependent/Circulation.t
5) prove t/db_dependent/Fines.t
6) Ensure you can still create/edit circulation rules
Edit: I removed the DBIx changes after a couple minutes fighting with them.
Will regenerate as usual in a RM followup / Tomas
Signed-off-by: Daniel Grobani <dgrobani@samuelmerritt.edu> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Marc Véron [Tue, 20 Oct 2015 15:03:16 +0000 (17:03 +0200)]
Bug 15039: Move top language menu to include and streamline logic
The language menu in koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc is used at other places as well (see Bug 14776).
This patch moves it to a file masthead-langmenu.inc to make it re-usable.
Additionally it streamlines the logic (not all combinations of Opac sysprefs that should display the menu did so).
To test:
- Apply patch
- Verify, that the language menu displays / does not display with combinations of:
- opaclanguagedisplay (Allow)
- opaclanguages ( > 1 language selected)
- OpacLangSelectorMode (top or both)
- Verify that sysprefs opacuserlogin and EnableOpacSearchHistory do not interfere
with the lenguage menu (before, at least one of them had to be on to display the menu)
- Verify that language switching works as before.
Signed-off-by: Chris Kirby <christopherlawrencekirby@gmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Julian Maurice [Thu, 1 Oct 2015 13:13:20 +0000 (15:13 +0200)]
Bug 11139: Add support for multiple values in AdvancedSearchTypes
AdvancedSearchTypes syspref can be multivalued, opac-topissues.pl
have to support that.
AdvancedSearchTypes can have one or more of the following values:
'itemtypes', 'ccode', 'loc'. But this patch adds support only for
itemtypes and ccode. AdvancedSearchTypes can still contain 'loc' but it
will change nothing to the behaviour of opac-topissues.pl.
This patch also removes duplicate code in template (the "Refine your
search" form was written in two different places)
This introduces a small behaviour change: when there is no results,
instead of having the form in the center of the page, it remains in the
left sidebar and we have a "No results" message in the main area.
Depends on bug 14788
Tested on top of 14788. Works as expected. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Julian Maurice [Fri, 4 Sep 2015 14:19:28 +0000 (16:19 +0200)]
Bug 14788: Move opac-topissues.pl code into C4::Circulation
Tested with syspref 'AdvancedSearchTypes' set to itemtypes an ccode (one at a time).
No problems found. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Blou [Fri, 21 Aug 2015 13:01:47 +0000 (09:01 -0400)]
Bug 10937: Fix Seach Type in Advanced Search
In order to see the checkboxes of the Collection and Shelving location of the advanced search, the if changed so that only the Itemtypes will go through the previous if
Bug 10937: cleanup and rename DOCTYPECAT to ITEMTYPECAT
- "Item" and not "Document" is the word used throughout Koha.
- Moved the updates to an atomic update
- changed searchcategory from varchar(20) to (80)
- cleanup
ahmed [Wed, 21 Jan 2015 19:33:47 +0000 (14:33 -0500)]
Bug 10937: Option to hide and group itemtypes from advanced search
This allows to group certain item types in a category, to be displayed (and searched) as such in OPAC's advanced search. For example, you can group Reserve 2h and Reserve 12h into a Reserve category. The 2 and 12h types won't appear anymore.
This also allows to simply prevent an item type from displaying as a search option.
TEST PLAN
------------------
0) Back up database, so you can reset and retest easily. ;)
1) Apply the patch
2) Run Koha QA tool.
3) prove -v t/db_dependent/Koha.t
-- all tests should pass.
4) run ./installer/data/mysql/updatedatabase.pl to add the
two columns to itemtypes
-- Does a meaningful message get printed?
Are the columns added?
"DESCRIBE itemtypes;" should list hideinopac and searchcategory.
5) You need to add a category to group your item types:
a) In Intranet/Koha Admin/Authorized values,
select DOCTYPECAT in the 'Show category:' dropdown
i) If you do not have a DOCTYPECAT category, create one.
b) Click button "New authorized value for DOCTYPECAT"
c) Enter
Authorized value: HARDWARE
Description : Hardware
Description (OPAC): Hardware
6) Group your items under that new category
a) In Intranet/Koha Admin/Item types, choose (at least)
two item types and for each:
- Click action/Edit on the right column
- Third row (below Description) is the Search category list box, select Hardware
- click Save changes at the bottom
7) Select at least one item to be hidden in the OPAC search
a) In Intranet/Koha Admin/Item types (again), choose a different item type:
- Click action/Edit
- Click the checkbox "Hide in OPAC" below the list of icons.
8) Go test your modifications
a) Go to OPAC/Adv search.
b) Validate that all items modified above (hidden or grouped) do not appear in Item type list
c) Validate that new item type Hardware does appear instead.
d) Select item Hardware, start Search.
) Validate returned items are the of the two types that were grouped into the Hardware category in step 4.
Sponsored-by: Vanier college Signed-off-by: Nick <nick@quecheelibrary.org> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Magnus Enger [Wed, 21 Oct 2015 11:11:28 +0000 (13:11 +0200)]
Bug 15042: Barcode hbyymmincr does not work when receiving serials
To test:
- Set autoBarcode = <branchcode>yymm0001
- Make sure you have a serial that is set to "create an item record
when receiving this serial"
- Receive an issue
- Click in the barcode field - nothing happens
- Apply patch and reload page
- Receive an issue
- Click in the barcode field - a barcode conforming to the
hbyymmincr setting appears
Patch works as advertised. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch adds a checkbox on Label creator
to use or not an oblique variant of main font
for title
Also fix font selection for title in case an
oblique variant is used.
To test:
Before patch
1) Go to Tools > Label creator
2) Create a new layout, default values but select
any 'Oblique' variant for main font and
'Biblio/Barcode' for layout type
3) Go to Manage batches, create a batch, add items,
export PDF, download
4) Check logs, you must find a line with
'ERROR in koha-conf.xml -- missing <font type="COO">'
for example if main font Courier-Oblique
5) Open PDF, title could be right but not using selected font
After patch
6) Apply the patch
7) Run updatedatabase.pl
8) Repeat 1-2, note new checkbox 'Oblique title',
default checked
9) Repeat export, no new warnings on log
10) Create a new layout or edit an existent one,
uncheck 'Oblique title', save, export again
Check PDF has non slanted title
Followed test plan, works as expected. (See comment #11). Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
When run with KEEP_PDF enviroment variable it will keep
test.pdf for manual inspection. This can be used to verify
that ttf font configuration is complete like:
sample of utf-8 text, font name and type will be on bottom of second page
Followed test plan, works as expected. (See comment#11) Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>