This commit is contained in:
ACT丶流星雨 2026-03-31 00:57:09 +08:00
commit 3b65143565
3 changed files with 12 additions and 3 deletions

View File

@ -43,11 +43,19 @@ export default router.post(
}
const childAssets = await childQuery;
// 为每个子资产添加图片地址
const childAssetsWithSrc = await Promise.all(
childAssets.map(async (child) => ({
...child,
src: child.filePath && (await u.oss.getFileUrl(child.filePath!)),
})),
);
// 为每个父资产添加子资产
const result = await Promise.all(
parentAssets.map(async (parent) => ({
...parent,
sonAssets: childAssets.filter((child) => child.assetsId === parent.id),
sonAssets: childAssetsWithSrc.filter((child) => child.assetsId === parent.id),
src: parent.filePath && (await u.oss.getFileUrl(parent.filePath!)),
})),
);

View File

@ -103,7 +103,6 @@ export default router.post(
3.
4.
5. `;
console.log("%c Line:110 🍑 prompt", "background:#b03734", prompt);
const aiVideo = u.Ai.Video(model);
await aiVideo.run(

View File

@ -1,4 +1,4 @@
// @db-hash 93b2462070c45c2b449e9a18c4e88763
// @db-hash 6be0a80e9c8f541987a4c1e907736237
//该文件由脚本自动生成,请勿手动修改
export interface memories {
@ -178,6 +178,7 @@ export interface o_storyboard {
'sound'?: string | null;
'state'?: string | null;
'title'?: string | null;
'videoPrompt'?: string | null;
}
export interface o_tasks {
'describe'?: string | null;
@ -211,6 +212,7 @@ export interface o_video {
'errorReason'?: string | null;
'filePath'?: string | null;
'id'?: number;
'projectId'?: number | null;
'scriptId'?: number | null;
'state'?: string | null;
'storyboardId'?: number | null;