mirror of
https://github.com/penpot/penpot.git
synced 2025-01-09 16:30:37 -05:00
Add create/delete project repository methods.
This commit is contained in:
parent
87adadd445
commit
63bcae9dc1
1 changed files with 13 additions and 0 deletions
|
@ -26,6 +26,19 @@
|
|||
[type data]
|
||||
(urc/req! {:url (str urc/url "/pages") :method :get}))
|
||||
|
||||
(defmethod urc/-do :create/project
|
||||
[_ data]
|
||||
(let [params {:url (str urc/url "/projects")
|
||||
:method :post
|
||||
:body data}]
|
||||
(urc/req! params)))
|
||||
|
||||
(defmethod urc/-do :delete/project
|
||||
[_ {:keys [id]}]
|
||||
(let [params {:url (str urc/url "/projects/" id)
|
||||
:method :delete}]
|
||||
(urc/req! params)))
|
||||
|
||||
(defmethod urc/-do :create/page
|
||||
[type {:keys [id] :as data}]
|
||||
(let [params {:url (str urc/url "/pages")
|
||||
|
|
Loading…
Reference in a new issue