20160425000001_add_clearbit_integration.rb 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. class AddClearbitIntegration < ActiveRecord::Migration
  2. def up
  3. Setting.create_if_not_exists(
  4. title: 'Clearbit integration',
  5. name: 'clearbit_integration',
  6. area: 'Integration::Switch',
  7. description: 'Define if Clearbit (http://www.clearbit.com) is enabled or not.',
  8. options: {
  9. form: [
  10. {
  11. display: '',
  12. null: true,
  13. name: 'clearbit_integration',
  14. tag: 'boolean',
  15. options: {
  16. true => 'yes',
  17. false => 'no',
  18. },
  19. },
  20. ],
  21. },
  22. state: false,
  23. preferences: { prio: 1 },
  24. frontend: false
  25. )
  26. Setting.create_if_not_exists(
  27. title: 'Clearbit config',
  28. name: 'clearbit_config',
  29. area: 'Integration::Clearbit',
  30. description: 'Define the Clearbit config.',
  31. options: {},
  32. state: {},
  33. frontend: false,
  34. preferences: { prio: 2 },
  35. )
  36. Setting.create_if_not_exists(
  37. title: 'Define transaction backend.',
  38. name: '9000_clearbit_enrichment',
  39. area: 'Transaction::Backend::Async',
  40. description: 'Define the transaction backend which will enrich customer and organization informations from (http://www.clearbit.com).',
  41. options: {},
  42. state: 'Transaction::ClearbitEnrichment',
  43. frontend: false
  44. )
  45. end
  46. end