Update the Javascript to remove JWT token auth

ECOM-6396
This commit is contained in:
Simon Chen
2016-11-28 15:49:04 -05:00
parent 5492fb9b8b
commit 664920b930
2 changed files with 3 additions and 14 deletions

View File

@@ -1,10 +0,0 @@
define([
'backbone',
'js/programs/utils/auth_utils'
],
function(Backbone, auth) {
'use strict';
return Backbone.Collection.extend(auth.autoSync);
}
);

View File

@@ -2,19 +2,18 @@ define([
'backbone',
'jquery',
'js/programs/utils/api_config',
'js/programs/collections/auto_auth_collection',
'jquery.cookie'
],
function(Backbone, $, apiConfig, AutoAuthCollection) {
function(Backbone, $, apiConfig) {
'use strict';
return AutoAuthCollection.extend({
return Backbone.Collection.extend({
allRuns: [],
initialize: function(models, options) {
// Ignore pagination and give me everything
var orgStr = options.organization.key,
queries = '?org=' + orgStr + '&username=' + apiConfig.get('username') + '&page_size=1000';
queries = '?org=' + orgStr + '&page_size=1000';
this.url = apiConfig.get('lmsBaseUrl') + 'api/courses/v1/courses/' + queries;
},