@x-edu/service 0.0.6 → 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.
- package/dist/service/tCourse.d.ts +2 -1
- package/dist/service.js +12 -5
- package/dist/service.mjs +12 -5
- package/dist/service.umd.js +12 -5
- package/package.json +1 -1
|
@@ -23,9 +23,10 @@ declare class TCourse {
|
|
|
23
23
|
activitySetId: any;
|
|
24
24
|
siteRelaId: any;
|
|
25
25
|
}) => Promise<any>;
|
|
26
|
-
getVideoActivity: ({ activityId, siteRelaId }: {
|
|
26
|
+
getVideoActivity: ({ activityId, siteRelaId, serviceName }: {
|
|
27
27
|
activityId: any;
|
|
28
28
|
siteRelaId: any;
|
|
29
|
+
serviceName: any;
|
|
29
30
|
}) => Promise<any>;
|
|
30
31
|
getDocumentActivity: ({ activityId, siteRelaId }: {
|
|
31
32
|
activityId: any;
|
package/dist/service.js
CHANGED
|
@@ -18966,11 +18966,18 @@ class TCourse {
|
|
|
18966
18966
|
return data;
|
|
18967
18967
|
});
|
|
18968
18968
|
// 获取视频活动课时
|
|
18969
|
-
__publicField(this, "getVideoActivity", async ({ activityId, siteRelaId }) => {
|
|
18970
|
-
|
|
18971
|
-
|
|
18972
|
-
|
|
18973
|
-
|
|
18969
|
+
__publicField(this, "getVideoActivity", async ({ activityId, siteRelaId, serviceName: serviceName2 }) => {
|
|
18970
|
+
if (siteRelaId) {
|
|
18971
|
+
const { data } = await this.request.cdn.cdnAPI.get(
|
|
18972
|
+
`/${this.config.serviceName.zxxRegion}/${siteRelaId}/s_course/v1/video_activity/${activityId}.json`
|
|
18973
|
+
);
|
|
18974
|
+
return data;
|
|
18975
|
+
} else {
|
|
18976
|
+
const { data } = await this.request.cdn.cdnAPI.get(
|
|
18977
|
+
`/${serviceName2}/s_course/v1/video_activity/${activityId}.json`
|
|
18978
|
+
);
|
|
18979
|
+
return data;
|
|
18980
|
+
}
|
|
18974
18981
|
});
|
|
18975
18982
|
// 获取文档活动课时
|
|
18976
18983
|
__publicField(this, "getDocumentActivity", async ({ activityId, siteRelaId }) => {
|
package/dist/service.mjs
CHANGED
|
@@ -18964,11 +18964,18 @@ class TCourse {
|
|
|
18964
18964
|
return data;
|
|
18965
18965
|
});
|
|
18966
18966
|
// 获取视频活动课时
|
|
18967
|
-
__publicField(this, "getVideoActivity", async ({ activityId, siteRelaId }) => {
|
|
18968
|
-
|
|
18969
|
-
|
|
18970
|
-
|
|
18971
|
-
|
|
18967
|
+
__publicField(this, "getVideoActivity", async ({ activityId, siteRelaId, serviceName: serviceName2 }) => {
|
|
18968
|
+
if (siteRelaId) {
|
|
18969
|
+
const { data } = await this.request.cdn.cdnAPI.get(
|
|
18970
|
+
`/${this.config.serviceName.zxxRegion}/${siteRelaId}/s_course/v1/video_activity/${activityId}.json`
|
|
18971
|
+
);
|
|
18972
|
+
return data;
|
|
18973
|
+
} else {
|
|
18974
|
+
const { data } = await this.request.cdn.cdnAPI.get(
|
|
18975
|
+
`/${serviceName2}/s_course/v1/video_activity/${activityId}.json`
|
|
18976
|
+
);
|
|
18977
|
+
return data;
|
|
18978
|
+
}
|
|
18972
18979
|
});
|
|
18973
18980
|
// 获取文档活动课时
|
|
18974
18981
|
__publicField(this, "getDocumentActivity", async ({ activityId, siteRelaId }) => {
|
package/dist/service.umd.js
CHANGED
|
@@ -18968,11 +18968,18 @@ var __publicField = (obj, key, value) => {
|
|
|
18968
18968
|
return data;
|
|
18969
18969
|
});
|
|
18970
18970
|
// 获取视频活动课时
|
|
18971
|
-
__publicField(this, "getVideoActivity", async ({ activityId, siteRelaId }) => {
|
|
18972
|
-
|
|
18973
|
-
|
|
18974
|
-
|
|
18975
|
-
|
|
18971
|
+
__publicField(this, "getVideoActivity", async ({ activityId, siteRelaId, serviceName: serviceName2 }) => {
|
|
18972
|
+
if (siteRelaId) {
|
|
18973
|
+
const { data } = await this.request.cdn.cdnAPI.get(
|
|
18974
|
+
`/${this.config.serviceName.zxxRegion}/${siteRelaId}/s_course/v1/video_activity/${activityId}.json`
|
|
18975
|
+
);
|
|
18976
|
+
return data;
|
|
18977
|
+
} else {
|
|
18978
|
+
const { data } = await this.request.cdn.cdnAPI.get(
|
|
18979
|
+
`/${serviceName2}/s_course/v1/video_activity/${activityId}.json`
|
|
18980
|
+
);
|
|
18981
|
+
return data;
|
|
18982
|
+
}
|
|
18976
18983
|
});
|
|
18977
18984
|
// 获取文档活动课时
|
|
18978
18985
|
__publicField(this, "getDocumentActivity", async ({ activityId, siteRelaId }) => {
|