Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(server) Tagging system #1046

Merged
merged 35 commits into from
Dec 5, 2022
Merged

feat(server) Tagging system #1046

merged 35 commits into from
Dec 5, 2022

Conversation

alextran1502
Copy link
Contributor

@alextran1502 alextran1502 commented Dec 2, 2022

This PR implements tagging system for Immich on the server. The following mechanisms are implemented.

Tag table and relation table

image

Todo

  • Create a tag
  • Update tag name
  • Remove the tag
  • Get a tag
  • Get all tags that belong to a user
  • Update asset with added/removed tags

@vercel
Copy link

vercel bot commented Dec 2, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
immich ✅ Ready (Inspect) Visit Preview Dec 5, 2022 at 5:53PM (UTC)

@alextran1502 alextran1502 marked this pull request as draft December 2, 2022 20:22
Copy link
Member

@bo0tzz bo0tzz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do I understand correctly that this PR implements the new tags system serverside, but for now everything still uses the old tags column in the SmartInfo table? I assume there'll then be a followup PR to change over the background jobs, clients, and to migrate the old tags from SmartInfo?

PR looks good, as usual just a few small nits.

server/libs/database/src/entities/tag.entity.ts Outdated Show resolved Hide resolved
server/apps/immich/src/api-v1/tag/tag.service.ts Outdated Show resolved Hide resolved
server/apps/immich/src/api-v1/tag/tag.service.ts Outdated Show resolved Hide resolved
server/apps/immich/src/api-v1/asset/asset-repository.ts Outdated Show resolved Hide resolved
@alextran1502
Copy link
Contributor Author

I assume there'll then be a followup PR to change over the background jobs, clients, and to migrate the old tags from SmartInfo?

Correct, that will be is my upcoming PRs

Copy link
Contributor

@jrasm91 jrasm91 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Few semantic things about modules 😛 otherwise looks good!

},
],
providers: [AlbumService, ALBUM_REPOSITORY_PROVIDER],
exports: [ALBUM_REPOSITORY_PROVIDER, TypeOrmModule],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TypeOrmModule should not need to be exported here.

NOTES.md Outdated
@@ -1,9 +1,31 @@
# TODO
# Tagging system
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this file need to be committed? Are we going to start documenting "notes" here? Should we maybe just add something like this to the documentation site instead?

server/apps/immich/src/api-v1/tag/tag.module.ts Outdated Show resolved Hide resolved
server/apps/immich/src/api-v1/tag/tag.repository.ts Outdated Show resolved Hide resolved
server/apps/immich/src/api-v1/user/user.module.ts Outdated Show resolved Hide resolved
server/apps/immich/src/api-v1/asset/asset.module.ts Outdated Show resolved Hide resolved
server/apps/immich/src/api-v1/tag/tag.service.ts Outdated Show resolved Hide resolved
@alextran1502 alextran1502 merged commit 5de8ea1 into main Dec 5, 2022
@alextran1502 alextran1502 deleted the feat/tagging-system branch December 5, 2022 17:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants