Bug 14356: Improvements to the 'Transfers to receive' page

Patch makes several small changes to the template for the
'Transfers to receive page'

1) Show the branch name instead of the branchcode in the
   table of incoming transfers.

If there is a hold connected with the transfer:
2) Show the patron's name as 'surname, firstname'
   intead of 'surname  firstname'
3) Restore broken feature: Show a mailto: link with a
   generated subject of 'Hold: <title>'.

The mailto: feature actually existed in the templates, but
was broken to a misnamed database column. I made some small
changes to make the subject translatable (see bug 8330).

To test:
- Create a transfer by placing a hold with pickup at another library
- Craete a transfer manually
- Go to the circulation > transfers to receive
- Check the changes explained above, compare before and after
- Check the mailto: link works as expected

Bonus: Check the Hold: bit in the subject is really translatable now.

Signed-off-by: Nick Clemens <nick@quecheelibrary.org>

Signed-off-by: Jonathan Druart <jonathan.druart@koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
Katrin Fischer 2015-06-08 01:30:58 +02:00 committed by Tomas Cohen Arazi
parent b61782f1e7
commit e5cea455d0
2 changed files with 9 additions and 6 deletions

View file

@ -105,7 +105,7 @@ foreach my $br ( keys %$branches ) {
$getransf{'borrowernum'} = $getborrower->{'borrowernumber'};
$getransf{'borrowername'} = $getborrower->{'surname'};
$getransf{'borrowerfirstname'} = $getborrower->{'firstname'};
$getransf{'borrowermail'} = $getborrower->{'emailaddress'} if $getborrower->{'emailaddress'};
$getransf{'borrowermail'} = $getborrower->{'email'} if $getborrower->{'email'};
$getransf{'borrowerphone'} = $getborrower->{'phone'};
}
push( @transferloop, \%getransf );

View file

@ -1,4 +1,5 @@
[% USE KohaDates %]
[% USE Branches %]
[% INCLUDE 'doc-head-open.inc' %]
<title>Koha &rsaquo; Circulation &rsaquo; Transfers to your library</title>
[% INCLUDE 'doc-head-close.inc' %]
@ -60,16 +61,18 @@ $(document).ready(function() {
<td><p><span title="[% reser.datetransfer %]">[% reser.datetransfer | $KohaDates %]</span></p> [% IF ( reser.messcompa ) %]<span class="error">Transfer is [% reser.diff %] days late</span>[% END %]</td>
<td>
[% INCLUDE 'biblio-default-view.inc' biblionumber = reser.biblionumber %][% reser.title |html %] [% IF ( reser.subtitle ) %] [% FOREACH subtitl IN reser.subtitle %][% subtitl.subfield %][% END %][% END %]</a> [% IF ( reser.author ) %]by [% reser.author %][% END %]
[% IF ( reser.itemtype ) %]&nbsp; (<b>[% reser.itemtype %]</b>)[% END %]
[% IF ( reser.itemtype ) %] (<b>[% reser.itemtype %]</b>)[% END %]
<br />Barcode: [% reser.barcode %]
</td>
<td>[% IF ( reser.borrowername ) %]
<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% reser.borrowernum %]">
[% reser.borrowername %] &nbsp; [% reser.borrowerfirstname %]
[% reser.borrowername %][%IF ( reser.borrowerfirstname ) %], [% reser.borrowerfirstname %][% END %]
</a>
<br />[% reser.borrowerphone %]<br />
[% IF ( reser.borrowerphone ) %]<br />[% reser.borrowerphone %][% END %]
[% IF ( reser.borrowermail ) %]
<a href="mailto:[% reser.email %]?subject=Reservation: [% reser.title |html %]">
<br />
[% BLOCK subject %]Hold:[% END %]
<a href="mailto:[% reser.borrowermail %]?subject=[% INCLUDE subject %] [% reser.title |html %]">
[% reser.borrowermail %]
</a>
[% END %]
@ -77,7 +80,7 @@ $(document).ready(function() {
<p>None</p>
[% END %]
</td>
<td>[% reser.homebranch %]</td>
<td>[% IF reser.homebranch %][% Branches.GetName( reser.homebranch ) %][% END %]</td>
<td>[% reser.itemcallnumber %]</td>
<td><a href="/cgi-bin/koha/circ/returns.pl?itemnumber=[% reser.itemnumber %]&amp;canceltransfer=1&amp;dest=ttr">Cancel transfer</a></td>
</tr>