@x-edu/service 0.0.1 → 0.0.3
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.
- package/dist/config/index.d.ts +24 -0
- package/dist/index.d.ts +26 -0
- package/dist/request/cdn.d.ts +9 -0
- package/dist/request/elearning-library.d.ts +4 -0
- package/dist/request/helper.d.ts +1 -1
- package/dist/request/site-config.d.ts +4 -0
- package/dist/service/channel.d.ts +20 -0
- package/dist/service/elearningTrain.d.ts +6 -0
- package/dist/service/library.d.ts +34 -0
- package/dist/service/siteConfig.d.ts +10 -0
- package/dist/service/tCourse.d.ts +35 -0
- package/dist/service.js +984 -110
- package/dist/service.mjs +984 -110
- package/dist/service.umd.js +984 -110
- package/dist/util.d.ts +5 -0
- package/package.json +4 -3
package/dist/config/index.d.ts
CHANGED
|
@@ -8,6 +8,19 @@ declare const config: {
|
|
|
8
8
|
'cs-feedback': string;
|
|
9
9
|
'e-favorite-api': string;
|
|
10
10
|
'x-study-record': string;
|
|
11
|
+
cdn: any;
|
|
12
|
+
'cdn-s-file': any;
|
|
13
|
+
'cdn-bdcs-file': string;
|
|
14
|
+
'site-config': string;
|
|
15
|
+
serviceName: {
|
|
16
|
+
site: string;
|
|
17
|
+
zxxRegion: string;
|
|
18
|
+
train: string;
|
|
19
|
+
't-course': string;
|
|
20
|
+
eLabour: string;
|
|
21
|
+
};
|
|
22
|
+
defaultAreaSite: string;
|
|
23
|
+
'elearning-library': string;
|
|
11
24
|
};
|
|
12
25
|
preproduction: {
|
|
13
26
|
'x-proxy': string;
|
|
@@ -17,6 +30,17 @@ declare const config: {
|
|
|
17
30
|
'cs-feedback': string;
|
|
18
31
|
'e-favorite-api': string;
|
|
19
32
|
'x-study-record': string;
|
|
33
|
+
cdn: string;
|
|
34
|
+
'site-config': string;
|
|
35
|
+
serviceName: {
|
|
36
|
+
site: string;
|
|
37
|
+
zxxRegion: string;
|
|
38
|
+
train: string;
|
|
39
|
+
't-course': string;
|
|
40
|
+
eLabour: string;
|
|
41
|
+
};
|
|
42
|
+
defaultAreaSite: string;
|
|
43
|
+
'elearning-library': string;
|
|
20
44
|
};
|
|
21
45
|
};
|
|
22
46
|
export default config;
|
package/dist/index.d.ts
CHANGED
|
@@ -6,10 +6,12 @@ declare class Service {
|
|
|
6
6
|
rawAPI: any;
|
|
7
7
|
recommend: any;
|
|
8
8
|
sdpAppId?: string;
|
|
9
|
+
config: any;
|
|
9
10
|
private static instance;
|
|
10
11
|
constructor(props: any);
|
|
11
12
|
static getInstance(ucInstance: any): Service;
|
|
12
13
|
setUC(ucInstance: any): void;
|
|
14
|
+
initSingleRequest(requestFn: any): any;
|
|
13
15
|
init(): void;
|
|
14
16
|
}
|
|
15
17
|
export default Service;
|
|
@@ -23,6 +25,19 @@ export declare const serviceConfig: {
|
|
|
23
25
|
'cs-feedback': string;
|
|
24
26
|
'e-favorite-api': string;
|
|
25
27
|
'x-study-record': string;
|
|
28
|
+
cdn: any;
|
|
29
|
+
'cdn-s-file': any;
|
|
30
|
+
'cdn-bdcs-file': string;
|
|
31
|
+
'site-config': string;
|
|
32
|
+
serviceName: {
|
|
33
|
+
site: string;
|
|
34
|
+
zxxRegion: string;
|
|
35
|
+
train: string;
|
|
36
|
+
't-course': string;
|
|
37
|
+
eLabour: string;
|
|
38
|
+
};
|
|
39
|
+
defaultAreaSite: string;
|
|
40
|
+
'elearning-library': string;
|
|
26
41
|
};
|
|
27
42
|
preproduction: {
|
|
28
43
|
'x-proxy': string;
|
|
@@ -32,5 +47,16 @@ export declare const serviceConfig: {
|
|
|
32
47
|
'cs-feedback': string;
|
|
33
48
|
'e-favorite-api': string;
|
|
34
49
|
'x-study-record': string;
|
|
50
|
+
cdn: string;
|
|
51
|
+
'site-config': string;
|
|
52
|
+
serviceName: {
|
|
53
|
+
site: string;
|
|
54
|
+
zxxRegion: string;
|
|
55
|
+
train: string;
|
|
56
|
+
't-course': string;
|
|
57
|
+
eLabour: string;
|
|
58
|
+
};
|
|
59
|
+
defaultAreaSite: string;
|
|
60
|
+
'elearning-library': string;
|
|
35
61
|
};
|
|
36
62
|
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const cdnAPI: ({ env, }: {
|
|
2
|
+
env: any;
|
|
3
|
+
}) => import('../../node_modules/@x-edu/functions/dist/request/interface').RequestInstance;
|
|
4
|
+
export declare const cdnSFileAPI: ({ env, }: {
|
|
5
|
+
env: any;
|
|
6
|
+
}) => import('../../node_modules/@x-edu/functions/dist/request/interface').RequestInstance;
|
|
7
|
+
export declare const cdnBdcsFileAPI: ({ env, }: {
|
|
8
|
+
env: any;
|
|
9
|
+
}) => import('../../node_modules/@x-edu/functions/dist/request/interface').RequestInstance;
|
package/dist/request/helper.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export declare const parseParams: (params: any) => any;
|
|
2
|
-
export declare function getApi({ uc, host, prefix, params, throwError, sdpAppId }: any): import('../../node_modules/@x-edu/functions/dist/request/interface').RequestInstance;
|
|
2
|
+
export declare function getApi({ uc, host, prefix, params, throwError, sdpAppId, noSdpAppId, }: any): import('../../node_modules/@x-edu/functions/dist/request/interface').RequestInstance;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
declare class Channel {
|
|
2
|
+
request: any;
|
|
3
|
+
constructor(props: any);
|
|
4
|
+
getChannelList: ({ scope, language, sdpAppId, sdpOrgId, serviceName, api }: {
|
|
5
|
+
scope: any;
|
|
6
|
+
language?: string | undefined;
|
|
7
|
+
sdpAppId: any;
|
|
8
|
+
sdpOrgId: any;
|
|
9
|
+
serviceName: any;
|
|
10
|
+
api?: any;
|
|
11
|
+
}) => Promise<any>;
|
|
12
|
+
getChannelSectionList: ({ channelId, serviceName, sdpAppId, sdpOrgId, api }: {
|
|
13
|
+
channelId: any;
|
|
14
|
+
serviceName: any;
|
|
15
|
+
sdpAppId: any;
|
|
16
|
+
sdpOrgId: any;
|
|
17
|
+
api?: any;
|
|
18
|
+
}) => Promise<any>;
|
|
19
|
+
}
|
|
20
|
+
export default Channel;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 内容库
|
|
3
|
+
*/
|
|
4
|
+
declare class Library {
|
|
5
|
+
request: any;
|
|
6
|
+
config: any;
|
|
7
|
+
constructor(props: any);
|
|
8
|
+
getLibraryDynamicData: ({ libraryId, sdpOrgId }: {
|
|
9
|
+
libraryId: any;
|
|
10
|
+
sdpOrgId: any;
|
|
11
|
+
}) => Promise<any>;
|
|
12
|
+
getRequestURL: ({ apiURL, language, serviceName, sdpOrgId, sdpAppId }: {
|
|
13
|
+
apiURL: any;
|
|
14
|
+
language?: string | undefined;
|
|
15
|
+
serviceName: any;
|
|
16
|
+
sdpOrgId: any;
|
|
17
|
+
sdpAppId: any;
|
|
18
|
+
}) => Promise<string>;
|
|
19
|
+
getLibraryContentListAll: any;
|
|
20
|
+
getLibraryContentByUnitId: ({ libraryId, unitId, sdpAppId, sdpOrgId, serviceName, api }: {
|
|
21
|
+
libraryId: any;
|
|
22
|
+
unitId: any;
|
|
23
|
+
sdpAppId: any;
|
|
24
|
+
sdpOrgId: any;
|
|
25
|
+
serviceName: any;
|
|
26
|
+
api: any;
|
|
27
|
+
}) => Promise<any>;
|
|
28
|
+
getDynamicCatalogs: ({ libraryId, sdpOrgId }: {
|
|
29
|
+
libraryId: any;
|
|
30
|
+
sdpOrgId: any;
|
|
31
|
+
}) => Promise<any>;
|
|
32
|
+
getLibraryCatalogs: any;
|
|
33
|
+
}
|
|
34
|
+
export default Library;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
declare class TCourse {
|
|
2
|
+
request: any;
|
|
3
|
+
config: any;
|
|
4
|
+
constructor(props: any);
|
|
5
|
+
getCourseRelativeInfo1: any;
|
|
6
|
+
getCourseRelativeInfo: ({ courseId, tenantCode }: {
|
|
7
|
+
courseId: any;
|
|
8
|
+
tenantCode: any;
|
|
9
|
+
}) => Promise<any>;
|
|
10
|
+
getAreaCourseRelativeInfo: any;
|
|
11
|
+
/**
|
|
12
|
+
* 获取活动集信息, 包括了章节目录信息
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @param {string} activitySetId
|
|
16
|
+
* @returns 课程的活动集信息, nodes字段中包含活动节点信息
|
|
17
|
+
*/
|
|
18
|
+
getActiveSet: ({ activitySetId, tenantCode }: {
|
|
19
|
+
activitySetId: any;
|
|
20
|
+
tenantCode: any;
|
|
21
|
+
}) => Promise<any>;
|
|
22
|
+
getAreaActiveSet: ({ activitySetId, siteRelaId }: {
|
|
23
|
+
activitySetId: any;
|
|
24
|
+
siteRelaId: any;
|
|
25
|
+
}) => Promise<any>;
|
|
26
|
+
getVideoActivity: ({ activityId, siteRelaId }: {
|
|
27
|
+
activityId: any;
|
|
28
|
+
siteRelaId: any;
|
|
29
|
+
}) => Promise<any>;
|
|
30
|
+
getDocumentActivity: ({ activityId, siteRelaId }: {
|
|
31
|
+
activityId: any;
|
|
32
|
+
siteRelaId: any;
|
|
33
|
+
}) => Promise<any>;
|
|
34
|
+
}
|
|
35
|
+
export default TCourse;
|