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

(-)a/circ/circulation.pl (-12 / +5 lines)
Lines 30-36 use DateTime::Duration; Link Here
30
use C4::Output;
30
use C4::Output;
31
use C4::Print;
31
use C4::Print;
32
use C4::Auth qw/:DEFAULT get_session haspermission/;
32
use C4::Auth qw/:DEFAULT get_session haspermission/;
33
use C4::Dates qw/format_date/;
34
use C4::Branch; # GetBranches
33
use C4::Branch; # GetBranches
35
use C4::Koha;   # GetPrinter
34
use C4::Koha;   # GetPrinter
36
use C4::Circulation;
35
use C4::Circulation;
Lines 167-178 if( $onsite_checkout && !$duedatespec_allow ) { Link Here
167
    $datedue .= ' 23:59:00';
166
    $datedue .= ' 23:59:00';
168
} elsif( $duedatespec_allow ) {
167
} elsif( $duedatespec_allow ) {
169
    if ($duedatespec) {
168
    if ($duedatespec) {
170
        if ($duedatespec =~ C4::Dates->regexp('syspref')) {
169
        output_pref({ dt => dt_from_string( $duedatespec ), dateformat => 'iso', dateonly => 1 });
171
                $datedue = dt_from_string($duedatespec);
172
        } else {
173
            $invalidduedate = 1;
174
            $template->param(IMPOSSIBLE=>1, INVALID_DATE=>$duedatespec);
175
        }
176
    }
170
    }
177
}
171
}
178
172
Lines 259-265 if ($borrowernumber) { Link Here
259
            noissues => ($force_allow_issue) ? 0 : "1",
253
            noissues => ($force_allow_issue) ? 0 : "1",
260
            forceallow => $force_allow_issue,
254
            forceallow => $force_allow_issue,
261
            expired => "1",
255
            expired => "1",
262
            renewaldate => format_date("$renew_year-$renew_month-$renew_day")
256
            renewaldate => "$renew_year-$renew_month-$renew_day"
263
        );
257
        );
264
    }
258
    }
265
    # check for NotifyBorrowerDeparture
259
    # check for NotifyBorrowerDeparture
Lines 268-274 if ($borrowernumber) { Link Here
268
            Date_to_Days( $today_year, $today_month, $today_day ) ) 
262
            Date_to_Days( $today_year, $today_month, $today_day ) ) 
269
    {
263
    {
270
        # borrower card soon to expire warn librarian
264
        # borrower card soon to expire warn librarian
271
        $template->param("warndeparture" => format_date($borrower->{dateexpiry}),
265
        $template->param("warndeparture" => $borrower->{dateexpiry},
272
        flagged       => "1",);
266
        flagged       => "1",);
273
        if (C4::Context->preference('ReturnBeforeExpiry')){
267
        if (C4::Context->preference('ReturnBeforeExpiry')){
274
            $template->param("returnbeforeexpiry" => 1);
268
            $template->param("returnbeforeexpiry" => 1);
Lines 287-294 if ($borrowernumber) { Link Here
287
        );
281
        );
288
282
289
        if ( $borrower->{debarred} ne "9999-12-31" ) {
283
        if ( $borrower->{debarred} ne "9999-12-31" ) {
290
            $template->param( 'userdebarreddate' =>
284
            $template->param( 'userdebarreddate' => $borrower->{debarred} );
291
                  C4::Dates::format_date( $borrower->{debarred} ) );
292
        }
285
        }
293
    }
286
    }
294
287
Lines 531-537 $template->param( Link Here
531
    printer           => $printer,
524
    printer           => $printer,
532
    printername       => $printer,
525
    printername       => $printer,
533
    was_renewed       => $query->param('was_renewed') ? 1 : 0,
526
    was_renewed       => $query->param('was_renewed') ? 1 : 0,
534
    expiry            => format_date($borrower->{'dateexpiry'}),
527
    expiry            => $borrower->{'dateexpiry'},
535
    roadtype          => $roadtype,
528
    roadtype          => $roadtype,
536
    amountold         => $amountold,
529
    amountold         => $amountold,
537
    barcode           => $barcode,
530
    barcode           => $barcode,
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt (-5 / +4 lines)
Lines 190-196 $(document).ready(function() { Link Here
190
</form>
190
</form>
191
</div>
191
</div>
192
192
193
[% IF ( was_renewed ) %]<div class="dialog message">Patron's account has been renewed until [% expiry %]</div>[% END %]
193
[% IF ( was_renewed ) %]<div class="dialog message">Patron's account has been renewed until [% expiry | $KohaDates %]</div>[% END %]
194
194
195
[% IF additional_materials %]
195
[% IF additional_materials %]
196
    <div id="materials" class="dialog message">Note about the accompanying materials: <br />
196
    <div id="materials" class="dialog message">Note about the accompanying materials: <br />
Lines 720-726 No patron matched <span class="ex">[% message %]</span> Link Here
720
720
721
			[% IF ( warndeparture ) %]
721
			[% IF ( warndeparture ) %]
722
			<li><span class="circ-hlt">Expiration:</span> Patron's card will expire soon.
722
			<li><span class="circ-hlt">Expiration:</span> Patron's card will expire soon.
723
			Patron's card expires on [% expiry %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% borrowernumber %]&amp;cardnumber=[% cardnumber %]&amp;destination=circ&amp;reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&amp;destination=circ&amp;borrowernumber=[% borrowernumber %]&amp;categorycode=[% categorycode %]">Edit Details</a>
723
                        Patron's card expires on [% expiry | $KohaDates %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% borrowernumber %]&amp;cardnumber=[% cardnumber %]&amp;destination=circ&amp;reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&amp;destination=circ&amp;borrowernumber=[% borrowernumber %]&amp;categorycode=[% categorycode %]">Edit Details</a>
724
724
725
			</li>
725
			</li>
726
			[% END %]
726
			[% END %]
Lines 733-739 No patron matched <span class="ex">[% message %]</span> Link Here
733
733
734
			[% IF ( expired ) %]
734
			[% IF ( expired ) %]
735
			<li><span class="circ-hlt">Expiration:</span> Patron's card has expired.
735
			<li><span class="circ-hlt">Expiration:</span> Patron's card has expired.
736
			[% IF ( expiry ) %]Patron's card expired on [% expiry %][% END %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% borrowernumber %]&amp;cardnumber=[% cardnumber %]&amp;destination=circ&amp;reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&amp;destination=circ&amp;borrowernumber=[% borrowernumber %]&amp;categorycode=[% categorycode %]">Edit Details</a>
736
                        [% IF ( expiry ) %]Patron's card expired on [% expiry | $KohaDates %][% END %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% borrowernumber %]&amp;cardnumber=[% cardnumber %]&amp;destination=circ&amp;reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&amp;destination=circ&amp;borrowernumber=[% borrowernumber %]&amp;categorycode=[% categorycode %]">Edit Details</a>
737
737
738
			</li>
738
			</li>
739
			[% END %]
739
			[% END %]
Lines 751-757 No patron matched <span class="ex">[% message %]</span> Link Here
751
                   <span class="circ-hlt"> Restricted:</span> Patron's account is restricted
751
                   <span class="circ-hlt"> Restricted:</span> Patron's account is restricted
752
752
753
                   [% IF ( userdebarreddate ) %]
753
                   [% IF ( userdebarreddate ) %]
754
                       until [% userdebarreddate %]
754
                       until [% userdebarreddate | $KohaDates %]
755
                   [% END %]
755
                   [% END %]
756
756
757
                   [% IF ( debarredcomment ) %]
757
                   [% IF ( debarredcomment ) %]
758
- 

Return to bug 14903