webstaff: add egJsonExporter directive
authorGalen Charlton <gmc@esilibrary.com>
Mon, 25 Jan 2016 23:30:48 +0000 (18:30 -0500)
committerKathy Lussier <klussier@masslnc.org>
Tue, 2 Feb 2016 19:58:53 +0000 (14:58 -0500)
commit4ed811a38128a29512e3de0f9dd84857ebb17145
treec5e9eaf69aba92800437cc0b5507c2ce6f63128f
parent66f9a004fe916e8217fd2bac71ed35ab49a5b9ff
webstaff: add egJsonExporter directive

This directive is used to allow a piece of JSON
to be saved to the user's filesystem.  For example:

<span eg-json-exporter container="foo" default-file-name="example.json">Export</span>

specifies a button that, when click, allows the user to save
the contents of the scope variable foo.  The dialog that
appears will use "example.json" as the default filename.

This also adds a new dependency, the MIT-licensed
 angular-file-saver service written by Philipp Alferov:

https://alferov.github.io/angular-file-saver/

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Open-ILS/src/templates/staff/base_js.tt2
Open-ILS/web/js/ui/default/staff/Gruntfile.js
Open-ILS/web/js/ui/default/staff/bower.json
Open-ILS/web/js/ui/default/staff/services/core.js
Open-ILS/web/js/ui/default/staff/services/file.js