@sunbird-cb/utils-v2 0.0.5 → 0.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2864,14 +2864,17 @@ var AuthKeycloakService = (function () {
2864
2864
  case 0:
2865
2865
  if (!storage$1.getItem('telemetrySessionId')) return [3, 1];
2866
2866
  storage$1.removeItem('telemetrySessionId');
2867
- return [3, 3];
2867
+ return [3, 4];
2868
2868
  case 1:
2869
2869
  storage$1.removeItem(storageKey$1);
2870
2870
  return [4, this.http.get('/apis/reset').toPromise()];
2871
2871
  case 2:
2872
2872
  _a.sent();
2873
- _a.label = 3;
2873
+ return [4, this.http.get('https://admin-test.ecornell.com/saml/logout.do').toPromise()];
2874
2874
  case 3:
2875
+ _a.sent();
2876
+ _a.label = 4;
2877
+ case 4:
2875
2878
  try {
2876
2879
  sessionStorage.clear();
2877
2880
  localStorage.clear();
@@ -2880,7 +2883,10 @@ var AuthKeycloakService = (function () {
2880
2883
  }
2881
2884
  storage$1.removeItem(storageKey$1);
2882
2885
  return [4, this.http.get('/apis/reset').toPromise()];
2883
- case 4:
2886
+ case 5:
2887
+ _a.sent();
2888
+ return [4, this.http.get('https://admin-test.ecornell.com/saml/logout.do').toPromise()];
2889
+ case 6:
2884
2890
  _a.sent();
2885
2891
  return [2];
2886
2892
  }
@@ -3948,9 +3954,12 @@ var PipePublicURL = (function () {
3948
3954
  this.environment = environment;
3949
3955
  }
3950
3956
  PipePublicURL.prototype.transform = function (value) {
3951
- var mainUrl = value && value.split('/content').pop() || '';
3952
- var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + "/content" + mainUrl;
3953
- return value ? finalURL : '';
3957
+ if (value.includes('karmayogi')) {
3958
+ var mainUrl = value && value.split('/content').pop() || '';
3959
+ var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + "/content" + mainUrl;
3960
+ return value ? finalURL : '';
3961
+ }
3962
+ return value;
3954
3963
  };
3955
3964
  PipePublicURL.decorators = [
3956
3965
  { type: Pipe, args: [{
@@ -5440,7 +5449,7 @@ var NsContent;
5440
5449
  var PROTECTED_SLAG_V8 = '/apis/protected/v8';
5441
5450
  var ɵ0 = function (type, id) {
5442
5451
  return PROTECTED_SLAG_V8 + "/content/collection/" + type + "/" + id;
5443
- }, ɵ1 = function (contentId) { return PROTECTED_SLAG_V8 + "/user/progress/" + contentId; };
5452
+ }, ɵ1 = function (contentId) { return PROTECTED_SLAG_V8 + "/user/progress/" + contentId; }, ɵ2 = function (contentId) { return "/apis/proxies/v8/cios-enroll/v1/readby/useridcourseid/" + contentId; };
5444
5453
  var API_END_POINTS = {
5445
5454
  CONTENT: PROTECTED_SLAG_V8 + "/content",
5446
5455
  AUTHORING_CONTENT: "/apis/authApi/hierarchy",
@@ -5459,6 +5468,8 @@ var API_END_POINTS = {
5459
5468
  COLLECTION_HIERARCHY: (ɵ0),
5460
5469
  REGISTRATION_STATUS: PROTECTED_SLAG_V8 + "/admin/userRegistration/checkUserRegistrationContent",
5461
5470
  MARK_AS_COMPLETE_META: (ɵ1),
5471
+ EXT_USER_COURSE_ENROLL: (ɵ2),
5472
+ EXT_CONTENT_EROLL: "/apis/proxies/v8/cios-enroll/v1/create",
5462
5473
  };
5463
5474
  var WidgetContentService = (function () {
5464
5475
  function WidgetContentService(http, configSvc) {
@@ -5622,6 +5633,12 @@ var WidgetContentService = (function () {
5622
5633
  WidgetContentService.prototype.fetchConfig = function (url) {
5623
5634
  return this.http.get(url);
5624
5635
  };
5636
+ WidgetContentService.prototype.fetchExtUserContentEnroll = function (contentId) {
5637
+ return this.http.get(API_END_POINTS.EXT_USER_COURSE_ENROLL(contentId));
5638
+ };
5639
+ WidgetContentService.prototype.extContentEnroll = function (requestBody) {
5640
+ return this.http.post("" + API_END_POINTS.EXT_CONTENT_EROLL, requestBody);
5641
+ };
5625
5642
  WidgetContentService.decorators = [
5626
5643
  { type: Injectable, args: [{
5627
5644
  providedIn: 'root',