# Requêtes CRUD tags

list:
  query: >
    SELECT id, name, color, created_at
    FROM tags
  filters:
    default: "user_id = :user_id"
    admin: ""

show:
  query: >
    SELECT id, name, color, created_at
    FROM tags WHERE id = :id
  filters:
    default: "user_id = :user_id"
    admin: ""

create:
  table: tags
  fields:
    - user_id
    - name
    - color

update:
  table: tags
  fields:
    - name
    - color
  filters:
    default: "user_id = :user_id"
    admin: ""

delete:
  table: tags
  filters:
    default: "user_id = :user_id"
    admin: ""
