Skip to content

Commit

Permalink
add study to entity union types
Browse files Browse the repository at this point in the history
  • Loading branch information
jdhayhurst committed Jan 29, 2025
1 parent 2896538 commit 283ebd3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions app/models/entities/Study.scala
Original file line number Diff line number Diff line change
Expand Up @@ -253,14 +253,14 @@ object Study extends Logging {
}
)
lazy val studyImp: ObjectType[Backend, JsValue] = ObjectType(
"Gwas",
"Study",
"A genome-wide association study",
fields[Backend, JsValue](
gwasFields ++ Seq(credibleSetField)*
)
)
val studyWithoutCredSetsImp: ObjectType[Backend, JsValue] = ObjectType(
"GwasWithoutCredSets",
"StudyWithoutCredSets",
"A genome-wide association study without credible sets",
fields[Backend, JsValue](
gwasFields*
Expand Down
4 changes: 3 additions & 1 deletion app/models/gql/Objects.scala
Original file line number Diff line number Diff line change
Expand Up @@ -1192,7 +1192,9 @@ object Objects extends Logging {
)

lazy val mUnionType: UnionType[Backend] =
UnionType("EntityUnionType", types = List(targetImp, drugImp, diseaseImp, variantIndexImp))
UnionType("EntityUnionType",
types = List(targetImp, drugImp, diseaseImp, variantIndexImp, studyImp)
)

implicit val searchResultAggsCategoryImp: ObjectType[Backend, SearchResultAggCategory] =
deriveObjectType[Backend, models.entities.SearchResultAggCategory]()
Expand Down

0 comments on commit 283ebd3

Please sign in to comment.