20220119102815_issue3924_confirmation_dialog.rb 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. # Copyright (C) 2012-2023 Zammad Foundation, https://zammad-foundation.org/
  2. class Issue3924ConfirmationDialog < ActiveRecord::Migration[6.0]
  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: 'Note - visibility confirmation dialog',
  8. name: 'ui_ticket_zoom_article_visibility_confirmation_dialog',
  9. area: 'UI::TicketZoom',
  10. description: 'Defines if the agent has to accept a confirmation dialog when changing the article visibility to "public".',
  11. options: {
  12. form: [
  13. {
  14. display: '',
  15. null: true,
  16. name: 'ui_ticket_zoom_article_visibility_confirmation_dialog',
  17. tag: 'boolean',
  18. options: {
  19. true => 'yes',
  20. false => 'no',
  21. },
  22. },
  23. ],
  24. },
  25. state: false,
  26. preferences: {
  27. prio: 100,
  28. permission: ['admin.ui'],
  29. },
  30. frontend: true
  31. )
  32. end
  33. end