mirror of
https://github.com/immich-app/immich.git
synced 2026-05-18 03:10:24 +03:00
chore!: migrate album owner to album_user (#27467)
Co-authored-by: mertalev <101130780+mertalev@users.noreply.github.com> Co-authored-by: shenlong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
This commit is contained in:
@@ -15279,9 +15279,11 @@
|
||||
"type": "string"
|
||||
},
|
||||
"albumUsers": {
|
||||
"description": "First entry is always the album owner. Second entry is the auth user, if it differs from the owner. The rest are ordered alphabetically.",
|
||||
"items": {
|
||||
"$ref": "#/components/schemas/AlbumUserResponseDto"
|
||||
},
|
||||
"minItems": 1,
|
||||
"type": "array"
|
||||
},
|
||||
"assetCount": {
|
||||
@@ -15330,13 +15332,6 @@
|
||||
"order": {
|
||||
"$ref": "#/components/schemas/AssetOrder"
|
||||
},
|
||||
"owner": {
|
||||
"$ref": "#/components/schemas/UserResponseDto"
|
||||
},
|
||||
"ownerId": {
|
||||
"description": "Owner user ID",
|
||||
"type": "string"
|
||||
},
|
||||
"shared": {
|
||||
"description": "Is shared album",
|
||||
"type": "boolean"
|
||||
@@ -15362,8 +15357,6 @@
|
||||
"hasSharedLink",
|
||||
"id",
|
||||
"isActivityEnabled",
|
||||
"owner",
|
||||
"ownerId",
|
||||
"shared",
|
||||
"updatedAt"
|
||||
],
|
||||
@@ -15453,6 +15446,7 @@
|
||||
"description": "Album user role",
|
||||
"enum": [
|
||||
"editor",
|
||||
"owner",
|
||||
"viewer"
|
||||
],
|
||||
"type": "string"
|
||||
@@ -22531,6 +22525,59 @@
|
||||
],
|
||||
"type": "object"
|
||||
},
|
||||
"SyncAlbumV2": {
|
||||
"properties": {
|
||||
"createdAt": {
|
||||
"description": "Created at",
|
||||
"example": "2024-01-01T00:00:00.000Z",
|
||||
"format": "date-time",
|
||||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
|
||||
"type": "string"
|
||||
},
|
||||
"description": {
|
||||
"description": "Album description",
|
||||
"type": "string"
|
||||
},
|
||||
"id": {
|
||||
"description": "Album ID",
|
||||
"type": "string"
|
||||
},
|
||||
"isActivityEnabled": {
|
||||
"description": "Is activity enabled",
|
||||
"type": "boolean"
|
||||
},
|
||||
"name": {
|
||||
"description": "Album name",
|
||||
"type": "string"
|
||||
},
|
||||
"order": {
|
||||
"$ref": "#/components/schemas/AssetOrder"
|
||||
},
|
||||
"thumbnailAssetId": {
|
||||
"description": "Thumbnail asset ID",
|
||||
"nullable": true,
|
||||
"type": "string"
|
||||
},
|
||||
"updatedAt": {
|
||||
"description": "Updated at",
|
||||
"example": "2024-01-01T00:00:00.000Z",
|
||||
"format": "date-time",
|
||||
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"createdAt",
|
||||
"description",
|
||||
"id",
|
||||
"isActivityEnabled",
|
||||
"name",
|
||||
"order",
|
||||
"thumbnailAssetId",
|
||||
"updatedAt"
|
||||
],
|
||||
"type": "object"
|
||||
},
|
||||
"SyncAssetDeleteV1": {
|
||||
"properties": {
|
||||
"assetId": {
|
||||
@@ -23216,6 +23263,7 @@
|
||||
"PartnerStackDeleteV1",
|
||||
"PartnerStackV1",
|
||||
"AlbumV1",
|
||||
"AlbumV2",
|
||||
"AlbumDeleteV1",
|
||||
"AlbumUserV1",
|
||||
"AlbumUserBackfillV1",
|
||||
@@ -23510,6 +23558,7 @@
|
||||
"description": "Sync request type",
|
||||
"enum": [
|
||||
"AlbumsV1",
|
||||
"AlbumsV2",
|
||||
"AlbumUsersV1",
|
||||
"AlbumToAssetsV1",
|
||||
"AlbumAssetsV1",
|
||||
|
||||
@@ -457,6 +457,7 @@ export type AlbumResponseDto = {
|
||||
albumName: string;
|
||||
/** Thumbnail asset ID */
|
||||
albumThumbnailAssetId: string | null;
|
||||
/** First entry is always the album owner. Second entry is the auth user, if it differs from the owner. The rest are ordered alphabetically. */
|
||||
albumUsers: AlbumUserResponseDto[];
|
||||
/** Number of assets */
|
||||
assetCount: number;
|
||||
@@ -476,9 +477,6 @@ export type AlbumResponseDto = {
|
||||
/** Last modified asset timestamp */
|
||||
lastModifiedAssetTimestamp?: string;
|
||||
order?: AssetOrder;
|
||||
owner: UserResponseDto;
|
||||
/** Owner user ID */
|
||||
ownerId: string;
|
||||
/** Is shared album */
|
||||
shared: boolean;
|
||||
/** Start date (earliest asset) */
|
||||
@@ -2881,6 +2879,23 @@ export type SyncAlbumV1 = {
|
||||
/** Updated at */
|
||||
updatedAt: string;
|
||||
};
|
||||
export type SyncAlbumV2 = {
|
||||
/** Created at */
|
||||
createdAt: string;
|
||||
/** Album description */
|
||||
description: string;
|
||||
/** Album ID */
|
||||
id: string;
|
||||
/** Is activity enabled */
|
||||
isActivityEnabled: boolean;
|
||||
/** Album name */
|
||||
name: string;
|
||||
order: AssetOrder;
|
||||
/** Thumbnail asset ID */
|
||||
thumbnailAssetId: string | null;
|
||||
/** Updated at */
|
||||
updatedAt: string;
|
||||
};
|
||||
export type SyncAssetDeleteV1 = {
|
||||
/** Asset ID */
|
||||
assetId: string;
|
||||
@@ -6731,6 +6746,7 @@ export enum AssetVisibility {
|
||||
}
|
||||
export enum AlbumUserRole {
|
||||
Editor = "editor",
|
||||
Owner = "owner",
|
||||
Viewer = "viewer"
|
||||
}
|
||||
export enum BulkIdErrorReason {
|
||||
@@ -7110,6 +7126,7 @@ export enum SyncEntityType {
|
||||
PartnerStackDeleteV1 = "PartnerStackDeleteV1",
|
||||
PartnerStackV1 = "PartnerStackV1",
|
||||
AlbumV1 = "AlbumV1",
|
||||
AlbumV2 = "AlbumV2",
|
||||
AlbumDeleteV1 = "AlbumDeleteV1",
|
||||
AlbumUserV1 = "AlbumUserV1",
|
||||
AlbumUserBackfillV1 = "AlbumUserBackfillV1",
|
||||
@@ -7142,6 +7159,7 @@ export enum SyncEntityType {
|
||||
}
|
||||
export enum SyncRequestType {
|
||||
AlbumsV1 = "AlbumsV1",
|
||||
AlbumsV2 = "AlbumsV2",
|
||||
AlbumUsersV1 = "AlbumUsersV1",
|
||||
AlbumToAssetsV1 = "AlbumToAssetsV1",
|
||||
AlbumAssetsV1 = "AlbumAssetsV1",
|
||||
|
||||
Reference in New Issue
Block a user