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

(-)a/circ/set-library.pl (-2 / +2 lines)
Lines 64-71 if ( Link Here
64
        $session->param('branch', $branch);                 # update sesssion in DB
64
        $session->param('branch', $branch);                 # update sesssion in DB
65
        push @updated, {
65
        push @updated, {
66
            updated_branch => 1,
66
            updated_branch => 1,
67
                old_branch => $userenv_branch,
67
                old_branch => Koha::Libraries->find( $userenv_branch )->branchname,
68
                new_branch => $branch,
68
                new_branch => Koha::Libraries->find( $branch )->branchname,
69
        };
69
        };
70
    } # else branch the same, no update
70
    } # else branch the same, no update
71
    if ( $desk_id && (!$userenv_desk or $userenv_desk ne $desk_id) ) {
71
    if ( $desk_id && (!$userenv_desk or $userenv_desk ne $desk_id) ) {
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/set-library.tt (-37 / +39 lines)
Lines 52-93 Link Here
52
                <h1>Set library</h1>
52
                <h1>Set library</h1>
53
53
54
[% IF ( updated ) %]
54
[% IF ( updated ) %]
55
55
    <fieldset class="rows">
56
<h2>Update succeeded</h2>
56
        <legend>Update succeeded</legend>
57
Updated:<ul>
57
        <ul>
58
    [% FOREACH update IN updated %]
58
            [% FOREACH update IN updated %]
59
    [% IF ( update.updated_branch || update.updated_desk ||  update.updated_register ) %]
59
                [% IF ( update.updated_branch || update.updated_desk ||  update.updated_register ) %]
60
        [% IF ( update.updated_branch ) %]
60
                    [% IF ( update.updated_branch ) %]
61
        <li>Library: [% update.old_branch or "?" | html %] &rArr; [% update.new_branch or "?" | html %]</li>
61
                        <li>Library updated from <strong>[% update.old_branch or "?" | html %]</strong> to <strong>[% update.new_branch or "?" | html %]</strong>.</li>
62
        [% END %]
62
                    [% END %]
63
        [% IF ( update.updated_desk ) %]
63
                    [% IF ( update.updated_desk ) %]
64
        <li>Desk: [% update.old_desk or "?" | html %] &rArr; [% LoginDeskname or "?" | html %]</li>
64
                        <li>Desk updated from <strong>[% update.old_desk or "?" | html %]</strong> to <strong>[% LoginDeskname or "?" | html %]</strong>.</li>
65
        [% END %]
65
                    [% END %]
66
        [% IF ( updated.updated_register ) %]
66
                    [% IF ( update.updated_register ) %]
67
        <li>Register: [% updated.old_register or "?" | html %] &rArr; [% Registers.session_register_name or "?" | html %]</li>
67
                        <li>Register updated from <strong>[% update.old_register or "?" | html %]</strong> to <strong>[% Registers.session_register_name or "?" | html %]</strong>.</li>
68
        [% END %]
68
                    [% END %]
69
    [% ELSE %]
69
                [% ELSE %]
70
        <li>ERROR - unknown</li>
70
                    <li>ERROR - unknown</li>
71
    [% END %]
71
                [% END %]
72
    [% END %]
72
            [% END %]
73
    </ul>
73
        </ul>
74
<form method="post" action="[% referer or "/cgi-bin/koha/circ/circulation.pl" %]">
74
    </fieldset>
75
    [% INCLUDE 'csrf-token.inc' %]
75
    <form method="post" action="[% referer or "/cgi-bin/koha/circ/circulation.pl" %]">
76
    <div class="noshow">
76
        [% INCLUDE 'csrf-token.inc' %]
77
        [% FOREACH recycle_loo IN recycle_loop %]
77
        <div class="noshow">
78
            [% SET param = recycle_loo.param %]
78
            [% FOREACH recycle_loo IN recycle_loop %]
79
            [% NEXT IF param == 'op' %]
79
                [% SET param = recycle_loo.param %]
80
            [% NEXT IF param == 'csrf_token' %]
80
                [% NEXT IF param == 'op' %]
81
            [% IF param == 'original_op' %][% param = 'op' %][% END %]
81
                [% NEXT IF param == 'csrf_token' %]
82
            <input type="text" name="[% param | html %]" value="[% recycle_loo.value | html %]" />
82
                [% IF param == 'original_op' %][% param = 'op' %][% END %]
83
            [% IF param == 'op' %][% SET has_op = 1 %][% END %]
83
                <input type="text" name="[% param | html %]" value="[% recycle_loo.value | html %]" />
84
        [% END %]
84
                [% IF param == 'op' %][% SET has_op = 1 %][% END %]
85
        [% UNLESS has_op %]
85
            [% END %]
86
            <input type="hidden" name="op" value="cud-no-op" /> [%# Trick to pass anti-CSRF requirements %]
86
            [% UNLESS has_op %]
87
        [% END %]
87
                <input type="hidden" name="op" value="cud-no-op" /> [%# Trick to pass anti-CSRF requirements %]
88
    </div>
88
            [% END %]
89
    <button type="submit">Continue</button>
89
        </div>
90
</form>
90
        <fieldset class="action">
91
            <button class="btn btn-primary" type="submit">Continue</button>
92
        </fieldset>
93
    </form>
91
94
92
[% ELSE %]
95
[% ELSE %]
93
96
94
- 

Return to bug 36237