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

(-)a/installer/data/mysql/atomicupdate/auto_renewals_notice.perl (+33 lines)
Line 0 Link Here
1
$DBversion = 'XXX'; # will be replaced by the RM
2
if( CheckVersion( $DBversion ) ) {
3
    # you can use $dbh here like:
4
     $dbh->do( "INSERT IGNORE INTO letter (module, code, name, title, content, message_transport_type) VALUES ('circulation', 'AUTO_RENEWALS', 'Notification of automatic renewal', 'Automatic renewal notice',
5
"Dear [% borrower.firstname %] [% borrower.surname %],
6
[% IF checkout.auto_renew_error %]
7
The following item, [% biblio.title %], has not been renewed because:
8
[% IF checkout.auto_renew_error == 'too_many' %]
9
You have reached the maximum of checkouts possible.
10
[% ELSIF checkout.auto_renew_error == 'on_reserve' %]
11
This item is on hold for another patron.
12
[% ELSIF checkout.auto_renew_error == 'restriction' %]
13
You are currently restricted.
14
[% ELSIF checkout.auto_renew_error == 'overdue' %]
15
You have overdue items.
16
[% ELSIF checkout.auto_renew_error == 'auto_too_late' %]
17
It\'s too late to renew this item.
18
[% ELSIF checkout.auto_renew_error == 'auto_too_much_oweing' %]
19
Your total unpaid fines are too high.
20
[% END %]
21
[% ELSE %]
22
The following item, [% biblio.title %], has correctly been renewed and is now due on [% checkout.date_due %]
23
[% END %]", 'email');" );
24
25
    # or perform some test and warn
26
    # if( !column_exists( 'biblio', 'biblionumber' ) ) {
27
    #    warn "There is something wrong";
28
    # }
29
30
    # Always end with this (adjust the bug info)
31
    SetVersion( $DBversion );
32
    print "Upgrade to $DBversion done (Bug 23787 - Add AUTO_RENEWALS in sample_notices.sql)\n";
33
}
(-)a/installer/data/mysql/de-DE/mandatory/sample_notices.sql (+21 lines)
Lines 384-386 INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, Link Here
384
    </tr>
384
    </tr>
385
</tfoot>
385
</tfoot>
386
</table>', 'print', 'default');
386
</table>', 'print', 'default');
387
388
INSERT INTO letter (module, code, name, title, content, message_transport_type) VALUES ('circulation', 'AUTO_RENEWALS', 'Notification of automatic renewal', 'Automatic renewal notice',
389
"Dear [% borrower.firstname %] [% borrower.surname %],
390
[% IF checkout.auto_renew_error %]
391
The following item, [% biblio.title %], has not been renewed because:
392
[% IF checkout.auto_renew_error == 'too_many' %]
393
You have reached the maximum of checkouts possible.
394
[% ELSIF checkout.auto_renew_error == 'on_reserve' %]
395
This item is on hold for another patron.
396
[% ELSIF checkout.auto_renew_error == 'restriction' %]
397
You are currently restricted.
398
[% ELSIF checkout.auto_renew_error == 'overdue' %]
399
You have overdue items.
400
[% ELSIF checkout.auto_renew_error == 'auto_too_late' %]
401
It\'s too late to renew this item.
402
[% ELSIF checkout.auto_renew_error == 'auto_too_much_oweing' %]
403
Your total unpaid fines are too high.
404
[% END %]
405
[% ELSE %]
406
The following item, [% biblio.title %], has correctly been renewed and is now due on [% checkout.date_due %]
407
[% END %]", 'email');
(-)a/installer/data/mysql/en/mandatory/sample_notices.sql (+21 lines)
Lines 382-384 INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, Link Here
382
    </tr>
382
    </tr>
383
</tfoot>
383
</tfoot>
384
</table>', 'print', 'default');
384
</table>', 'print', 'default');
385
386
INSERT INTO letter (module, code, name, title, content, message_transport_type) VALUES ('circulation', 'AUTO_RENEWALS', 'Notification of automatic renewal', 'Automatic renewal notice',
387
"Dear [% borrower.firstname %] [% borrower.surname %],
388
[% IF checkout.auto_renew_error %]
389
The following item, [% biblio.title %], has not been renewed because:
390
[% IF checkout.auto_renew_error == 'too_many' %]
391
You have reached the maximum of checkouts possible.
392
[% ELSIF checkout.auto_renew_error == 'on_reserve' %]
393
This item is on hold for another patron.
394
[% ELSIF checkout.auto_renew_error == 'restriction' %]
395
You are currently restricted.
396
[% ELSIF checkout.auto_renew_error == 'overdue' %]
397
You have overdue items.
398
[% ELSIF checkout.auto_renew_error == 'auto_too_late' %]
399
It\'s too late to renew this item.
400
[% ELSIF checkout.auto_renew_error == 'auto_too_much_oweing' %]
401
Your total unpaid fines are too high.
402
[% END %]
403
[% ELSE %]
404
The following item, [% biblio.title %], has correctly been renewed and is now due on [% checkout.date_due %]
405
[% END %]", 'email');
(-)a/installer/data/mysql/es-ES/mandatory/sample_notices.sql (+21 lines)
Lines 376-378 INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, Link Here
376
    </tr>
376
    </tr>
377
</tfoot>
377
</tfoot>
378
</table>', 'print', 'default');
378
</table>', 'print', 'default');
379
380
INSERT INTO letter (module, code, name, title, content, message_transport_type) VALUES ('circulation', 'AUTO_RENEWALS', 'Notification of automatic renewal', 'Automatic renewal notice',
381
"Dear [% borrower.firstname %] [% borrower.surname %],
382
[% IF checkout.auto_renew_error %]
383
The following item, [% biblio.title %], has not been renewed because:
384
[% IF checkout.auto_renew_error == 'too_many' %]
385
You have reached the maximum of checkouts possible.
386
[% ELSIF checkout.auto_renew_error == 'on_reserve' %]
387
This item is on hold for another patron.
388
[% ELSIF checkout.auto_renew_error == 'restriction' %]
389
You are currently restricted.
390
[% ELSIF checkout.auto_renew_error == 'overdue' %]
391
You have overdue items.
392
[% ELSIF checkout.auto_renew_error == 'auto_too_late' %]
393
It\'s too late to renew this item.
394
[% ELSIF checkout.auto_renew_error == 'auto_too_much_oweing' %]
395
Your total unpaid fines are too high.
396
[% END %]
397
[% ELSE %]
398
The following item, [% biblio.title %], has correctly been renewed and is now due on [% checkout.date_due %]
399
[% END %]", 'email');
(-)a/installer/data/mysql/fr-CA/obligatoire/sample_notices.sql (+21 lines)
Lines 264-266 INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, Link Here
264
    </tr>
264
    </tr>
265
</tfoot>
265
</tfoot>
266
</table>', 'print', 'default');
266
</table>', 'print', 'default');
267
268
INSERT INTO letter (module, code, name, title, content, message_transport_type) VALUES ('circulation', 'AUTO_RENEWALS', 'Notification of automatic renewal', 'Automatic renewal notice',
269
"Dear [% borrower.firstname %] [% borrower.surname %],
270
[% IF checkout.auto_renew_error %]
271
The following item, [% biblio.title %], has not been renewed because:
272
[% IF checkout.auto_renew_error == 'too_many' %]
273
You have reached the maximum of checkouts possible.
274
[% ELSIF checkout.auto_renew_error == 'on_reserve' %]
275
This item is on hold for another patron.
276
[% ELSIF checkout.auto_renew_error == 'restriction' %]
277
You are currently restricted.
278
[% ELSIF checkout.auto_renew_error == 'overdue' %]
279
You have overdue items.
280
[% ELSIF checkout.auto_renew_error == 'auto_too_late' %]
281
It\'s too late to renew this item.
282
[% ELSIF checkout.auto_renew_error == 'auto_too_much_oweing' %]
283
Your total unpaid fines are too high.
284
[% END %]
285
[% ELSE %]
286
The following item, [% biblio.title %], has correctly been renewed and is now due on [% checkout.date_due %]
287
[% END %]", 'email');
(-)a/installer/data/mysql/fr-FR/1-Obligatoire/sample_notices.sql (+21 lines)
Lines 377-379 INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, Link Here
377
    </tr>
377
    </tr>
378
</tfoot>
378
</tfoot>
379
</table>', 'print', 'default');
379
</table>', 'print', 'default');
380
381
INSERT INTO letter (module, code, name, title, content, message_transport_type) VALUES ('circulation', 'AUTO_RENEWALS', 'Notification of automatic renewal', 'Automatic renewal notice',
382
"Dear [% borrower.firstname %] [% borrower.surname %],
383
[% IF checkout.auto_renew_error %]
384
The following item, [% biblio.title %], has not been renewed because:
385
[% IF checkout.auto_renew_error == 'too_many' %]
386
You have reached the maximum of checkouts possible.
387
[% ELSIF checkout.auto_renew_error == 'on_reserve' %]
388
This item is on hold for another patron.
389
[% ELSIF checkout.auto_renew_error == 'restriction' %]
390
You are currently restricted.
391
[% ELSIF checkout.auto_renew_error == 'overdue' %]
392
You have overdue items.
393
[% ELSIF checkout.auto_renew_error == 'auto_too_late' %]
394
It\'s too late to renew this item.
395
[% ELSIF checkout.auto_renew_error == 'auto_too_much_oweing' %]
396
Your total unpaid fines are too high.
397
[% END %]
398
[% ELSE %]
399
The following item, [% biblio.title %], has correctly been renewed and is now due on [% checkout.date_due %]
400
[% END %]", 'email');
(-)a/installer/data/mysql/it-IT/necessari/notices.sql (+21 lines)
Lines 380-382 INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, Link Here
380
    </tr>
380
    </tr>
381
</tfoot>
381
</tfoot>
382
</table>', 'print', 'default');
382
</table>', 'print', 'default');
383
384
INSERT INTO letter (module, code, name, title, content, message_transport_type) VALUES ('circulation', 'AUTO_RENEWALS', 'Notification of automatic renewal', 'Automatic renewal notice',
385
"Dear [% borrower.firstname %] [% borrower.surname %],
386
[% IF checkout.auto_renew_error %]
387
The following item, [% biblio.title %], has not been renewed because:
388
[% IF checkout.auto_renew_error == 'too_many' %]
389
You have reached the maximum of checkouts possible.
390
[% ELSIF checkout.auto_renew_error == 'on_reserve' %]
391
This item is on hold for another patron.
392
[% ELSIF checkout.auto_renew_error == 'restriction' %]
393
You are currently restricted.
394
[% ELSIF checkout.auto_renew_error == 'overdue' %]
395
You have overdue items.
396
[% ELSIF checkout.auto_renew_error == 'auto_too_late' %]
397
It\'s too late to renew this item.
398
[% ELSIF checkout.auto_renew_error == 'auto_too_much_oweing' %]
399
Your total unpaid fines are too high.
400
[% END %]
401
[% ELSE %]
402
The following item, [% biblio.title %], has correctly been renewed and is now due on [% checkout.date_due %]
403
[% END %]", 'email');
(-)a/installer/data/mysql/nb-NO/1-Obligatorisk/sample_notices.sql (+21 lines)
Lines 396-398 INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, Link Here
396
    </tr>
396
    </tr>
397
</tfoot>
397
</tfoot>
398
</table>', 'print', 'default');
398
</table>', 'print', 'default');
399
400
INSERT INTO letter (module, code, name, title, content, message_transport_type) VALUES ('circulation', 'AUTO_RENEWALS', 'Notification of automatic renewal', 'Automatic renewal notice',
401
"Dear [% borrower.firstname %] [% borrower.surname %],
402
[% IF checkout.auto_renew_error %]
403
The following item, [% biblio.title %], has not been renewed because:
404
[% IF checkout.auto_renew_error == 'too_many' %]
405
You have reached the maximum of checkouts possible.
406
[% ELSIF checkout.auto_renew_error == 'on_reserve' %]
407
This item is on hold for another patron.
408
[% ELSIF checkout.auto_renew_error == 'restriction' %]
409
You are currently restricted.
410
[% ELSIF checkout.auto_renew_error == 'overdue' %]
411
You have overdue items.
412
[% ELSIF checkout.auto_renew_error == 'auto_too_late' %]
413
It\'s too late to renew this item.
414
[% ELSIF checkout.auto_renew_error == 'auto_too_much_oweing' %]
415
Your total unpaid fines are too high.
416
[% END %]
417
[% ELSE %]
418
The following item, [% biblio.title %], has correctly been renewed and is now due on [% checkout.date_due %]
419
[% END %]", 'email');
(-)a/installer/data/mysql/pl-PL/mandatory/sample_notices.sql (+21 lines)
Lines 374-376 INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, Link Here
374
    </tr>
374
    </tr>
375
</tfoot>
375
</tfoot>
376
</table>', 'print', 'default');
376
</table>', 'print', 'default');
377
378
INSERT INTO letter (module, code, name, title, content, message_transport_type) VALUES ('circulation', 'AUTO_RENEWALS', 'Notification of automatic renewal', 'Automatic renewal notice',
379
"Dear [% borrower.firstname %] [% borrower.surname %],
380
[% IF checkout.auto_renew_error %]
381
The following item, [% biblio.title %], has not been renewed because:
382
[% IF checkout.auto_renew_error == 'too_many' %]
383
You have reached the maximum of checkouts possible.
384
[% ELSIF checkout.auto_renew_error == 'on_reserve' %]
385
This item is on hold for another patron.
386
[% ELSIF checkout.auto_renew_error == 'restriction' %]
387
You are currently restricted.
388
[% ELSIF checkout.auto_renew_error == 'overdue' %]
389
You have overdue items.
390
[% ELSIF checkout.auto_renew_error == 'auto_too_late' %]
391
It\'s too late to renew this item.
392
[% ELSIF checkout.auto_renew_error == 'auto_too_much_oweing' %]
393
Your total unpaid fines are too high.
394
[% END %]
395
[% ELSE %]
396
The following item, [% biblio.title %], has correctly been renewed and is now due on [% checkout.date_due %]
397
[% END %]", 'email');
(-)a/installer/data/mysql/ru-RU/mandatory/sample_notices.sql (+21 lines)
Lines 376-378 INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, Link Here
376
    </tr>
376
    </tr>
377
</tfoot>
377
</tfoot>
378
</table>', 'print', 'default');
378
</table>', 'print', 'default');
379
380
INSERT INTO letter (module, code, name, title, content, message_transport_type) VALUES ('circulation', 'AUTO_RENEWALS', 'Notification of automatic renewal', 'Automatic renewal notice',
381
"Dear [% borrower.firstname %] [% borrower.surname %],
382
[% IF checkout.auto_renew_error %]
383
The following item, [% biblio.title %], has not been renewed because:
384
[% IF checkout.auto_renew_error == 'too_many' %]
385
You have reached the maximum of checkouts possible.
386
[% ELSIF checkout.auto_renew_error == 'on_reserve' %]
387
This item is on hold for another patron.
388
[% ELSIF checkout.auto_renew_error == 'restriction' %]
389
You are currently restricted.
390
[% ELSIF checkout.auto_renew_error == 'overdue' %]
391
You have overdue items.
392
[% ELSIF checkout.auto_renew_error == 'auto_too_late' %]
393
It\'s too late to renew this item.
394
[% ELSIF checkout.auto_renew_error == 'auto_too_much_oweing' %]
395
Your total unpaid fines are too high.
396
[% END %]
397
[% ELSE %]
398
The following item, [% biblio.title %], has correctly been renewed and is now due on [% checkout.date_due %]
399
[% END %]", 'email');
(-)a/installer/data/mysql/uk-UA/mandatory/sample_notices.sql (-1 / +21 lines)
Lines 465-467 INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, Link Here
465
    </tr>
465
    </tr>
466
</tfoot>
466
</tfoot>
467
</table>', 'print', 'default');
467
</table>', 'print', 'default');
468
- 
468
469
INSERT INTO letter (module, code, name, title, content, message_transport_type) VALUES ('circulation', 'AUTO_RENEWALS', 'Notification of automatic renewal', 'Automatic renewal notice',
470
"Dear [% borrower.firstname %] [% borrower.surname %],
471
[% IF checkout.auto_renew_error %]
472
The following item, [% biblio.title %], has not been renewed because:
473
[% IF checkout.auto_renew_error == 'too_many' %]
474
You have reached the maximum of checkouts possible.
475
[% ELSIF checkout.auto_renew_error == 'on_reserve' %]
476
This item is on hold for another patron.
477
[% ELSIF checkout.auto_renew_error == 'restriction' %]
478
You are currently restricted.
479
[% ELSIF checkout.auto_renew_error == 'overdue' %]
480
You have overdue items.
481
[% ELSIF checkout.auto_renew_error == 'auto_too_late' %]
482
It\'s too late to renew this item.
483
[% ELSIF checkout.auto_renew_error == 'auto_too_much_oweing' %]
484
Your total unpaid fines are too high.
485
[% END %]
486
[% ELSE %]
487
The following item, [% biblio.title %], has correctly been renewed and is now due on [% checkout.date_due %]
488
[% END %]", 'email');

Return to bug 23787