refactor: library type (#9525)

This commit is contained in:
Jason Rasmussen 2024-05-20 18:09:10 -04:00 committed by GitHub
parent 4353153fe6
commit 84d824d6a7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
66 changed files with 183 additions and 984 deletions

View file

@ -483,26 +483,16 @@ LIMIT
1
-- AssetRepository.getUploadAssetIdByChecksum
SELECT DISTINCT
"distinctAlias"."AssetEntity_id" AS "ids_AssetEntity_id"
SELECT
"AssetEntity"."id" AS "AssetEntity_id"
FROM
"assets" "AssetEntity"
WHERE
(
SELECT
"AssetEntity"."id" AS "AssetEntity_id"
FROM
"assets" "AssetEntity"
LEFT JOIN "libraries" "AssetEntity__AssetEntity_library" ON "AssetEntity__AssetEntity_library"."id" = "AssetEntity"."libraryId"
WHERE
(
("AssetEntity"."ownerId" = $1)
AND ("AssetEntity"."checksum" = $2)
AND (
(("AssetEntity__AssetEntity_library"."type" = $3))
)
)
) "distinctAlias"
ORDER BY
"AssetEntity_id" ASC
("AssetEntity"."ownerId" = $1)
AND ("AssetEntity"."checksum" = $2)
AND ("AssetEntity"."libraryId" IS NULL)
)
LIMIT
1