LP#1724915 Webstaff auth timeout works w/ multiple tabs
authorBill Erickson <berickxx@gmail.com>
Thu, 19 Oct 2017 18:46:01 +0000 (14:46 -0400)
committerGalen Charlton <gmc@equinoxinitiative.org>
Wed, 8 Nov 2017 17:32:16 +0000 (12:32 -0500)
commitcb4d5435608e61d75556a3112971d957a6f4c4c2
tree5122567bd2d6934da37e399153d0b861460908bf
parentceda20ae40203ef15056dce5dd453e9f8558cf9e
LP#1724915 Webstaff auth timeout works w/ multiple tabs

Adds a new API parameter to open-ils.session.retrieve which allows the
session to be fetched without extending the auth session timeout.

Teach the browser client to use the new API.

Teach the browser client to notify all webstaff tabs when a logout event
has occurred, so every tab can immediately log out.

To test
-------
[0] Apply the patch.
[1] Log in the web staff client, then open a new window/tab
    and navigate to the web staff client.
[2] Log out of the web staff client in one window. Verify that
    the second window automatically refreshes and goes to the
    login page.
[3] Set a low staff idle timeout (optional).
[4] Repeat step 1, then wait for the timeout. Verify that the
    staff client is logged out in both windows.

Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Open-ILS/src/c-apps/oils_auth.c
Open-ILS/web/js/ui/default/staff/services/auth.js
Open-ILS/web/js/ui/default/staff/services/startup.js