Bug 8208 follow-up: move Clear and Create new buttons out of results

Turns "Clear" and "Create new" links into buttons that are visible
before a search is performed, so that the user does not have to do
a search just to clear the field or create a new authority. This
commit also changes the formatting from textual links to buttons.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Nicer and more logical display.
Allows creating of a new authority without doing a search first
or when no results were found.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
This commit is contained in:
Jared Camins-Esakov 2012-07-09 08:56:27 -04:00 committed by Paul Poulain
parent 5ff81e2e8e
commit 899597c826
3 changed files with 21 additions and 22 deletions

View file

@ -2347,6 +2347,10 @@ ul.ui-tabs-nav li {
font-style: italic;
}
#authfinderops {
float: right;
}
/* jQuery UI Datepicker */
.ui-datepicker-trigger {
vertical-align: middle;

View file

@ -2,6 +2,11 @@
//<![CDATA[
$(document).ready(function(){
var searchButton = new YAHOO.widget.Button("search");
var cancelButton = new YAHOO.widget.Button("cancel");
var clearButton = new YAHOO.widget.Button("clear");
var newButton = new YAHOO.widget.Button("createnew");
// marclist
$( "#value_any" ).autocomplete({
source: function(request, response) {
@ -85,6 +90,11 @@ $(document).ready(function(){
});
});
function finderjumpfull(page)
{
window.open(page,'','fullscreen,scrollbars');
}
//]]>
</script>
@ -159,5 +169,10 @@ $(document).ready(function(){
<option value="HeadingDsc">Heading descendant</option>
</select>
</li></ol></fieldset>
<fieldset class="action"> <input type="submit" value="Start search" class="submit" /> <a class="cancel close" href="#">Cancel</a></fieldset>
<fieldset class="action"> <input type="submit" value="Start search" class="submit" id="search" /> <a id="cancel" class="cancel close" href="#">Cancel</a>
<span id="authfinderops">
<a href="javascript:finderjumpfull('blinddetail-biblio-search.pl?authid=0&amp;index=[% index %]')" id="clear" class="button">Clear field</a>
<a href="javascript:finderjumpfull('authorities.pl?index=[% index %]&authtypecode=[% authtypecode %]')" id="createnew" class="button">Create new</a>
</span>
</fieldset>
</form>

View file

@ -56,26 +56,6 @@ function jumpfull(page)
<th>Get it!</th>
<th>Other action</th>
</tr>
<tr>
<td>&nbsp;</td>
<td>&nbsp;</td>
<td>
<a href="javascript:jumpfull('blinddetail-biblio-search.pl?authid=0&amp;index=[% index %]')" class="button">
Clear
</a>
</td>
<td>&nbsp;</td>
</tr>
<tr>
<td>&nbsp;</td>
<td>&nbsp;</td>
<td>
<a href="javascript:jumpfull('authorities.pl?index=[% index %]&authtypecode=[% authtypecode %]')" class="button">
Create new
</a>
</td>
<td>&nbsp;</td>
</tr>
[% FOREACH resul IN result %]
<tr>
<td>[% PROCESS authresult summary=resul.summary %]</td>
@ -86,7 +66,7 @@ function jumpfull(page)
<a href="javascript:jumpfull('blinddetail-biblio-search.pl?authid=[% resul.authid %]&amp;index=[% repet.index %]&amps;repet=[% repet.repet %]')" title="[% repet.value %]">[% repet.repet %]</a>
[% END %]
[% ELSE %]
<a href="javascript:jumpfull('blinddetail-biblio-search.pl?authid=[% resul.authid %]&amp;index=[% index %]')">choose</a>
<a href="javascript:jumpfull('blinddetail-biblio-search.pl?authid=[% resul.authid %]&amp;index=[% index %]')">Choose</a>
[% END %]
</td>
<td><a href="authorities.pl?authid=[% resul.authid %]">Edit authority</a></td>