mirror of
https://github.com/immich-app/immich
synced 2025-11-14 17:36:12 +00:00
chore: remove all deprecated endpoints/properties from server and mobile app (#9724)
* chore: remove deprecated title property from MemoryLaneResponseDto * chore: remove deprecated webpPath and resizePath from MetadataSearchDto * chore: remove deprecated sharedUserIds property from Album AddUsersDto * chore: remove deprecated sharedUsers property from AlbumResponseDto * chore: remove deprecated sharedWithUserIds property from CreateAlbumDto * chore: remove deprecated isExternal and isReadOnly properties from AssetResponseDto * chore: remove deprecated /server-info endpoint * chore: bloody linters
This commit is contained in:
parent
1f5d82e9d9
commit
39d2c4f37b
32 changed files with 66 additions and 451 deletions
|
|
@ -88,7 +88,7 @@
|
|||
<div class="w-full">{user.name}</div>
|
||||
<div>Owner</div>
|
||||
</div>
|
||||
{#each album.sharedUsers as user (user.id)}
|
||||
{#each album.albumUsers as { user } (user.id)}
|
||||
<div class="flex items-center gap-2 py-2">
|
||||
<div>
|
||||
<UserAvatar {user} size="md" />
|
||||
|
|
|
|||
|
|
@ -42,8 +42,8 @@
|
|||
users = data.filter((user) => !(user.deletedAt || user.id === album.ownerId));
|
||||
|
||||
// Remove the existed shared users from the album
|
||||
for (const sharedUser of album.sharedUsers) {
|
||||
users = users.filter((user) => user.id !== sharedUser.id);
|
||||
for (const sharedUser of album.albumUsers) {
|
||||
users = users.filter((user) => user.id !== sharedUser.user.id);
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -571,7 +571,7 @@
|
|||
</div>
|
||||
{/if}
|
||||
|
||||
{#if currentAlbum && currentAlbum.sharedUsers.length > 0 && asset.owner}
|
||||
{#if currentAlbum && currentAlbum.albumUsers.length > 0 && asset.owner}
|
||||
<section class="px-6 dark:text-immich-dark-fg mt-4">
|
||||
<p class="text-sm">SHARED BY</p>
|
||||
<div class="flex gap-4 pt-4">
|
||||
|
|
|
|||
|
|
@ -136,7 +136,7 @@
|
|||
assetGridWidth = isShowActivity ? globalWidth - (globalWidth < 768 ? 360 : 460) : globalWidth;
|
||||
}
|
||||
$: showActivityStatus =
|
||||
album.sharedUsers.length > 0 && !$showAssetViewer && (album.isActivityEnabled || $numberOfComments > 0);
|
||||
album.albumUsers.length > 0 && !$showAssetViewer && (album.isActivityEnabled || $numberOfComments > 0);
|
||||
|
||||
$: isEditor =
|
||||
album.albumUsers.find(({ user: { id } }) => id === $user.id)?.role === AlbumUserRole.Editor ||
|
||||
|
|
@ -158,7 +158,7 @@
|
|||
|
||||
backUrl = url || AppRoute.ALBUMS;
|
||||
|
||||
if (backUrl === AppRoute.SHARING && album.sharedUsers.length === 0 && !album.hasSharedLink) {
|
||||
if (backUrl === AppRoute.SHARING && album.albumUsers.length === 0 && !album.hasSharedLink) {
|
||||
isCreatingSharedAlbum = true;
|
||||
}
|
||||
});
|
||||
|
|
@ -229,7 +229,7 @@
|
|||
isShowActivity = !isShowActivity;
|
||||
};
|
||||
|
||||
$: if (album.sharedUsers.length > 0) {
|
||||
$: if (album.albumUsers.length > 0) {
|
||||
handlePromiseError(getFavorite());
|
||||
handlePromiseError(getNumberOfComments());
|
||||
}
|
||||
|
|
@ -342,7 +342,7 @@
|
|||
|
||||
try {
|
||||
await refreshAlbum();
|
||||
viewMode = album.sharedUsers.length > 0 ? ViewMode.VIEW_USERS : ViewMode.VIEW;
|
||||
viewMode = album.albumUsers.length > 0 ? ViewMode.VIEW_USERS : ViewMode.VIEW;
|
||||
} catch (error) {
|
||||
handleError(error, 'Error deleting shared user');
|
||||
}
|
||||
|
|
@ -482,7 +482,7 @@
|
|||
{/if}
|
||||
{/if}
|
||||
|
||||
{#if isCreatingSharedAlbum && album.sharedUsers.length === 0}
|
||||
{#if isCreatingSharedAlbum && album.albumUsers.length === 0}
|
||||
<Button
|
||||
size="sm"
|
||||
rounded="lg"
|
||||
|
|
@ -546,7 +546,7 @@
|
|||
{album}
|
||||
{assetStore}
|
||||
{assetInteractionStore}
|
||||
isShared={album.sharedUsers.length > 0}
|
||||
isShared={album.albumUsers.length > 0}
|
||||
isSelectionMode={viewMode === ViewMode.SELECT_THUMBNAIL}
|
||||
singleSelect={viewMode === ViewMode.SELECT_THUMBNAIL}
|
||||
showArchiveIcon
|
||||
|
|
@ -563,7 +563,7 @@
|
|||
{/if}
|
||||
|
||||
<!-- ALBUM SHARING -->
|
||||
{#if album.sharedUsers.length > 0 || (album.hasSharedLink && isOwned)}
|
||||
{#if album.albumUsers.length > 0 || (album.hasSharedLink && isOwned)}
|
||||
<div class="my-3 flex gap-x-1">
|
||||
<!-- link -->
|
||||
{#if album.hasSharedLink && isOwned}
|
||||
|
|
@ -649,7 +649,7 @@
|
|||
{/key}
|
||||
</main>
|
||||
</div>
|
||||
{#if album.sharedUsers.length > 0 && album && isShowActivity && $user && !$showAssetViewer}
|
||||
{#if album.albumUsers.length > 0 && album && isShowActivity && $user && !$showAssetViewer}
|
||||
<div class="flex">
|
||||
<div
|
||||
transition:fly={{ duration: 150 }}
|
||||
|
|
|
|||
|
|
@ -15,7 +15,6 @@ export const albumFactory = Sync.makeFactory<AlbumResponseDto>({
|
|||
ownerId: Sync.each(() => faker.string.uuid()),
|
||||
owner: userFactory.build(),
|
||||
shared: false,
|
||||
sharedUsers: [],
|
||||
albumUsers: [],
|
||||
hasSharedLink: false,
|
||||
isActivityEnabled: true,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue