MT 1801 : Opac shelves and basket are displayed the same way
This patch also fixes broken location display in both shelves and basket.
This commit is contained in:
parent
f0aee34d3f
commit
6281ed6b91
4 changed files with 35 additions and 27 deletions
|
@ -191,6 +191,11 @@ SWITCH: {
|
|||
$this_item->{'imageurl'} = getitemtypeinfo($this_item->{'itemtype'})->{'imageurl'};
|
||||
$this_item->{'coins'} = GetCOinSBiblio($this_item->{'biblionumber'});
|
||||
$this_item->{'subtitle'} = C4::Biblio::get_koha_field_from_marc('bibliosubtitle', 'subtitle', $record, '');
|
||||
|
||||
# Getting items infos for location display
|
||||
my @items_infos = &GetItemsInfo($this_item->{'biblionumber'}, $type);
|
||||
$this_item->{'ITEM_RESULTS'} = \@items_infos;
|
||||
|
||||
}
|
||||
push @paramsloop, {display => 'privateshelves'} if $category == 1;
|
||||
$showadd = 1;
|
||||
|
|
|
@ -295,7 +295,7 @@ function tagAdded() {
|
|||
<th scope="row">Location(s)</th>
|
||||
<td><!-- TMPL_IF NAME="ITEM_RESULTS" --><!-- TMPL_LOOP NAME="ITEM_RESULTS" -->
|
||||
<p>
|
||||
<!-- TMPL_VAR NAME="branchname" --> <!-- TMPL_VAR NAME="location_description" -->
|
||||
<!-- TMPL_VAR NAME="branchname" --><!-- TMPL_IF NAME="location" -->, <!-- TMPL_VAR NAME="location" --><!-- /TMPL_IF -->
|
||||
<!-- TMPL_IF name="itemcallnumber" -->
|
||||
(<!-- TMPL_VAR NAME="itemcallnumber" -->)
|
||||
<!-- /TMPL_IF -->
|
||||
|
@ -333,7 +333,8 @@ function tagAdded() {
|
|||
<thead><tr>
|
||||
<th> </th>
|
||||
<th>Title</th>
|
||||
<th>Item Type</th>
|
||||
<th>Author</th>
|
||||
<th>Year</th>
|
||||
<th>Location</th>
|
||||
</tr></thead>
|
||||
|
||||
|
@ -347,27 +348,25 @@ function tagAdded() {
|
|||
<input type="checkbox" value="<!-- TMPL_VAR NAME="biblionumber" -->" name="bib<!-- TMPL_VAR NAME="biblionumber" -->" id="bib<!-- TMPL_VAR NAME="biblionumber" -->" onclick="selRecord(value,checked);" />
|
||||
|
||||
</td> <!-- /TMPL_UNLESS -->
|
||||
<td><a href="#" onclick="openBiblio('<!-- TMPL_VAR name="dest" -->',<!-- TMPL_VAR name="biblionumber" -->)">
|
||||
<td>
|
||||
<a href="#" onclick="openBiblio('<!-- TMPL_VAR name="dest" -->',<!-- TMPL_VAR name="biblionumber" -->)">
|
||||
<!-- TMPL_VAR NAME="title" escape="html" -->
|
||||
</a>
|
||||
<!-- TMPL_VAR NAME="author" -->
|
||||
<p><!-- TMPL_IF name="publishercode" -->- <!-- TMPL_VAR name="publishercode" -->
|
||||
<!-- TMPL_IF name="place" --> <!-- TMPL_VAR name="place" --><!-- /TMPL_IF --><!-- /TMPL_IF -->
|
||||
<!-- TMPL_IF name="pages" --> - <!-- TMPL_VAR name="pages" --><!-- TMPL_IF name="size" --> <!-- TMPL_VAR name="size" -->
|
||||
<!-- /TMPL_IF -->
|
||||
<!-- /TMPL_IF --></p>
|
||||
<!-- TMPL_IF name="notes" -->
|
||||
<p><!-- TMPL_VAR name="notes" --></p>
|
||||
<!-- /TMPL_IF -->
|
||||
<!-- COinS / OpenURL -->
|
||||
<span class="Z3988" title="ctx_ver=Z39.88-2004&rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Abook&rft.au=<!-- TMPL_VAR NAME="author" -->&rft.btitle=<!-- TMPL_VAR NAME="title" ESCAPE="url" -->&rft.date=<!-- TMPL_VAR NAME="publicationyear" -->&rft.tpages=<!-- TMPL_VAR NAME="size" -->&rft.isbn=<!-- TMPL_VAR NAME="isbn" ESCAPE="url" -->&rft.aucorp=&rft.place=<!-- TMPL_VAR NAME="place" -->&rft.pub=<!-- TMPL_VAR NAME="publisher" ESCAPE="url" -->&rft.edition=<!-- TMPL_VAR NAME="edition" -->&rft.series=<!-- TMPL_VAR NAME="series" -->&rft.genre="></span>
|
||||
<div id="newtag<!-- TMPL_VAR NAME="biblionumber">_status" class="tagstatus results_summary" style="display:none">Tag status here.</div>
|
||||
|
||||
</td>
|
||||
<td><!-- TMPL_VAR name="description" --></td>
|
||||
</a>
|
||||
<!-- COinS / OpenURL -->
|
||||
<span class="Z3988" title="ctx_ver=Z39.88-2004&rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Abook&rft.au=<!-- TMPL_VAR NAME="author" -->&rft.btitle=<!-- TMPL_VAR NAME="title" ESCAPE="url" -->&rft.date=<!-- TMPL_VAR NAME="publicationyear" -->&rft.tpages=<!-- TMPL_VAR NAME="size" -->&rft.isbn=<!-- TMPL_VAR NAME="isbn" ESCAPE="url" -->&rft.aucorp=&rft.place=<!-- TMPL_VAR NAME="place" -->&rft.pub=<!-- TMPL_VAR NAME="publisher" ESCAPE="url" -->&rft.edition=<!-- TMPL_VAR NAME="edition" -->&rft.series=<!-- TMPL_VAR NAME="series" -->&rft.genre="></span>
|
||||
<div id="newtag<!-- TMPL_VAR NAME="biblionumber">_status" class="tagstatus results_summary" style="display:none">Tag status here.</div>
|
||||
</td>
|
||||
<td><!-- TMPL_VAR NAME="author" --></td>
|
||||
<td>
|
||||
<!-- TMPL_IF NAME="publicationyear" -->
|
||||
<!-- TMPL_VAR NAME="publicationyear" -->
|
||||
<!-- TMPL_ELSE -->
|
||||
<!-- TMPL_VAR NAME="copyrightdate" -->
|
||||
<!-- /TMPL_IF -->
|
||||
</td>
|
||||
<td><!-- TMPL_IF NAME="ITEM_RESULTS" --><!-- TMPL_LOOP NAME="ITEM_RESULTS" -->
|
||||
<p>
|
||||
<!-- TMPL_VAR NAME="branchname" --> <!-- TMPL_VAR NAME="location_description" -->
|
||||
<!-- TMPL_VAR NAME="branchname" --><!-- TMPL_IF NAME="location" -->, <!-- TMPL_VAR NAME="location" --><!-- /TMPL_IF -->
|
||||
<!-- TMPL_IF name="itemcallnumber" -->
|
||||
(<!-- TMPL_VAR NAME="itemcallnumber" -->)
|
||||
<!-- /TMPL_IF -->
|
||||
|
|
|
@ -247,6 +247,7 @@ $(function() {
|
|||
<th>Title</th>
|
||||
<th>Author</th>
|
||||
<th>Year</th>
|
||||
<th>Location</th>
|
||||
</tr></thead>
|
||||
<tbody>
|
||||
<!-- TMPL_LOOP NAME="itemsloop" -->
|
||||
|
@ -278,6 +279,16 @@ $(function() {
|
|||
<!-- TMPL_VAR NAME="copyrightdate" -->
|
||||
<!-- /TMPL_IF -->
|
||||
</td>
|
||||
<td>
|
||||
<!-- TMPL_IF NAME="ITEM_RESULTS" --><!-- TMPL_LOOP NAME="ITEM_RESULTS" -->
|
||||
<p>
|
||||
<!-- TMPL_VAR NAME="branchname" --><!-- TMPL_IF NAME="location" -->, <!-- TMPL_VAR NAME="location" --><!-- /TMPL_IF -->
|
||||
<!-- TMPL_IF name="itemcallnumber" -->
|
||||
(<!-- TMPL_VAR NAME="itemcallnumber" -->)
|
||||
<!-- /TMPL_IF -->
|
||||
</p>
|
||||
<!-- /TMPL_LOOP --><!-- TMPL_ELSE -->This record has no items.<!-- /TMPL_IF -->
|
||||
</td>
|
||||
</tr>
|
||||
<!-- /TMPL_LOOP --><!-- /itemsloop -->
|
||||
</tbody>
|
||||
|
|
|
@ -73,15 +73,8 @@ foreach my $biblionumber ( @bibs ) {
|
|||
if($dat->{'author'} || @$marcauthorsarray) {
|
||||
$hasauthors = 1;
|
||||
}
|
||||
|
||||
my $shelflocations =GetKohaAuthorisedValues('items.location',$dat->{'frameworkcode'}, 'opac');
|
||||
my $collections = GetKohaAuthorisedValues('items.ccode',$dat->{'frameworkcode'}, 'opac');
|
||||
|
||||
for my $itm (@items) {
|
||||
if ($itm->{'location'}){
|
||||
$itm->{'location_description'} = $shelflocations->{$itm->{'location'} };
|
||||
}
|
||||
}
|
||||
# COinS format FIXME: for books Only
|
||||
my $coins_format;
|
||||
my $fmt = substr $record->leader(), 6,2;
|
||||
|
|
Loading…
Reference in a new issue