Selectively disallow opt-in based on patron's home library

Bug #1533329 reported by Jeff Davis on 2016-01-12
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Evergreen
Wishlist
Unassigned

Bug Description

Patrons from Library A can "opt in" to sharing their personal information with Library B. However, there's no way for Library A to prevent their patrons from being opted in at other libraries. The ability to selectively disallow opt-in by home library would be useful if, for example, Library A is a school library and does not want other libraries in the consortium to have access to student accounts.

I am working on adding this as a new feature. Here's the plan:

1. Add an org setting (org.restrict_opt_to_depth) that governs opt-in restrictions. All org units within the home OU's section of the org tree at or below depth X are within the patron's opt-in scope; opt-in is disallowed at any library outside of that scope. If the setting is not enabled, the entire org tree is effectively within scope. (None of this should be confused with the opt boundary, which defines the point at which patrons need to be opted in vs. just granting access without opt-in.)

2. Modify open-ils.actor.user.org_unit_opt_in.check so that it checks that setting and determines if the current work OU is within the patron's opt-in scope. If opt-in is not permitted at this work OU, return an appropriate response.

3. Handle the response in the staff client. This means adding equivalent functionality to both the XUL client (which we are currently using) and the web client.

Changed in evergreen:
importance: Undecided → Wishlist
assignee: nobody → Jeff Davis (jdavis-sitka)
Jeff Davis (jdavis-sitka) wrote :

Initial changes pushed to working repo:

http://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/jeffdavis/lp1533329-restrict-opt-in

Todo (by me):

1. Add pgTAP isnt_empty() test for the new org setting.
2. Add Perl live test for all possible return values of open-ils.actor.user.org_unit_opt_in.check.

Changed in evergreen:
milestone: none → 2.next
Jeff Davis (jdavis-sitka) wrote :

The aforementioned tests have been pushed to the branch.

tags: added: pullrequest
Changed in evergreen:
milestone: 2.next → 2.10-beta
Jeff Davis (jdavis-sitka) wrote :

Release notes pushed to working branch.

Galen Charlton (gmc) wrote :

Pushed to master. Thanks, Jeff!

Changed in evergreen:
status: New → Fix Committed
assignee: Jeff Davis (jdavis-sitka) → nobody
Changed in evergreen:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers