signature.rb 411 B

1234567891011121314
  1. # Copyright (C) 2012-2023 Zammad Foundation, https://zammad-foundation.org/
  2. class Signature < ApplicationModel
  3. include ChecksHtmlSanitized
  4. include HasCollectionUpdate
  5. has_many :groups, after_add: :cache_update, after_remove: :cache_update
  6. validates :name, presence: true
  7. validates :note, length: { maximum: 250 }
  8. sanitized_html :body, :note
  9. collection_push_permission('ticket.agent')
  10. end