Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: 修复Console快速拉取条目后无法定位到对应条目的问题 #713

Merged
merged 3 commits into from
Oct 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.MD
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

更新日志文档,版本顺序从新到旧,最新版本在最前(上)面。

# 0.18.1

- 修复Console快速拉取条目后无法定位到对应条目的问题

# 0.18.0

> 注意:提供给插件的内部条目同步接口有所变化,此版本升级后,番组计划插件也需要升级到v18.x.x,不然无法正常快速拉取条目
Expand Down
2 changes: 1 addition & 1 deletion console/packages/api-client/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ npm publish
选择当前目录下的更改进行`git add .`

```bash
git commit -am "build: gen new api-client v0.17.0.5"
git commit -am "build: gen new api-client v18.1.0"
```

合成版(powershell),升级 package.json 版本,并启动服务端后,在 api-client 路径下:
Expand Down
2 changes: 1 addition & 1 deletion console/packages/api-client/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@runikaros/api-client",
"version": "0.17.0.5",
"version": "18.1.0",
"description": "Project ikaros console api-client package",
"type": "module",
"scripts": {
Expand Down
3 changes: 2 additions & 1 deletion console/packages/api-client/src/.openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ api/v1alpha1-security-api.ts
api/v1alpha1-static-api.ts
api/v1alpha1-subject-api.ts
api/v1alpha1-subject-relation-api.ts
api/v1alpha1-subject-sync-platform-api.ts
api/v1alpha1-subject-sync-api.ts
api/v1alpha1-tag-api.ts
api/v1alpha1-task-api.ts
api/v1alpha1-user-api.ts
Expand All @@ -34,6 +34,7 @@ git_push.sh
index.ts
models/attachment-reference.ts
models/attachment-relation.ts
models/attachment-tag.ts
models/attachment.ts
models/author.ts
models/authority.ts
Expand Down
2 changes: 1 addition & 1 deletion console/packages/api-client/src/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export * from "./api/v1alpha1-security-api";
export * from "./api/v1alpha1-static-api";
export * from "./api/v1alpha1-subject-api";
export * from "./api/v1alpha1-subject-relation-api";
export * from "./api/v1alpha1-subject-sync-platform-api";
export * from "./api/v1alpha1-subject-sync-api";
export * from "./api/v1alpha1-tag-api";
export * from "./api/v1alpha1-task-api";
export * from "./api/v1alpha1-user-api";
Expand Down
247 changes: 242 additions & 5 deletions console/packages/api-client/src/api/v1alpha1-episode-api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -210,16 +210,110 @@ export const V1alpha1EpisodeApiAxiosParamCreator = function (
},
/**
* Get episode by episode id.
* @param {number} id Episode id
* @param {number} id Subject id
* @param {'MAIN' | 'PROMOTION_VIDEO' | 'OPENING_SONG' | 'ENDING_SONG' | 'SPECIAL_PROMOTION' | 'SMALL_THEATER' | 'LIVE' | 'COMMERCIAL_MESSAGE' | 'ORIGINAL_SOUND_TRACK' | 'ORIGINAL_VIDEO_ANIMATION' | 'ORIGINAL_ANIMATION_DISC' | 'MUSIC_DIST1' | 'MUSIC_DIST2' | 'MUSIC_DIST3' | 'MUSIC_DIST4' | 'MUSIC_DIST5' | 'OTHER'} group episode group
* @param {number} sequence episode sequence
* @param {string} name episode name, need base64 encode.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getById: async (
id: number,
group:
| "MAIN"
| "PROMOTION_VIDEO"
| "OPENING_SONG"
| "ENDING_SONG"
| "SPECIAL_PROMOTION"
| "SMALL_THEATER"
| "LIVE"
| "COMMERCIAL_MESSAGE"
| "ORIGINAL_SOUND_TRACK"
| "ORIGINAL_VIDEO_ANIMATION"
| "ORIGINAL_ANIMATION_DISC"
| "MUSIC_DIST1"
| "MUSIC_DIST2"
| "MUSIC_DIST3"
| "MUSIC_DIST4"
| "MUSIC_DIST5"
| "OTHER",
sequence: number,
name: string,
options: AxiosRequestConfig = {}
): Promise<RequestArgs> => {
// verify required parameter 'id' is not null or undefined
assertParamExists("getById", "id", id);
// verify required parameter 'group' is not null or undefined
assertParamExists("getById", "group", group);
// verify required parameter 'sequence' is not null or undefined
assertParamExists("getById", "sequence", sequence);
// verify required parameter 'name' is not null or undefined
assertParamExists("getById", "name", name);
const localVarPath = `/api/v1alpha1/episode/subjectId/{id}`.replace(
`{${"id"}}`,
encodeURIComponent(String(id))
);
// use dummy base URL string because the URL constructor only accepts absolute URLs.
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
let baseOptions;
if (configuration) {
baseOptions = configuration.baseOptions;
}

const localVarRequestOptions = {
method: "GET",
...baseOptions,
...options,
};
const localVarHeaderParameter = {} as any;
const localVarQueryParameter = {} as any;

// authentication BasicAuth required
// http basic authentication required
setBasicAuthToObject(localVarRequestOptions, configuration);

// authentication BearerAuth required
// http bearer authentication required
await setBearerAuthToObject(localVarHeaderParameter, configuration);

if (group !== undefined) {
localVarQueryParameter["group"] = group;
}

if (sequence !== undefined) {
localVarQueryParameter["sequence"] = sequence;
}

if (name !== undefined) {
localVarQueryParameter["name"] = name;
}

setSearchParams(localVarUrlObj, localVarQueryParameter);
let headersFromBaseOptions =
baseOptions && baseOptions.headers ? baseOptions.headers : {};
localVarRequestOptions.headers = {
...localVarHeaderParameter,
...headersFromBaseOptions,
...options.headers,
};

return {
url: toPathString(localVarUrlObj),
options: localVarRequestOptions,
};
},
/**
* Get episode by episode id.
* @param {number} id Episode id
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getById1: async (
id: number,
options: AxiosRequestConfig = {}
): Promise<RequestArgs> => {
// verify required parameter 'id' is not null or undefined
assertParamExists("getById1", "id", id);
const localVarPath = `/api/v1alpha1/episode/{id}`.replace(
`{${"id"}}`,
encodeURIComponent(String(id))
Expand Down Expand Up @@ -560,17 +654,66 @@ export const V1alpha1EpisodeApiFp = function (configuration?: Configuration) {
},
/**
* Get episode by episode id.
* @param {number} id Episode id
* @param {number} id Subject id
* @param {'MAIN' | 'PROMOTION_VIDEO' | 'OPENING_SONG' | 'ENDING_SONG' | 'SPECIAL_PROMOTION' | 'SMALL_THEATER' | 'LIVE' | 'COMMERCIAL_MESSAGE' | 'ORIGINAL_SOUND_TRACK' | 'ORIGINAL_VIDEO_ANIMATION' | 'ORIGINAL_ANIMATION_DISC' | 'MUSIC_DIST1' | 'MUSIC_DIST2' | 'MUSIC_DIST3' | 'MUSIC_DIST4' | 'MUSIC_DIST5' | 'OTHER'} group episode group
* @param {number} sequence episode sequence
* @param {string} name episode name, need base64 encode.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async getById(
id: number,
group:
| "MAIN"
| "PROMOTION_VIDEO"
| "OPENING_SONG"
| "ENDING_SONG"
| "SPECIAL_PROMOTION"
| "SMALL_THEATER"
| "LIVE"
| "COMMERCIAL_MESSAGE"
| "ORIGINAL_SOUND_TRACK"
| "ORIGINAL_VIDEO_ANIMATION"
| "ORIGINAL_ANIMATION_DISC"
| "MUSIC_DIST1"
| "MUSIC_DIST2"
| "MUSIC_DIST3"
| "MUSIC_DIST4"
| "MUSIC_DIST5"
| "OTHER",
sequence: number,
name: string,
options?: AxiosRequestConfig
): Promise<
(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Episode>
> {
const localVarAxiosArgs = await localVarAxiosParamCreator.getById(
id,
group,
sequence,
name,
options
);
return createRequestFunction(
localVarAxiosArgs,
globalAxios,
BASE_PATH,
configuration
);
},
/**
* Get episode by episode id.
* @param {number} id Episode id
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async getById1(
id: number,
options?: AxiosRequestConfig
): Promise<
(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Episode>
> {
const localVarAxiosArgs = await localVarAxiosParamCreator.getById1(
id,
options
);
Expand Down Expand Up @@ -739,7 +882,27 @@ export const V1alpha1EpisodeApiFactory = function (
options?: AxiosRequestConfig
): AxiosPromise<Episode> {
return localVarFp
.getById(requestParameters.id, options)
.getById(
requestParameters.id,
requestParameters.group,
requestParameters.sequence,
requestParameters.name,
options
)
.then((request) => request(axios, basePath));
},
/**
* Get episode by episode id.
* @param {V1alpha1EpisodeApiGetById1Request} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getById1(
requestParameters: V1alpha1EpisodeApiGetById1Request,
options?: AxiosRequestConfig
): AxiosPromise<Episode> {
return localVarFp
.getById1(requestParameters.id, options)
.then((request) => request(axios, basePath));
},
/**
Expand Down Expand Up @@ -850,11 +1013,63 @@ export interface V1alpha1EpisodeApiGetAttachmentRefsByIdRequest {
*/
export interface V1alpha1EpisodeApiGetByIdRequest {
/**
* Episode id
* Subject id
* @type {number}
* @memberof V1alpha1EpisodeApiGetById
*/
readonly id: number;

/**
* episode group
* @type {'MAIN' | 'PROMOTION_VIDEO' | 'OPENING_SONG' | 'ENDING_SONG' | 'SPECIAL_PROMOTION' | 'SMALL_THEATER' | 'LIVE' | 'COMMERCIAL_MESSAGE' | 'ORIGINAL_SOUND_TRACK' | 'ORIGINAL_VIDEO_ANIMATION' | 'ORIGINAL_ANIMATION_DISC' | 'MUSIC_DIST1' | 'MUSIC_DIST2' | 'MUSIC_DIST3' | 'MUSIC_DIST4' | 'MUSIC_DIST5' | 'OTHER'}
* @memberof V1alpha1EpisodeApiGetById
*/
readonly group:
| "MAIN"
| "PROMOTION_VIDEO"
| "OPENING_SONG"
| "ENDING_SONG"
| "SPECIAL_PROMOTION"
| "SMALL_THEATER"
| "LIVE"
| "COMMERCIAL_MESSAGE"
| "ORIGINAL_SOUND_TRACK"
| "ORIGINAL_VIDEO_ANIMATION"
| "ORIGINAL_ANIMATION_DISC"
| "MUSIC_DIST1"
| "MUSIC_DIST2"
| "MUSIC_DIST3"
| "MUSIC_DIST4"
| "MUSIC_DIST5"
| "OTHER";

/**
* episode sequence
* @type {number}
* @memberof V1alpha1EpisodeApiGetById
*/
readonly sequence: number;

/**
* episode name, need base64 encode.
* @type {string}
* @memberof V1alpha1EpisodeApiGetById
*/
readonly name: string;
}

/**
* Request parameters for getById1 operation in V1alpha1EpisodeApi.
* @export
* @interface V1alpha1EpisodeApiGetById1Request
*/
export interface V1alpha1EpisodeApiGetById1Request {
/**
* Episode id
* @type {number}
* @memberof V1alpha1EpisodeApiGetById1
*/
readonly id: number;
}

/**
Expand Down Expand Up @@ -980,7 +1195,29 @@ export class V1alpha1EpisodeApi extends BaseAPI {
options?: AxiosRequestConfig
) {
return V1alpha1EpisodeApiFp(this.configuration)
.getById(requestParameters.id, options)
.getById(
requestParameters.id,
requestParameters.group,
requestParameters.sequence,
requestParameters.name,
options
)
.then((request) => request(this.axios, this.basePath));
}

/**
* Get episode by episode id.
* @param {V1alpha1EpisodeApiGetById1Request} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof V1alpha1EpisodeApi
*/
public getById1(
requestParameters: V1alpha1EpisodeApiGetById1Request,
options?: AxiosRequestConfig
) {
return V1alpha1EpisodeApiFp(this.configuration)
.getById1(requestParameters.id, options)
.then((request) => request(this.axios, this.basePath));
}

Expand Down
Loading
Loading