8000 add MutationField and QueryField to limit field's visibility on either just mutation or query · Issue #40 · capaj/decapi · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
add MutationField and QueryField to limit field's visibility on either just mutation or query #40
Open
@capaj

Description

@capaj

usage would be

  @MutationField({ castTo: GroupModelAsAdmin })
  async group(
    @Arg({ type: PositiveInt }) id: number,
    @Context ctx: UserSessionContext
  ) {
    return ctx.organisation
      .$relatedQuery<GroupModelAsAdmin>('groups')
      .findById(id)
  }

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0