Bug 28542: Move new authority from Z39.50/SRU to a button

Actually in authority tools bar, 'New from Z39.50/SRU' is inside 'New autority' menu.
This is different from biblio cataloguing toolbar, and adds a click to access it.

I propose to move this to its own button.

Test plan :
1) Create a Z39.50/SRU server connexion for authorities
2) Go to authorities home page
3) Check you see buttons 'New autority' and 'New from Z39.50/SRU'
4) Click on 'New autority'
5) Check you only see autority types
6) Click on 'New from Z39.50/SRU'
7) Check you go to Z39.50/SRU popup
8) Delete Z39.50/SRU server connexion for authorities
9) Go to authorities home page
10) Check you dont see 'New from Z39.50/SRU'

Signed-off-by: David Nind <david@davidnind.com>

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

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
This commit is contained in:
Fridolin Somers 2021-06-10 15:05:51 +02:00 committed by Kyle M Hall
parent 2f2c35da9b
commit c2e164891d

View file

@ -4,20 +4,23 @@
<div id="toolbar" class="btn-toolbar">
[% IF ( CAN_user_editauthorities ) %]
<div class="btn-group">
<a class="btn btn-default dropdown-toggle" data-toggle="dropdown" href="#">
<button class="btn btn-default dropdown-toggle" data-toggle="dropdown">
<i class="fa fa-plus"></i> New authority
<span class="caret"></span>
</a>
</button>
<ul class="dropdown-menu">
[% IF servers.count > 0 %]
<li><a id="z3950_new" href="#">New from Z39.50/SRU</a></li>
<li role="separator" class="divider"></li>
[% END %]
[% FOREACH authority_type IN authority_types %]
<li><a href="/cgi-bin/koha/authorities/authorities.pl?authtypecode=[% authority_type.authtypecode | uri %]">[% authority_type.authtypetext | html %]</a></li>
[% END %]
</ul>
</div>
[% IF servers.count > 0 %]
<div class="btn-group">
<button id="z3950_new" class="btn btn-default">
<i class="fa fa-search"></i> New from Z39.50/SRU
</button>
</div>
[% END %]
[% END %]
[% IF ( authid ) %]