@easyedu/js-lsm-api 1.65.0 → 1.66.0

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.
Files changed (44) hide show
  1. package/README.md +2 -2
  2. package/dist/esm/models/GetCourse.d.ts +27 -0
  3. package/dist/esm/models/GetCourse.js +20 -0
  4. package/dist/esm/models/GetCourseEnrollment.d.ts +29 -1
  5. package/dist/esm/models/GetCourseEnrollment.js +23 -1
  6. package/dist/esm/models/GetCourseEnrollmentListItem.d.ts +28 -1
  7. package/dist/esm/models/GetCourseEnrollmentListItem.js +23 -1
  8. package/dist/esm/models/PostCourse.d.ts +29 -0
  9. package/dist/esm/models/PostCourse.js +14 -0
  10. package/dist/esm/models/PostCourseEnrollment.d.ts +18 -1
  11. package/dist/esm/models/PostCourseEnrollment.js +10 -3
  12. package/dist/esm/models/PutCourse.d.ts +27 -0
  13. package/dist/esm/models/PutCourse.js +14 -0
  14. package/dist/esm/models/PutCourseEnrollment.d.ts +8 -1
  15. package/dist/esm/models/PutCourseEnrollment.js +4 -1
  16. package/dist/models/GetCourse.d.ts +27 -0
  17. package/dist/models/GetCourse.js +21 -0
  18. package/dist/models/GetCourseEnrollment.d.ts +29 -1
  19. package/dist/models/GetCourseEnrollment.js +24 -2
  20. package/dist/models/GetCourseEnrollmentListItem.d.ts +28 -1
  21. package/dist/models/GetCourseEnrollmentListItem.js +24 -2
  22. package/dist/models/PostCourse.d.ts +29 -0
  23. package/dist/models/PostCourse.js +15 -0
  24. package/dist/models/PostCourseEnrollment.d.ts +18 -1
  25. package/dist/models/PostCourseEnrollment.js +11 -4
  26. package/dist/models/PutCourse.d.ts +27 -0
  27. package/dist/models/PutCourse.js +15 -0
  28. package/dist/models/PutCourseEnrollment.d.ts +8 -1
  29. package/dist/models/PutCourseEnrollment.js +4 -1
  30. package/docs/GetCourse.md +6 -0
  31. package/docs/GetCourseEnrollment.md +4 -0
  32. package/docs/GetCourseEnrollmentListItem.md +4 -0
  33. package/docs/PostCourse.md +6 -0
  34. package/docs/PostCourseEnrollment.md +2 -0
  35. package/docs/PutCourse.md +6 -0
  36. package/docs/PutCourseEnrollment.md +2 -0
  37. package/package.json +1 -1
  38. package/src/models/GetCourse.ts +39 -0
  39. package/src/models/GetCourseEnrollment.ts +37 -2
  40. package/src/models/GetCourseEnrollmentListItem.ts +36 -2
  41. package/src/models/PostCourse.ts +38 -0
  42. package/src/models/PostCourseEnrollment.ts +22 -3
  43. package/src/models/PutCourse.ts +36 -0
  44. package/src/models/PutCourseEnrollment.ts +11 -2
@@ -44,7 +44,7 @@ export interface GetCourseEnrollment {
44
44
  * @type {number}
45
45
  * @memberof GetCourseEnrollment
46
46
  */
47
- enrollmentDateEnd: number;
47
+ enrollmentDateEnd: number | null;
48
48
  /**
49
49
  * Optional notes about the enrollment
50
50
  * @type {string}
@@ -61,11 +61,24 @@ export interface GetCourseEnrollment {
61
61
  * - Withdrawn: learner pulled out before completion
62
62
  * - Removed: admin-removed enrollment
63
63
  * - Archived: historical / read-only (e.g. course share revoked)
64
+ * - Suspended: access temporarily disabled by an admin
64
65
  *
65
66
  * @type {GetCourseEnrollmentStatusEnum}
66
67
  * @memberof GetCourseEnrollment
67
68
  */
68
69
  status: GetCourseEnrollmentStatusEnum;
70
+ /**
71
+ * Derived learner access state for UI indicators and access decisions.
72
+ * @type {GetCourseEnrollmentAccessStateEnum}
73
+ * @memberof GetCourseEnrollment
74
+ */
75
+ accessState: GetCourseEnrollmentAccessStateEnum;
76
+ /**
77
+ * Whole days until access expiry; null for never-expiring or already inactive enrollments.
78
+ * @type {number}
79
+ * @memberof GetCourseEnrollment
80
+ */
81
+ daysUntilExpiry: number | null;
69
82
  /**
70
83
  * The role/type of the user in this enrollment
71
84
  * @type {GetCourseEnrollmentUserTypeEnum}
@@ -91,8 +104,23 @@ export declare const GetCourseEnrollmentStatusEnum: {
91
104
  readonly Withdrawn: "Withdrawn";
92
105
  readonly Removed: "Removed";
93
106
  readonly Archived: "Archived";
107
+ readonly Suspended: "Suspended";
94
108
  };
95
109
  export type GetCourseEnrollmentStatusEnum = typeof GetCourseEnrollmentStatusEnum[keyof typeof GetCourseEnrollmentStatusEnum];
110
+ /**
111
+ * @export
112
+ */
113
+ export declare const GetCourseEnrollmentAccessStateEnum: {
114
+ readonly Active: "active";
115
+ readonly CompletedReview: "completed_review";
116
+ readonly Expired: "expired";
117
+ readonly Suspended: "suspended";
118
+ readonly Failed: "failed";
119
+ readonly Withdrawn: "withdrawn";
120
+ readonly Removed: "removed";
121
+ readonly Archived: "archived";
122
+ };
123
+ export type GetCourseEnrollmentAccessStateEnum = typeof GetCourseEnrollmentAccessStateEnum[keyof typeof GetCourseEnrollmentAccessStateEnum];
96
124
  /**
97
125
  * @export
98
126
  */
@@ -13,7 +13,7 @@
13
13
  * Do not edit the class manually.
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
- exports.GetCourseEnrollmentUserTypeEnum = exports.GetCourseEnrollmentStatusEnum = void 0;
16
+ exports.GetCourseEnrollmentUserTypeEnum = exports.GetCourseEnrollmentAccessStateEnum = exports.GetCourseEnrollmentStatusEnum = void 0;
17
17
  exports.instanceOfGetCourseEnrollment = instanceOfGetCourseEnrollment;
18
18
  exports.GetCourseEnrollmentFromJSON = GetCourseEnrollmentFromJSON;
19
19
  exports.GetCourseEnrollmentFromJSONTyped = GetCourseEnrollmentFromJSONTyped;
@@ -30,7 +30,21 @@ exports.GetCourseEnrollmentStatusEnum = {
30
30
  Expired: 'Expired',
31
31
  Withdrawn: 'Withdrawn',
32
32
  Removed: 'Removed',
33
- Archived: 'Archived'
33
+ Archived: 'Archived',
34
+ Suspended: 'Suspended'
35
+ };
36
+ /**
37
+ * @export
38
+ */
39
+ exports.GetCourseEnrollmentAccessStateEnum = {
40
+ Active: 'active',
41
+ CompletedReview: 'completed_review',
42
+ Expired: 'expired',
43
+ Suspended: 'suspended',
44
+ Failed: 'failed',
45
+ Withdrawn: 'withdrawn',
46
+ Removed: 'removed',
47
+ Archived: 'archived'
34
48
  };
35
49
  /**
36
50
  * @export
@@ -57,6 +71,10 @@ function instanceOfGetCourseEnrollment(value) {
57
71
  return false;
58
72
  if (!('status' in value) || value['status'] === undefined)
59
73
  return false;
74
+ if (!('accessState' in value) || value['accessState'] === undefined)
75
+ return false;
76
+ if (!('daysUntilExpiry' in value) || value['daysUntilExpiry'] === undefined)
77
+ return false;
60
78
  if (!('userType' in value) || value['userType'] === undefined)
61
79
  return false;
62
80
  if (!('completionDate' in value) || value['completionDate'] === undefined)
@@ -78,6 +96,8 @@ function GetCourseEnrollmentFromJSONTyped(json, ignoreDiscriminator) {
78
96
  'enrollmentDateEnd': json['enrollment_date_end'],
79
97
  'notes': json['notes'],
80
98
  'status': json['status'],
99
+ 'accessState': json['access_state'],
100
+ 'daysUntilExpiry': json['days_until_expiry'],
81
101
  'userType': json['user_type'],
82
102
  'completionDate': json['completion_date'],
83
103
  };
@@ -97,6 +117,8 @@ function GetCourseEnrollmentToJSONTyped(value, ignoreDiscriminator = false) {
97
117
  'enrollment_date_end': value['enrollmentDateEnd'],
98
118
  'notes': value['notes'],
99
119
  'status': value['status'],
120
+ 'access_state': value['accessState'],
121
+ 'days_until_expiry': value['daysUntilExpiry'],
100
122
  'user_type': value['userType'],
101
123
  'completion_date': value['completionDate'],
102
124
  };
@@ -56,13 +56,25 @@ export interface GetCourseEnrollmentListItem {
56
56
  * @type {number}
57
57
  * @memberof GetCourseEnrollmentListItem
58
58
  */
59
- enrollmentDateEnd: number;
59
+ enrollmentDateEnd: number | null;
60
60
  /**
61
61
  * Current status of the enrollment
62
62
  * @type {GetCourseEnrollmentListItemStatusEnum}
63
63
  * @memberof GetCourseEnrollmentListItem
64
64
  */
65
65
  status: GetCourseEnrollmentListItemStatusEnum;
66
+ /**
67
+ * Derived learner access state for UI indicators and access decisions.
68
+ * @type {GetCourseEnrollmentListItemAccessStateEnum}
69
+ * @memberof GetCourseEnrollmentListItem
70
+ */
71
+ accessState: GetCourseEnrollmentListItemAccessStateEnum;
72
+ /**
73
+ * Whole days until access expiry; null for never-expiring or already inactive enrollments.
74
+ * @type {number}
75
+ * @memberof GetCourseEnrollmentListItem
76
+ */
77
+ daysUntilExpiry: number | null;
66
78
  /**
67
79
  * The role/type of the user in this enrollment
68
80
  * @type {GetCourseEnrollmentListItemUserTypeEnum}
@@ -88,8 +100,23 @@ export declare const GetCourseEnrollmentListItemStatusEnum: {
88
100
  readonly Withdrawn: "Withdrawn";
89
101
  readonly Removed: "Removed";
90
102
  readonly Archived: "Archived";
103
+ readonly Suspended: "Suspended";
91
104
  };
92
105
  export type GetCourseEnrollmentListItemStatusEnum = typeof GetCourseEnrollmentListItemStatusEnum[keyof typeof GetCourseEnrollmentListItemStatusEnum];
106
+ /**
107
+ * @export
108
+ */
109
+ export declare const GetCourseEnrollmentListItemAccessStateEnum: {
110
+ readonly Active: "active";
111
+ readonly CompletedReview: "completed_review";
112
+ readonly Expired: "expired";
113
+ readonly Suspended: "suspended";
114
+ readonly Failed: "failed";
115
+ readonly Withdrawn: "withdrawn";
116
+ readonly Removed: "removed";
117
+ readonly Archived: "archived";
118
+ };
119
+ export type GetCourseEnrollmentListItemAccessStateEnum = typeof GetCourseEnrollmentListItemAccessStateEnum[keyof typeof GetCourseEnrollmentListItemAccessStateEnum];
93
120
  /**
94
121
  * @export
95
122
  */
@@ -13,7 +13,7 @@
13
13
  * Do not edit the class manually.
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
- exports.GetCourseEnrollmentListItemUserTypeEnum = exports.GetCourseEnrollmentListItemStatusEnum = void 0;
16
+ exports.GetCourseEnrollmentListItemUserTypeEnum = exports.GetCourseEnrollmentListItemAccessStateEnum = exports.GetCourseEnrollmentListItemStatusEnum = void 0;
17
17
  exports.instanceOfGetCourseEnrollmentListItem = instanceOfGetCourseEnrollmentListItem;
18
18
  exports.GetCourseEnrollmentListItemFromJSON = GetCourseEnrollmentListItemFromJSON;
19
19
  exports.GetCourseEnrollmentListItemFromJSONTyped = GetCourseEnrollmentListItemFromJSONTyped;
@@ -30,7 +30,21 @@ exports.GetCourseEnrollmentListItemStatusEnum = {
30
30
  Expired: 'Expired',
31
31
  Withdrawn: 'Withdrawn',
32
32
  Removed: 'Removed',
33
- Archived: 'Archived'
33
+ Archived: 'Archived',
34
+ Suspended: 'Suspended'
35
+ };
36
+ /**
37
+ * @export
38
+ */
39
+ exports.GetCourseEnrollmentListItemAccessStateEnum = {
40
+ Active: 'active',
41
+ CompletedReview: 'completed_review',
42
+ Expired: 'expired',
43
+ Suspended: 'suspended',
44
+ Failed: 'failed',
45
+ Withdrawn: 'withdrawn',
46
+ Removed: 'removed',
47
+ Archived: 'archived'
34
48
  };
35
49
  /**
36
50
  * @export
@@ -59,6 +73,10 @@ function instanceOfGetCourseEnrollmentListItem(value) {
59
73
  return false;
60
74
  if (!('status' in value) || value['status'] === undefined)
61
75
  return false;
76
+ if (!('accessState' in value) || value['accessState'] === undefined)
77
+ return false;
78
+ if (!('daysUntilExpiry' in value) || value['daysUntilExpiry'] === undefined)
79
+ return false;
62
80
  if (!('userType' in value) || value['userType'] === undefined)
63
81
  return false;
64
82
  if (!('completionDate' in value) || value['completionDate'] === undefined)
@@ -81,6 +99,8 @@ function GetCourseEnrollmentListItemFromJSONTyped(json, ignoreDiscriminator) {
81
99
  'enrollmentDateStart': json['enrollment_date_start'],
82
100
  'enrollmentDateEnd': json['enrollment_date_end'],
83
101
  'status': json['status'],
102
+ 'accessState': json['access_state'],
103
+ 'daysUntilExpiry': json['days_until_expiry'],
84
104
  'userType': json['user_type'],
85
105
  'completionDate': json['completion_date'],
86
106
  };
@@ -101,6 +121,8 @@ function GetCourseEnrollmentListItemToJSONTyped(value, ignoreDiscriminator = fal
101
121
  'enrollment_date_start': value['enrollmentDateStart'],
102
122
  'enrollment_date_end': value['enrollmentDateEnd'],
103
123
  'status': value['status'],
124
+ 'access_state': value['accessState'],
125
+ 'days_until_expiry': value['daysUntilExpiry'],
104
126
  'user_type': value['userType'],
105
127
  'completion_date': value['completionDate'],
106
128
  };
@@ -27,7 +27,36 @@ export interface PostCourse {
27
27
  * @memberof PostCourse
28
28
  */
29
29
  description: string;
30
+ /**
31
+ * Course-level learner access policy. If omitted, new courses default to
32
+ * duration_days with 90 days.
33
+ *
34
+ * @type {PostCourseAccessPolicyTypeEnum}
35
+ * @memberof PostCourse
36
+ */
37
+ accessPolicyType?: PostCourseAccessPolicyTypeEnum;
38
+ /**
39
+ * Number of access days from enrollment start when access_policy_type is duration_days.
40
+ * @type {number}
41
+ * @memberof PostCourse
42
+ */
43
+ accessDurationDays?: number | null;
44
+ /**
45
+ * Fixed Unix timestamp when access expires when access_policy_type is fixed_end_date.
46
+ * @type {number}
47
+ * @memberof PostCourse
48
+ */
49
+ accessFixedEndAt?: number | null;
30
50
  }
51
+ /**
52
+ * @export
53
+ */
54
+ export declare const PostCourseAccessPolicyTypeEnum: {
55
+ readonly DurationDays: "duration_days";
56
+ readonly FixedEndDate: "fixed_end_date";
57
+ readonly NeverExpires: "never_expires";
58
+ };
59
+ export type PostCourseAccessPolicyTypeEnum = typeof PostCourseAccessPolicyTypeEnum[keyof typeof PostCourseAccessPolicyTypeEnum];
31
60
  /**
32
61
  * Check if a given object implements the PostCourse interface.
33
62
  */
@@ -13,11 +13,20 @@
13
13
  * Do not edit the class manually.
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.PostCourseAccessPolicyTypeEnum = void 0;
16
17
  exports.instanceOfPostCourse = instanceOfPostCourse;
17
18
  exports.PostCourseFromJSON = PostCourseFromJSON;
18
19
  exports.PostCourseFromJSONTyped = PostCourseFromJSONTyped;
19
20
  exports.PostCourseToJSON = PostCourseToJSON;
20
21
  exports.PostCourseToJSONTyped = PostCourseToJSONTyped;
22
+ /**
23
+ * @export
24
+ */
25
+ exports.PostCourseAccessPolicyTypeEnum = {
26
+ DurationDays: 'duration_days',
27
+ FixedEndDate: 'fixed_end_date',
28
+ NeverExpires: 'never_expires'
29
+ };
21
30
  /**
22
31
  * Check if a given object implements the PostCourse interface.
23
32
  */
@@ -38,6 +47,9 @@ function PostCourseFromJSONTyped(json, ignoreDiscriminator) {
38
47
  return {
39
48
  'name': json['name'],
40
49
  'description': json['description'],
50
+ 'accessPolicyType': json['access_policy_type'] == null ? undefined : json['access_policy_type'],
51
+ 'accessDurationDays': json['access_duration_days'] == null ? undefined : json['access_duration_days'],
52
+ 'accessFixedEndAt': json['access_fixed_end_at'] == null ? undefined : json['access_fixed_end_at'],
41
53
  };
42
54
  }
43
55
  function PostCourseToJSON(json) {
@@ -50,5 +62,8 @@ function PostCourseToJSONTyped(value, ignoreDiscriminator = false) {
50
62
  return {
51
63
  'name': value['name'],
52
64
  'description': value['description'],
65
+ 'access_policy_type': value['accessPolicyType'],
66
+ 'access_duration_days': value['accessDurationDays'],
67
+ 'access_fixed_end_at': value['accessFixedEndAt'],
53
68
  };
54
69
  }
@@ -26,7 +26,7 @@ export interface PostCourseEnrollment {
26
26
  * @type {number}
27
27
  * @memberof PostCourseEnrollment
28
28
  */
29
- enrollmentDateStart: number;
29
+ enrollmentDateStart?: number;
30
30
  /**
31
31
  * End date of the enrollment (Unix timestamp)
32
32
  * @type {number}
@@ -45,6 +45,15 @@ export interface PostCourseEnrollment {
45
45
  * @memberof PostCourseEnrollment
46
46
  */
47
47
  userType?: PostCourseEnrollmentUserTypeEnum | null;
48
+ /**
49
+ * How to handle a learner with a prior terminal enrollment for this course.
50
+ * restart creates a new enrollment period; resume reopens the latest terminal
51
+ * enrollment. Active enrollments always conflict.
52
+ *
53
+ * @type {PostCourseEnrollmentReEnrollmentModeEnum}
54
+ * @memberof PostCourseEnrollment
55
+ */
56
+ reEnrollmentMode?: PostCourseEnrollmentReEnrollmentModeEnum | null;
48
57
  }
49
58
  /**
50
59
  * @export
@@ -54,6 +63,14 @@ export declare const PostCourseEnrollmentUserTypeEnum: {
54
63
  readonly Instructor: "Instructor";
55
64
  };
56
65
  export type PostCourseEnrollmentUserTypeEnum = typeof PostCourseEnrollmentUserTypeEnum[keyof typeof PostCourseEnrollmentUserTypeEnum];
66
+ /**
67
+ * @export
68
+ */
69
+ export declare const PostCourseEnrollmentReEnrollmentModeEnum: {
70
+ readonly Restart: "restart";
71
+ readonly Resume: "resume";
72
+ };
73
+ export type PostCourseEnrollmentReEnrollmentModeEnum = typeof PostCourseEnrollmentReEnrollmentModeEnum[keyof typeof PostCourseEnrollmentReEnrollmentModeEnum];
57
74
  /**
58
75
  * Check if a given object implements the PostCourseEnrollment interface.
59
76
  */
@@ -13,7 +13,7 @@
13
13
  * Do not edit the class manually.
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
- exports.PostCourseEnrollmentUserTypeEnum = void 0;
16
+ exports.PostCourseEnrollmentReEnrollmentModeEnum = exports.PostCourseEnrollmentUserTypeEnum = void 0;
17
17
  exports.instanceOfPostCourseEnrollment = instanceOfPostCourseEnrollment;
18
18
  exports.PostCourseEnrollmentFromJSON = PostCourseEnrollmentFromJSON;
19
19
  exports.PostCourseEnrollmentFromJSONTyped = PostCourseEnrollmentFromJSONTyped;
@@ -26,14 +26,19 @@ exports.PostCourseEnrollmentUserTypeEnum = {
26
26
  Student: 'Student',
27
27
  Instructor: 'Instructor'
28
28
  };
29
+ /**
30
+ * @export
31
+ */
32
+ exports.PostCourseEnrollmentReEnrollmentModeEnum = {
33
+ Restart: 'restart',
34
+ Resume: 'resume'
35
+ };
29
36
  /**
30
37
  * Check if a given object implements the PostCourseEnrollment interface.
31
38
  */
32
39
  function instanceOfPostCourseEnrollment(value) {
33
40
  if (!('userId' in value) || value['userId'] === undefined)
34
41
  return false;
35
- if (!('enrollmentDateStart' in value) || value['enrollmentDateStart'] === undefined)
36
- return false;
37
42
  return true;
38
43
  }
39
44
  function PostCourseEnrollmentFromJSON(json) {
@@ -45,10 +50,11 @@ function PostCourseEnrollmentFromJSONTyped(json, ignoreDiscriminator) {
45
50
  }
46
51
  return {
47
52
  'userId': json['user_id'],
48
- 'enrollmentDateStart': json['enrollment_date_start'],
53
+ 'enrollmentDateStart': json['enrollment_date_start'] == null ? undefined : json['enrollment_date_start'],
49
54
  'enrollmentDateEnd': json['enrollment_date_end'] == null ? undefined : json['enrollment_date_end'],
50
55
  'notes': json['notes'] == null ? undefined : json['notes'],
51
56
  'userType': json['user_type'] == null ? undefined : json['user_type'],
57
+ 'reEnrollmentMode': json['re_enrollment_mode'] == null ? undefined : json['re_enrollment_mode'],
52
58
  };
53
59
  }
54
60
  function PostCourseEnrollmentToJSON(json) {
@@ -64,5 +70,6 @@ function PostCourseEnrollmentToJSONTyped(value, ignoreDiscriminator = false) {
64
70
  'enrollment_date_end': value['enrollmentDateEnd'],
65
71
  'notes': value['notes'],
66
72
  'user_type': value['userType'],
73
+ 're_enrollment_mode': value['reEnrollmentMode'],
67
74
  };
68
75
  }
@@ -39,7 +39,34 @@ export interface PutCourse {
39
39
  * @memberof PutCourse
40
40
  */
41
41
  published?: boolean;
42
+ /**
43
+ * Course-level learner access policy.
44
+ * @type {PutCourseAccessPolicyTypeEnum}
45
+ * @memberof PutCourse
46
+ */
47
+ accessPolicyType?: PutCourseAccessPolicyTypeEnum;
48
+ /**
49
+ * Number of access days from enrollment start when access_policy_type is duration_days.
50
+ * @type {number}
51
+ * @memberof PutCourse
52
+ */
53
+ accessDurationDays?: number | null;
54
+ /**
55
+ * Fixed Unix timestamp when access expires when access_policy_type is fixed_end_date.
56
+ * @type {number}
57
+ * @memberof PutCourse
58
+ */
59
+ accessFixedEndAt?: number | null;
42
60
  }
61
+ /**
62
+ * @export
63
+ */
64
+ export declare const PutCourseAccessPolicyTypeEnum: {
65
+ readonly DurationDays: "duration_days";
66
+ readonly FixedEndDate: "fixed_end_date";
67
+ readonly NeverExpires: "never_expires";
68
+ };
69
+ export type PutCourseAccessPolicyTypeEnum = typeof PutCourseAccessPolicyTypeEnum[keyof typeof PutCourseAccessPolicyTypeEnum];
43
70
  /**
44
71
  * Check if a given object implements the PutCourse interface.
45
72
  */
@@ -13,11 +13,20 @@
13
13
  * Do not edit the class manually.
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.PutCourseAccessPolicyTypeEnum = void 0;
16
17
  exports.instanceOfPutCourse = instanceOfPutCourse;
17
18
  exports.PutCourseFromJSON = PutCourseFromJSON;
18
19
  exports.PutCourseFromJSONTyped = PutCourseFromJSONTyped;
19
20
  exports.PutCourseToJSON = PutCourseToJSON;
20
21
  exports.PutCourseToJSONTyped = PutCourseToJSONTyped;
22
+ /**
23
+ * @export
24
+ */
25
+ exports.PutCourseAccessPolicyTypeEnum = {
26
+ DurationDays: 'duration_days',
27
+ FixedEndDate: 'fixed_end_date',
28
+ NeverExpires: 'never_expires'
29
+ };
21
30
  /**
22
31
  * Check if a given object implements the PutCourse interface.
23
32
  */
@@ -36,6 +45,9 @@ function PutCourseFromJSONTyped(json, ignoreDiscriminator) {
36
45
  'name': json['name'] == null ? undefined : json['name'],
37
46
  'description': json['description'] == null ? undefined : json['description'],
38
47
  'published': json['published'] == null ? undefined : json['published'],
48
+ 'accessPolicyType': json['access_policy_type'] == null ? undefined : json['access_policy_type'],
49
+ 'accessDurationDays': json['access_duration_days'] == null ? undefined : json['access_duration_days'],
50
+ 'accessFixedEndAt': json['access_fixed_end_at'] == null ? undefined : json['access_fixed_end_at'],
39
51
  };
40
52
  }
41
53
  function PutCourseToJSON(json) {
@@ -49,5 +61,8 @@ function PutCourseToJSONTyped(value, ignoreDiscriminator = false) {
49
61
  'name': value['name'],
50
62
  'description': value['description'],
51
63
  'published': value['published'],
64
+ 'access_policy_type': value['accessPolicyType'],
65
+ 'access_duration_days': value['accessDurationDays'],
66
+ 'access_fixed_end_at': value['accessFixedEndAt'],
52
67
  };
53
68
  }
@@ -35,7 +35,13 @@ export interface PutCourseEnrollment {
35
35
  * @type {number}
36
36
  * @memberof PutCourseEnrollment
37
37
  */
38
- enrollmentDateEnd?: number;
38
+ enrollmentDateEnd?: number | null;
39
+ /**
40
+ * Add this many days to the current end date, or to now if the enrollment is already expired.
41
+ * @type {number}
42
+ * @memberof PutCourseEnrollment
43
+ */
44
+ extensionDays?: number;
39
45
  /**
40
46
  * Optional notes about the enrollment
41
47
  * @type {string}
@@ -53,6 +59,7 @@ export declare const PutCourseEnrollmentStatusEnum: {
53
59
  readonly Withdrawn: "Withdrawn";
54
60
  readonly Removed: "Removed";
55
61
  readonly Archived: "Archived";
62
+ readonly Suspended: "Suspended";
56
63
  };
57
64
  export type PutCourseEnrollmentStatusEnum = typeof PutCourseEnrollmentStatusEnum[keyof typeof PutCourseEnrollmentStatusEnum];
58
65
  /**
@@ -28,7 +28,8 @@ exports.PutCourseEnrollmentStatusEnum = {
28
28
  Failed: 'Failed',
29
29
  Withdrawn: 'Withdrawn',
30
30
  Removed: 'Removed',
31
- Archived: 'Archived'
31
+ Archived: 'Archived',
32
+ Suspended: 'Suspended'
32
33
  };
33
34
  /**
34
35
  * @export
@@ -54,6 +55,7 @@ function PutCourseEnrollmentFromJSONTyped(json, ignoreDiscriminator) {
54
55
  'status': json['status'] == null ? undefined : json['status'],
55
56
  'userType': json['user_type'] == null ? undefined : json['user_type'],
56
57
  'enrollmentDateEnd': json['enrollment_date_end'] == null ? undefined : json['enrollment_date_end'],
58
+ 'extensionDays': json['extension_days'] == null ? undefined : json['extension_days'],
57
59
  'notes': json['notes'] == null ? undefined : json['notes'],
58
60
  };
59
61
  }
@@ -68,6 +70,7 @@ function PutCourseEnrollmentToJSONTyped(value, ignoreDiscriminator = false) {
68
70
  'status': value['status'],
69
71
  'user_type': value['userType'],
70
72
  'enrollment_date_end': value['enrollmentDateEnd'],
73
+ 'extension_days': value['extensionDays'],
71
74
  'notes': value['notes'],
72
75
  };
73
76
  }
package/docs/GetCourse.md CHANGED
@@ -12,6 +12,9 @@ Name | Type
12
12
  `imageUrl` | string
13
13
  `published` | boolean
14
14
  `createdAt` | number
15
+ `accessPolicyType` | string
16
+ `accessDurationDays` | number
17
+ `accessFixedEndAt` | number
15
18
 
16
19
  ## Example
17
20
 
@@ -26,6 +29,9 @@ const example = {
26
29
  "imageUrl": null,
27
30
  "published": null,
28
31
  "createdAt": null,
32
+ "accessPolicyType": null,
33
+ "accessDurationDays": null,
34
+ "accessFixedEndAt": null,
29
35
  } satisfies GetCourse
30
36
 
31
37
  console.log(example)
@@ -14,6 +14,8 @@ Name | Type
14
14
  `enrollmentDateEnd` | number
15
15
  `notes` | string
16
16
  `status` | string
17
+ `accessState` | string
18
+ `daysUntilExpiry` | number
17
19
  `userType` | string
18
20
  `completionDate` | number
19
21
 
@@ -31,6 +33,8 @@ const example = {
31
33
  "enrollmentDateEnd": null,
32
34
  "notes": null,
33
35
  "status": null,
36
+ "accessState": null,
37
+ "daysUntilExpiry": null,
34
38
  "userType": null,
35
39
  "completionDate": null,
36
40
  } satisfies GetCourseEnrollment
@@ -15,6 +15,8 @@ Name | Type
15
15
  `enrollmentDateStart` | number
16
16
  `enrollmentDateEnd` | number
17
17
  `status` | string
18
+ `accessState` | string
19
+ `daysUntilExpiry` | number
18
20
  `userType` | string
19
21
  `completionDate` | number
20
22
 
@@ -33,6 +35,8 @@ const example = {
33
35
  "enrollmentDateStart": null,
34
36
  "enrollmentDateEnd": null,
35
37
  "status": null,
38
+ "accessState": null,
39
+ "daysUntilExpiry": null,
36
40
  "userType": null,
37
41
  "completionDate": null,
38
42
  } satisfies GetCourseEnrollmentListItem
@@ -8,6 +8,9 @@ Name | Type
8
8
  ------------ | -------------
9
9
  `name` | string
10
10
  `description` | string
11
+ `accessPolicyType` | string
12
+ `accessDurationDays` | number
13
+ `accessFixedEndAt` | number
11
14
 
12
15
  ## Example
13
16
 
@@ -18,6 +21,9 @@ import type { PostCourse } from '@easyedu/js-lsm-api'
18
21
  const example = {
19
22
  "name": null,
20
23
  "description": null,
24
+ "accessPolicyType": null,
25
+ "accessDurationDays": null,
26
+ "accessFixedEndAt": null,
21
27
  } satisfies PostCourse
22
28
 
23
29
  console.log(example)
@@ -11,6 +11,7 @@ Name | Type
11
11
  `enrollmentDateEnd` | number
12
12
  `notes` | string
13
13
  `userType` | string
14
+ `reEnrollmentMode` | string
14
15
 
15
16
  ## Example
16
17
 
@@ -24,6 +25,7 @@ const example = {
24
25
  "enrollmentDateEnd": null,
25
26
  "notes": null,
26
27
  "userType": null,
28
+ "reEnrollmentMode": null,
27
29
  } satisfies PostCourseEnrollment
28
30
 
29
31
  console.log(example)
package/docs/PutCourse.md CHANGED
@@ -10,6 +10,9 @@ Name | Type
10
10
  `name` | string
11
11
  `description` | string
12
12
  `published` | boolean
13
+ `accessPolicyType` | string
14
+ `accessDurationDays` | number
15
+ `accessFixedEndAt` | number
13
16
 
14
17
  ## Example
15
18
 
@@ -22,6 +25,9 @@ const example = {
22
25
  "name": null,
23
26
  "description": null,
24
27
  "published": null,
28
+ "accessPolicyType": null,
29
+ "accessDurationDays": null,
30
+ "accessFixedEndAt": null,
25
31
  } satisfies PutCourse
26
32
 
27
33
  console.log(example)
@@ -9,6 +9,7 @@ Name | Type
9
9
  `status` | string
10
10
  `userType` | string
11
11
  `enrollmentDateEnd` | number
12
+ `extensionDays` | number
12
13
  `notes` | string
13
14
 
14
15
  ## Example
@@ -21,6 +22,7 @@ const example = {
21
22
  "status": null,
22
23
  "userType": null,
23
24
  "enrollmentDateEnd": null,
25
+ "extensionDays": null,
24
26
  "notes": null,
25
27
  } satisfies PutCourseEnrollment
26
28
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@easyedu/js-lsm-api",
3
- "version": "1.65.0",
3
+ "version": "1.66.0",
4
4
  "description": "OpenAPI client for @easyedu/js-lsm-api",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {