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

(-)a/installer/data/mysql/sysprefs.sql (-1 / +1 lines)
Lines 191-197 INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES Link Here
191
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OAI-PMH:archiveID','KOHA-OAI-TEST','OAI-PMH archive identification',NULL,'Free');
191
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OAI-PMH:archiveID','KOHA-OAI-TEST','OAI-PMH archive identification',NULL,'Free');
192
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OAI-PMH:MaxCount','50','OAI-PMH maximum number of records by answer to ListRecords and ListIdentifiers queries',NULL,'Integer');
192
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OAI-PMH:MaxCount','50','OAI-PMH maximum number of records by answer to ListRecords and ListIdentifiers queries',NULL,'Integer');
193
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');
193
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');
194
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPACItemHolds','1','Allow OPAC users to place hold on specific items. If OFF, users can only request next available copy.','','YesNo');
194
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPACItemHolds','yes','Allow OPAC users to place hold on specific items. If No, users can only request next available copy. If Yes, users can choose between next available and specific copy. If Force, users *must* choose a specific copy.','no|yes|force','Choice');
195
195
196
INSERT INTO `systempreferences` (variable, value,options,type, explanation) VALUES ('AddPatronLists','categorycode','categorycode|category_type','Choice','Allow user to choose what list to pick up from when adding patrons');
196
INSERT INTO `systempreferences` (variable, value,options,type, explanation) VALUES ('AddPatronLists','categorycode','categorycode|category_type','Choice','Allow user to choose what list to pick up from when adding patrons');
197
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ExtendedPatronAttributes','0','Use extended patron IDs and attributes',NULL,'YesNo');
197
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ExtendedPatronAttributes','0','Use extended patron IDs and attributes',NULL,'YesNo');
(-)a/installer/data/mysql/updatedatabase.pl (+7 lines)
Lines 5086-5091 if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { Link Here
5086
    SetVersion($DBversion);
5086
    SetVersion($DBversion);
5087
}
5087
}
5088
5088
5089
$DBversion = "3.07.00.XXX";
5090
if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) {
5091
	$dbh->do("UPDATE systempreferences SET type = 'Choice', options = 'no|yes|force', value = CASE value WHEN '1' THEN 'yes' ELSE  'no' END, explanation = 'Allow OPAC users to place hold on specific items. If No, users can only request next available copy. If Yes, users can choose between next available and specific copy. If Force, users *must* choose a specific copy.' WHERE variable = 'OPACItemHolds'");
5092
    print "Upgrade to $DBversion done (Changed OPACItemHolds syspref to Choice)\n";
5093
    SetVersion($DBversion);
5094
}
5095
5089
=head1 FUNCTIONS
5096
=head1 FUNCTIONS
5090
5097
5091
=head2 DropAllForeignKeys($table)
5098
=head2 DropAllForeignKeys($table)
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref (-2 / +3 lines)
Lines 339-347 OPAC: Link Here
339
        -
339
        -
340
            - pref: OPACItemHolds
340
            - pref: OPACItemHolds
341
              choices:
341
              choices:
342
                  yes: Allow
343
                  no: "Don't allow"
342
                  no: "Don't allow"
344
            - patrons to place holds on specific items in the OPAC. If this is disabled, users can only put a hold on the next available item.
343
                  yes: Allow
344
                  force: Force
345
            - patrons to place holds on specific items in the OPAC. If this is disabled, users can only put a hold on the next available item. If this is forced, users must put a hold on a specific item.
345
        -
346
        -
346
            - pref: OpacRenewalAllowed
347
            - pref: OpacRenewalAllowed
347
              choices:
348
              choices:
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-reserve.tt (-28 / +15 lines)
Lines 249-255 Link Here
249
		  <th>Hold Starts on Date</th>
249
		  <th>Hold Starts on Date</th>
250
		  [% END %]
250
		  [% END %]
251
		  <th>Hold Not Needed After</th>
251
		  <th>Hold Not Needed After</th>
252
                  [% IF ( OPACItemHolds ) %]
252
                  [% IF OPACItemHolds == 'yes' %]
253
                    <th id="place_on_hdr" style="display:none">Place On</th>
253
                    <th id="place_on_hdr" style="display:none">Place On</th>
254
                  [% END %]
254
                  [% END %]
255
                  [% UNLESS ( singleBranchMode ) %]
255
                  [% UNLESS ( singleBranchMode ) %]
Lines 384-433 Link Here
384
    </td>[% END %]
384
    </td>[% END %]
385
385
386
                    [% IF ( bibitemloo.holdable ) %]
386
                    [% IF ( bibitemloo.holdable ) %]
387
		    <!-- HOLD ABLE -->
387
		    <!-- HOLDABLE -->
388
		    [% IF ( OPACItemHolds ) %]
388
		        [% IF OPACItemHolds == 'yes' %]
389
		    <!-- ITEM HOLDS -->
389
		        <!-- ITEM HOLDS -->
390
                                          <td class="place_on_type" style="display:none">
390
                                          <td class="place_on_type" style="display:none">
391
                                            <ul>
391
                                            <ul>
392
                                                <li>
392
                                                <li>
393
                                                  [% UNLESS ( bibitemloo.holdable ) %]
394
                                                    <input type="radio" name="reqtype_[% bibitemloo.biblionumber %]"
395
                                                           id="reqany_[% bibitemloo.biblionumber %]"
396
                                                           class="selectany"
397
                                                           value="Any"
398
                                                           disabled="disabled"
399
                                                    />
400
                                                  [% ELSE %]
401
                                                    <input type="radio" name="reqtype_[% bibitemloo.biblionumber %]"
393
                                                    <input type="radio" name="reqtype_[% bibitemloo.biblionumber %]"
402
                                                           id="reqany_[% bibitemloo.biblionumber %]"
394
                                                           id="reqany_[% bibitemloo.biblionumber %]"
403
                                                           class="selectany"
395
                                                           class="selectany"
404
                                                           value="Any"
396
                                                           value="Any"
405
                                                           checked="checked"
397
                                                           checked="checked"
406
                                                    />
398
                                                    />
407
                                                  [% END %]
399
                                                    <label for="reqany_[% bibitemloo.biblionumber %]">Next available copy</label>
408
                                                  <label for="reqany_[% bibitemloo.biblionumber %]">Next available copy</label>
409
                                                </li>
400
                                                </li>
410
                                                <li>
401
                                                <li>
411
                                                  [% UNLESS ( bibitemloo.holdable ) %]
412
                                                    <input type="radio" name="reqtype_[% bibitemloo.biblionumber %]"
413
                                                           id="reqspecific_[% bibitemloo.biblionumber %]"
414
                                                           class="selectspecific"
415
                                                           disabled="disabled"
416
                                                           value="Specific"
417
                                                    />
418
                                                  [% ELSE %]
419
                                                    <input type="radio" name="reqtype_[% bibitemloo.biblionumber %]"
402
                                                    <input type="radio" name="reqtype_[% bibitemloo.biblionumber %]"
420
                                                           id="reqspecific_[% bibitemloo.biblionumber %]"
403
                                                           id="reqspecific_[% bibitemloo.biblionumber %]"
421
                                                           class="selectspecific"
404
                                                           class="selectspecific"
422
                                                           value="Specific"
405
                                                           value="Specific"
423
                                                    />
406
                                                    />
424
                                                  [% END %]
407
                                                    <label for="reqspecific_[% bibitemloo.biblionumber %]">A specific copy</label>
425
                                                  <label for="reqspecific_[% bibitemloo.biblionumber %]">A specific copy</label>
426
                                                </li>
408
                                                </li>
427
                                            </ul>
409
                                            </ul>
428
                                          </td>
410
                                          </td>
429
                                        [% END %][% END %]
411
		        [% ELSIF OPACItemHolds == 'force' %]
430
412
<script type="text/javascript">
413
    $(document).ready(function() {
414
        $("#copiesrow_[% bibitemloo.biblionumber %]").show();
415
    });
416
</script>
417
                        [% END %]
418
                    [% END  # holdable%]
431
                    [% UNLESS ( singleBranchMode ) %]
419
                    [% UNLESS ( singleBranchMode ) %]
432
                        [% IF ( bibitemloo.holdable ) %]
420
                        [% IF ( bibitemloo.holdable ) %]
433
			    [% IF ( choose_branch ) %]
421
			    [% IF ( choose_branch ) %]
Lines 459-465 Link Here
459
                    [% END %]
447
                    [% END %]
460
                  </tr>
448
                  </tr>
461
449
462
                  [% IF ( OPACItemHolds ) %]
450
                  [% IF OPACItemHolds == 'yes' || OPACItemHolds == 'force' %]
463
                  [% IF ( bibitemloo.holdable ) %]
451
                  [% IF ( bibitemloo.holdable ) %]
464
                    <tr class="copiesrow" id="copiesrow_[% bibitemloo.biblionumber %]">
452
                    <tr class="copiesrow" id="copiesrow_[% bibitemloo.biblionumber %]">
465
                      <td>&nbsp;</td>
453
                      <td>&nbsp;</td>
466
- 

Return to bug 7825