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

(-)a/installer/data/mysql/atomicupdate/bug_29792_add_AutomaticConfirmTransfer_preference.pl (+16 lines)
Line 0 Link Here
1
use Modern::Perl;
2
3
return {
4
    bug_number => "29792",
5
    description => "Add AutomaticConfirmTransfer system preference",
6
    up => sub {
7
        my ($args) = @_;
8
        my ($dbh, $out) = @$args{qw(dbh out)};
9
        $dbh->do(q{
10
            INSERT IGNORE INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `type` ) VALUES
11
            ('AutomaticConfirmTransfer','0',NULL,'Defines whether transfers should be automatically confirmed at checkin if modal dismissed','YesNo')
12
        });
13
        # Print useful stuff here
14
        say $out "AutomaticConfirmTransfer system preference added";
15
    },
16
};
(-)a/installer/data/mysql/mandatory/sysprefs.sql (+1 lines)
Lines 83-88 INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` Link Here
83
('AutoLocation','0',NULL,'If ON, IP authentication is enabled, blocking access to the staff interface from unauthorized IP addresses','YesNo'),
83
('AutoLocation','0',NULL,'If ON, IP authentication is enabled, blocking access to the staff interface from unauthorized IP addresses','YesNo'),
84
('AutomaticItemReturn','1',NULL,'If ON, Koha will automatically set up a transfer of this item to its homebranch','YesNo'),
84
('AutomaticItemReturn','1',NULL,'If ON, Koha will automatically set up a transfer of this item to its homebranch','YesNo'),
85
('AutoLinkBiblios','0',NULL,'If enabled, link biblio to authorities on creation and edit','YesNo'),
85
('AutoLinkBiblios','0',NULL,'If enabled, link biblio to authorities on creation and edit','YesNo'),
86
('AutomaticWrongTransfer','0',NULL,'Defines whether transfers should be automatically confirmed at checkin if modal dismissed','YesNo'),
86
('autoMemberNum','0','','If ON, patron number is auto-calculated','YesNo'),
87
('autoMemberNum','0','','If ON, patron number is auto-calculated','YesNo'),
87
('AutoRemoveOverduesRestrictions','0',NULL,'Defines whether an OVERDUES debarment should be lifted automatically if all overdue items are returned by the patron.','YesNo'),
88
('AutoRemoveOverduesRestrictions','0',NULL,'Defines whether an OVERDUES debarment should be lifted automatically if all overdue items are returned by the patron.','YesNo'),
88
('AutoRenewalNotices','cron','cron|preferences|never','How should Koha determine whether to end autorenewal notices','Choice'),
89
('AutoRenewalNotices','cron','cron|preferences|never','How should Koha determine whether to end autorenewal notices','Choice'),
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref (+6 lines)
Lines 656-661 Circulation: Link Here
656
                  1: "Block"
656
                  1: "Block"
657
                  0: "Don't block"
657
                  0: "Don't block"
658
            - staff from continuing to checkin items when a transfer is triggered.
658
            - staff from continuing to checkin items when a transfer is triggered.
659
        -
660
            - pref: AutomaticConfirmTransfer
661
              choices:
662
                  1: "Do"
663
                  0: "Don't"
664
            - automatically confirm a transfer when the modal is dismissed without clicking 'Yes'.
659
        -
665
        -
660
            - pref: StoreLastBorrower
666
            - pref: StoreLastBorrower
661
              default: 0
667
              default: 0
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt (-1 / +10 lines)
Lines 1622-1627 Link Here
1622
            $('.printModal').click(function() {
1622
            $('.printModal').click(function() {
1623
                window.print();
1623
                window.print();
1624
            });
1624
            });
1625
            [% IF ( !(Koha.Preference('TransfersBlockCirc')) && Koha.Preference('AutomaticConfirmTransfer') ) %]
1626
                $("#wrong-transfer-modal").on('hidden.bs.modal',function(){
1627
                    $("#wrongtransferform").submit();
1628
                });
1629
                [% IF (transfer) %]
1630
                    $("#item-transfer-modal").on('hidden.bs.modal',function(){
1631
                        $("#mainform").submit();
1632
                    });
1633
                [% END %]
1634
            [% END %]
1625
        });
1635
        });
1626
    </script>
1636
    </script>
1627
1637
1628
- 

Return to bug 29792