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

(-)a/C4/Circulation.pm (-21 / +87 lines)
Lines 684-691 sub CanBookBeIssued { Link Here
684
684
685
        my $branch = _GetCircControlBranch($item,$borrower);
685
        my $branch = _GetCircControlBranch($item,$borrower);
686
        my $itype = ( C4::Context->preference('item-level_itypes') ) ? $item->{'itype'} : $biblioitem->{'itemtype'};
686
        my $itype = ( C4::Context->preference('item-level_itypes') ) ? $item->{'itype'} : $biblioitem->{'itemtype'};
687
        my $loanlength = GetLoanLength( $borrower->{'categorycode'}, $itype, $branch );
687
        $duedate = CalcDateDue( C4::Dates->new( $issuedate, 'iso' ), $itype, $branch, $borrower );
688
        $duedate = CalcDateDue( C4::Dates->new( $issuedate, 'iso' ), $loanlength, $branch, $borrower );
689
688
690
        # Offline circ calls AddIssue directly, doesn't run through here
689
        # Offline circ calls AddIssue directly, doesn't run through here
691
        #  So issuingimpossible should be ok.
690
        #  So issuingimpossible should be ok.
Lines 1042-1049 sub AddIssue { Link Here
1042
          );
1041
          );
1043
        unless ($datedue) {
1042
        unless ($datedue) {
1044
            my $itype = ( C4::Context->preference('item-level_itypes') ) ? $biblio->{'itype'} : $biblio->{'itemtype'};
1043
            my $itype = ( C4::Context->preference('item-level_itypes') ) ? $biblio->{'itype'} : $biblio->{'itemtype'};
1045
            my $loanlength = GetLoanLength( $borrower->{'categorycode'}, $itype, $branch );
1044
            $datedue = CalcDateDue( C4::Dates->new( $issuedate, 'iso' ), $itype, $branch, $borrower );
1046
            $datedue = CalcDateDue( C4::Dates->new( $issuedate, 'iso' ), $loanlength, $branch, $borrower );
1047
1045
1048
        }
1046
        }
1049
        $sth->execute(
1047
        $sth->execute(
Lines 1173-1178 sub GetLoanLength { Link Here
1173
    return 21;
1171
    return 21;
1174
}
1172
}
1175
1173
1174
1175
=head2 GetHardDueDate
1176
1177
  my ($hardduedate,$hardduedatecompare) = &GetHardDueDate($borrowertype,$itemtype,branchcode)
1178
1179
Get the Hard Due Date and it's comparison for an itemtype, a borrower type and a branch
1180
1181
=cut
1182
1183
sub GetHardDueDate {
1184
    my ( $borrowertype, $itemtype, $branchcode ) = @_;
1185
    my $dbh = C4::Context->dbh;
1186
    my $sth =
1187
      $dbh->prepare(
1188
"select hardduedate, hardduedatecompare from issuingrules where categorycode=? and itemtype=? and branchcode=?"
1189
      );
1190
    $sth->execute( $borrowertype, $itemtype, $branchcode );
1191
    my $results = $sth->fetchrow_hashref;
1192
    return (C4::Dates->new($results->{hardduedate}, 'iso'),$results->{hardduedatecompare})
1193
      if defined($results) && $results->{hardduedate} ne 'NULL';
1194
1195
    $sth->execute( $borrowertype, "*", $branchcode );
1196
    $results = $sth->fetchrow_hashref;
1197
    return (C4::Dates->new($results->{hardduedate}, 'iso'),$results->{hardduedatecompare})
1198
      if defined($results) && $results->{hardduedate} ne 'NULL';
1199
1200
    $sth->execute( "*", $itemtype, $branchcode );
1201
    $results = $sth->fetchrow_hashref;
1202
    return (C4::Dates->new($results->{hardduedate}, 'iso'),$results->{hardduedatecompare})
1203
      if defined($results) && $results->{hardduedate} ne 'NULL';
1204
1205
    $sth->execute( "*", "*", $branchcode );
1206
    $results = $sth->fetchrow_hashref;
1207
    return (C4::Dates->new($results->{hardduedate}, 'iso'),$results->{hardduedatecompare})
1208
      if defined($results) && $results->{hardduedate} ne 'NULL';
1209
1210
    $sth->execute( $borrowertype, $itemtype, "*" );
1211
    $results = $sth->fetchrow_hashref;
1212
    return (C4::Dates->new($results->{hardduedate}, 'iso'),$results->{hardduedatecompare})
1213
      if defined($results) && $results->{hardduedate} ne 'NULL';
1214
1215
    $sth->execute( $borrowertype, "*", "*" );
1216
    $results = $sth->fetchrow_hashref;
1217
    return (C4::Dates->new($results->{hardduedate}, 'iso'),$results->{hardduedatecompare})
1218
      if defined($results) && $results->{hardduedate} ne 'NULL';
1219
1220
    $sth->execute( "*", $itemtype, "*" );
1221
    $results = $sth->fetchrow_hashref;
1222
    return (C4::Dates->new($results->{hardduedate}, 'iso'),$results->{hardduedatecompare})
1223
      if defined($results) && $results->{hardduedate} ne 'NULL';
1224
1225
    $sth->execute( "*", "*", "*" );
1226
    $results = $sth->fetchrow_hashref;
1227
    return (C4::Dates->new($results->{hardduedate}, 'iso'),$results->{hardduedatecompare})
1228
      if defined($results) && $results->{hardduedate} ne 'NULL';
1229
1230
    # if no rule is set => return undefined
1231
    return (undef, undef);
1232
}
1233
1176
=head2 GetIssuingRule
1234
=head2 GetIssuingRule
1177
1235
1178
  my $irule = &GetIssuingRule($borrowertype,$itemtype,branchcode)
1236
  my $irule = &GetIssuingRule($borrowertype,$itemtype,branchcode)
Lines 2197-2211 sub AddRenewal { Link Here
2197
    unless ($datedue) {
2255
    unless ($datedue) {
2198
2256
2199
        my $borrower = C4::Members::GetMemberDetails( $borrowernumber, 0 ) or return undef;
2257
        my $borrower = C4::Members::GetMemberDetails( $borrowernumber, 0 ) or return undef;
2200
        my $loanlength = GetLoanLength(
2258
        my $itemtype = (C4::Context->preference('item-level_itypes')) ? $biblio->{'itype'} : $biblio->{'itemtype'} ,
2201
                    $borrower->{'categorycode'},
2202
                    (C4::Context->preference('item-level_itypes')) ? $biblio->{'itype'} : $biblio->{'itemtype'} ,
2203
			        $issuedata->{'branchcode'}  );   # that's the circ control branch.
2204
2259
2205
        $datedue = (C4::Context->preference('RenewalPeriodBase') eq 'date_due') ?
2260
        $datedue = (C4::Context->preference('RenewalPeriodBase') eq 'date_due') ?
2206
                                        C4::Dates->new($issuedata->{date_due}, 'iso') :
2261
                                        C4::Dates->new($issuedata->{date_due}, 'iso') :
2207
                                        C4::Dates->new();
2262
                                        C4::Dates->new();
2208
        $datedue =  CalcDateDue($datedue,$loanlength,$issuedata->{'branchcode'},$borrower);
2263
        $datedue =  CalcDateDue($datedue,$itemtype,$issuedata->{'branchcode'},$borrower);
2209
    }
2264
    }
2210
2265
2211
    # Update the issues record to have the new due date, and a new count
2266
    # Update the issues record to have the new due date, and a new count
Lines 2589-2605 sub UpdateHoldingbranch { Link Here
2589
2644
2590
=head2 CalcDateDue
2645
=head2 CalcDateDue
2591
2646
2592
$newdatedue = CalcDateDue($startdate,$loanlength,$branchcode);
2647
$newdatedue = CalcDateDue($startdate,$itemtype,$branchcode,$borrower);
2593
this function calculates the due date given the loan length ,
2648
2649
this function calculates the due date given the start date and configured circulation rules,
2594
checking against the holidays calendar as per the 'useDaysMode' syspref.
2650
checking against the holidays calendar as per the 'useDaysMode' syspref.
2595
C<$startdate>   = C4::Dates object representing start date of loan period (assumed to be today)
2651
C<$startdate>   = C4::Dates object representing start date of loan period (assumed to be today)
2652
C<$itemtype>  = itemtype code of item in question
2596
C<$branch>  = location whose calendar to use
2653
C<$branch>  = location whose calendar to use
2597
C<$loanlength>  = loan length prior to adjustment
2654
C<$borrower> = Borrower object
2598
=cut
2655
=cut
2599
2656
2600
sub CalcDateDue { 
2657
sub CalcDateDue { 
2601
	my ($startdate,$loanlength,$branch,$borrower) = @_;
2658
	my ($startdate,$itemtype,$branch,$borrower) = @_;
2602
	my $datedue;
2659
	my $datedue;
2660
        my $loanlength = GetLoanLength($borrower->{'categorycode'},$itemtype, $branch);
2603
2661
2604
	if(C4::Context->preference('useDaysMode') eq 'Days') {  # ignoring calendar
2662
	if(C4::Context->preference('useDaysMode') eq 'Days') {  # ignoring calendar
2605
		my $timedue = time + ($loanlength) * 86400;
2663
		my $timedue = time + ($loanlength) * 86400;
Lines 2611-2629 sub CalcDateDue { Link Here
2611
		$datedue = $calendar->addDate($startdate, $loanlength);
2669
		$datedue = $calendar->addDate($startdate, $loanlength);
2612
	}
2670
	}
2613
2671
2672
	# if Hard Due Dates are used, retreive them and apply as necessary
2673
        my ($hardduedate, $hardduedatecompare) = GetHardDueDate($borrower->{'categorycode'},$itemtype, $branch);
2674
	if ( $hardduedate->output('iso') && $hardduedate->output('iso') ne '0000-00-00') {
2675
            # if the calculated due date is after the 'before' Hard Due Date (ceiling), override
2676
            if ( $datedue->output( 'iso' ) gt $hardduedate->output( 'iso' ) && $hardduedatecompare == -1) {
2677
                $datedue = $hardduedate;
2678
            # if the calculated date is before the 'after' Hard Due Date (floor), override
2679
            } elsif ( $datedue->output( 'iso' ) lt $hardduedate->output( 'iso' ) && $hardduedatecompare == 1) {
2680
                $datedue = $hardduedate;               
2681
            # if the hard due date is set to 'exactly', overrride
2682
            } elsif ( $hardduedatecompare == 0) {
2683
                $datedue = $hardduedate;
2684
            }
2685
            # in all other cases, keep the date due as it is
2686
	}
2687
2614
	# if ReturnBeforeExpiry ON the datedue can't be after borrower expirydate
2688
	# if ReturnBeforeExpiry ON the datedue can't be after borrower expirydate
2615
	if ( C4::Context->preference('ReturnBeforeExpiry') && $datedue->output('iso') gt $borrower->{dateexpiry} ) {
2689
	if ( C4::Context->preference('ReturnBeforeExpiry') && $datedue->output('iso') gt $borrower->{dateexpiry} ) {
2616
	    $datedue = C4::Dates->new( $borrower->{dateexpiry}, 'iso' );
2690
	    $datedue = C4::Dates->new( $borrower->{dateexpiry}, 'iso' );
2617
	}
2691
	}
2618
2692
2619
	# if ceilingDueDate ON the datedue can't be after the ceiling date
2620
	if ( C4::Context->preference('ceilingDueDate')
2621
             && ( C4::Context->preference('ceilingDueDate') =~ C4::Dates->regexp('syspref') ) ) {
2622
            my $ceilingDate = C4::Dates->new( C4::Context->preference('ceilingDueDate') );
2623
            if ( $datedue->output( 'iso' ) gt $ceilingDate->output( 'iso' ) ) {
2624
                $datedue = $ceilingDate;
2625
            }
2626
	}
2627
2693
2628
	return $datedue;
2694
	return $datedue;
2629
}
2695
}
(-)a/admin/smart-rules.pl (-4 / +16 lines)
Lines 26-31 use C4::Auth; Link Here
26
use C4::Koha;
26
use C4::Koha;
27
use C4::Debug;
27
use C4::Debug;
28
use C4::Branch; # GetBranches
28
use C4::Branch; # GetBranches
29
use C4::Dates qw/format_date format_date_in_iso/;
29
30
30
my $input = new CGI;
31
my $input = new CGI;
31
my $dbh = C4::Context->dbh;
32
my $dbh = C4::Context->dbh;
Lines 100-107 elsif ($op eq 'delete-branch-item') { Link Here
100
# save the values entered
101
# save the values entered
101
elsif ($op eq 'add') {
102
elsif ($op eq 'add') {
102
    my $sth_search = $dbh->prepare("SELECT COUNT(*) AS total FROM issuingrules WHERE branchcode=? AND categorycode=? AND itemtype=?");
103
    my $sth_search = $dbh->prepare("SELECT COUNT(*) AS total FROM issuingrules WHERE branchcode=? AND categorycode=? AND itemtype=?");
103
    my $sth_insert = $dbh->prepare("INSERT INTO issuingrules (branchcode, categorycode, itemtype, maxissueqty, renewalsallowed, reservesallowed, issuelength, fine, finedays, firstremind, chargeperiod,rentaldiscount) VALUES(?,?,?,?,?,?,?,?,?,?,?,?)");
104
    my $sth_insert = $dbh->prepare("INSERT INTO issuingrules (branchcode, categorycode, itemtype, maxissueqty, renewalsallowed, reservesallowed, issuelength, hardduedate, hardduedatecompare, fine, finedays, firstremind, chargeperiod,rentaldiscount) VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?)");
104
    my $sth_update=$dbh->prepare("UPDATE issuingrules SET fine=?, finedays=?, firstremind=?, chargeperiod=?, maxissueqty=?, renewalsallowed=?, reservesallowed=?, issuelength=?, rentaldiscount=?  WHERE branchcode=? AND categorycode=? AND itemtype=?");
105
    my $sth_update=$dbh->prepare("UPDATE issuingrules SET fine=?, finedays=?, firstremind=?, chargeperiod=?, maxissueqty=?, renewalsallowed=?, reservesallowed=?, issuelength=?, hardduedate=?, hardduedatecompare=?, rentaldiscount=?  WHERE branchcode=? AND categorycode=? AND itemtype=?");
105
    
106
    
106
    my $br = $branch; # branch
107
    my $br = $branch; # branch
107
    my $bor  = $input->param('categorycode'); # borrower category
108
    my $bor  = $input->param('categorycode'); # borrower category
Lines 116-130 elsif ($op eq 'add') { Link Here
116
    $maxissueqty =~ s/\s//g;
117
    $maxissueqty =~ s/\s//g;
117
    $maxissueqty = undef if $maxissueqty !~ /^\d+/;
118
    $maxissueqty = undef if $maxissueqty !~ /^\d+/;
118
    my $issuelength  = $input->param('issuelength');
119
    my $issuelength  = $input->param('issuelength');
120
    my $hardduedate = $input->param('hardduedate');
121
    $hardduedate = format_date_in_iso($hardduedate);
122
    my $hardduedatecompare = $input->param('hardduedatecompare');
119
    my $rentaldiscount = $input->param('rentaldiscount');
123
    my $rentaldiscount = $input->param('rentaldiscount');
120
    $debug and warn "Adding $br, $bor, $cat, $fine, $maxissueqty";
124
    $debug and warn "Adding $br, $bor, $cat, $fine, $maxissueqty";
121
125
122
    $sth_search->execute($br,$bor,$cat);
126
    $sth_search->execute($br,$bor,$cat);
123
    my $res = $sth_search->fetchrow_hashref();
127
    my $res = $sth_search->fetchrow_hashref();
124
    if ($res->{total}) {
128
    if ($res->{total}) {
125
        $sth_update->execute($fine, $finedays,$firstremind, $chargeperiod, $maxissueqty, $renewalsallowed,$reservesallowed, $issuelength,$rentaldiscount, $br,$bor,$cat);
129
        $sth_update->execute($fine, $finedays,$firstremind, $chargeperiod, $maxissueqty, $renewalsallowed,$reservesallowed, $issuelength,$hardduedate,$hardduedatecompare,$rentaldiscount, $br,$bor,$cat);
126
    } else {
130
    } else {
127
        $sth_insert->execute($br,$bor,$cat,$maxissueqty,$renewalsallowed,$reservesallowed,$issuelength,$fine,$finedays,$firstremind,$chargeperiod,$rentaldiscount);
131
        $sth_insert->execute($br,$bor,$cat,$maxissueqty,$renewalsallowed,$reservesallowed,$issuelength,$hardduedate,$hardduedatecompare,$fine,$finedays,$firstremind,$chargeperiod,$rentaldiscount);
128
    }
132
    }
129
} 
133
} 
130
elsif ($op eq "set-branch-defaults") {
134
elsif ($op eq "set-branch-defaults") {
Lines 377-382 while (my $row = $sth2->fetchrow_hashref) { Link Here
377
    $row->{'humancategorycode'} ||= $row->{'categorycode'};
381
    $row->{'humancategorycode'} ||= $row->{'categorycode'};
378
    $row->{'default_humancategorycode'} = 1 if $row->{'humancategorycode'} eq '*';
382
    $row->{'default_humancategorycode'} = 1 if $row->{'humancategorycode'} eq '*';
379
    $row->{'fine'} = sprintf('%.2f', $row->{'fine'});
383
    $row->{'fine'} = sprintf('%.2f', $row->{'fine'});
384
    if ($row->{'hardduedate'} ne '0000-00-00') {
385
       $row->{'hardduedate'} = format_date( $row->{'hardduedate'});
386
       $row->{'hardduedatebefore'} = 1 if ($row->{'hardduedatecompare'} == -1);
387
       $row->{'hardduedateexact'} = 1 if ($row->{'hardduedatecompare'} ==  0);
388
       $row->{'hardduedateafter'} = 1 if ($row->{'hardduedatecompare'} ==  1);
389
    } else {
390
       $row->{'hardduedate'} = 0;
391
    }
380
    push @row_loop, $row;
392
    push @row_loop, $row;
381
}
393
}
382
$sth->finish;
394
$sth->finish;
(-)a/admin/systempreferences.pl (-2 lines)
Lines 162-168 $tabsysprefs{IssuingInProcess} = "Circulation"; Link Here
162
$tabsysprefs{patronimages}                   = "Circulation";
162
$tabsysprefs{patronimages}                   = "Circulation";
163
$tabsysprefs{printcirculationslips}          = "Circulation";
163
$tabsysprefs{printcirculationslips}          = "Circulation";
164
$tabsysprefs{ReturnBeforeExpiry}             = "Circulation";
164
$tabsysprefs{ReturnBeforeExpiry}             = "Circulation";
165
$tabsysprefs{ceilingDueDate}                 = "Circulation";
166
$tabsysprefs{SpecifyDueDate}                 = "Circulation";
165
$tabsysprefs{SpecifyDueDate}                 = "Circulation";
167
$tabsysprefs{AutomaticItemReturn}            = "Circulation";
166
$tabsysprefs{AutomaticItemReturn}            = "Circulation";
168
$tabsysprefs{ReservesMaxPickUpDelay}         = "Circulation";
167
$tabsysprefs{ReservesMaxPickUpDelay}         = "Circulation";
Lines 175-181 $tabsysprefs{canreservefromotherbranches} = "Circulation"; Link Here
175
$tabsysprefs{finesMode}                      = "Circulation";
174
$tabsysprefs{finesMode}                      = "Circulation";
176
$tabsysprefs{numReturnedItemsToShow}         = "Circulation";
175
$tabsysprefs{numReturnedItemsToShow}         = "Circulation";
177
$tabsysprefs{emailLibrarianWhenHoldIsPlaced} = "Circulation";
176
$tabsysprefs{emailLibrarianWhenHoldIsPlaced} = "Circulation";
178
$tabsysprefs{globalDueDate}                  = "Circulation";
179
$tabsysprefs{itemBarcodeInputFilter}         = "Circulation";
177
$tabsysprefs{itemBarcodeInputFilter}         = "Circulation";
180
$tabsysprefs{WebBasedSelfCheck}              = "Circulation";
178
$tabsysprefs{WebBasedSelfCheck}              = "Circulation";
181
$tabsysprefs{ShowPatronImageInWebBasedSelfCheck} = "Circulation";
179
$tabsysprefs{ShowPatronImageInWebBasedSelfCheck} = "Circulation";
(-)a/circ/circulation.pl (-17 / +1 lines)
Lines 136-146 if ( $barcode ) { Link Here
136
    }
136
    }
137
}
137
}
138
138
139
my ($datedue,$invalidduedate,$globalduedate);
139
my ($datedue,$invalidduedate);
140
140
141
if(C4::Context->preference('globalDueDate') && (C4::Context->preference('globalDueDate') =~ C4::Dates->regexp('syspref'))){
142
        $globalduedate = C4::Dates->new(C4::Context->preference('globalDueDate'));
143
}
144
my $duedatespec_allow = C4::Context->preference('SpecifyDueDate');
141
my $duedatespec_allow = C4::Context->preference('SpecifyDueDate');
145
if($duedatespec_allow){
142
if($duedatespec_allow){
146
    if ($duedatespec) {
143
    if ($duedatespec) {
Lines 157-172 if($duedatespec_allow){ Link Here
157
            $invalidduedate = 1;
154
            $invalidduedate = 1;
158
            $template->param(IMPOSSIBLE=>1, INVALID_DATE=>$duedatespec);
155
            $template->param(IMPOSSIBLE=>1, INVALID_DATE=>$duedatespec);
159
        }
156
        }
160
    } else {
161
        # pass global due date to tmpl if specifyduedate is true 
162
        # and we have no barcode (loading circ page but not checking out)
163
        if($globalduedate &&  ! $barcode ){
164
            $duedatespec = $globalduedate->output();
165
            $stickyduedate = 1;
166
        }
167
    }
157
    }
168
} else {
169
    $datedue = $globalduedate if ($globalduedate);
170
}
158
}
171
159
172
my $todaysdate = C4::Dates->new->output('iso');
160
my $todaysdate = C4::Dates->new->output('iso');
Lines 311-320 if ($barcode) { Link Here
311
        unless($confirm_required) {
299
        unless($confirm_required) {
312
            AddIssue( $borrower, $barcode, $datedue, $cancelreserve );
300
            AddIssue( $borrower, $barcode, $datedue, $cancelreserve );
313
            $inprocess = 1;
301
            $inprocess = 1;
314
            if($globalduedate && ! $stickyduedate && $duedatespec_allow ){
315
                $duedatespec = $globalduedate->output();
316
                $stickyduedate = 1;
317
            }
318
        }
302
        }
319
    }
303
    }
320
    
304
    
(-)a/installer/data/mysql/de-DE/mandatory/sysprefs.sql (-2 lines)
Lines 150-157 INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES Link Here
150
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
150
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
151
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
151
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
152
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines).  Requires accruefines cronjob.','off|test|production','Choice');
152
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines).  Requires accruefines cronjob.','off|test|production','Choice');
153
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('globalDueDate','','If set, allows a global static due date for all checkouts','10','free');
154
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ceilingDueDate','','If set, date due will not be past this date.  Enter date according to the dateformat System Preference',NULL,'free');
155
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
153
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
156
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
154
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
157
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
155
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
(-)a/installer/data/mysql/en/mandatory/sysprefs.sql (-2 lines)
Lines 151-158 INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES Link Here
151
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
151
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
152
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
152
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
153
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines).  Requires accruefines cronjob.','off|test|production','Choice');
153
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines).  Requires accruefines cronjob.','off|test|production','Choice');
154
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('globalDueDate','','If set, allows a global static due date for all checkouts','10','free');
155
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ceilingDueDate','','If set, date due will not be past this date.  Enter date according to the dateformat System Preference',NULL,'free');
156
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat|libsuite8','Choice');
154
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat|libsuite8','Choice');
157
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
155
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
158
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
156
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
(-)a/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql (-2 lines)
Lines 151-158 INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES Link Here
151
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'Si activé, envoie un mail à la bibliothèque lorsqu''une réservation est posée',NULL,'YesNo');
151
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'Si activé, envoie un mail à la bibliothèque lorsqu''une réservation est posée',NULL,'YesNo');
152
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Nombre d''exemplaires rendus à afficher sur la page de retour',NULL,'Integer');
152
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Nombre d''exemplaires rendus à afficher sur la page de retour',NULL,'Integer');
153
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choisissez un mode pour le calcul des amendes : Test ou Production.','test|production','Choice');
153
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choisissez un mode pour le calcul des amendes : Test ou Production.','test|production','Choice');
154
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('globalDueDate','','Si défini, autorise une date de retour statique pour tous les prêts','10','free');
155
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ceilingDueDate','','Si présent, les dates de retour des prêts ne pourront être antérieures à cette date. Formatez cette date conformément à la préférence système dateformat.',NULL,'free');
156
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','Si activé, permet de définir le format des codes à barre','whitespace|T-prefix|cuecat','Choice');
154
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','Si activé, permet de définir le format des codes à barre','whitespace|T-prefix|cuecat','Choice');
157
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Activer s''il n''y a qu''une seule bibliothèque sur ce catalogue, cela cache le sélecteur de bibliothèque inutile',NULL,'YesNo');
155
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Activer s''il n''y a qu''une seule bibliothèque sur ce catalogue, cela cache le sélecteur de bibliothèque inutile',NULL,'YesNo');
158
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Texte à afficher dans l''ancre du logo de l''OPAC',NULL,'free');
156
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Texte à afficher dans l''ancre du logo de l''OPAC',NULL,'free');
(-)a/installer/data/mysql/it-IT/necessari/sysprefs.sql (-2 lines)
Lines 61-67 insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, Link Here
61
-- insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('FrameworksLoaded','auth_val.sql|authority_framework.sql|class_sources.sql|message_transport_types.sql|notices.sql|parameters.sql|patron_categories.sql|sample_holidays.sql|sample_itemtypes.sql|sample_labels.sql|sample_news.sql|sample_notices_message_attributes.sql|sample_notices_message_transports.sql|stopwords.sql|subtag_registry.sql|sysprefs.sql|unimarc_framework.sql|userflags.sql|userpermissions.sql',NULL,'Frameworks loaded through webinstaller','choice');
61
-- insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('FrameworksLoaded','auth_val.sql|authority_framework.sql|class_sources.sql|message_transport_types.sql|notices.sql|parameters.sql|patron_categories.sql|sample_holidays.sql|sample_itemtypes.sql|sample_labels.sql|sample_news.sql|sample_notices_message_attributes.sql|sample_notices_message_transports.sql|stopwords.sql|subtag_registry.sql|sysprefs.sql|unimarc_framework.sql|userflags.sql|userpermissions.sql',NULL,'Frameworks loaded through webinstaller','choice');
62
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('FRBRizeEditions','1','','Se ON, Koha farà delle richieste a uno o più ISBN web services per trovare gli ISBN associabili e li visualizzarà in un tab \'Edizioni\' nella visualizzazione dettagliata','YesNo');
62
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('FRBRizeEditions','1','','Se ON, Koha farà delle richieste a uno o più ISBN web services per trovare gli ISBN associabili e li visualizzarà in un tab \'Edizioni\' nella visualizzazione dettagliata','YesNo');
63
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('gist','0','','Valore predefinito per la Goods and Services  tax (l\'IVA) calcolato non in %, ma in forma numerica (0.12 for 12%), impostare a 0 per disabilitarla.','Float');
63
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('gist','0','','Valore predefinito per la Goods and Services  tax (l\'IVA) calcolato non in %, ma in forma numerica (0.12 for 12%), impostare a 0 per disabilitarla.','Float');
64
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('globalDueDate','','10','Se impostata forza un’unica data di scadenza per tutti i prestiti','free');
65
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('GoogleJackets','1','','Se ON, visualizza le copertine usando Google Books','YesNo');
64
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('GoogleJackets','1','','Se ON, visualizza le copertine usando Google Books','YesNo');
66
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('hidelostitems','0','','Se ON, viene disabilitata la visualizzazione nell\'OPAC delle copie perse.','YesNo');
65
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('hidelostitems','0','','Se ON, viene disabilitata la visualizzazione nell\'OPAC delle copie perse.','YesNo');
67
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('hide_marc','0','','Se su ON, disabilita la visualizzazione dei campi del MARC, codici di sottocampi e indicatori (mostra ancora i dati)','YesNo');
66
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('hide_marc','0','','Se su ON, disabilita la visualizzazione dei campi del MARC, codici di sottocampi e indicatori (mostra ancora i dati)','YesNo');
Lines 224-230 INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES Link Here
224
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('casAuthentication', '0', 'Enable or disable CAS authentication', '', 'YesNo');
223
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('casAuthentication', '0', 'Enable or disable CAS authentication', '', 'YesNo');
225
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('casLogout', '0', 'Does a logout from Koha should also log the user out of CAS?', '', 'YesNo');
224
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('casLogout', '0', 'Does a logout from Koha should also log the user out of CAS?', '', 'YesNo');
226
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('casServerUrl', 'https://localhost:8443/cas', 'URL of the cas server', '', 'Free');
225
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('casServerUrl', 'https://localhost:8443/cas', 'URL of the cas server', '', 'Free');
227
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ceilingDueDate','','If set, date due will not be past this date.  Enter date according to the dateformat System Preference',NULL,'free');
228
INSERT INTO `systempreferences` (variable,value,options,explanation,type)  VALUES ('CurrencyFormat','FR','US|FR','Determines the display format of currencies. eg: \'36000\' is displayed as \'360 000,00\'  in \'FR\' or \'360,000.00\'  in \'US\'.','Choice');
226
INSERT INTO `systempreferences` (variable,value,options,explanation,type)  VALUES ('CurrencyFormat','FR','US|FR','Determines the display format of currencies. eg: \'36000\' is displayed as \'360 000,00\'  in \'FR\' or \'360,000.00\'  in \'US\'.','Choice');
229
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('DisplayMultiPlaceHold','1','Display the ability to place multiple holds or not','','YesNo');
227
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('DisplayMultiPlaceHold','1','Display the ability to place multiple holds or not','','YesNo');
230
INSERT INTO systempreferences (variable,value,options,explanation,type)VALUES('DisplayOPACiconsXSLT', '1', '', 'If ON, displays the format, audience, type icons in XSLT MARC21 results and display pages.', 'YesNo');
228
INSERT INTO systempreferences (variable,value,options,explanation,type)VALUES('DisplayOPACiconsXSLT', '1', '', 'If ON, displays the format, audience, type icons in XSLT MARC21 results and display pages.', 'YesNo');
(-)a/installer/data/mysql/kohastructure.sql (+2 lines)
Lines 965-970 CREATE TABLE `issuingrules` ( Link Here
965
  `chargename` varchar(100) default NULL,
965
  `chargename` varchar(100) default NULL,
966
  `maxissueqty` int(4) default NULL,
966
  `maxissueqty` int(4) default NULL,
967
  `issuelength` int(4) default NULL,
967
  `issuelength` int(4) default NULL,
968
  `hardduedate` date default NULL,
969
  `hardduedatecompare` tinyint NOT NULL default "0",
968
  `renewalsallowed` smallint(6) NOT NULL default "0",
970
  `renewalsallowed` smallint(6) NOT NULL default "0",
969
  `reservesallowed` smallint(6) NOT NULL default "0",
971
  `reservesallowed` smallint(6) NOT NULL default "0",
970
  `branchcode` varchar(10) NOT NULL default '',
972
  `branchcode` varchar(10) NOT NULL default '',
(-)a/installer/data/mysql/pl-PL/mandatory/sysprefs.sql (-2 lines)
Lines 149-156 INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES Link Here
149
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
149
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
150
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
150
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
151
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines).  Requires accruefines cronjob.','off|test|production','Choice');
151
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines).  Requires accruefines cronjob.','off|test|production','Choice');
152
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('globalDueDate','','If set, allows a global static due date for all checkouts','10','free');
153
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ceilingDueDate','','If set, date due will not be past this date.  Enter date according to the dateformat System Preference',NULL,'free');
154
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
152
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
155
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
153
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
156
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
154
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
(-)a/installer/data/mysql/ru-RU/mandatory/system_preferences_full_optimal_for_install_only.sql (-2 lines)
Lines 177-183 INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES Link Here
177
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('noItemTypeImages',0,'If ON, disables item-type images',NULL,'YesNo');
177
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('noItemTypeImages',0,'If ON, disables item-type images',NULL,'YesNo');
178
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
178
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
179
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines).  Requires accruefines cronjob.','off|test|production','Choice');
179
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines).  Requires accruefines cronjob.','off|test|production','Choice');
180
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('globalDueDate','','If set, allows a global static due date for all checkouts','10','free');
181
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
180
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
182
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
181
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
183
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
182
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
Lines 286-292 INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES Link Here
286
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('intranetbookbag','1','If ON, enables display of Cart feature in the intranet','','YesNo');
285
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('intranetbookbag','1','If ON, enables display of Cart feature in the intranet','','YesNo');
287
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('opacSerialDefaultTab', 'subscriptions', 'Define the default tab for serials in OPAC.', 'holdings|serialcollection|subscriptions', 'Choice');
286
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('opacSerialDefaultTab', 'subscriptions', 'Define the default tab for serials in OPAC.', 'holdings|serialcollection|subscriptions', 'Choice');
288
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
287
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
289
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ceilingDueDate','','If set, date due will not be past this date.  Enter date according to the dateformat System Preference',NULL,'free');
290
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OAI-PMH:ConfFile','','If empty, Koha OAI Server operates in normal mode, otherwise it operates in extended mode.',NULL,'File');
288
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OAI-PMH:ConfFile','','If empty, Koha OAI Server operates in normal mode, otherwise it operates in extended mode.',NULL,'File');
291
('OPACXSLTDetailsDisplay','0','','Enable XSL stylesheet control over details page display on OPAC','YesNo'),
289
('OPACXSLTDetailsDisplay','0','','Enable XSL stylesheet control over details page display on OPAC','YesNo'),
292
('OPACXSLTResultsDisplay','0','','Enable XSL stylesheet control over results page display on OPAC','YesNo'),
290
('OPACXSLTResultsDisplay','0','','Enable XSL stylesheet control over results page display on OPAC','YesNo'),
(-)a/installer/data/mysql/uk-UA/mandatory/system_preferences_full_optimal_for_install_only.sql (-2 lines)
Lines 176-182 INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES Link Here
176
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('noItemTypeImages',0,'If ON, disables item-type images',NULL,'YesNo');
176
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('noItemTypeImages',0,'If ON, disables item-type images',NULL,'YesNo');
177
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
177
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
178
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines).  Requires accruefines cronjob.','off|test|production','Choice');
178
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines).  Requires accruefines cronjob.','off|test|production','Choice');
179
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('globalDueDate','','If set, allows a global static due date for all checkouts','10','free');
180
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
179
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
181
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
180
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
182
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
181
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
Lines 311-317 INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES Link Here
311
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('intranetbookbag','1','If ON, enables display of Cart feature in the intranet','','YesNo');
310
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('intranetbookbag','1','If ON, enables display of Cart feature in the intranet','','YesNo');
312
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('opacSerialDefaultTab', 'subscriptions', 'Define the default tab for serials in OPAC.', 'holdings|serialcollection|subscriptions', 'Choice');
311
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('opacSerialDefaultTab', 'subscriptions', 'Define the default tab for serials in OPAC.', 'holdings|serialcollection|subscriptions', 'Choice');
313
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
312
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
314
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ceilingDueDate','','If set, date due will not be past this date.  Enter date according to the dateformat System Preference',NULL,'free');
315
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OAI-PMH:ConfFile','','If empty, Koha OAI Server operates in normal mode, otherwise it operates in extended mode.',NULL,'File');
313
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OAI-PMH:ConfFile','','If empty, Koha OAI Server operates in normal mode, otherwise it operates in extended mode.',NULL,'File');
316
('OPACXSLTDetailsDisplay','0','','Enable XSL stylesheet control over details page display on OPAC','YesNo'),
314
('OPACXSLTDetailsDisplay','0','','Enable XSL stylesheet control over details page display on OPAC','YesNo'),
317
('OPACXSLTResultsDisplay','0','','Enable XSL stylesheet control over results page display on OPAC','YesNo'),
315
('OPACXSLTResultsDisplay','0','','Enable XSL stylesheet control over results page display on OPAC','YesNo'),
(-)a/installer/data/mysql/updatedatabase.pl (+18 lines)
Lines 37-42 use Getopt::Long; Link Here
37
# Koha modules
37
# Koha modules
38
use C4::Context;
38
use C4::Context;
39
use C4::Installer;
39
use C4::Installer;
40
use C4::Dates;
40
41
41
use MARC::Record;
42
use MARC::Record;
42
use MARC::File::XML ( BinaryEncoding => 'utf8' );
43
use MARC::File::XML ( BinaryEncoding => 'utf8' );
Lines 4134-4139 if (C4::Context->preference("Version") < TransformToNum($DBversion)) { Link Here
4134
    SetVersion ($DBversion);
4135
    SetVersion ($DBversion);
4135
}
4136
}
4136
4137
4138
$DBversion = '3.03.00.XXX';
4139
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
4140
    $dbh->do("ALTER TABLE `issuingrules` ADD hardduedate date default NULL AFTER issuelength");
4141
    $dbh->do("ALTER TABLE `issuingrules` ADD hardduedatecompare tinyint NOT NULL default 0 AFTER hardduedate");
4142
    my $duedate;
4143
    if (C4::Context->preference("globalDueDate")) {
4144
      $duedate = C4::Dates::format_date_in_iso(C4::Context->preference("globalDueDate"));
4145
      $dbh->do("UPDATE `issuingrules` SET hardduedate = '$duedate', hardduedatecompare = 0");
4146
    } elsif (C4::Context->preference("ceilingDueDate")) {
4147
      $duedate = C4::Dates::format_date_in_iso(C4::Context->preference("ceilingDueDate"));
4148
      $dbh->do("UPDATE `issuingrules` SET hardduedate = '$duedate', hardduedatecompare = -1");
4149
    }
4150
    $dbh->do("DELETE FROM `systempreferences` WHERE variable = 'globalDueDate' OR variable = 'ceilingDueDate'");
4151
    print "Upgrade to $DBversion done (Move global and ceiling due dates to Circ Rules level)\n";
4152
    SetVersion ($DBversion);
4153
}
4154
4137
=head1 FUNCTIONS
4155
=head1 FUNCTIONS
4138
4156
4139
=head2 DropAllForeignKeys($table)
4157
=head2 DropAllForeignKeys($table)
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref (-10 lines)
Lines 148-163 Circulation: Link Here
148
                  homebranch: the library the item is from.
148
                  homebranch: the library the item is from.
149
                  holdingbranch: the library the item was checked out from.
149
                  holdingbranch: the library the item was checked out from.
150
        -
150
        -
151
            - Make all checkouts have a due date of
152
            - pref: globalDueDate
153
              class: date
154
            - .
155
        -
156
            - Make all checkouts due on or before
157
            - pref: ceilingDueDate
158
              class: date
159
            - .
160
        -
161
            - Calculate the due date using 
151
            - Calculate the due date using 
162
            - pref: useDaysMode
152
            - pref: useDaysMode
163
              choices:
153
              choices:
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smart-rules.tmpl (-2 / +37 lines)
Lines 12-18 $(document).ready(function() { Link Here
12
});
12
});
13
//]]>
13
//]]>
14
</script>
14
</script>
15
15
<!-- Enable Calendar system -->
16
<link rel="stylesheet" type="text/css" href="<!-- TMPL_VAR name="themelang" -->/lib/calendar/calendar-system.css" />
17
<script type="text/javascript" src="<!-- TMPL_VAR name="themelang" -->/lib/calendar/calendar.js"></script>
18
<script type="text/javascript" src="<!-- TMPL_VAR name="themelang" -->/lib/calendar/calendar-en.js"></script>
19
<script type="text/javascript" src="<!-- TMPL_VAR name="themelang" -->/lib/calendar/calendar-setup.js"></script>
20
<!-- End Calendar system additions -->
16
</head>
21
</head>
17
<body>
22
<body>
18
<!-- TMPL_INCLUDE NAME="header.inc" -->
23
<!-- TMPL_INCLUDE NAME="header.inc" -->
Lines 68-73 for="tobranch"><strong>Clone these rules to:</strong></label> <input type="hidde Link Here
68
                <th>Item Type</th>
73
                <th>Item Type</th>
69
                <th>Current Checkouts Allowed</th>
74
                <th>Current Checkouts Allowed</th>
70
                <th>Loan Period (day)</th>
75
                <th>Loan Period (day)</th>
76
                <th>Hard Due Date</th>
71
                <th>Fine Amount</th>
77
                <th>Fine Amount</th>
72
                <th>Fine Charging Interval</th>
78
                <th>Fine Charging Interval</th>
73
                <th>Fine Grace period (day)</th>
79
                <th>Fine Grace period (day)</th>
Lines 102-107 for="tobranch"><strong>Clone these rules to:</strong></label> <input type="hidde Link Here
102
								<!-- /TMPL_IF -->
108
								<!-- /TMPL_IF -->
103
							</td>
109
							</td>
104
							<td><!-- TMPL_VAR NAME="issuelength" --></td>
110
							<td><!-- TMPL_VAR NAME="issuelength" --></td>
111
                                                        <td><!-- TMPL_IF NAME="hardduedate" -->
112
                                                               <!-- TMPL_IF NAME="hardduedatebefore" -->before <!-- TMPL_VAR NAME="hardduedate" --></td>
113
                                                               <!-- TMPL_ELSE --><!-- TMPL_IF NAME="hardduedateexact" -->on <!-- TMPL_VAR NAME="hardduedate" --></td>
114
                                                                                 <!-- TMPL_ELSE --><!-- TMPL_IF NAME="hardduedateafter" -->after <!-- TMPL_VAR NAME="hardduedate" --></td><!-- /TMPL_IF -->
115
                                                                                 <!-- /TMPL_IF -->
116
                                                               <!-- /TMPL_IF -->
117
                                                            <!-- TMPL_ELSE -->None defined<!-- /TMPL_IF -->   
105
							<td><!-- TMPL_VAR NAME="fine" --></td>
118
							<td><!-- TMPL_VAR NAME="fine" --></td>
106
							<td><!-- TMPL_VAR NAME="chargeperiod" --></td>
119
							<td><!-- TMPL_VAR NAME="chargeperiod" --></td>
107
							<td><!-- TMPL_VAR NAME="firstremind" --></td>
120
							<td><!-- TMPL_VAR NAME="firstremind" --></td>
Lines 133-138 for="tobranch"><strong>Clone these rules to:</strong></label> <input type="hidde Link Here
133
                    </td>
146
                    </td>
134
                    <td><input name="maxissueqty" size="3" /></td>
147
                    <td><input name="maxissueqty" size="3" /></td>
135
                    <td><input name="issuelength" size="3" /> </td>
148
                    <td><input name="issuelength" size="3" /> </td>
149
                    <td><select name="hardduedatecompare">
150
                           <option value="-1">Before</option>
151
                           <option value="0">Exactly on</option>
152
                           <option value="1">After</option>
153
                        </select>
154
                        <input type="text" size="10" id="hardduedate" name="hardduedate" value="<!-- TMPL_VAR NAME="hardduedate" -->" />
155
                        <!-- TMPL_INCLUDE NAME="date-format.inc" -->
156
                        <img src="<!-- TMPL_VAR Name="themelang" -->/lib/calendar/cal.gif" alt="Show Calendar"  border="0" id="CalendarDueDate" style="cursor: pointer;"/>
157
                        <script language="JavaScript" type="text/javascript">
158
                             function refocus(calendar) {
159
                                 document.getElementById('hardduedate').focus();
160
                                 calendar.hide();
161
                             };
162
                             Calendar.setup(
163
                             {
164
                             inputField : "hardduedate",
165
                             ifFormat : "%m/%d/%Y",
166
                             button : "CalendarDueDate",
167
                             onClose: refocus
168
                             }
169
                             );
170
                 </script>
171
                    </td>
136
                    <td><input name="fine" size="4" /></td>
172
                    <td><input name="fine" size="4" /></td>
137
                    <td><input name="chargeperiod" size="2" /></td>
173
                    <td><input name="chargeperiod" size="2" /></td>
138
                    <td><input name="firstremind" size="2" /> </td>
174
                    <td><input name="firstremind" size="2" /> </td>
139
- 

Return to bug 5548