20230705074628_ticket_conditions_regular_expression_operators.rb 1.1 KB

1234567891011121314151617181920212223242526272829303132333435
  1. # Copyright (C) 2012-2024 Zammad Foundation, https://zammad-foundation.org/
  2. class TicketConditionsRegularExpressionOperators < ActiveRecord::Migration[6.1]
  3. def change
  4. # return if it's a new setup
  5. return if !Setting.exists?(name: 'system_init_done')
  6. Setting.create_if_not_exists(
  7. title: 'Ticket Conditions Regular Expression Operators',
  8. name: 'ticket_conditions_allow_regular_expression_operators',
  9. area: 'Ticket::Core',
  10. description: 'Defines if the ticket conditions editor supports regular expression operators for triggers and ticket auto assignment.',
  11. options: {
  12. form: [
  13. {
  14. display: '',
  15. null: true,
  16. name: 'ticket_conditions_allow_regular_expression_operators',
  17. tag: 'boolean',
  18. options: {
  19. true => 'yes',
  20. false => 'no',
  21. },
  22. },
  23. ],
  24. },
  25. state: true,
  26. preferences: {
  27. online_service_disable: true,
  28. permission: ['admin.ticket'],
  29. },
  30. frontend: true
  31. )
  32. end
  33. end