View | Details | Raw Unified | Return to bug 31028
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/biblio-title.inc (-27 / +27 lines)
Lines 1-31 Link Here
1
[% IF ( link ) %]
1
[%- IF ( link ) -%]
2
    <a href="[% PROCESS biblio_a_href biblionumber => biblio.biblionumber %]" class="title">
2
    <a href="[%- PROCESS biblio_a_href biblionumber => biblio.biblionumber -%]" class="title">
3
[% END %]
3
[%- END -%]
4
4
5
[% IF ( biblio.title ) %]
5
[%- IF ( biblio.title ) -%]
6
    <span class="biblio-title">[% biblio.title | html %]</span>
6
    <span class="biblio-title">[%- biblio.title | html -%]</span>
7
[% ELSE %]
7
[%- ELSE -%]
8
    <span>No title</span>
8
    <span>No title</span>
9
[% END %]
9
[%- END -%]
10
[% IF ( biblio.medium ) %]
10
[%- IF ( biblio.medium ) -%]
11
    <span class="biblio-medium">[% biblio.medium | html %]</span>
11
    <span class="biblio-medium">[%- biblio.medium | html -%]</span>
12
[% END %]
12
[%- END -%]
13
[% FOREACH subtitle IN biblio.subtitle.split(' \\| ') %][% IF Koha.Preference('marcflavour')=='UNIMARC' %],[% END %]
13
[%- FOREACH subtitle IN biblio.subtitle.split(' \\| ') -%][%- IF Koha.Preference('marcflavour')=='UNIMARC' -%],[%- END -%]
14
    <span class="subtitle">[% subtitle | html %]</span>
14
    <span class="subtitle">[%- subtitle | html -%]</span>
15
[% END %]
15
[%- END -%]
16
[% part_numbers = biblio.part_number.split(' \\| ') %]
16
[%- part_numbers = biblio.part_number.split(' \\| ') -%]
17
[% part_names = biblio.part_name.split(' \\| ') %]
17
[%- part_names = biblio.part_name.split(' \\| ') -%]
18
[% i = 0 %]
18
[%- i = 0 -%]
19
[% WHILE ( part_numbers.$i.defined || part_names.$i.defined ) %]
19
[%- WHILE ( part_numbers.$i.defined || part_names.$i.defined ) -%]
20
    [% IF ( part_numbers.$i.defined ) %]
20
    [%- IF ( part_numbers.$i.defined ) -%]
21
        <span class="part-number">[% part_numbers.$i | html %]</span>
21
        <span class="part-number">[%- part_numbers.$i | html -%]</span>
22
    [% END %]
22
    [%- END -%]
23
    [% IF ( part_names.$i.defined ) %]
23
    [%- IF ( part_names.$i.defined ) -%]
24
        <span class="part-name">[% part_names.$i | html %]</span>
24
        <span class="part-name">[%- part_names.$i | html -%]</span>
25
    [% END %]
25
    [%- END -%]
26
    [% i = i + 1 %]
26
    [%- i = i + 1 -%]
27
[% END %]
27
[%- END -%]
28
28
29
[% IF ( link ) %]
29
[%- IF ( link ) -%]
30
    </a>
30
    </a>
31
[% END %]
31
[%- END -%]
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-title.inc (-23 / +22 lines)
Lines 30-52 Link Here
30
    [%- SET data.borrowernumber = borrowernumber -%]
30
    [%- SET data.borrowernumber = borrowernumber -%]
31
    [%- SET data.title          = title -%]
31
    [%- SET data.title          = title -%]
32
[%- END -%]
32
[%- END -%]
33
[%# Parameter no_html - if 1, the html tags are NOT generated %]
33
[%# Parameter no_html - if 1, the html tags are NOT generated -%]
34
[%- IF no_title %][% SET data.title = "" %][% END -%]
34
[%- IF no_title -%][%- SET data.title = "" -%][%- END -%]
35
[%- IF data.title %]
35
[%- IF data.title -%]
36
    [%- IF no_html %]
36
    [%- IF no_html -%]
37
        [%- span_start = '' %]
37
        [%- span_start = '' -%]
38
        [%- span_end   = '' %]
38
        [%- span_end   = '' -%]
39
    [%- ELSE %]
39
    [%- ELSE -%]
40
        [%- span_start = '<span class="patron-title">' %]
40
        [%- span_start = '<span class="patron-title">' -%]
41
        [%- span_end   = '</span>' %]
41
        [%- span_end   = '</span>' -%]
42
    [%- END %]
42
    [%- END -%]
43
    [% data.title = data.title | html %]
43
    [%- data.title = data.title | html -%]
44
    [%- SET data.title = span_start _ data.title _ span_end _ ' ' -%]
44
    [%- SET data.title = span_start _ data.title _ span_end _ ' ' -%]
45
[%- END -%]
45
[%- END -%]
46
[%- SET display_patron_name = 1 -%]
46
[%- SET display_patron_name = 1 -%]
47
[%- SET display_cardnumber = 1 -%]
47
[%- SET display_cardnumber = 1 -%]
48
[%- IF no_cardnumber %][% SET display_cardnumber = 0 %][% END -%]
48
[%- IF no_cardnumber -%][%- SET display_cardnumber = 0 -%][%- END -%]
49
[%- IF hide_patron_infos_if_needed %] [%# Should only be set if patron is set -%]
49
[%- IF hide_patron_infos_if_needed -%] [%# Should only be set if patron is set -%]
50
    [%- SET can_see_patron_infos = logged_in_user.can_see_patron_infos( patron ) -%]
50
    [%- SET can_see_patron_infos = logged_in_user.can_see_patron_infos( patron ) -%]
51
    [%- UNLESS can_see_patron_infos -%]
51
    [%- UNLESS can_see_patron_infos -%]
52
        [%- SET display_patron_name = 0 -%]
52
        [%- SET display_patron_name = 0 -%]
Lines 56-82 Link Here
56
    [%- END -%]
56
    [%- END -%]
57
[%- END -%]
57
[%- END -%]
58
[%- IF hide_patron_infos_if_needed AND ( display_patron_name OR display_cardnumber ) -%]
58
[%- IF hide_patron_infos_if_needed AND ( display_patron_name OR display_cardnumber ) -%]
59
    [%- IF link_to == 'circulation_reserves' %]<a href="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[% data.borrowernumber | uri %]#reserves">
59
    [%- IF link_to == 'circulation_reserves' -%]<a href="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[%- data.borrowernumber | uri -%]#reserves">
60
    [%- ELSIF link_to == 'circulation_recalls' %]<a href="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[% data.borrowernumber | uri %]#recalls">
60
    [%- ELSIF link_to == 'circulation_recalls' -%]<a href="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[%- data.borrowernumber | uri -%]#recalls">
61
    [%- ELSIF link_to == 'members_pay' %]<a href="/cgi-bin/koha/members/pay.pl?borrowernumber=[% patron.borrowernumber | uri %]">
61
    [%- ELSIF link_to == 'members_pay' -%]<a href="/cgi-bin/koha/members/pay.pl?borrowernumber=[%- patron.borrowernumber | uri -%]">
62
    [%- ELSE %]<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% data.borrowernumber | uri %]">
62
    [%- ELSE -%]<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[%- data.borrowernumber | uri -%]">
63
    [%- END -%]
63
    [%- END -%]
64
[%- END -%]
64
[%- END -%]
65
[%- IF display_patron_name -%]
65
[%- IF display_patron_name -%]
66
    [%- IF data.category_type == 'I' -%]
66
    [%- IF data.category_type == 'I' -%]
67
        [%- data.surname | html %] [% IF data.othernames %] ([% data.othernames | html %])[% END -%]
67
        [%- data.surname | html -%] [%- IF data.othernames -%] ([%- data.othernames | html -%])[%- END -%]
68
    [%- ELSIF invert_name -%]
68
    [%- ELSIF invert_name -%]
69
        [% data.title | $raw %][%- data.surname | html %][% IF ( data.firstname ) %], [% data.firstname | html %][% END %][% IF data.middle_name %] [% data.middle_name | html %][% END %][% IF data.othernames %] ([% data.othernames | html %]) [% END -%]
69
        [%- data.title | $raw -%][%- data.surname | html -%][%- IF ( data.firstname ) -%], [%- data.firstname | html -%][%- END -%][%- IF data.middle_name -%] [%- data.middle_name | html -%][%- END -%][%- IF data.othernames -%] ([%- data.othernames | html -%]) [%- END -%]
70
    [%- ELSE -%]
70
    [%- ELSE -%]
71
        [% data.title | $raw %][%- data.firstname | html %][% IF data.middle_name %] [% data.middle_name | html %][% END %][% IF data.othernames %] ([% data.othernames | html %]) [% END %] [% data.surname | html -%]
71
        [%- data.title | $raw -%][%- data.firstname | html -%][%- IF data.middle_name -%] [%- data.middle_name | html -%][%- END -%][%- IF data.othernames -%] ([%- data.othernames | html -%]) [%- END -%] [%- data.surname | html -%]
72
    [%- END -%]
72
    [%- END -%]
73
    [%- IF display_cardnumber AND data.cardnumber %] ([% data.cardnumber | html %])[% END -%]
73
    [%- IF display_cardnumber AND data.cardnumber -%] ([%- data.cardnumber | html -%])[%- END -%]
74
[%- ELSIF display_cardnumber -%]
74
[%- ELSIF display_cardnumber -%]
75
    [%- IF data.cardnumber -%][%# FIXME Cardnumber should always be defined, right? -%]
75
    [%- IF data.cardnumber -%][%# FIXME Cardnumber should always be defined, right? -%]
76
        [%- data.cardnumber | html -%]
76
        [%- data.cardnumber | html -%]
77
    [%- END -%]
77
    [%- END -%]
78
[%- ELSE -%]
78
[%- ELSE -%]
79
    <span>A patron from library [% Branches.GetName( patron.branchcode ) | html -%]</span>
79
    <span>A patron from library [%- Branches.GetName( patron.branchcode ) | html -%]</span>
80
[%- END -%]
80
[%- END -%]
81
81
82
[%- IF hide_patron_infos_if_needed AND ( display_patron_name OR display_cardnumber ) -%]
82
[%- IF hide_patron_infos_if_needed AND ( display_patron_name OR display_cardnumber ) -%]
83
- 

Return to bug 31028