Commit graph

25888 commits

Author SHA1 Message Date
4a3404594f Bug 15163: Do not erase patron attributes if limited to another library
The patron attributes displayed on editing a patron are not displayed if
limited to another library.

C4::Members::Attributes::SetBorrowerAttributes will now only delete attributes
the librarian is editing.
SetBorrowerAttributes takes a new $no_branch_limit parameter. If set,
the branch limitations have not effect and all attributes are deleted
(same behavior as before this patch).

Test plan:
1/ Create 2 patron attributes, without branch limitations.
2/ Edit a patron and set a value for these attributes
3/ Limit a patron attributes to a library (one you are not logged in
with).
4/ Edit again the patron.
=> You should not see the limited attributes
5/ Edit the patron attributes and remove the branch limitation
=> Without this patch, it has been removed from the database and is not
displayed anymore.
=> With this patch, you should see it.

Signed-off-by: Jesse Weaver <jweaver@bywatersolutions.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-21 16:56:37 +00:00
8d64bb9eb0 Bug 16073: (follow-up) Fix software error in circulation.pl
Do not crash if the patron does not exist.

Test plan:
Access circ/circulation.pl?borrowernumber=42424242
you should get an error without this patch
With this patch, you will get an empty patron detail page (should be
fixed in another patch, but this behavior exists for a while)

Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-21 16:07:18 +00:00
cfa76a3577 Bug 16073: Fix software error in circulation.pl
Can't call method "guarantor" on an undefined value at
/home/koha/src/circ/circulation.pl line 588.
 at /home/koha/src/circ/circulation.pl line 673

Introduced by bug 15656

Test plan:
Just trigger circ/circulation.pl

Signed-off-by: Jacek Ablewicz <abl@biblos.pk.edu.pl>
Triggered circ/circulation.pl - nothing exploded, and error is gone
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-21 16:07:18 +00:00
Marc Véron
52c77ad914 Bug 16089: (Follow up) Display currency symbol properly
This patch fixes the display of the currency symbol on invoice.tt

See comment #5

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-21 16:05:51 +00:00
Marc Véron
d003b24532 Bug 16089: Acquisitions -> Invoice broken by Bug 15084
To test:
- Reproduce error described in first comment.
- Apply patch
- Try to reproduce error. Page will display as expected.

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

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-21 16:05:50 +00:00
a5519b36a8 Bug 15990: (follow-up) Making record matching rules actions buttons
Adds the actions class to the td elt to keep the buttons next to each
other.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-18 07:10:29 +00:00
Aleisha
6638d3f73f Bug 15990: Making record matching rules actions buttons
To test:

1) Go to Administration -> Record matching rules
2) Confirm that the actions 'Edit' and 'Delete' are not buttons and behave as expected.

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

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-18 07:10:29 +00:00
9752d14796 Bug 15993 [Follow-up] Making currency actions buttons
This trivial follow-up adds an "actions" class to the table cell
containing the new buttons. In conjunction with the style update in Bug
16048, this will prevent the buttons from wrapping at narrow browser
window widths.

To test, apply the patch for Bug 16048 and go to Administration ->
Currencies and exchange rates.

In the table of currencies, confirm that the "Edit" and "Delete" buttons
are not stacked one on top of the other even at narrow browser window
widths.

Signed-off-by: Aleisha <aleishaamohia@hotmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-18 07:09:32 +00:00
Aleisha
2e7d614997 Bug 15993: Making currency actions buttons
To test:

1) Go to Administration -> Currencies and exchange rates
2) Confirm that the actions 'Edit' and 'Delete' are now buttons and behave as expected.

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

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-18 07:09:32 +00:00
c21a291747 Bug 15995 [Follow-up] Making libraries actions buttons
This trivial follow-up adds an "actions" class to the table cell
containing the new buttons. In conjunction with the style update in Bug
16048, this will prevent the buttons from wrapping at narrow browser
window widths.

To test, apply the patch for Bug 16048 and go to Administration ->
Libraries and Groups.

Confirm that the "Edit" and "Delete" buttons do not wrap even at narrow
browser window widths.

Signed-off-by: Aleisha <aleishaamohia@hotmail.com>
You forgot to add the class to one of the tables, but I have added it

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-18 07:08:29 +00:00
Aleisha
37ee313180 Bug 15995: Making libraries actions buttons
To test:

1) Go to Administration -> Libraries and Groups
2) Confirm that the actions 'Edit' and 'Delete' are now buttons for BOTH
   tables under one column 'Actions' and buttons behave as expected.

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

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-18 07:08:29 +00:00
9ecb394a80 Bug 16036 [Follow-up] Making basket actions buttons
This trivial follow-up adds an "actions" class to the table cell
containing the new buttons. In conjunction with the style update in Bug
16048, this will prevent the buttons from wrapping at narrow browser
window widths.

To test, apply the patch for Bug 16048 and search for a vendor in
Acquisitions which has at least one open basket.

Confirm that the "View" and "Add to basket" buttons look correct and do
not wrap when you make your browser window narrower.

Signed-off-by: Aleisha <aleishaamohia@hotmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-18 07:07:12 +00:00
Aleisha
ddfd58a13c Bug 16036: Making basket actions buttons
To test:
1) Go to Acqui -> do a vendor search
2) Confirm actions 'View' and 'Add to basket' are now buttons and behave as
   expected

Sponsored-by: Catalyst IT
Signed-off-by: Frédéric Demians <f.demians@tamil.fr>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-18 07:07:12 +00:00
da21ad0659 Bug 16054: Fix variable scope error in paycollect.pl
$borrower, $borrowernumber and $template and not visible in the
subroutine.
Using $b_ref and passing $template fixes the issue.

Test plan:
Under plack, use the pay selected button.
On the paycollect page, you should see the image of the patron

It certainly fixes some other bugs.

Signed-off-by: Srdjan <srdjan@catalyst.net.nz>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-15 07:12:12 +00:00
55b78f1a5d Bug 11998: Clear L1 cache from psgi files
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Jacek Ablewicz <abl@biblos.pk.edu.pl>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-15 07:08:30 +00:00
47fbbb7cf5 Bug 11998: Add a L1 cache for sysprefs
Accessing to the cache for each call to C4::Context->preference might
have an impact on performances.
To avoid that this patch introduces a L1 cache (simple hashref). It will
be populated by accessing the L2 cache (Koha::Cache).
If a pref is retrieved 10x, the first one will get the value from the L2
cache, then the L1 cache will be check.
To do so we will need to clear the L1 cache every time a page is loaded.

Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Jacek Ablewicz <abl@biblos.pk.edu.pl>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-15 07:08:29 +00:00
2eaf2cd71b Bug 11998: follow-up for the debian package psgi file
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Jacek Ablewicz <abl@biblos.pk.edu.pl>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-15 07:08:29 +00:00
d4039ce093 Bug 11998: Revert "Bug 13805: (Plack) Disable syspref cache"
This reverts commit ca00f0ddae.

Bug 13805 fixes an installer bug by disabling the syspref cache.
It was not a good idea, it introduced performance issues (see bug 13805
comment 14).

Test plan:
Test plan:
0/ Create a new database and fill the database entry in the koha conf
with its name
1/ Go on the mainpage, you should be redirected to the installer
2/ Try to log in
You should not get the login form again.

Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Jacek Ablewicz <abl@biblos.pk.edu.pl>
Test plan not followed by me for this patch, due to lack of working
plack setup, but I don't expect it to cause any problems, and performace
gain for plack will be tremendous

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-15 07:08:29 +00:00
f25e3ed90b Bug 11998: Do not clear syspref cache in psgi file
This in only in koha.psgi, it has been introduced by bug 13815 but
should not have been added by this patch.

Removing it should not introduce any changes.
Not that it won't impact debian packages.

Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Jacek Ablewicz <abl@biblos.pk.edu.pl>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-15 07:08:29 +00:00
3907401a6d Bug 11998: Make HoldsQueue.t tests pass [TO REVERT]
This patch should not be the way to make these tests pass.
The prefs should not be updated using set_preference, it will modify the
values in the cache.

I have no idea how to make them pass using the correct way, please help
:)

Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Jacek Ablewicz <abl@biblos.pk.edu.pl>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-15 07:08:29 +00:00
a691e88a4e Bug 11998: Use C4::Context->preference in Koha/Schema/Result/Item.pm
Otherwise some tests won't pass

Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Jacek Ablewicz <abl@biblos.pk.edu.pl>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-15 07:08:28 +00:00
56a782c666 Bug 11998: Use t::lib::Mocks::mock_preference in tests
Unless in t/db_dependent/Context.t where we want to test the cache
behaviors.

Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
Signed-off-by: Jacek Ablewicz <abl@biblos.pk.edu.pl>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-15 07:08:28 +00:00
9820f9dfbd Bug 11998: Use Koha::Cache to cache sysprefs
At the moment, the sysprefs are only cache in the thread memory
executing the processus
When using Plack, that means we need to clear the syspref cache on each
page.
To avoid that, we can use Koha::Cache to cache the sysprefs correctly.

A big part of the authorship of this patch goes to Robin Sheat.

Test plan:
1/ Add/Update/Delete local use prefs
2/ Update pref values and confirm that the changes are correctly taken
into account

Signed-off-by: Chris <chrisc@catalyst.net.nz>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Tested with plack with syspref cache enabled, there is some time between setting the syspref and applying it, but it takes just one reload of page, it shouldn't be problem, should it?
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>

Signed-off-by: Jacek Ablewicz <abl@biblos.pk.edu.pl>
Tested with CGI and CGI + memcache; some small issues still remain,
but it would be better to deal with them in separate bug reports
if necessary

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-15 07:08:28 +00:00
fc640d2a86 Bug 15111: Do not include the antiClickjack legacy browser trick for greybox
Most of the scripts called via greybox (which uses iframe) don't include
doc-head-close. But some do.
This patch adds a popup parameter for these templates, not to include
the legacy browser trick and avoid the replacement of the location.

Test plan:
1/ Export patroncard and label
2/ translate itemtypes
3/ click on a idref link at the OPAC

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
2016-03-14 16:30:09 +00:00
fb167c0e4b Bug 15111: Change X-Frame-Options with SAMEORIGIN
There are some places where frames are used, the greybox JS plugin for
instance.

We need either to allow them from Koha or replace this plugin.
The easier for now is to switch the value from DENY with SAMEORIGIN.

Test plan:
- modify a record in a batch (tools/batch_record_modification.pl)
- click on preview marc
=> With only the previous patch you will get a blank page.
=> With this patch apply, it will work as expected.

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

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
2016-03-14 16:30:08 +00:00
dc03bca76c Bug 15111 - Koha is vulnerable to Cross-Frame Scripting (XFS) attacks
Web pages that can be embedded in frames are vulnerable to cross-frame
scripting attacks. Cross-frame scripting is a type of phishing attack
that involves instructions to an unsuspecting user to follow a specific
link to update confidential information in an online application.
Because the link leads to a legitimate page from the online application
that is embedded in a frame hosted by the attackers' server, the
attackers can capture all the information that the user enters.

https://www.owasp.org/index.php/Clickjacking_Defense_Cheat_Sheet
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
2016-03-14 16:30:08 +00:00
665a0052a1 Bug 16045 - Use Font Awesome icons in OAI sets administration
There are links on the OAI sets administration page which can use Font
Awesome icons instead of being styled with background images. This patch
makes that change.

Another minor change: Added the "fa-fw" class to items in the "Actions"
menu which didn't have it. This helps the items line up correctly:
http://fortawesome.github.io/Font-Awesome/examples/#fixed-width

To test, apply the patches for Bugs 16014 and 15991 if necessary. Apply
this patch and:

- Go to Administration ->  OAI sets configuration.
- Click the "New set" button and verify that the "Add description" link
  uses a Font Awesome icon.
- Confirm that the "Add description" link works correctly.
- After adding a description, verify that the "Remove" link looks
  correct and works correctly.
- From the list of OAI sets choose "Define mappings" from the "Actions"
  menu.
- Confirm that the "Delete" button is styled correctly and works
  correctly.

Signed-off-by: Aleisha <aleishaamohia@hotmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:44:52 +00:00
9c5c1bc9f1 Bug 15206: Make strings translatable
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:41:40 +00:00
Alex Arnaud
c4c87f5982 Bug 15206 - Make CalculateAge a reusable function
Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:41:40 +00:00
Alex Arnaud
d49f7741bf Bug 15206 - Show patron's age under date of birth in memberentry.pl
Test plan:

Create or edit a patron (members/memberentry.pl), enter a date of birth
(for a new patron), patron'a age should be shown under

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

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:41:40 +00:00
e8036c9794 Bug 15656 [QA Followup] - Return without searching if patron has no guarantor
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:40:10 +00:00
aa73c96aed Bug 15656: Move guarantor/guarantees code - GetMemberRelatives
Note:
QA question: Does the Koha::Patron->siblings method should return undef
if there is no guarantor?
It would avoid the weird  != undef, = $borrowernumber conditions.

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

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

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:40:10 +00:00
bff0ca0b0b Bug 15656: Move guarantor/guarantees code - GetGuarantees
2 subroutines of C4::Members deal with guarantor/guarantees:
GetGuarantees and GetMemberRelatives.
Since we already have a Koha::Patron->guarantor method, it makes sense
to move these 2 subroutines to this module.

This first patch deals with GetGuarantees.

Test plan for the entire patch set:
1/ Create 5 patrons A (adult), B (child), C (child), D (child), E
(child), F (adult)
2/ Add relation between them: A is father of B, C and D.
E does not have a guarantor
F does not have guarantees
3/ Check some items out for all of these patrons
4/ On the "Check out" and "Details" tabs, you should not see any
differences with these patch applied : The "Relatives' checkouts" tabs
should list all of the guarantor/guarantee/siblings checkouts

Note:
$template->param('C' => 1);
I have not found any reference of this 'C' in the template.
It seems it's an old c/p from members/memberentrygen.tt

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

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

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:40:10 +00:00
186f630407 Bug 15653: Remove unused C4::Members::UpdateGuarantees subroutine
Looking at the code, there is some broken with the guarantees code.
It seems that the expected behavior would be to update address, fax,
B_city, mobile, city and phone info of the guarantees when a guarantor
is modified.
But the code in C4::Members::ModMember is broken:

 668         my $borrowercategory= GetBorrowercategory(
$data{'category_type'} );
 669         if ( exists  $borrowercategory->{'category_type'} &&
$borrowercategory->{'category_type'} eq ('A' || 'S') ) {
 670             # is adult check guarantees;
 671             UpdateGuarantees(%data);
 672         }

First, GetBorrowerCategory expects a categorycode, not a category_type.
Then UpdateGuarantees retrieves the param like:

 989 sub UpdateGuarantees {
 990     my %data = shift;

Which means that %data will always be something like ( a_key => undef )
And nothing more.

The updateguarantees subroutine (It has been renamed) has been introduced by

commit 56825e415f
Date:   Mon Aug 30 13:48:58 2004 +0000
    modularizing (with Members.pm) members management
    (beginning of...)

And the `%data = shift` already existed...

This code has never worked and could be removed.

See http://lists.koha-community.org/pipermail/koha-devel/2016-January/042241.html

Test plan:
Confirm the previous assertions.

Note that I have found this bug working on bug 15631, see patch "Bug
15631: Koha::Cities - remove getidcity and GetCities"

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>

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

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:39:09 +00:00
3352ca6a70 Bug 15886 - Revise layout and behavior of audio alerts management
This patch changes the behavior of the audio alerts management page so
that sections of the page are shown or hidden based on what the current
task is. Other changes include:

- Moving JavaScript to a separate file
- Adding a toolbar with a "New alert" button.
- Enabling or disabling the "play sound" button based on the value of
  the sound file field.
- Enabling or disabling the "delete" button based on whether there are
  checkboxes checked.
- Switching the patron category administration header search form for
  the "generic" catalog search one.
- Adding "Required" classes to required fields so that the staff
  client's built-in JS validation library can be used.
- Styling the add/edit form in a way which is consistent with other
  interfaces in Koha.
- Removing the invalid "border" attribute from images.
- Adding better alt attributes to images.

To test, the AudioAlerts system preference must be enabled. Apply the
patch and go to Administration -> Audio alerts.

- Confirm that the add/edit form is hidden initially. A toolbar with a
  "New" button should appear with existing audio alerts in a table
  below.
- Confirm that the "New alert" button works:
  - The table should be hidden and an empty "add" form displayed.
  - Confirm that an empty form cannot be submitted.
  - Confirm that typing or selecting a sound enables the "Play sound"
    button and that it works to play the sound.
  - Confirm that adding valid data works.
  - Confirm that clicking the "Cancel" button hides the form and
    redisplays the table.
- Test the "edit" button for an existing sound:
  - Confirm that the edit form is displayed and populated with the
    correct data.
  - Confirm that edits are saved correctly.
- When viewing the table of existing alerts, confirm that checking one
  of the checkboxes "enables" the delete button.
- With one or more checkboxes checked, test that clicking the delete
  button triggers a deletion confirmation. Test both confirm and cancel
  operations.
- With no checkboxes checked, test that clicking the delete button
  triggers an alert that checkboxes must be checked.
- Ponder whether all this is an improvement or not.

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

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:36:12 +00:00
5b89339272 Bug 15960: Use Font Awesome icons for classification filing rule deletion error
When deletion of a classification filing rule is impossible, the dialog
saying so should be styled with Font Awesome icons. This patch corrects
this omission from the patch for Bug 15785.

Also changed: The dialog is now an "alert" style dialog instead of a
"message" one.

To test, apply the patch and go to Administration -> Classification
sources.

- Locate a classification filing rule which is in use by a
  classification source.
- Click the "Delete" link for that rule and verify that the resulting
  dialog is correctly styled.
- Click the "OK" button and confirm that you are correctly redirected.

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as advertise

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:34:55 +00:00
0366c22bac Bug 15963: Use Font Awesome icons for confirmation after deleting MARC tag
This patch revises the dialog which appears after you have deleted a
MARC tag.

To test, apply the patch and go to Administration -> MARC frameworks ->
MARC sturcture -> Delete.

- Confirm that you want to delete a MARC tag.
- Verify that the confirmation dialog you are shown is styled correctly.
- Verify that clicking "OK" redirects you to the right place.

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as advertised

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:33:25 +00:00
Aleisha
e4799500cb Bug 15966: Move MARC frameworks actions into a drop down menu
EDIT: Switching icons for Export and Import. What I had initially was what I intended because export is like downloading and import is like upload, but it seems to make more sense reversed.
EDIT2: Fixing Import problem

To test:

1) Go to Administration -> MARC bibliographic framework (admin/biblio_framework.pl)
2) Confirm that all actions have now been moved into drop down menus.
  a) For Default framework, actions available are 'MARC structure', 'Export' and 'Import'.
  b) Confirm these buttons all work as expected.
  c) For all other frameworks, actions available are 'MARC structure', 'Edit', 'Delete', 'Export' and 'Import'.
  d) Confirm these buttons all work as expected.

Sponsored-by: Catalyst IT

Signed-off-by: Nicole C Engard <nengard@bywatersolutions.com>

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:32:31 +00:00
987874f4d8 Bug 15978: Use Font Awesome icons for guided reports error dialog
If you try to save an SQL report with an invalid authorized value
placeholder you will be presented with a confirmation dialog. This patch
updates it to use Font Awesome icons.

Also fixed: Validation error found in testing: Duplicated <form> tag and
series of redundant inputs. Each input cut had an exact duplicate in the
same form.

To test, apply the patch and go to Reports -> Create from SQL.

- Create a new SQL report and fill in as many fields as possible to
  verify correct operation.
- Try to save your report with an invalid authorized value
  placeholder, for example: SELECT * FROM items WHERE items.itype =
  <<foo|bar>>
- Confirm that the confirmation dialog is styled correctly.
- Test the operation of the "Edit SQL" button. You should be sent back a
  page.
- Test the operation of the "Save anyway" button and confirm that your
  report was saved.
- Repeat these steps when editing an existing report.

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as described

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:31:44 +00:00
7742d8911b Bug 15980: Use Font Awesome icons in subscription frequency deletion confirmation dialog
If you try to delete a subscription frequency which is in use by an
existing subscription you will be shown a confirmation dialog. This
dialog should use Font Awesome icons.

Other minor changes:

- Added "action" attributes to <form>s to fix validation errors.
- Added "alert" class to confirmation dialog so that it is correctly
  styled.

To test, apply the patch and go to Serials -> Frequencies.

- Click "Delete" on a frequency which is in use by a subscription.
- Verify that the confirmation dialog is styled correctly.
- Test that the "No, do not delete" button works correctly.
- Test that the "Yes, delete" button deletes the correct frequency.

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as advertised

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:30:01 +00:00
364844cfd7 Bug 15983: Use Font Awesome icons in serial numbering pattern deletion confirmation dialog
If you try to delete a serial numbering pattern which is in use by an
existing subscription you will be shown a confirmation dialog. This
dialog should use Font Awesome icons.

Other minor changes:

- Added "action" attributes to <form>s to fix validation errors.
- Added "alert" class to confirmation dialogs so that they correctly
  styled.

To test, apply the patch and go to Serials -> Numbering patterns.

- Click "Delete" on a numbering pattern which is in use by a
  subscription.
- Verify that the confirmation dialog is styled correctly.
- Test that the "No, do not delete" button works correctly.
- Test that the "Yes, delete" button deletes the correct numbering
  pattern.

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as described

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:29:07 +00:00
Aleisha
71e1f75a30 Bug 15991: Moving OAI sets actions into a drop-down menu
To test:

1) Apply Bug 16014 first
2) Go to Administration -> OAI sets
3) Confirm that the actions 'Modify', 'Delete' and 'Define mappings' have been moved into a drop-down menu and buttons behave as expected.
4) Confirm you are asked to confirm on 'Delete' as per Bug 16014

Sponsored-by: Catalyst IT

Signed-off-by: Nicole C Engard <nengard@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:28:13 +00:00
Aleisha
024af5ee9f Bug 15992: Renaming 'Operations' column heading to 'Actions'
to be consistent with other Administration tables
These actions were already made into buttons so will just make this small string change

To test:

1) Go to Admin -> Item search fields
2) Confirm column heading now reads 'Actions'

Sponsored-by: Catalyst IT

NOTE: Trivial string change, screen refresh confirms change.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:26:59 +00:00
460a856628 Bug 16021 - Use Font Awesome icons on automatic item modifications by age page
This patch revises the automatic item modifications by age page to use
Font Awesome icons instead of Glyphicons.

To test, apply the patch and go to Tools -> Automatic item modifications
by age.

- Confirm that the "Edit" toolbar button uses a "pencil" icon instead of
  a "plus." (Edit -> Pencil; Add -> Plus).
- Confirm that the icons associated with adding, editing, or removing
  rules look correct and work correctly.

Signed-off-by: Nicole C Engard <nengard@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
2016-03-12 23:25:20 +00:00
765535c09a Bug 16048 [Follow-up] Making notices actions buttons
This followup adds a "td.actions" style with "white-space:nowrap" and
replaces the inline styles. Also modified is the way non-sorting table
columns are defined. This corrects a problem with non-sortable columns
introducted by the previous patch's column changes.

To test, apply the patch and clear your browser cache if necessary.

- Go to Tools -> Notices and confirm that even at narrow browser widths
  the "Edit" and "Delete" buttons stay side by side.
- Confirm that all columns are sortable except "Copy notice" and
  "Actions."

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
2016-03-11 23:01:39 +00:00
Aleisha
76fe7ec396 Bug 16048: Making notices actions buttons
EDIT: Adding no wrap class to Actions column for when libraries with longer names mess up formatting

To test:
1) Go to Tools -> Notices and slips (tools/letter.pl)
2) Confirm that all actions (Copy, Edit and Delete) now show as font awesome buttons and work as expected

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

I have a couple of corrections in a follow-up.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
2016-03-11 23:01:38 +00:00
d638520f85 Bug 16024 - Use Font Awesome icons on item types administration page
When editing an item type, a Glyphicon is used for the "translate" link.
It should use a Font Awesome icon instead. This patch corrects it.

To test, apply the patch and go to Administration -> Item types.

- Edit an existing item type.
- Confirm that the icon associated with the "Translate into other
  languages" link is correct.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
2016-03-11 23:00:11 +00:00
a6917deede Bug 16026 - Use Font Awesome icons on cataloging home page
The cataloging home page has one instance of a Glyphicon. This patch
replaces it with a Font Awesome icon.

To test you must have the EnableAdvancedCatalogingEditor preference
enabled.

- Apply the patch and go to the Cataloging home page.
- Confirm that the "Advanced editor" button uses the "pencil" icon and
  that it still works correctly.

Signed-off-by: Nicole C Engard <nengard@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
2016-03-11 22:59:10 +00:00
Nicole C Engard
39f9b9ddb0 Bug 15694: Add aliases for date/time last modified
This patch will add indexes for Date/time-last-modified.

To test:

1. apply patch
2. reindex
3. search for dtlm:DATE and date-time-last-modified:DATE
4. confirm that you get results

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as advertised

Signed-off-by: Frédéric Demians <f.demians@tamil.fr>
  I confirm Hector signing-off. A simple Zebra server restart suffice to get
  working the searches on date-time-last-modified and dtlm.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
2016-03-11 21:56:50 +00:00
Zeno Tajoli
69cf2d9451 Bug 15955: Tuning function 'New child record' for Unimarc 205$a -> 461$e
Now the sYstem tries to insert value of 205$a into 461$a when a child is
created from the father record.  In UNIMARC 46x tags there is not
present a subfield for ediction value (205$a in UNIMARC).

To Test:
1) Check to have EasyAnalyticalRecords on 'off'
2) Check to use UNIMARC
3) Create a record with data in 200$a (title), 205$a (ediction), 700
   (author) 215$a(Place), 215$d(date)
4) From those record create a child using 'New'->'New child record'
5) See the values in 461 tag: You can see that in 461$a there is the
   value of 205$a from father This is wrong, you need to have the value
   of 700 $a and $b from father record, and 205$a in 461$e.
6) Appy the patch
7) Redo 4-5
8) Now 461 is good

Signed-off-by: Frédéric Demians <f.demians@tamil.fr>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
I have not checked the doc but trusting author and signoffer.

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
2016-03-11 21:55:24 +00:00