mirror of
https://github.com/penpot/penpot.git
synced 2025-06-05 03:31:42 +02:00
✨ Add info in modal
This commit is contained in:
parent
a5bf1c03e7
commit
c108974ad2
19 changed files with 327 additions and 58 deletions
|
@ -384,7 +384,7 @@
|
|||
|
||||
(s/def ::file-data-for-thumbnail
|
||||
(s/keys :req-un [::profile-id ::file-id]
|
||||
:opt-in [::components-v2]))
|
||||
:opt-un [::components-v2]))
|
||||
|
||||
(sv/defmethod ::file-data-for-thumbnail
|
||||
"Retrieves the data for generate the thumbnail of the file. Used
|
||||
|
@ -464,6 +464,24 @@
|
|||
(check-read-permissions! pool profile-id file-id)
|
||||
(retrieve-file-libraries cfg false file-id))
|
||||
|
||||
|
||||
;; --- Query: Files that use this File library
|
||||
|
||||
(def ^:private sql:library-using-files
|
||||
"SELECT f.id,
|
||||
f.name
|
||||
FROM file_library_rel AS flr
|
||||
INNER JOIN file AS f ON f.id = flr.file_id
|
||||
WHERE flr.library_file_id = ?;")
|
||||
|
||||
(s/def ::library-using-files
|
||||
(s/keys :req-un [::profile-id ::file-id]))
|
||||
|
||||
(sv/defmethod ::library-using-files
|
||||
[{:keys [pool] :as cfg} {:keys [profile-id file-id] :as params}]
|
||||
(check-read-permissions! pool profile-id file-id)
|
||||
(db/exec! pool [sql:library-using-files file-id]))
|
||||
|
||||
;; --- QUERY: team-recent-files
|
||||
|
||||
(def sql:team-recent-files
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue