add back gallery media action buttons to new gallery carousel view

This commit is contained in:
Weixuan Fu
2024-03-31 15:01:21 +08:00
parent 3e8f6614fa
commit bdfd0b8f2c
6 changed files with 143 additions and 67 deletions
+6 -2
View File
@@ -57,10 +57,14 @@ export default function MoreActionMenu({ workflow }: Props) {
method: "POST",
body,
});
Array.from(files).forEach((file) => {
Array.from(files).forEach(async (file) => {
const localPath = `workspace_manager/${file.name}`;
mediaTable?.create({
workflowID: workflow.id,
localPath: `workspace_manager/${file.name}`,
localPath: localPath,
});
workflowsTable?.updateMetaInfo(workflow.id, {
coverMediaPath: localPath,
});
});
};