webstaff: add routine for Dojo JS to detect if running in iframe
authorGalen Charlton <gmc@esilibrary.com>
Thu, 27 Aug 2015 22:23:23 +0000 (22:23 +0000)
committerGalen Charlton <gmc@esilibrary.com>
Mon, 14 Sep 2015 13:01:42 +0000 (13:01 +0000)
commit321b4224d8eecfbdbf8efe4b59d90ce909810908
tree26491f01d73e9d9a6b5a0b34cd6d6d2bdd6edf74
parent7513bec53fe334cd2767d9038e6e2cece4ae3b23
webstaff: add routine for Dojo JS to detect if running in iframe

Sometimes legacy Dojo interfaces may need to adjust their
behavior if they're embedded in the web staff client. This patch
adds a new utility function, openils.Util.inIFrame(), to detect
if such code is running in an iframe. If so, the presumption
is that iframe belongs to the web staff client.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Open-ILS/web/js/dojo/openils/Util.js