Skip to content

Commit

Permalink
Merge pull request #277 from ianmcorvidae/core-1971
Browse files Browse the repository at this point in the history
Pass through parameters for tool details requests so include-defaults comes through
  • Loading branch information
ianmcorvidae authored Jan 4, 2024
2 parents b380542 + 18ccd20 commit 708f03a
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 7 deletions.
2 changes: 1 addition & 1 deletion project.clj
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
[org.cyverse/cyverse-groups-client "0.1.8"]
[org.cyverse/common-cfg "2.8.2"]
[org.cyverse/common-cli "2.8.1"]
[org.cyverse/common-swagger-api "3.4.3"]
[org.cyverse/common-swagger-api "3.4.4"]
[org.cyverse/kameleon "3.0.6"
:exclusion [com.impossibl.pgjdbc-ng/pgjdbc-ng]]
[com.impossibl.pgjdbc-ng/pgjdbc-ng "0.8.9"]
Expand Down
8 changes: 4 additions & 4 deletions src/terrain/clients/apps/raw.clj
Original file line number Diff line number Diff line change
Expand Up @@ -1105,11 +1105,11 @@
:as :json}))))

(defn admin-get-tool
[tool-id]
[tool-id params]
(:body
(client/get (apps-url "admin" "tools" tool-id)
(disable-redirects
{:query-params (secured-params)
{:query-params (secured-params params)
:as :json}))))

(defn admin-update-tool
Expand Down Expand Up @@ -1197,11 +1197,11 @@
:as :json}))))

(defn get-tool
[tool-id]
[tool-id params]
(:body
(client/get (apps-url "tools" tool-id)
(disable-redirects
{:query-params (secured-params)
{:query-params (secured-params params)
:as :json}))))

(defn update-private-tool
Expand Down
3 changes: 2 additions & 1 deletion src/terrain/routes/apps/admin/tools.clj
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,11 @@
(ok (apps/admin-delete-tool tool-id)))

(GET "/" []
:query [params schema/ToolDetailsParams]
:responses admin-schema/ToolDetailsResponses
:summary schema/ToolDetailsSummary
:description admin-schema/ToolDetailsDocs
(ok (apps/admin-get-tool tool-id)))
(ok (apps/admin-get-tool tool-id params)))

(PATCH "/" []
:query [params admin-schema/ToolUpdateParams]
Expand Down
3 changes: 2 additions & 1 deletion src/terrain/routes/apps/tools.clj
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,11 @@
(ok (apps/delete-private-tool tool-id params)))

(GET "/" []
:query [params schema/ToolDetailsParams]
:responses schema/ToolDetailsResponses
:summary schema/ToolDetailsSummary
:description schema/ToolDetailsDocs
(ok (apps/get-tool tool-id)))
(ok (apps/get-tool tool-id params)))

(PATCH "/" []
:middleware [schema/coerce-tool-import-requests]
Expand Down

0 comments on commit 708f03a

Please sign in to comment.