mirror of
https://github.com/BTMuli/TeyvatGuide.git
synced 2025-12-14 09:38:13 +08:00
✏️ 验证非空ID
This commit is contained in:
@@ -82,7 +82,10 @@
|
|||||||
},
|
},
|
||||||
"id": {
|
"id": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"title": "Internal ID of the record"
|
"title": "Internal ID of the record",
|
||||||
|
"maxLength": 19,
|
||||||
|
"minLength": 1,
|
||||||
|
"pattern": "^[0-9]+$"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"required": ["uigf_gacha_type", "gacha_type", "id", "item_id", "time"],
|
"required": ["uigf_gacha_type", "gacha_type", "id", "item_id", "time"],
|
||||||
|
|||||||
@@ -114,7 +114,10 @@
|
|||||||
"id": {
|
"id": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"description": "记录内部 ID,米哈游 API 返回"
|
"description": "记录内部 ID,米哈游 API 返回"
|
||||||
}
|
},
|
||||||
|
"maxLength": 19,
|
||||||
|
"minLength": 1,
|
||||||
|
"pattern": "^[0-9]+$"
|
||||||
},
|
},
|
||||||
"required": ["uigf_gacha_type", "gacha_type", "item_id", "time", "id"]
|
"required": ["uigf_gacha_type", "gacha_type", "item_id", "time", "id"]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/**
|
/**
|
||||||
* @file plugins/Mys/request/postReq.ts
|
* @file plugins/Mys/request/postReq.ts
|
||||||
* @description 帖子相关的获取
|
* @description 帖子相关的获取
|
||||||
* @since Beta v0.6.3
|
* @since Beta v0.6.4
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import TGHttp from "../../../utils/TGHttp.js";
|
import TGHttp from "../../../utils/TGHttp.js";
|
||||||
@@ -91,7 +91,7 @@ export async function getPostFullInCollection(
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @description 获取帖子回复信息
|
* @description 获取帖子回复信息
|
||||||
* @since Beta v0.6.2
|
* @since Beta v0.6.4
|
||||||
* @param {string} postId 帖子 ID
|
* @param {string} postId 帖子 ID
|
||||||
* @param {number} gid 社区 ID
|
* @param {number} gid 社区 ID
|
||||||
* @param {boolean} isHot 是否热门
|
* @param {boolean} isHot 是否热门
|
||||||
@@ -125,6 +125,7 @@ export async function getPostReplies(
|
|||||||
if (onlyMaster) {
|
if (onlyMaster) {
|
||||||
params.is_hot = false;
|
params.is_hot = false;
|
||||||
params.only_master = onlyMaster;
|
params.only_master = onlyMaster;
|
||||||
|
params.order_type = 1;
|
||||||
}
|
}
|
||||||
const resp = await TGHttp<TGApp.Plugins.Mys.Reply.Response>(`${Mpabu}getPostReplies`, {
|
const resp = await TGHttp<TGApp.Plugins.Mys.Reply.Response>(`${Mpabu}getPostReplies`, {
|
||||||
method: "GET",
|
method: "GET",
|
||||||
|
|||||||
Reference in New Issue
Block a user