@selfcommunity/api-services 0.6.4-courses.245 → 0.6.4-courses.247
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.
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { SCCourseCommentType, SCCourseLessonType, SCCourseSectionType, SCCourseType, SCUserType } from '@selfcommunity/types';
|
|
2
2
|
import { AxiosRequestConfig } from 'axios';
|
|
3
|
-
import { BaseGetParams, CourseCreateParams, CourseDashboardUsersParams, CourseInfoParams, CourseLessonCommentsParams, CourseSearchParams, CourseUserRoleParams, CourseUsersParams, SCPaginatedResponse } from '../../types';
|
|
3
|
+
import { BaseGetParams, BaseSearchParams, CourseCreateParams, CourseDashboardUsersParams, CourseInfoParams, CourseLessonCommentsParams, CourseSearchParams, CourseUserRoleParams, CourseUsersParams, SCPaginatedResponse } from '../../types';
|
|
4
4
|
import { CourseSectionParams, CourseUserParams } from '../../types/course';
|
|
5
5
|
export interface CourseApiClientInterface {
|
|
6
6
|
changeCourseUserRole(id: number | string, data: CourseUserRoleParams, config?: AxiosRequestConfig): Promise<any>;
|
|
@@ -432,7 +432,7 @@ export default class CourseService {
|
|
|
432
432
|
static markLessonComplete(id: number | string, section_id: number | string, lesson_id: number | string, config?: AxiosRequestConfig): Promise<any>;
|
|
433
433
|
static markLessonIncomplete(id: number | string, section_id: number | string, lesson_id: number | string, config?: AxiosRequestConfig): Promise<any>;
|
|
434
434
|
static changeCourseCover(id: number | string, data: FormData, config?: AxiosRequestConfig): Promise<SCCourseType>;
|
|
435
|
-
static getCourseWaitingApproval(id: number | string, params?:
|
|
435
|
+
static getCourseWaitingApproval(id: number | string, params?: BaseSearchParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCUserType>>;
|
|
436
436
|
static getCourseSuggestedUsers(id: number | string, search: string, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCUserType>>;
|
|
437
437
|
static getCourseInvitedUsers(id: number | string, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCUserType>>;
|
|
438
438
|
static getCourseJoinedUsers(id: number | string, params?: CourseUsersParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCUserType>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* CourseCreateParams interface
|
|
3
3
|
*/
|
|
4
|
-
import { SCCoursePrivacyType, SCCourseJoinStatusType, SCCourseTypologyType } from '@selfcommunity/types';
|
|
4
|
+
import { SCCoursePrivacyType, SCCourseJoinStatusType, SCCourseTypologyType, SCCourseOrderingUsersType } from '@selfcommunity/types';
|
|
5
5
|
import { BaseGetParams, BaseSearchParams } from './baseParams';
|
|
6
6
|
export interface CourseCreateParams {
|
|
7
7
|
/**
|
|
@@ -120,4 +120,8 @@ export interface CourseDashboardUsersParams extends BaseSearchParams {
|
|
|
120
120
|
* Filter by join_status; default: ["manager", "joined"]
|
|
121
121
|
*/
|
|
122
122
|
statuses?: SCCourseJoinStatusType[];
|
|
123
|
+
/**
|
|
124
|
+
* The order of the users. Default to -joined_at
|
|
125
|
+
*/
|
|
126
|
+
ordering?: SCCourseOrderingUsersType;
|
|
123
127
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { SCCourseCommentType, SCCourseLessonType, SCCourseSectionType, SCCourseType, SCUserType } from '@selfcommunity/types';
|
|
2
2
|
import { AxiosRequestConfig } from 'axios';
|
|
3
|
-
import { BaseGetParams, CourseCreateParams, CourseDashboardUsersParams, CourseInfoParams, CourseLessonCommentsParams, CourseSearchParams, CourseUserRoleParams, CourseUsersParams, SCPaginatedResponse } from '../../types';
|
|
3
|
+
import { BaseGetParams, BaseSearchParams, CourseCreateParams, CourseDashboardUsersParams, CourseInfoParams, CourseLessonCommentsParams, CourseSearchParams, CourseUserRoleParams, CourseUsersParams, SCPaginatedResponse } from '../../types';
|
|
4
4
|
import { CourseSectionParams, CourseUserParams } from '../../types/course';
|
|
5
5
|
export interface CourseApiClientInterface {
|
|
6
6
|
changeCourseUserRole(id: number | string, data: CourseUserRoleParams, config?: AxiosRequestConfig): Promise<any>;
|
|
@@ -432,7 +432,7 @@ export default class CourseService {
|
|
|
432
432
|
static markLessonComplete(id: number | string, section_id: number | string, lesson_id: number | string, config?: AxiosRequestConfig): Promise<any>;
|
|
433
433
|
static markLessonIncomplete(id: number | string, section_id: number | string, lesson_id: number | string, config?: AxiosRequestConfig): Promise<any>;
|
|
434
434
|
static changeCourseCover(id: number | string, data: FormData, config?: AxiosRequestConfig): Promise<SCCourseType>;
|
|
435
|
-
static getCourseWaitingApproval(id: number | string, params?:
|
|
435
|
+
static getCourseWaitingApproval(id: number | string, params?: BaseSearchParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCUserType>>;
|
|
436
436
|
static getCourseSuggestedUsers(id: number | string, search: string, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCUserType>>;
|
|
437
437
|
static getCourseInvitedUsers(id: number | string, params?: BaseGetParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCUserType>>;
|
|
438
438
|
static getCourseJoinedUsers(id: number | string, params?: CourseUsersParams, config?: AxiosRequestConfig): Promise<SCPaginatedResponse<SCUserType>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* CourseCreateParams interface
|
|
3
3
|
*/
|
|
4
|
-
import { SCCoursePrivacyType, SCCourseJoinStatusType, SCCourseTypologyType } from '@selfcommunity/types';
|
|
4
|
+
import { SCCoursePrivacyType, SCCourseJoinStatusType, SCCourseTypologyType, SCCourseOrderingUsersType } from '@selfcommunity/types';
|
|
5
5
|
import { BaseGetParams, BaseSearchParams } from './baseParams';
|
|
6
6
|
export interface CourseCreateParams {
|
|
7
7
|
/**
|
|
@@ -120,4 +120,8 @@ export interface CourseDashboardUsersParams extends BaseSearchParams {
|
|
|
120
120
|
* Filter by join_status; default: ["manager", "joined"]
|
|
121
121
|
*/
|
|
122
122
|
statuses?: SCCourseJoinStatusType[];
|
|
123
|
+
/**
|
|
124
|
+
* The order of the users. Default to -joined_at
|
|
125
|
+
*/
|
|
126
|
+
ordering?: SCCourseOrderingUsersType;
|
|
123
127
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@selfcommunity/api-services",
|
|
3
|
-
"version": "0.6.4-courses.
|
|
3
|
+
"version": "0.6.4-courses.247+7e1c58ffd",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"private": false,
|
|
6
6
|
"main": "./lib/cjs/index.js",
|
|
@@ -58,8 +58,8 @@
|
|
|
58
58
|
"access": "public"
|
|
59
59
|
},
|
|
60
60
|
"dependencies": {
|
|
61
|
-
"@selfcommunity/types": "0.7.4-courses.
|
|
62
|
-
"@selfcommunity/utils": "0.2.61-courses.
|
|
61
|
+
"@selfcommunity/types": "0.7.4-courses.247+7e1c58ffd",
|
|
62
|
+
"@selfcommunity/utils": "0.2.61-courses.247+7e1c58ffd",
|
|
63
63
|
"axios": "^1.4.0",
|
|
64
64
|
"jose": "^4.14.4"
|
|
65
65
|
},
|
|
@@ -115,5 +115,5 @@
|
|
|
115
115
|
"bugs": {
|
|
116
116
|
"url": "https://github.com/selfcommunity/community-js/issues"
|
|
117
117
|
},
|
|
118
|
-
"gitHead": "
|
|
118
|
+
"gitHead": "7e1c58ffdef056415e23217a119adc50bba058d8"
|
|
119
119
|
}
|