Bug 12344 - Multi transport types for issues and checkins
authorKoha instance knakk-koha <knakk-koha@vagrant-saucy64>
Mon, 2 Jun 2014 12:18:30 +0000 (14:18 +0200)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Mon, 30 Mar 2015 16:38:31 +0000 (13:38 -0300)
commit2ab4a4287ba6081a872f1123fe44e5596c829bf1
tree926b78bbfede43f139a2ecfbcff1fbc7e07c6cf7
parent27962ff4117c5f9281794162d16ac19373ad451e
Bug 12344 - Multi transport types for issues and checkins

This small patch corrects the order of generating notices for issues and returns (checkout/checkin) so that borrower's notices are rendered correctly (for sms,email,etc.)

Test plan:

1) Edit SMSSendDriver syspref to use driver 'Test'
2) Edit CHECKOUT template for sms to 'SMS test'
3) select SMS for test patron's messaging prefs for item checkout
4) checkout an item
5) check the table message_queue, verify that template sms is
   not used (message content is not 'SMS test')

6) apply patch, make new checkout
7) check that message_queue table now has a correctly generated
   notice with 'SMS test'

For a real world test use a real SMS::Send driver and run the
cronjob process-message-queue.pl to send messages immediately.

Signed-off-by: Sophie Meynieux <sophie.meynieux@biblibre.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
C4/Circulation.pm