summaryrefslogtreecommitdiff
path: root/www/js/rivendell.rh.js
diff options
context:
space:
mode:
authorPeterTheOne <petertheone@gmail.com>2016-01-29 14:06:18 (GMT)
committerPeterTheOne <petertheone@gmail.com>2016-01-29 14:06:18 (GMT)
commitf306d3578d0ec18e34df3b7ed30e20fa71339bf6 (patch)
treea95f562a6698d139e0a2901e3b7985a9080b0b5a /www/js/rivendell.rh.js
parentc09725d1a62830d69daf8d286638e0d334394f78 (diff)
move authLogin function to rivendel.rh.js, use more namespaces in jingles
Diffstat (limited to 'www/js/rivendell.rh.js')
-rw-r--r--www/js/rivendell.rh.js13
1 files changed, 12 insertions, 1 deletions
diff --git a/www/js/rivendell.rh.js b/www/js/rivendell.rh.js
index bc8252e..8e58d01 100644
--- a/www/js/rivendell.rh.js
+++ b/www/js/rivendell.rh.js
@@ -24,9 +24,20 @@
var Rivendell = Rivendell || {};
+Rivendell.Rivendell.authLogin = function(authEndpoint, username, password, success) {
+ return $.ajax(authEndpoint, {
+ username: username,
+ password: password,
+ success: success,
+ dataType: 'json',
+ cache: false
+ });
+};
+
Rivendell.Rivendell.prototype.setListDropboxesEndpoint = function(listDropboxesEndpoint) {
this.listDropboxesEndpoint = listDropboxesEndpoint;
};
+
Rivendell.Rivendell.prototype.setMusicgridEndpoint = function(musicgridEndpoint) {
this.musicgridEndpoint = musicgridEndpoint;
};
@@ -85,7 +96,7 @@ Rivendell.GroupList.prototype.fetch = function(type) {
// todo
break;*/
case 'jingle':
- group = new JingleGroup(groupXml);
+ group = new Rivendell.JingleGroup(groupXml);
break;
case 'musicpool':
group = new Rivendell.Musicpool(groupXml);