fix: migrate to Immich v3.0 API and DB schema
- Updated albumColumns and AlbumThumbnail components to display placeholder when no thumbnail is available. - added album_user table (album ownership moved here, role='owner') - drop asset.deviceId/deviceAssetId and albums.ownerId - asset.duration varchar -> integer (milliseconds) - removed isArchived instead use visibility
This commit is contained in:
1 parent
303abc72cd
commit
af4cfceb47
20 files changed
+110
-79
No files matched your search
@@ -163,16 +163,15 @@ export async function executeAction(
|
||||
}
|
||||
|
||||
case "archive": {
|
||||
await immichFetch("/assets", "PUT", { ids: assetIds, isArchived: true }, user);
|
||||
await immichFetch("/assets", "PUT", { ids: assetIds, visibility: "archive" }, user);
|
||||
return { action: "archive", assetsProcessed: assetIds.length };
|
||||
}
|
||||
|
||||
case "tag": {
|
||||
if (!config.tagName) throw new Error("Tag name is required");
|
||||
// Tags API may vary by Immich version — try the standard approach
|
||||
try {
|
||||
// Create or get tag
|
||||
const tag = await immichFetch("/tags", "POST", { name: config.tagName, type: "OBJECT" }, user);
|
||||
const tag = await immichFetch("/tags", "POST", { name: config.tagName }, user);
|
||||
// Tag assets
|
||||
await immichFetch(`/tags/${tag.id}/assets`, "PUT", { ids: assetIds }, user);
|
||||
return { action: "tag", assetsProcessed: assetIds.length };
|
||||
|
||||
Reference in new issue
Block a user