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

(-)a/circ/pendingreserves.pl (-1 / +9 lines)
Lines 215-221 my $strsth = Link Here
215
            count(DISTINCT items.itemnumber) as icount,
215
            count(DISTINCT items.itemnumber) as icount,
216
            count(DISTINCT reserves.borrowernumber) as rcount,
216
            count(DISTINCT reserves.borrowernumber) as rcount,
217
            borrowers.firstname,
217
            borrowers.firstname,
218
            borrowers.surname
218
            borrowers.surname,
219
            borrowers.branchcode as bbranch
219
    FROM  reserves
220
    FROM  reserves
220
        LEFT JOIN items ON items.biblionumber=reserves.biblionumber 
221
        LEFT JOIN items ON items.biblionumber=reserves.biblionumber 
221
        LEFT JOIN biblio ON reserves.biblionumber=biblio.biblionumber
222
        LEFT JOIN biblio ON reserves.biblionumber=biblio.biblionumber
Lines 249-254 $strsth .= " GROUP BY reserves.biblionumber ORDER BY biblio.title "; Link Here
249
my $sth = $dbh->prepare($strsth);
250
my $sth = $dbh->prepare($strsth);
250
$sth->execute(@query_params);
251
$sth->execute(@query_params);
251
252
253
my $cancel_notify_templates = Koha::Notice::Templates->search({ module => 'reserves', code => 'HOLD_CANCELLATION' });
254
my $cancel_notice_exists;
255
while ( my $notice = $cancel_notify_templates->next ) {
256
    $cancel_notice_exists->{$notice->branchcode} = 1;
257
}
258
252
while ( my $data = $sth->fetchrow_hashref ) {
259
while ( my $data = $sth->fetchrow_hashref ) {
253
    push(
260
    push(
254
        @reservedata, {
261
        @reservedata, {
Lines 280-285 while ( my $data = $sth->fetchrow_hashref ) { Link Here
280
            homebranch       => $data->{homebranch},
287
            homebranch       => $data->{homebranch},
281
            itemnumber       => $data->{itemnumber},
288
            itemnumber       => $data->{itemnumber},
282
            publicationyear  => C4::Context->preference('marcflavour') eq "MARC21" ? $data->{copyrightdate} : $data->{publicationyear},
289
            publicationyear  => C4::Context->preference('marcflavour') eq "MARC21" ? $data->{copyrightdate} : $data->{publicationyear},
290
            cancel_notify    => exists($cancel_notice_exists->{$data->{bbranch}}) ? 1 : exists($cancel_notice_exists->{''}),
283
        }
291
        }
284
    );
292
    );
285
}
293
}
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/pendingreserves.tt (-6 / +8 lines)
Lines 167-182 Link Here
167
                                <option value="[% reason.authorised_value | html %]">[% reason.lib | html %]</option>
167
                                <option value="[% reason.authorised_value | html %]">[% reason.lib | html %]</option>
168
                            [% END %]
168
                            [% END %]
169
                        </select>
169
                        </select>
170
171
                        <input type="checkbox" name="cancellation-notify-patron" id="cancellation-notify-patron" value="1" checked/>
172
                        <label for="cancellation-notify-patron">Notify patron</label>
173
                    </div>
170
                    </div>
174
                [% END %]
171
                [% END %]
175
172
176
                [% IF reserveloo.holdingbranch != reserveloo.homebranch %]
173
                [% IF reserveloo.holdingbranch != reserveloo.homebranch %]
177
                    <input class="btn btn-default" type="submit" value="Cancel hold and return to : [% Branches.GetName( reserveloo.homebranch ) | html %]" />
174
                <button class="btn btn-default" name="cancellation-notify-patron" value="0" type="submit">Cancel hold and return to : [% Branches.GetName( reserveloo.homebranch ) | html %]</button>
175
                [% IF reserveloo.cancel_notify %]
176
                <button class="btn btn-default" name="cancellation-notify-patron" value="1" type="submit">Cancel hold, notify and return to : [% Branches.GetName( reserveloo.homebranch ) | html %]</button
177
                [% END %]
178
                [% ELSE %]
178
                [% ELSE %]
179
                    <input class="btn btn-default" type="submit" value="Cancel hold" />
179
                <button class="btn btn-default" name="cancellation-notify-patron" value="0" type="submit">Cancel hold</button>
180
                [% IF reserveloo.cancel_notify %]
181
                <button class="btn btn-default" name="cancellation-notify-patron" value="1" type="submit">Cancel hold and notify</button>
182
                [% END %]
180
                [% END %]
183
                [% END %]
181
            </form>
184
            </form>
182
185
183
- 

Return to bug 26282