20180320000001_setting_table_group_by_show_count.rb 888 B

12345678910111213141516171819202122232425262728293031323334
  1. class SettingTableGroupByShowCount < ActiveRecord::Migration[5.1]
  2. def up
  3. # return if it's a new setup
  4. return if !Setting.exists?(name: 'system_init_done')
  5. Setting.create_if_not_exists(
  6. title: 'Open ticket indicator',
  7. name: 'ui_table_group_by_show_count',
  8. area: 'UI::Base',
  9. description: 'Total display of the number of objects in a grouping.',
  10. options: {
  11. form: [
  12. {
  13. display: '',
  14. null: true,
  15. name: 'ui_table_group_by_show_count',
  16. tag: 'boolean',
  17. translate: true,
  18. options: {
  19. true => 'yes',
  20. false => 'no',
  21. },
  22. },
  23. ],
  24. },
  25. state: false,
  26. preferences: {
  27. permission: ['admin.ui'],
  28. },
  29. frontend: true
  30. )
  31. end
  32. end