{% import '_includes/forms' as forms %}

Fields

{{ forms.field({ instructions: "Choose which fields are forbidden from being accessed through queries and mutations – per schema. Any attempts to access a restricted field will cause the request to throw.", first: true, }, '') }}
{% for schema in schemaOptions %} {% endfor %} {% for field in fields %} {% set first = loop.first %} {% for schema in schemaOptions %} {% set schemaKey = 'schema-' ~ (schema.value != '' ? schema.value : '1') %} {% endfor %} {% endfor %}
Field {{ schema.label == '-' ? 'Public' : schema.label }}
{{ forms.field({ label: field.name, instructions: "(" ~ field.handle ~ ")", }, '') }} {{ forms.selectField({ name: 'fieldRestrictions[' ~ schemaKey ~ '][' ~ field.handle ~ ']', value: settings.fieldRestrictions[schemaKey][field.handle] ?? 'queryMutate', options: [ { value: 'queryMutate', label: 'Query & Mutate' }, { value: 'query', label: 'Query' }, { value: 'private', label: 'Private' }, ], }) }}