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

(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt (-12 / +41 lines)
Lines 47-53 var MSG_CONFIRM_RESUME_HOLDS = _("Are you sure you want to resume all suspended Link Here
47
            $("#renewall").submit();
47
            $("#renewall").submit();
48
        });
48
        });
49
        $("#checkoutst caption").append("<div id=\"renewcontrols\"><a id=\"renewselected_link\" href=\"#\">"+_("Renew selected")+"</a> <a id=\"renewall_link\" href=\"#\">"+_("Renew all")+"</a></div>");[% END %]
49
        $("#checkoutst caption").append("<div id=\"renewcontrols\"><a id=\"renewselected_link\" href=\"#\">"+_("Renew selected")+"</a> <a id=\"renewall_link\" href=\"#\">"+_("Renew all")+"</a></div>");[% END %]
50
        $( "#suspend_until" ).datepicker({ minDate: 1 }); // Require that "until date" be in the future
50
        $( ".suspend-until" ).datepicker({ minDate: 1 }); // Require that "until date" be in the future
51
            });
51
            });
52
//]]>
52
//]]>
53
</script>
53
</script>
Lines 351-370 var MSG_CONFIRM_RESUME_HOLDS = _("Are you sure you want to resume all suspended Link Here
351
        <div id="opac-user-holds">
351
        <div id="opac-user-holds">
352
        <table id="holdst">
352
        <table id="holdst">
353
        <caption>Holds <span class="count">([% reserves_count %] total)</span></caption>
353
        <caption>Holds <span class="count">([% reserves_count %] total)</span></caption>
354
            <!-- RESERVES TABLE ROWS -->
354
355
            <thead><tr>
355
        <!-- RESERVES TABLE ROWS -->
356
        <thead>
357
            <tr>
356
                <th>Title</th>
358
                <th>Title</th>
357
                <th class="psort">Placed on</th>
359
                <th class="psort">Placed on</th>
358
                [% IF OpacHoldNotes %]<th>Notes</th>[% END %]
360
                [% IF OpacHoldNotes %]
359
        <th>Expires on</th>
361
                    <th>Notes</th>
362
                [% END %]
363
                <th>Expires on</th>
360
                <th>Pick up location</th>
364
                <th>Pick up location</th>
361
		[% IF ( showpriority ) %]
365
                [% IF ( showpriority ) %]
362
			<th>Priority</th>
366
                    <th>Priority</th>
363
		[% END %]
367
                [% END %]
364
                <th>Status</th>
368
                <th>Status</th>
365
        <th class="nosort">Modify</th>
369
                <th class="nosort">Modify</th>
366
            </tr></thead>
370
                [% IF SuspendHoldsOpac %]
367
			<tbody>
371
                    <th class="nosort" >Suspend individual holds</th>
372
                [% END %]
373
            </tr>
374
        </thead>
375
        <tbody>
368
            [% FOREACH RESERVE IN RESERVES %]
376
            [% FOREACH RESERVE IN RESERVES %]
369
           [% IF ( RESERVE.wait ) %]
377
           [% IF ( RESERVE.wait ) %]
370
                        [% IF ( RESERVE.atdestination ) %]
378
                        [% IF ( RESERVE.atdestination ) %]
Lines 428-433 var MSG_CONFIRM_RESUME_HOLDS = _("Are you sure you want to resume all suspended Link Here
428
		[% END %]
436
		[% END %]
429
		</td>
437
		</td>
430
438
439
        [% IF SuspendHoldsOpac %]
440
            <td>
441
                [% IF ( RESERVE.cancelable ) %]
442
                    <form action="/cgi-bin/koha/opac-modrequest-suspend.pl" method="post">
443
                        <input type="hidden" name="reserve_id" value="[% RESERVE.reserve_id %]" />
444
445
                        [% IF RESERVE.suspend %]
446
                            <input type="submit" name="submit" value="Resume suspended hold" />
447
                        [% ELSE %]
448
                            <input type="submit" name="submit" class="icon delete cancel" value="Suspend hold" />
449
450
                            [% IF AutoResumeSuspendedHolds %]
451
                                <label for="suspend_until_[% RESERVE.reserve_id %]"> until </label>
452
                                <input name="suspend_until" id="suspend_until_[% RESERVE.reserve_id %]" class="suspend-until" readonly="readonly" size="10" />
453
                                <a href="#" style="font-size:85%;text-decoration:none;" onclick="document.getElementById('suspend_until_[% RESERVE.reserve_id %]').value='';return false;">Clear date</a>
454
                            [% END %]
455
                        [% END %]
456
                    </form>
457
                [% END %]
458
            </td>
459
        [% END %]
431
460
432
            </tr>
461
            </tr>
433
            [% END %]
462
            [% END %]
Lines 442-448 var MSG_CONFIRM_RESUME_HOLDS = _("Are you sure you want to resume all suspended Link Here
442
471
443
	      [% IF AutoResumeSuspendedHolds %]
472
	      [% IF AutoResumeSuspendedHolds %]
444
	      <label for="suspend_until"> until </label>
473
	      <label for="suspend_until"> until </label>
445
              <input name="suspend_until" id="suspend_until" readonly="readonly" size="10" />
474
              <input name="suspend_until" id="suspend_until" class="suspend-until" readonly="readonly" size="10" />
446
              <a href="#" style="font-size:85%;text-decoration:none;" onclick="document.getElementById('suspend_until').value='';return false;">Clear date</a></p>
475
              <a href="#" style="font-size:85%;text-decoration:none;" onclick="document.getElementById('suspend_until').value='';return false;">Clear date</a></p>
447
              [% END %]
476
              [% END %]
448
            </form>
477
            </form>
(-)a/opac/opac-modrequest-suspend.pl (-6 / +11 lines)
Lines 36-46 my ( $template, $borrowernumber, $cookie ) = get_template_and_user( Link Here
36
36
37
my $suspend       = $query->param('suspend');
37
my $suspend       = $query->param('suspend');
38
my $suspend_until = $query->param('suspend_until') || undef;
38
my $suspend_until = $query->param('suspend_until') || undef;
39
my $reserve_id    = $query->param('reserve_id');
39
40
40
SuspendAll(
41
if ($reserve_id) {
41
    borrowernumber => $borrowernumber,
42
    ToggleSuspend( $reserve_id, $suspend_until );
42
    suspend        => $suspend,
43
}
43
    suspend_until  => $suspend_until,
44
else {
44
);
45
    SuspendAll(
46
        borrowernumber => $borrowernumber,
47
        suspend        => $suspend,
48
        suspend_until  => $suspend_until,
49
    );
50
}
45
51
46
print $query->redirect("/cgi-bin/koha/opac-user.pl#opac-user-holds");
52
print $query->redirect("/cgi-bin/koha/opac-user.pl#opac-user-holds");
47
- 

Return to bug 10774