From ef612e566767fbc1283e2d42c14bee14450c64f0 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Wed, 31 Dec 2008 14:28:38 -0600 Subject: [PATCH] Providing options for adding to order when existing record search has failed. I've duplicated the "Add to Order" block on the search results page to display after a user has searched for an existing record to add to an order. This block is displayed whether or not results were found on the assumption that a non-empty result set may not contain the desired result. Changes to neworderbiblio.pl allow supplier name to appear in breadcrumb nav. Signed-off-by: Galen Charlton --- acqui/neworderbiblio.pl | 20 +++++++++---------- .../prog/en/css/staff-global.css | 5 +++++ .../prog/en/modules/acqui/basket.tmpl | 8 ++++---- .../prog/en/modules/acqui/neworderbiblio.tmpl | 16 +++++++++++++-- 4 files changed, 32 insertions(+), 17 deletions(-) diff --git a/acqui/neworderbiblio.pl b/acqui/neworderbiblio.pl index 9682e7507f..824b664b2d 100755 --- a/acqui/neworderbiblio.pl +++ b/acqui/neworderbiblio.pl @@ -76,6 +76,7 @@ my $results_per_page = $params->{'num'} || 20; my $booksellerid = $params->{'booksellerid'}; my $basketno = $params->{'basketno'}; my $sub = $params->{'sub'}; +my $bookseller = GetBookSellerFromId($booksellerid); # getting the template my ( $template, $loggedinuser, $cookie ) = get_template_and_user( @@ -92,8 +93,13 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user( my ($error, $marcresults, $total_hits) = SimpleSearch($query, $results_per_page * ($page - 1), $results_per_page); if (defined $error) { - $template->param(query_error => $error); warn "error: ".$error; + $template->param( + query_error => $error, + basketno => $basketno, + booksellerid => $bookseller->{'id'}, + name => $bookseller->{'name'}, + ); output_html_with_http_headers $input, $cookie, $template->output; exit; } @@ -114,19 +120,11 @@ foreach my $i ( 0 .. scalar @$marcresults ) { $template->param( basketno => $basketno, - booksellerid => $booksellerid, + booksellerid => $bookseller->{'id'}, + name => $bookseller->{'name'}, resultsloop => \@results, total => $total_hits, query => $query, - virtualshelves => C4::Context->preference("virtualshelves"), - LibraryName => C4::Context->preference("LibraryName"), - OpacNav => C4::Context->preference("OpacNav"), - opaccredits => C4::Context->preference("opaccredits"), - AmazonContent => C4::Context->preference("AmazonContent"), - opacsmallimage => C4::Context->preference("opacsmallimage"), - opaclayoutstylesheet => C4::Context->preference("opaclayoutstylesheet"), - opaccolorstylesheet => C4::Context->preference("opaccolorstylesheet"), - "BiblioDefaultView".C4::Context->preference("IntranetBiblioDefaultView") => 1, pagination_bar => pagination_bar( "$ENV{'SCRIPT_NAME'}?q=$query&booksellerid=$booksellerid&", getnbpages( $total_hits, $results_per_page ), $page, 'page' ), ); diff --git a/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css b/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css index d51db246d5..c9f302d208 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css +++ b/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css @@ -1407,6 +1407,11 @@ input[type=reset]:active, input[type=button]:active, input.submit:active, button border : 1px inset #999999; } +ul li input.submit { + font-size : 87%; + padding : 2px; +} + .searchhighlightblob { font-size:75%; font-style : italic; diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tmpl index e423e6d751..79436b355d 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tmpl +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tmpl @@ -157,18 +157,18 @@
-
-

Add To Order

+
+ Add To Order
" /> " />
-
+ diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tmpl index a5f090317f..c600b8cd9c 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tmpl +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tmpl @@ -7,7 +7,7 @@ - +
@@ -26,7 +26,6 @@

No results match your search for in

-Perform a new search @@ -78,6 +77,19 @@
+
+ Add To Order +
+ " /> + " /> + +
+
+
-- 2.20.1