Bug 16947

Summary: Can not modify patron messaging preferences
Product: Koha Reporter: Marc Véron <veron>
Component: Staff interfaceAssignee: Marc Véron <veron>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: major    
Priority: P5 - low CC: f.demians, gmcharlt, jonathan.druart, julian.maurice, kyle
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Attachments: Bug 16947: Can not modify patron messaging preferences
Bug 16947: Can not modify patron messaging preferences
Bug 16947: Can not modify patron messaging preferences

Description Marc Véron 2016-07-20 16:49:32 UTC
It is no longer possible to modify messaging preferences for an existing patron.

To verify:
- Set syspref 'EnhancedMessagingPreferences' to 'Allow'
- In staff client, go to a patron's detail page
- Edit Patron messaging preferences (using link below table)
- Save
Result: Form does not save, stays open
JavaScript error in intranet-tmpl/prog/js/members.js line 107 
TypeError: document.form.password is undefined

Note: Changing settings from OPAC works (needs EnhancedMessagingPreferencesOPAC)
Comment 1 Marc Véron 2016-07-21 08:29:32 UTC Comment hidden (obsolete)
Comment 2 Mark Tompsett 2016-07-21 13:49:25 UTC Comment hidden (obsolete)
Comment 3 Jonathan Druart 2016-07-21 16:27:56 UTC
Created attachment 53593 [details] [review]
Bug 16947: Can not modify patron messaging preferences

To verify:
- Set syspref 'EnhancedMessagingPreferences' to 'Allow'
- In staff client, go to a patron's detail page
- Edit Patron messaging preferences (using link below table)
- Save
Result: Form does not save, stays open
JavaScript error in intranet-tmpl/prog/js/members.js line 107
TypeError: document.form.password is undefined

To test:
- Apply patch
- Repeat steps above
- Verify that messaging preferences save as expected
- Verify that other patron modifications work as before

NOTE: remember to force reload of the javascripts.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 4 Jonathan Druart 2016-07-21 16:29:05 UTC
This will need to be adapted for stable versions. I have not tested on 3.22.x but looking at the code the issue certainly exists.

Since the bug exists for a while, I don't think it's a critical one.
Comment 5 Kyle M Hall 2016-07-22 17:11:14 UTC
Pushed to master for 16.11, thanks Marc!
Comment 6 Frédéric Demians 2016-08-01 13:44:37 UTC
Pushed in 16.05. Will be in 16.05.02.
Comment 7 Julian Maurice 2016-08-17 11:45:26 UTC
Not needed in 3.22.x