From f0284113caad1c2148eaa2deb13cdaec7a4cfd05 Mon Sep 17 00:00:00 2001 From: Paul Sarando Date: Fri, 28 Jun 2024 20:07:32 -0700 Subject: [PATCH] CORE-1901 Allow Agave jobs only in job listings --- src/apps/persistence/jobs.clj | 1 + src/apps/service/apps/combined.clj | 5 +++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/apps/persistence/jobs.clj b/src/apps/persistence/jobs.clj index 657eef90..c250e4c7 100644 --- a/src/apps/persistence/jobs.clj +++ b/src/apps/persistence/jobs.clj @@ -23,6 +23,7 @@ [permissions-client.core :as pc])) (def de-job-type "DE") +(def agave-job-type "Agave") (def tapis-job-type "Tapis") (def interactive-job-type "Interactive") (def osg-job-type "OSG") diff --git a/src/apps/service/apps/combined.clj b/src/apps/service/apps/combined.clj index 0cc0593d..c5ef338c 100644 --- a/src/apps/service/apps/combined.clj +++ b/src/apps/service/apps/combined.clj @@ -23,7 +23,7 @@ jp/combined-client-name) (getJobTypes [_] - (mapcat #(.getJobTypes %) clients)) + (conj (mapcat #(.getJobTypes %) clients) jp/agave-job-type)) (listSystemIds [_] (mapcat #(.listSystemIds %) clients)) @@ -368,4 +368,5 @@ (.hasAppPermission (util/get-apps-client clients system-id) username system-id app-id required-level)) (supportsJobSharing [_ job-step] - (.supportsJobSharing (util/apps-client-for-job-step clients job-step) job-step))) + (and (not= (:job_type job-step) jp/agave-job-type) + (.supportsJobSharing (util/apps-client-for-job-step clients job-step) job-step))))