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

(-)a/installer/data/mysql/atomicupdate/ill_tables.sql (+55 lines)
Line 0 Link Here
1
-- ILL Requests
2
3
CREATE TABLE illrequests (
4
    illrequest_id serial PRIMARY KEY,           -- ILL request number
5
    borrowernumber integer DEFAULT NULL,        -- Patron associated with request
6
    biblio_id integer DEFAULT NULL,             -- Potential bib linked to request
7
    branchcode varchar(50) NOT NULL,            -- The branch associated with the request
8
    status varchar(50) DEFAULT NULL,            -- Current Koha status of request
9
    placed date DEFAULT NULL,                   -- Date the request was placed
10
    replied date DEFAULT NULL,                  -- Last API response
11
    updated timestamp DEFAULT CURRENT_TIMESTAMP -- Last modification to request
12
      ON UPDATE CURRENT_TIMESTAMP,
13
    completed date DEFAULT NULL,                -- Date the request was completed
14
    medium varchar(30) DEFAULT NULL,            -- The Koha request type
15
    accessurl varchar(500) DEFAULT NULL,        -- Potential URL for accessing item
16
    cost varchar(20) DEFAULT NULL,              -- Cost of request
17
    notesopac text DEFAULT NULL,                -- Patron notes attached to request
18
    notesstaff text DEFAULT NULL,               -- Staff notes attached to request
19
    orderid varchar(50) DEFAULT NULL,           -- Backend id attached to request
20
    backend varchar(20) DEFAULT NULL,           -- The backend used to create request
21
    CONSTRAINT `illrequests_bnfk`
22
      FOREIGN KEY (`borrowernumber`)
23
      REFERENCES `borrowers` (`borrowernumber`)
24
      ON UPDATE CASCADE ON DELETE CASCADE,
25
    CONSTRAINT `illrequests_bcfk_2`
26
      FOREIGN KEY (`branchcode`)
27
      REFERENCES `branches` (`branchcode`)
28
      ON UPDATE CASCADE ON DELETE CASCADE
29
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
30
31
-- ILL Request Attributes
32
33
CREATE TABLE illrequestattributes (
34
    illrequest_id bigint(20) unsigned NOT NULL, -- ILL request number
35
    type varchar(200) NOT NULL,                 -- API ILL property name
36
    value text NOT NULL,                        -- API ILL property value
37
    PRIMARY KEY  (`illrequest_id`,`type`),
38
    CONSTRAINT `illrequestattributes_ifk`
39
      FOREIGN KEY (illrequest_id)
40
      REFERENCES `illrequests` (`illrequest_id`)
41
      ON UPDATE CASCADE ON DELETE CASCADE
42
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
43
44
-- System preferences
45
46
INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES
47
       ('ILLModule','0','If ON, enables the interlibrary loans module.','','YesNo');
48
49
INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES
50
       ('ILLModuleCopyrightClearance','','70|10','Enter text to enable the copyright clearance stage of request creation. Text will be displayed','Textarea');
51
52
-- Userflags
53
54
INSERT INTO userflags (bit,flag,flagdesc,defaulton)
55
VALUES (22,'ill','The Interlibrary Loans Module',0);
(-)a/installer/data/mysql/kohastructure.sql (+49 lines)
Lines 4125-4130 CREATE TABLE IF NOT EXISTS club_fields ( Link Here
4125
  CONSTRAINT club_fields_ibfk_4 FOREIGN KEY (club_id) REFERENCES clubs (id) ON DELETE CASCADE ON UPDATE CASCADE
4125
  CONSTRAINT club_fields_ibfk_4 FOREIGN KEY (club_id) REFERENCES clubs (id) ON DELETE CASCADE ON UPDATE CASCADE
4126
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
4126
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
4127
4127
4128
--
4129
-- Table structure for table `illrequests`
4130
--
4131
4132
DROP TABLE IF EXISTS `illrequests`;
4133
CREATE TABLE illrequests (
4134
    illrequest_id serial PRIMARY KEY,           -- ILL request number
4135
    borrowernumber integer DEFAULT NULL,        -- Patron associated with request
4136
    biblio_id integer DEFAULT NULL,             -- Potential bib linked to request
4137
    branchcode varchar(50) NOT NULL,            -- The branch associated with the request
4138
    status varchar(50) DEFAULT NULL,            -- Current Koha status of request
4139
    placed date DEFAULT NULL,                   -- Date the request was placed
4140
    replied date DEFAULT NULL,                  -- Last API response
4141
    updated timestamp DEFAULT CURRENT_TIMESTAMP -- Last modification to request
4142
      ON UPDATE CURRENT_TIMESTAMP,
4143
    completed date DEFAULT NULL,                -- Date the request was completed
4144
    medium varchar(30) DEFAULT NULL,            -- The Koha request type
4145
    accessurl varchar(500) DEFAULT NULL,        -- Potential URL for accessing item
4146
    cost varchar(20) DEFAULT NULL,              -- Cost of request
4147
    notesopac text DEFAULT NULL,                -- Patron notes attached to request
4148
    notesstaff text DEFAULT NULL,               -- Staff notes attached to request
4149
    orderid varchar(50) DEFAULT NULL,           -- Backend id attached to request
4150
    backend varchar(20) DEFAULT NULL,           -- The backend used to create request
4151
    CONSTRAINT `illrequests_bnfk`
4152
      FOREIGN KEY (`borrowernumber`)
4153
      REFERENCES `borrowers` (`borrowernumber`)
4154
      ON UPDATE CASCADE ON DELETE CASCADE,
4155
    CONSTRAINT `illrequests_bcfk_2`
4156
      FOREIGN KEY (`branchcode`)
4157
      REFERENCES `branches` (`branchcode`)
4158
      ON UPDATE CASCADE ON DELETE CASCADE
4159
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
4160
4161
--
4162
-- Table structure for table `illrequestattributes`
4163
--
4164
4165
DROP TABLE IF EXISTS `illrequestattributes`;
4166
CREATE TABLE illrequestattributes (
4167
    illrequest_id bigint(20) unsigned NOT NULL, -- ILL request number
4168
    type varchar(200) NOT NULL,                 -- API ILL property name
4169
    value text NOT NULL,                        -- API ILL property value
4170
    PRIMARY KEY  (`illrequest_id`,`type`),
4171
    CONSTRAINT `illrequestattributes_ifk`
4172
      FOREIGN KEY (illrequest_id)
4173
      REFERENCES `illrequests` (`illrequest_id`)
4174
      ON UPDATE CASCADE ON DELETE CASCADE
4175
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
4176
4128
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
4177
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
4129
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
4178
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
4130
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
4179
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
(-)a/installer/data/mysql/sysprefs.sql (+2 lines)
Lines 199-204 INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` Link Here
199
('IDreamBooksResults','0','','Display IDreamBooks.com rating in search results','YesNo'),
199
('IDreamBooksResults','0','','Display IDreamBooks.com rating in search results','YesNo'),
200
('IDreamBooksReviews','0','','Display book review snippets from IDreamBooks.com','YesNo'),
200
('IDreamBooksReviews','0','','Display book review snippets from IDreamBooks.com','YesNo'),
201
('IdRef','0','','Disable/enable the IdRef webservice from the OPAC detail page.','YesNo'),
201
('IdRef','0','','Disable/enable the IdRef webservice from the OPAC detail page.','YesNo'),
202
('ILLModule','0','If ON, enables the interlibrary loans module.','','YesNo'),
203
('ILLModuleCopyrightClearance','','70|10','Enter text to enable the copyright clearance stage of request creation. Text will be displayed','Textarea'),
202
('ILS-DI','0','','Enables ILS-DI services at OPAC.','YesNo'),
204
('ILS-DI','0','','Enables ILS-DI services at OPAC.','YesNo'),
203
('ILS-DI:AuthorizedIPs','','Restricts usage of ILS-DI to some IPs','.','Free'),
205
('ILS-DI:AuthorizedIPs','','Restricts usage of ILS-DI to some IPs','.','Free'),
204
('ImageLimit','5','','Limit images stored in the database by the Patron Card image manager to this number.','Integer'),
206
('ImageLimit','5','','Limit images stored in the database by the Patron Card image manager to this number.','Integer'),
(-)a/installer/data/mysql/userflags.sql (-1 / +2 lines)
Lines 18-22 INSERT INTO userflags (bit, flag, flagdesc, defaulton) VALUES Link Here
18
(18,'coursereserves','Course reserves',0),
18
(18,'coursereserves','Course reserves',0),
19
(19, 'plugins', 'Koha plugins', '0'),
19
(19, 'plugins', 'Koha plugins', '0'),
20
(20, 'lists', 'Lists', 0),
20
(20, 'lists', 'Lists', 0),
21
(21, 'clubs', 'Patron clubs', '0')
21
(21, 'clubs', 'Patron clubs', '0'),
22
(22,'ill','The Interlibrary Loans Module',0)
22
;
23
;
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/admin.pref (-1 / +13 lines)
Lines 65-70 Administration: Link Here
65
              choices:
65
              choices:
66
                  yes: "The logged-in library"
66
                  yes: "The logged-in library"
67
                  no: "All libraries"
67
                  no: "All libraries"
68
    Interlibrary Loans:
69
        -
70
            - pref: ILLModule
71
              default: 0
72
              choices:
73
                  yes: Enable
74
                  no: Disable
75
            - the interlibrary loans module (master switch).
76
        -
77
            - "Adding text will enable the copyright clearance stage in request creation. The text you enter will be the text displayed."
78
            - pref: ILLModuleCopyrightClearance
79
              type: textarea
80
              class: long
68
    Login options:
81
    Login options:
69
        -
82
        -
70
            - "Inactivity timeout in seconds to automatically log out users: "
83
            - "Inactivity timeout in seconds to automatically log out users: "
71
- 

Return to bug 7317