table:
  name: notifications
  schema: public
object_relationships:
  - name: bodyshop
    using:
      foreign_key_constraint_on: bodyshopid
select_permissions:
  - role: user
    permission:
      columns:
        - acceptedat
        - acceptedby
        - bodyshopid
        - created_at
        - effectivedate
        - html
        - id
        - requiresconfirmation
        - requiresconfirmationby
        - updated_at
      filter:
        bodyshop:
          associations:
            user:
              authid:
                _eq: X-Hasura-User-Id
update_permissions:
  - role: user
    permission:
      columns:
        - acceptedat
        - acceptedby
      filter:
        _and:
          - bodyshop:
              associations:
                user:
                  authid:
                    _eq: X-Hasura-User-Id
          - acceptedat:
              _is_null: true
      check: null
