knitkit 2.1.14 → 2.1.15

Sign up to get free protection for your applications and to get access to all the features.
Files changed (63) hide show
  1. data/app/widgets/scaffold/base.rb +2 -2
  2. data/lib/knitkit/version.rb +1 -1
  3. metadata +5 -124
  4. data/spec/dummy/db/data_migrations/20110109173616_create_capability_scope_types.erp_tech_svcs.rb +0 -15
  5. data/spec/dummy/db/data_migrations/20110509223702_add_publisher_role.knitkit.rb +0 -22
  6. data/spec/dummy/db/data_migrations/20110525001935_add_usd_currency.erp_base_erp_svcs.rb +0 -12
  7. data/spec/dummy/db/data_migrations/20110608185830_create_default_dynamic_models_and_forms.erp_forms.rb +0 -33
  8. data/spec/dummy/db/data_migrations/20110609150135_add_iso_codes.erp_base_erp_svcs.rb +0 -19
  9. data/spec/dummy/db/data_migrations/20110728201729_erp_app_setup.erp_app.rb +0 -252
  10. data/spec/dummy/db/data_migrations/20110728201733_update_preferences.erp_app.rb +0 -53
  11. data/spec/dummy/db/data_migrations/20110802200222_schedule_delete_expired_sessions_job.erp_tech_svcs.rb +0 -16
  12. data/spec/dummy/db/data_migrations/20110816153456_add_knitkit_application.knitkit.rb +0 -32
  13. data/spec/dummy/db/data_migrations/20110816161238_create_desktop_app_audit_log_viewer.erp_app.rb +0 -21
  14. data/spec/dummy/db/data_migrations/20110817160743_add_file_manager_application.erp_app.rb +0 -32
  15. data/spec/dummy/db/data_migrations/20110828190913_create_desktop_app_dynamic_forms.erp_forms.rb +0 -19
  16. data/spec/dummy/db/data_migrations/20110913145838_setup_compass_ae_instance.erp_base_erp_svcs.rb +0 -12
  17. data/spec/dummy/db/data_migrations/20111108183739_add_default_capabilities.erp_app.rb +0 -23
  18. data/spec/dummy/db/data_migrations/20111108183740_add_new_contact_widgets.erp_app.rb +0 -42
  19. data/spec/dummy/db/data_migrations/20111111144706_setup_audit_log_types.erp_tech_svcs.rb +0 -22
  20. data/spec/dummy/db/data_migrations/20111118182910_setup_knitkit_capabilities.knitkit.rb +0 -128
  21. data/spec/dummy/db/data_migrations/20120127144444_create_website_role_types.knitkit.rb +0 -14
  22. data/spec/dummy/db/data_migrations/20120127150505_create_website_default_configuration.knitkit.rb +0 -73
  23. data/spec/dummy/db/data_migrations/20120127150506_add_primary_host_to_website_configuration.knitkit.rb +0 -34
  24. data/spec/dummy/db/data_migrations/20120229160222_add_userinfo_widget.erp_app.rb +0 -29
  25. data/spec/dummy/db/data_migrations/20120316150424_add_is_template_to_default_website_config.knitkit.rb +0 -17
  26. data/spec/dummy/db/data_migrations/20120405193721_create_party_and_role_type_for_communication_events.erp_app.rb +0 -11
  27. data/spec/dummy/db/data_migrations/20120411180756_create_user_management_mobile_application.erp_app.rb +0 -19
  28. data/spec/dummy/db/data_migrations/20120418164215_create_configuration_management_desktop_application.erp_app.rb +0 -23
  29. data/spec/dummy/db/data_migrations/20120809020508_update_website_and_configuration.knitkit.rb +0 -78
  30. data/spec/dummy/db/data_migrations/20120824013449_create_ticket_form.erp_forms.rb +0 -67
  31. data/spec/dummy/db/data_migrations/20121026013449_update_ticket_form.erp_forms.rb +0 -65
  32. data/spec/dummy/db/data_migrations/20121026191738_update_contact_form.erp_forms.rb +0 -27
  33. data/spec/dummy/db/data_migrations/20121116155018_create_group_relationship_and_role_types.erp_tech_svcs.rb +0 -20
  34. data/spec/dummy/db/data_migrations/20121129185611_upgrade_website_role_iid.knitkit.rb +0 -21
  35. data/spec/dummy/db/data_migrations/20121130201859_upgrade_remove_system_mgmt_app.erp_app.rb +0 -16
  36. data/spec/dummy/db/data_migrations/20121130212146_note_capabilities.erp_tech_svcs.rb +0 -24
  37. data/spec/dummy/db/data_migrations/20121218175028_create_security_management_desktop_application.erp_app.rb +0 -23
  38. data/spec/dummy/db/data_migrations/20130422154409_upgrade_compass_ae_instances_data.erp_base_erp_svcs.rb +0 -19
  39. data/spec/dummy/db/data_migrations/20130422154410_add_guid_to_instances.erp_base_erp_svcs.rb +0 -10
  40. data/spec/dummy/db/data_migrations/20130422154411_create_job_tracker_desktop_application.erp_app.rb +0 -23
  41. data/spec/dummy/db/data_migrations/20130422154412_created_tracked_jobs.erp_app.rb +0 -15
  42. data/spec/dummy/db/data_migrations/20130422154413_add_job_tracker_mobile_app.erp_app.rb +0 -17
  43. data/spec/dummy/db/migrate/20130107153232_base_erp_services.erp_base_erp_svcs.rb +0 -461
  44. data/spec/dummy/db/migrate/20130107153233_base_tech_services.erp_tech_svcs.rb +0 -271
  45. data/spec/dummy/db/migrate/20130107153234_create_has_attribute_tables.erp_tech_svcs.rb +0 -39
  46. data/spec/dummy/db/migrate/20130107153235_create_groups.erp_tech_svcs.rb +0 -19
  47. data/spec/dummy/db/migrate/20130107153236_upgrade_security.erp_tech_svcs.rb +0 -54
  48. data/spec/dummy/db/migrate/20130107153237_upgrade_security2.erp_tech_svcs.rb +0 -270
  49. data/spec/dummy/db/migrate/20130107153238_base_app_framework.erp_app.rb +0 -276
  50. data/spec/dummy/db/migrate/20130107153239_dynamic_forms.erp_forms.rb +0 -95
  51. data/spec/dummy/db/migrate/20130107153240_create_tickets.erp_forms.rb +0 -19
  52. data/spec/dummy/db/migrate/20130107153241_upgrade_dynamic_forms_table.erp_forms.rb +0 -32
  53. data/spec/dummy/db/migrate/20130107153242_setup_knitkit.knitkit.rb +0 -316
  54. data/spec/dummy/db/migrate/20130422154401_add_txn_status.erp_base_erp_svcs.rb +0 -37
  55. data/spec/dummy/db/migrate/20130422154402_upgrade_compass_ae_instances.erp_base_erp_svcs.rb +0 -34
  56. data/spec/dummy/db/migrate/20130422154403_add_uuid_compass_ae_instance.erp_base_erp_svcs.rb +0 -17
  57. data/spec/dummy/db/migrate/20130422154404_add_long_lat_to_address.erp_base_erp_svcs.rb +0 -16
  58. data/spec/dummy/db/migrate/20130422154405_add_queue_to_delayed_jobs.erp_tech_svcs.rb +0 -14
  59. data/spec/dummy/db/migrate/20130422154406_add_job_tracker.erp_app.rb +0 -20
  60. data/spec/dummy/db/migrate/20130422154407_update_mobile_application.erp_app.rb +0 -28
  61. data/spec/dummy/db/migrate/20130422154408_add_use_markdown_to_section.knitkit.rb +0 -20
  62. data/spec/dummy/db/schema.rb +0 -1248
  63. data/spec/dummy/db/spec.sqlite3 +0 -0
@@ -1,37 +0,0 @@
1
- # This migration comes from erp_base_erp_svcs (originally 20120606183856)
2
- class AddTxnStatus < ActiveRecord::Migration
3
- def up
4
- unless table_exists?(:status_applications)
5
- create_table :status_applications do |t|
6
- t.references :tracked_status_type
7
- t.references :status_application_record, :polymorphic => true
8
- t.datetime :from_date
9
- t.datetime :thru_date
10
-
11
- t.timestamps
12
- end
13
-
14
- add_index :status_applications, [:status_application_record_id, :status_application_record_type], :name => 'status_applications_record_idx'
15
- add_index :status_applications, :tracked_status_type_id, :name => 'tracked_status_type_id_idx'
16
- add_index :status_applications, :from_date, :name => 'from_date_idx'
17
- add_index :status_applications, :thru_date, :name => 'thru_date_idx'
18
- end
19
-
20
- unless table_exists?(:tracked_status_types)
21
- create_table :tracked_status_types do |t|
22
- t.string :description
23
- t.string :internal_identifier
24
- t.string :external_identifier
25
-
26
- t.timestamps
27
- end
28
-
29
- add_index :tracked_status_types, :internal_identifier, :name => 'tracked_status_types_iid_idx'
30
- end
31
- end
32
-
33
- def down
34
- drop_table :status_applications if table_exists?(:status_applications)
35
- drop_table :tracked_status_types if table_exists?(:tracked_status_types)
36
- end
37
- end
@@ -1,34 +0,0 @@
1
- # This migration comes from erp_base_erp_svcs (originally 20130211444444)
2
- # This migration comes from erp_base_erp_svcs (originally 20130211444444)
3
- class UpgradeCompassAeInstances < ActiveRecord::Migration
4
- def self.up
5
- unless columns(:compass_ae_instances).collect {|c| c.name}.include?('type')
6
- add_column :compass_ae_instances, :description, :string
7
- add_column :compass_ae_instances, :internal_identifier, :string
8
- add_column :compass_ae_instances, :type, :string
9
- add_column :compass_ae_instances, :schema, :string, :default => 'public'
10
- add_column :compass_ae_instances, :parent_id, :integer
11
-
12
- add_index :compass_ae_instances, :internal_identifier, :name => "iid_idx"
13
- add_index :compass_ae_instances, :schema, :name => "schema_idx"
14
- add_index :compass_ae_instances, :type, :name => "type_idx"
15
- add_index :compass_ae_instances, :parent_id, :name => "parent_id_idx"
16
- end
17
- end
18
-
19
- unless table_exists?(:compass_ae_instance_party_roles)
20
- create_table :compass_ae_instance_party_roles do |t|
21
- t.string :description
22
- t.integer :compass_ae_instance_id
23
- t.integer :party_id
24
- t.integer :role_type_id
25
-
26
- t.timestamps
27
- end
28
-
29
- add_index :compass_ae_instance_party_roles, :compass_ae_instance_id, :name => "compass_ae_instance_id_idx"
30
- add_index :compass_ae_instance_party_roles, :party_id, :name => "party_id_idx"
31
- add_index :compass_ae_instance_party_roles, :role_type_id, :name => "role_type_id_idx"
32
- end
33
-
34
- end
@@ -1,17 +0,0 @@
1
- # This migration comes from erp_base_erp_svcs (originally 20130404171435)
2
- require 'uuid'
3
-
4
- class AddUuidCompassAeInstance < ActiveRecord::Migration
5
- def self.up
6
- unless columns(:compass_ae_instances).collect {|c| c.name}.include?('guid')
7
- add_column :compass_ae_instances, :guid, :string
8
- add_index :compass_ae_instances, :guid, :name => "guid_idx"
9
- end
10
- end
11
-
12
- def self.down
13
- if columns(:compass_ae_instances).collect {|c| c.name}.include?('guid')
14
- remove_column :compass_ae_instances, :guid
15
- end
16
- end
17
- end
@@ -1,16 +0,0 @@
1
- # This migration comes from erp_base_erp_svcs (originally 20130411125210)
2
- class AddLongLatToAddress < ActiveRecord::Migration
3
- def up
4
- unless columns(:postal_addresses).collect {|c| c.name}.include?('latitude')
5
- add_column :postal_addresses, :latitude, :decimal, :precision => 12, :scale => 8
6
- add_column :postal_addresses, :longitude, :decimal, :precision => 12, :scale => 8
7
- end
8
- end
9
-
10
- def down
11
- if columns(:postal_addresses).collect {|c| c.name}.include?('latitude')
12
- remove_column :postal_addresses, :latitude
13
- remove_column :postal_addresses, :longitude
14
- end
15
- end
16
- end
@@ -1,14 +0,0 @@
1
- # This migration comes from erp_tech_svcs (originally 20130410135419)
2
- class AddQueueToDelayedJobs < ActiveRecord::Migration
3
- def up
4
- unless columns(:delayed_jobs).collect {|c| c.name}.include?('queue')
5
- add_column :delayed_jobs, :queue, :string
6
- end
7
- end
8
-
9
- def down
10
- if columns(:delayed_jobs).collect {|c| c.name}.include?('queue')
11
- remove_column :delayed_jobs, :queue, :string
12
- end
13
- end
14
- end
@@ -1,20 +0,0 @@
1
- # This migration comes from erp_app (originally 20120920145259)
2
- class AddJobTracker < ActiveRecord::Migration
3
- def up
4
- unless table_exists?(:job_trackers)
5
- create_table :job_trackers do |t|
6
- t.string :job_name
7
- t.string :job_klass
8
- t.string :run_time
9
- t.datetime :last_run_at
10
- t.datetime :next_run_at
11
- end
12
- end
13
- end
14
-
15
- def down
16
- if table_exists?(:job_trackers)
17
- drop_table :job_trackers
18
- end
19
- end
20
- end
@@ -1,28 +0,0 @@
1
- # This migration comes from erp_app (originally 20130410182333)
2
- class UpdateMobileApplication < ActiveRecord::Migration
3
- def up
4
- unless columns(:applications).collect { |c| c.name }.include?('xtype')
5
- rename_column :applications, :base_url, :xtype
6
-
7
- user_management = MobileApplication.find_by_internal_identifier('user_management')
8
- if user_management.nil?
9
- MobileApplication.create(
10
- :description => 'User Mgmt',
11
- :icon => 'icon-user',
12
- :internal_identifier => 'user_management',
13
- :xtype => 'compass-erpapp-mobile-usermanagement-application'
14
- )
15
- else
16
- user_management.description = 'User Mgmt'
17
- user_management.xtype = 'compass-erpapp-mobile-usermanagement-application'
18
- user_management.save
19
- end
20
- end
21
- end
22
-
23
- def down
24
- if columns(:applications).collect { |c| c.name }.include?('xtype')
25
- rename_column :applications, :xtype, :base_url
26
- end
27
- end
28
- end
@@ -1,20 +0,0 @@
1
- # This migration comes from knitkit (originally 20130405184234)
2
- class AddUseMarkdownToSection < ActiveRecord::Migration
3
- def self.up
4
- unless columns(:website_sections).collect {|c| c.name}.include?('use_markdown')
5
- add_column :website_sections, :use_markdown, :boolean
6
-
7
- WebsiteSection.all.each do |section|
8
- section.use_markdown = false
9
- section.save
10
- end
11
-
12
- end
13
- end
14
-
15
- def self.down
16
- if columns(:website_sections).collect {|c| c.name}.include?('use_markdown')
17
- remove_column :website_sections, :use_markdown
18
- end
19
- end
20
- end
@@ -1,1248 +0,0 @@
1
- # encoding: UTF-8
2
- # This file is auto-generated from the current state of the database. Instead
3
- # of editing this file, please use the migrations feature of Active Record to
4
- # incrementally modify your database, and then regenerate this schema definition.
5
- #
6
- # Note that this schema.rb definition is the authoritative source for your
7
- # database schema. If you need to create the application database on another
8
- # system, you should be using db:schema:load, not running all the migrations
9
- # from scratch. The latter is a flawed and unsustainable approach (the more migrations
10
- # you'll amass, the slower it'll run and the greater likelihood for issues).
11
- #
12
- # It's strongly recommended to check this file into your version control system.
13
-
14
- ActiveRecord::Schema.define(:version => 20130422154408) do
15
-
16
- create_table "app_containers", :force => true do |t|
17
- t.integer "user_id"
18
- t.string "description"
19
- t.string "internal_identifier"
20
- t.string "type"
21
- t.datetime "created_at", :null => false
22
- t.datetime "updated_at", :null => false
23
- end
24
-
25
- add_index "app_containers", ["type"], :name => "index_app_containers_on_type"
26
- add_index "app_containers", ["user_id"], :name => "index_app_containers_on_user_id"
27
-
28
- create_table "app_containers_applications", :id => false, :force => true do |t|
29
- t.integer "app_container_id"
30
- t.integer "application_id"
31
- end
32
-
33
- add_index "app_containers_applications", ["app_container_id"], :name => "index_app_containers_applications_on_app_container_id"
34
- add_index "app_containers_applications", ["application_id"], :name => "index_app_containers_applications_on_application_id"
35
-
36
- create_table "applications", :force => true do |t|
37
- t.string "description"
38
- t.string "icon"
39
- t.string "internal_identifier"
40
- t.string "javascript_class_name"
41
- t.string "shortcut_id"
42
- t.string "xtype"
43
- t.string "type"
44
- t.datetime "created_at", :null => false
45
- t.datetime "updated_at", :null => false
46
- end
47
-
48
- create_table "applications_widgets", :id => false, :force => true do |t|
49
- t.integer "application_id"
50
- t.integer "widget_id"
51
- end
52
-
53
- add_index "applications_widgets", ["application_id"], :name => "index_applications_widgets_on_application_id"
54
- add_index "applications_widgets", ["widget_id"], :name => "index_applications_widgets_on_widget_id"
55
-
56
- create_table "attribute_types", :force => true do |t|
57
- t.string "internal_identifier"
58
- t.string "description"
59
- t.string "data_type"
60
- t.datetime "created_at", :null => false
61
- t.datetime "updated_at", :null => false
62
- end
63
-
64
- add_index "attribute_types", ["internal_identifier"], :name => ":attribute_types_iid_idx"
65
-
66
- create_table "attribute_values", :force => true do |t|
67
- t.integer "attributed_record_id"
68
- t.string "attributed_record_type"
69
- t.integer "attribute_type_id"
70
- t.string "value"
71
- t.datetime "created_at", :null => false
72
- t.datetime "updated_at", :null => false
73
- end
74
-
75
- add_index "attribute_values", ["attribute_type_id"], :name => "attribute_values_attributed_type_idx"
76
- add_index "attribute_values", ["attributed_record_id", "attributed_record_type"], :name => "attribute_values_attributed_record_idx"
77
- add_index "attribute_values", ["value"], :name => "attribute_values_value_idx"
78
-
79
- create_table "audit_log_item_types", :force => true do |t|
80
- t.string "internal_identifier"
81
- t.string "external_identifier"
82
- t.string "external_id_source"
83
- t.string "description"
84
- t.string "comments"
85
- t.integer "parent_id"
86
- t.integer "lft"
87
- t.integer "rgt"
88
- t.datetime "created_at", :null => false
89
- t.datetime "updated_at", :null => false
90
- end
91
-
92
- create_table "audit_log_items", :force => true do |t|
93
- t.integer "audit_log_id"
94
- t.integer "audit_log_item_type_id"
95
- t.string "audit_log_item_value"
96
- t.string "description"
97
- t.datetime "created_at", :null => false
98
- t.datetime "updated_at", :null => false
99
- end
100
-
101
- create_table "audit_log_types", :force => true do |t|
102
- t.string "description"
103
- t.string "error_code"
104
- t.string "comments"
105
- t.string "internal_identifier"
106
- t.string "external_identifier"
107
- t.string "external_id_source"
108
- t.integer "parent_id"
109
- t.integer "lft"
110
- t.integer "rgt"
111
- t.datetime "created_at", :null => false
112
- t.datetime "updated_at", :null => false
113
- end
114
-
115
- create_table "audit_logs", :force => true do |t|
116
- t.string "application"
117
- t.string "description"
118
- t.integer "party_id"
119
- t.text "additional_info"
120
- t.integer "audit_log_type_id"
121
- t.integer "event_record_id"
122
- t.string "event_record_type"
123
- t.datetime "created_at", :null => false
124
- t.datetime "updated_at", :null => false
125
- end
126
-
127
- add_index "audit_logs", ["event_record_id", "event_record_type"], :name => "event_record_index"
128
- add_index "audit_logs", ["party_id"], :name => "index_audit_logs_on_party_id"
129
-
130
- create_table "capabilities", :force => true do |t|
131
- t.string "description"
132
- t.integer "capability_type_id"
133
- t.string "capability_resource_type"
134
- t.integer "capability_resource_id"
135
- t.integer "scope_type_id"
136
- t.text "scope_query"
137
- t.datetime "created_at", :null => false
138
- t.datetime "updated_at", :null => false
139
- end
140
-
141
- add_index "capabilities", ["capability_resource_id", "capability_resource_type"], :name => "capability_resource_index"
142
- add_index "capabilities", ["capability_type_id"], :name => "index_capabilities_on_capability_type_id"
143
- add_index "capabilities", ["scope_type_id"], :name => "index_capabilities_on_scope_type_id"
144
-
145
- create_table "capability_accessors", :force => true do |t|
146
- t.string "capability_accessor_record_type"
147
- t.integer "capability_accessor_record_id"
148
- t.integer "capability_id"
149
- t.datetime "created_at", :null => false
150
- t.datetime "updated_at", :null => false
151
- end
152
-
153
- add_index "capability_accessors", ["capability_accessor_record_id", "capability_accessor_record_type"], :name => "capability_accessor_record_index"
154
- add_index "capability_accessors", ["capability_id"], :name => "index_capability_accessors_on_capability_id"
155
-
156
- create_table "capability_types", :force => true do |t|
157
- t.string "internal_identifier"
158
- t.string "description"
159
- t.datetime "created_at", :null => false
160
- t.datetime "updated_at", :null => false
161
- end
162
-
163
- create_table "capable_models", :force => true do |t|
164
- t.integer "capable_model_record_id"
165
- t.string "capable_model_record_type"
166
- t.datetime "created_at", :null => false
167
- t.datetime "updated_at", :null => false
168
- end
169
-
170
- add_index "capable_models", ["capable_model_record_id", "capable_model_record_type"], :name => "capable_model_record_idx"
171
-
172
- create_table "categories", :force => true do |t|
173
- t.string "description"
174
- t.string "external_identifier"
175
- t.datetime "from_date"
176
- t.datetime "to_date"
177
- t.string "internal_identifier"
178
- t.integer "category_record_id"
179
- t.string "category_record_type"
180
- t.integer "parent_id"
181
- t.integer "lft"
182
- t.integer "rgt"
183
- t.datetime "created_at", :null => false
184
- t.datetime "updated_at", :null => false
185
- end
186
-
187
- add_index "categories", ["category_record_id", "category_record_type"], :name => "category_polymorphic"
188
-
189
- create_table "category_classifications", :force => true do |t|
190
- t.integer "category_id"
191
- t.string "classification_type"
192
- t.integer "classification_id"
193
- t.datetime "from_date"
194
- t.datetime "to_date"
195
- t.datetime "created_at", :null => false
196
- t.datetime "updated_at", :null => false
197
- end
198
-
199
- add_index "category_classifications", ["classification_id", "classification_type"], :name => "classification_polymorphic"
200
-
201
- create_table "comments", :force => true do |t|
202
- t.string "commentor_name"
203
- t.string "email"
204
- t.text "comment"
205
- t.integer "approved"
206
- t.datetime "approved_at"
207
- t.integer "user_id"
208
- t.integer "commented_record_id"
209
- t.string "commented_record_type"
210
- t.datetime "created_at", :null => false
211
- t.datetime "updated_at", :null => false
212
- end
213
-
214
- add_index "comments", ["approved"], :name => "index_comments_on_approved"
215
- add_index "comments", ["commented_record_id", "commented_record_type"], :name => "commented_record_idx"
216
- add_index "comments", ["user_id"], :name => "index_comments_on_user_id"
217
-
218
- create_table "compass_ae_instance_party_roles", :force => true do |t|
219
- t.string "description"
220
- t.integer "compass_ae_instance_id"
221
- t.integer "party_id"
222
- t.integer "role_type_id"
223
- t.datetime "created_at", :null => false
224
- t.datetime "updated_at", :null => false
225
- end
226
-
227
- add_index "compass_ae_instance_party_roles", ["compass_ae_instance_id"], :name => "compass_ae_instance_id_idx"
228
- add_index "compass_ae_instance_party_roles", ["party_id"], :name => "party_id_idx"
229
- add_index "compass_ae_instance_party_roles", ["role_type_id"], :name => "role_type_id_idx"
230
-
231
- create_table "compass_ae_instances", :force => true do |t|
232
- t.decimal "version", :precision => 8, :scale => 3
233
- t.datetime "created_at", :null => false
234
- t.datetime "updated_at", :null => false
235
- t.string "description"
236
- t.string "internal_identifier"
237
- t.string "type"
238
- t.string "schema", :default => "public"
239
- t.integer "parent_id"
240
- t.string "guid"
241
- end
242
-
243
- add_index "compass_ae_instances", ["guid"], :name => "guid_idx"
244
- add_index "compass_ae_instances", ["internal_identifier"], :name => "iid_idx"
245
- add_index "compass_ae_instances", ["parent_id"], :name => "parent_id_idx"
246
- add_index "compass_ae_instances", ["schema"], :name => "schema_idx"
247
- add_index "compass_ae_instances", ["type"], :name => "type_idx"
248
-
249
- create_table "configuration_item_types", :force => true do |t|
250
- t.integer "parent_id"
251
- t.integer "lft"
252
- t.integer "rgt"
253
- t.string "description"
254
- t.string "internal_identifier"
255
- t.boolean "allow_user_defined_options", :default => false
256
- t.boolean "is_multi_optional", :default => false
257
- t.datetime "created_at", :null => false
258
- t.datetime "updated_at", :null => false
259
- end
260
-
261
- create_table "configuration_item_types_configuration_options", :force => true do |t|
262
- t.integer "configuration_item_type_id"
263
- t.integer "configuration_option_id"
264
- t.boolean "is_default", :default => false
265
- t.datetime "created_at", :null => false
266
- t.datetime "updated_at", :null => false
267
- end
268
-
269
- add_index "configuration_item_types_configuration_options", ["configuration_item_type_id"], :name => "conf_item_type_conf_opt_id_item_idx"
270
- add_index "configuration_item_types_configuration_options", ["configuration_option_id"], :name => "conf_item_type_conf_opt_id_opt_idx"
271
-
272
- create_table "configuration_item_types_configurations", :id => false, :force => true do |t|
273
- t.integer "configuration_item_type_id"
274
- t.integer "configuration_id"
275
- end
276
-
277
- add_index "configuration_item_types_configurations", ["configuration_id"], :name => "conf_id_idx"
278
- add_index "configuration_item_types_configurations", ["configuration_item_type_id", "configuration_id"], :name => "conf_config_type_uniq_idx", :unique => true
279
- add_index "configuration_item_types_configurations", ["configuration_item_type_id"], :name => "conf_conf_type_id_item_idx"
280
-
281
- create_table "configuration_items", :force => true do |t|
282
- t.integer "configuration_id"
283
- t.integer "configuration_item_type_id"
284
- t.integer "configuration_option_id"
285
- t.datetime "created_at", :null => false
286
- t.datetime "updated_at", :null => false
287
- end
288
-
289
- add_index "configuration_items", ["configuration_id"], :name => "index_configuration_items_on_configuration_id"
290
- add_index "configuration_items", ["configuration_item_type_id"], :name => "index_configuration_items_on_configuration_item_type_id"
291
- add_index "configuration_items", ["configuration_option_id"], :name => "index_configuration_items_on_configuration_option_id"
292
-
293
- create_table "configuration_items_configuration_options", :id => false, :force => true do |t|
294
- t.integer "configuration_item_id"
295
- t.integer "configuration_option_id"
296
- end
297
-
298
- add_index "configuration_items_configuration_options", ["configuration_item_id"], :name => "conf_item_conf_opt_id_item_idx"
299
- add_index "configuration_items_configuration_options", ["configuration_option_id"], :name => "conf_item_conf_opt_id_opt_idx"
300
-
301
- create_table "configuration_options", :force => true do |t|
302
- t.string "description"
303
- t.string "internal_identifier"
304
- t.string "value"
305
- t.text "comment"
306
- t.boolean "user_defined", :default => false
307
- t.datetime "created_at", :null => false
308
- t.datetime "updated_at", :null => false
309
- end
310
-
311
- add_index "configuration_options", ["internal_identifier"], :name => "index_configuration_options_on_internal_identifier"
312
- add_index "configuration_options", ["user_defined"], :name => "index_configuration_options_on_user_defined"
313
- add_index "configuration_options", ["value"], :name => "index_configuration_options_on_value"
314
-
315
- create_table "configurations", :force => true do |t|
316
- t.string "description"
317
- t.string "internal_identifier"
318
- t.boolean "active"
319
- t.boolean "is_template", :default => false
320
- t.datetime "created_at", :null => false
321
- t.datetime "updated_at", :null => false
322
- end
323
-
324
- add_index "configurations", ["is_template"], :name => "index_configurations_on_is_template"
325
-
326
- create_table "contact_purposes", :force => true do |t|
327
- t.integer "parent_id"
328
- t.integer "lft"
329
- t.integer "rgt"
330
- t.string "description"
331
- t.string "comments"
332
- t.string "internal_identifier"
333
- t.string "external_identifier"
334
- t.string "external_id_source"
335
- t.datetime "created_at", :null => false
336
- t.datetime "updated_at", :null => false
337
- end
338
-
339
- add_index "contact_purposes", ["parent_id"], :name => "index_contact_purposes_on_parent_id"
340
-
341
- create_table "contact_purposes_contacts", :id => false, :force => true do |t|
342
- t.integer "contact_id"
343
- t.integer "contact_purpose_id"
344
- end
345
-
346
- add_index "contact_purposes_contacts", ["contact_id", "contact_purpose_id"], :name => "contact_purposes_contacts_index"
347
-
348
- create_table "contact_types", :force => true do |t|
349
- t.integer "parent_id"
350
- t.integer "lft"
351
- t.integer "rgt"
352
- t.string "description"
353
- t.string "comments"
354
- t.string "internal_identifier"
355
- t.string "external_identifier"
356
- t.string "external_id_source"
357
- t.datetime "created_at", :null => false
358
- t.datetime "updated_at", :null => false
359
- end
360
-
361
- add_index "contact_types", ["parent_id"], :name => "index_contact_types_on_parent_id"
362
-
363
- create_table "contacts", :force => true do |t|
364
- t.integer "party_id"
365
- t.integer "contact_mechanism_id"
366
- t.string "contact_mechanism_type"
367
- t.string "external_identifier"
368
- t.string "external_id_source"
369
- t.datetime "created_at", :null => false
370
- t.datetime "updated_at", :null => false
371
- end
372
-
373
- add_index "contacts", ["contact_mechanism_id", "contact_mechanism_type"], :name => "besi_2"
374
- add_index "contacts", ["party_id"], :name => "index_contacts_on_party_id"
375
-
376
- create_table "content_versions", :force => true do |t|
377
- t.integer "content_id"
378
- t.integer "version"
379
- t.string "title"
380
- t.string "permalink"
381
- t.text "excerpt_html"
382
- t.text "body_html"
383
- t.integer "created_by_id"
384
- t.integer "updated_by_id"
385
- t.string "internal_identifier"
386
- t.boolean "display_title"
387
- t.datetime "created_at"
388
- t.datetime "updated_at"
389
- t.string "versioned_type"
390
- end
391
-
392
- add_index "content_versions", ["content_id"], :name => "index_content_versions_on_content_id"
393
-
394
- create_table "contents", :force => true do |t|
395
- t.string "type"
396
- t.string "title"
397
- t.string "permalink"
398
- t.text "excerpt_html"
399
- t.text "body_html"
400
- t.integer "created_by_id"
401
- t.integer "updated_by_id"
402
- t.string "internal_identifier"
403
- t.boolean "display_title"
404
- t.integer "version"
405
- t.datetime "created_at", :null => false
406
- t.datetime "updated_at", :null => false
407
- end
408
-
409
- add_index "contents", ["created_by_id"], :name => "index_contents_on_created_by_id"
410
- add_index "contents", ["internal_identifier"], :name => "contents_iid_idx"
411
- add_index "contents", ["permalink"], :name => "index_contents_on_permalink"
412
- add_index "contents", ["type"], :name => "index_contents_on_type"
413
- add_index "contents", ["updated_by_id"], :name => "index_contents_on_updated_by_id"
414
- add_index "contents", ["version"], :name => "index_contents_on_version"
415
-
416
- create_table "currencies", :force => true do |t|
417
- t.string "name"
418
- t.string "definition"
419
- t.string "internal_identifier"
420
- t.string "numeric_code"
421
- t.string "major_unit_symbol"
422
- t.string "minor_unit_symbol"
423
- t.string "ratio_of_minor_unit_to_major_unit"
424
- t.string "postfix_label"
425
- t.datetime "introduction_date"
426
- t.datetime "expiration_date"
427
- t.datetime "created_at", :null => false
428
- t.datetime "updated_at", :null => false
429
- end
430
-
431
- add_index "currencies", ["internal_identifier"], :name => "index_currencies_on_internal_identifier"
432
-
433
- create_table "delayed_jobs", :force => true do |t|
434
- t.integer "priority", :default => 0
435
- t.integer "attempts", :default => 0
436
- t.text "handler"
437
- t.text "last_error"
438
- t.datetime "run_at"
439
- t.datetime "locked_at"
440
- t.datetime "failed_at"
441
- t.string "locked_by"
442
- t.string "queue"
443
- t.datetime "created_at", :null => false
444
- t.datetime "updated_at", :null => false
445
- end
446
-
447
- add_index "delayed_jobs", ["priority", "run_at"], :name => "delayed_jobs_priority"
448
-
449
- create_table "descriptive_assets", :force => true do |t|
450
- t.integer "view_type_id"
451
- t.string "internal_identifier"
452
- t.text "description"
453
- t.string "external_identifier"
454
- t.string "external_id_source"
455
- t.integer "described_record_id"
456
- t.string "described_record_type"
457
- t.datetime "created_at", :null => false
458
- t.datetime "updated_at", :null => false
459
- end
460
-
461
- add_index "descriptive_assets", ["described_record_id", "described_record_type"], :name => "described_record_idx"
462
- add_index "descriptive_assets", ["view_type_id"], :name => "index_descriptive_assets_on_view_type_id"
463
-
464
- create_table "document_types", :force => true do |t|
465
- t.string "external_identifier"
466
- t.string "internal_identifier"
467
- t.string "description"
468
- t.datetime "created_at", :null => false
469
- t.datetime "updated_at", :null => false
470
- end
471
-
472
- create_table "documented_items", :force => true do |t|
473
- t.string "documented_klass"
474
- t.integer "documented_content_id"
475
- t.integer "online_document_section_id"
476
- t.datetime "created_at", :null => false
477
- t.datetime "updated_at", :null => false
478
- end
479
-
480
- create_table "documents", :force => true do |t|
481
- t.string "external_identifier"
482
- t.string "internal_identifier"
483
- t.string "description"
484
- t.datetime "document_date"
485
- t.text "dynamic_attributes"
486
- t.integer "document_record_id"
487
- t.string "document_record_type"
488
- t.integer "document_type_id"
489
- t.datetime "created_at", :null => false
490
- t.datetime "updated_at", :null => false
491
- end
492
-
493
- add_index "documents", ["document_record_type", "document_record_id"], :name => "document_record_poly_idx"
494
- add_index "documents", ["document_type_id"], :name => "document_type_idx"
495
-
496
- create_table "dynamic_data", :force => true do |t|
497
- t.string "reference_type"
498
- t.integer "reference_id"
499
- t.text "dynamic_attributes"
500
- t.integer "created_with_form_id"
501
- t.integer "updated_with_form_id"
502
- t.integer "created_by_id"
503
- t.integer "updated_by_id"
504
- t.datetime "created_at", :null => false
505
- t.datetime "updated_at", :null => false
506
- end
507
-
508
- add_index "dynamic_data", ["created_by_id"], :name => "index_dynamic_data_on_created_by_id"
509
- add_index "dynamic_data", ["created_with_form_id"], :name => "index_dynamic_data_on_created_with_form_id"
510
- add_index "dynamic_data", ["reference_id"], :name => "index_dynamic_data_on_reference_id"
511
- add_index "dynamic_data", ["reference_type"], :name => "index_dynamic_data_on_reference_type"
512
- add_index "dynamic_data", ["updated_by_id"], :name => "index_dynamic_data_on_updated_by_id"
513
- add_index "dynamic_data", ["updated_with_form_id"], :name => "index_dynamic_data_on_updated_with_form_id"
514
-
515
- create_table "dynamic_form_documents", :force => true do |t|
516
- t.integer "dynamic_form_model_id"
517
- t.string "type"
518
- t.datetime "created_at", :null => false
519
- t.datetime "updated_at", :null => false
520
- end
521
-
522
- add_index "dynamic_form_documents", ["dynamic_form_model_id"], :name => "index_dynamic_form_documents_on_dynamic_form_model_id"
523
- add_index "dynamic_form_documents", ["type"], :name => "index_dynamic_form_documents_on_type"
524
-
525
- create_table "dynamic_form_models", :force => true do |t|
526
- t.string "model_name"
527
- t.boolean "show_in_multitask", :default => false
528
- t.boolean "allow_comments", :default => true
529
- t.boolean "allow_files", :default => true
530
- t.string "file_security_default", :default => "private"
531
- t.datetime "created_at", :null => false
532
- t.datetime "updated_at", :null => false
533
- end
534
-
535
- create_table "dynamic_forms", :force => true do |t|
536
- t.string "description"
537
- t.text "definition"
538
- t.integer "dynamic_form_model_id"
539
- t.string "model_name"
540
- t.string "internal_identifier"
541
- t.boolean "default"
542
- t.string "widget_action", :default => "save"
543
- t.string "widget_email_recipients"
544
- t.boolean "focus_first_field", :default => true
545
- t.boolean "submit_empty_text", :default => false
546
- t.string "msg_target", :default => "qtip"
547
- t.string "submit_button_label", :default => "Submit"
548
- t.string "cancel_button_label", :default => "Cancel"
549
- t.text "comment"
550
- t.integer "created_by_id"
551
- t.integer "updated_by_id"
552
- t.datetime "created_at", :null => false
553
- t.datetime "updated_at", :null => false
554
- end
555
-
556
- add_index "dynamic_forms", ["created_by_id"], :name => "index_dynamic_forms_on_created_by_id"
557
- add_index "dynamic_forms", ["dynamic_form_model_id"], :name => "index_dynamic_forms_on_dynamic_form_model_id"
558
- add_index "dynamic_forms", ["internal_identifier"], :name => "index_dynamic_forms_on_internal_identifier"
559
- add_index "dynamic_forms", ["model_name"], :name => "index_dynamic_forms_on_model_name"
560
- add_index "dynamic_forms", ["updated_by_id"], :name => "index_dynamic_forms_on_updated_by_id"
561
-
562
- create_table "email_addresses", :force => true do |t|
563
- t.string "email_address"
564
- t.string "description"
565
- t.datetime "created_at", :null => false
566
- t.datetime "updated_at", :null => false
567
- end
568
-
569
- create_table "file_assets", :force => true do |t|
570
- t.integer "file_asset_holder_id"
571
- t.string "file_asset_holder_type"
572
- t.string "type"
573
- t.string "name"
574
- t.string "directory"
575
- t.string "data_file_name"
576
- t.string "data_content_type"
577
- t.integer "data_file_size"
578
- t.datetime "data_updated_at"
579
- t.string "width"
580
- t.string "height"
581
- t.datetime "created_at", :null => false
582
- t.datetime "updated_at", :null => false
583
- end
584
-
585
- add_index "file_assets", ["directory"], :name => "index_file_assets_on_directory"
586
- add_index "file_assets", ["file_asset_holder_id", "file_asset_holder_type"], :name => "file_asset_holder_idx"
587
- add_index "file_assets", ["name"], :name => "index_file_assets_on_name"
588
- add_index "file_assets", ["type"], :name => "index_file_assets_on_type"
589
-
590
- create_table "geo_countries", :force => true do |t|
591
- t.string "name"
592
- t.string "iso_code_2"
593
- t.string "iso_code_3"
594
- t.boolean "display", :default => true
595
- t.integer "external_id"
596
- t.datetime "created_at"
597
- end
598
-
599
- add_index "geo_countries", ["iso_code_2"], :name => "index_geo_countries_on_iso_code_2"
600
- add_index "geo_countries", ["name"], :name => "index_geo_countries_on_name"
601
-
602
- create_table "geo_zones", :force => true do |t|
603
- t.integer "geo_country_id"
604
- t.string "zone_code", :default => "2"
605
- t.string "zone_name"
606
- t.datetime "created_at"
607
- end
608
-
609
- add_index "geo_zones", ["geo_country_id"], :name => "index_geo_zones_on_geo_country_id"
610
- add_index "geo_zones", ["zone_code"], :name => "index_geo_zones_on_zone_code"
611
- add_index "geo_zones", ["zone_name"], :name => "index_geo_zones_on_zone_name"
612
-
613
- create_table "groups", :force => true do |t|
614
- t.string "description"
615
- t.datetime "created_at", :null => false
616
- t.datetime "updated_at", :null => false
617
- end
618
-
619
- create_table "individuals", :force => true do |t|
620
- t.integer "party_id"
621
- t.string "current_last_name"
622
- t.string "current_first_name"
623
- t.string "current_middle_name"
624
- t.string "current_personal_title"
625
- t.string "current_suffix"
626
- t.string "current_nickname"
627
- t.string "gender", :limit => 1
628
- t.date "birth_date"
629
- t.decimal "height", :precision => 5, :scale => 2
630
- t.integer "weight"
631
- t.string "mothers_maiden_name"
632
- t.string "marital_status", :limit => 1
633
- t.string "social_security_number"
634
- t.integer "current_passport_number"
635
- t.date "current_passport_expire_date"
636
- t.integer "total_years_work_experience"
637
- t.string "comments"
638
- t.string "encrypted_ssn"
639
- t.string "temp_ssn"
640
- t.string "salt"
641
- t.string "ssn_last_four"
642
- t.datetime "created_at", :null => false
643
- t.datetime "updated_at", :null => false
644
- end
645
-
646
- add_index "individuals", ["party_id"], :name => "index_individuals_on_party_id"
647
-
648
- create_table "job_trackers", :force => true do |t|
649
- t.string "job_name"
650
- t.string "job_klass"
651
- t.string "run_time"
652
- t.datetime "last_run_at"
653
- t.datetime "next_run_at"
654
- end
655
-
656
- create_table "money", :force => true do |t|
657
- t.string "description"
658
- t.decimal "amount", :precision => 8, :scale => 2
659
- t.integer "currency_id"
660
- t.datetime "created_at", :null => false
661
- t.datetime "updated_at", :null => false
662
- end
663
-
664
- add_index "money", ["currency_id"], :name => "index_money_on_currency_id"
665
-
666
- create_table "note_types", :force => true do |t|
667
- t.integer "parent_id"
668
- t.integer "lft"
669
- t.integer "rgt"
670
- t.string "description"
671
- t.string "internal_identifier"
672
- t.string "external_identifier"
673
- t.integer "note_type_record_id"
674
- t.string "note_type_record_type"
675
- t.datetime "created_at", :null => false
676
- t.datetime "updated_at", :null => false
677
- end
678
-
679
- add_index "note_types", ["note_type_record_id", "note_type_record_type"], :name => "note_type_record_idx"
680
-
681
- create_table "notes", :force => true do |t|
682
- t.integer "created_by_id"
683
- t.text "content"
684
- t.integer "noted_record_id"
685
- t.string "noted_record_type"
686
- t.integer "note_type_id"
687
- t.datetime "created_at", :null => false
688
- t.datetime "updated_at", :null => false
689
- end
690
-
691
- add_index "notes", ["created_by_id"], :name => "index_notes_on_created_by_id"
692
- add_index "notes", ["note_type_id"], :name => "index_notes_on_note_type_id"
693
- add_index "notes", ["noted_record_id", "noted_record_type"], :name => "index_notes_on_noted_record_id_and_noted_record_type"
694
-
695
- create_table "organizations", :force => true do |t|
696
- t.string "description"
697
- t.string "tax_id_number"
698
- t.datetime "created_at", :null => false
699
- t.datetime "updated_at", :null => false
700
- end
701
-
702
- create_table "parties", :force => true do |t|
703
- t.string "description"
704
- t.integer "business_party_id"
705
- t.string "business_party_type"
706
- t.integer "list_view_image_id"
707
- t.string "enterprise_identifier"
708
- t.datetime "created_at", :null => false
709
- t.datetime "updated_at", :null => false
710
- end
711
-
712
- add_index "parties", ["business_party_id", "business_party_type"], :name => "besi_1"
713
-
714
- create_table "parties_security_roles", :id => false, :force => true do |t|
715
- t.integer "party_id"
716
- t.integer "security_role_id"
717
- end
718
-
719
- add_index "parties_security_roles", ["party_id"], :name => "index_parties_security_roles_on_party_id"
720
- add_index "parties_security_roles", ["security_role_id"], :name => "index_parties_security_roles_on_security_role_id"
721
-
722
- create_table "party_relationships", :force => true do |t|
723
- t.string "description"
724
- t.integer "party_id_from"
725
- t.integer "party_id_to"
726
- t.integer "role_type_id_from"
727
- t.integer "role_type_id_to"
728
- t.integer "status_type_id"
729
- t.integer "priority_type_id"
730
- t.integer "relationship_type_id"
731
- t.date "from_date"
732
- t.date "thru_date"
733
- t.string "external_identifier"
734
- t.string "external_id_source"
735
- t.datetime "created_at", :null => false
736
- t.datetime "updated_at", :null => false
737
- end
738
-
739
- add_index "party_relationships", ["priority_type_id"], :name => "index_party_relationships_on_priority_type_id"
740
- add_index "party_relationships", ["relationship_type_id"], :name => "index_party_relationships_on_relationship_type_id"
741
- add_index "party_relationships", ["status_type_id"], :name => "index_party_relationships_on_status_type_id"
742
-
743
- create_table "party_roles", :force => true do |t|
744
- t.string "type"
745
- t.integer "party_id"
746
- t.integer "role_type_id"
747
- t.datetime "created_at", :null => false
748
- t.datetime "updated_at", :null => false
749
- end
750
-
751
- add_index "party_roles", ["party_id"], :name => "index_party_roles_on_party_id"
752
- add_index "party_roles", ["role_type_id"], :name => "index_party_roles_on_role_type_id"
753
-
754
- create_table "party_search_facts", :force => true do |t|
755
- t.integer "party_id"
756
- t.string "eid"
757
- t.string "type"
758
- t.text "roles"
759
- t.string "party_description"
760
- t.string "party_business_party_type"
761
- t.string "user_login"
762
- t.string "individual_current_last_name"
763
- t.string "individual_current_first_name"
764
- t.string "individual_current_middle_name"
765
- t.string "individual_birth_date"
766
- t.string "individual_ssn"
767
- t.string "party_phone_number"
768
- t.string "party_email_address"
769
- t.string "party_address_1"
770
- t.string "party_address_2"
771
- t.string "party_primary_address_city"
772
- t.string "party_primary_address_state"
773
- t.string "party_primary_address_zip"
774
- t.string "party_primary_address_country"
775
- t.boolean "user_enabled"
776
- t.string "user_type"
777
- t.boolean "reindex"
778
- t.datetime "created_at", :null => false
779
- t.datetime "updated_at", :null => false
780
- end
781
-
782
- create_table "phone_numbers", :force => true do |t|
783
- t.string "phone_number"
784
- t.string "description"
785
- t.datetime "created_at", :null => false
786
- t.datetime "updated_at", :null => false
787
- end
788
-
789
- create_table "postal_addresses", :force => true do |t|
790
- t.string "address_line_1"
791
- t.string "address_line_2"
792
- t.string "city"
793
- t.string "state"
794
- t.string "zip"
795
- t.string "country"
796
- t.string "description"
797
- t.integer "geo_country_id"
798
- t.integer "geo_zone_id"
799
- t.datetime "created_at", :null => false
800
- t.datetime "updated_at", :null => false
801
- t.decimal "latitude", :precision => 12, :scale => 8
802
- t.decimal "longitude", :precision => 12, :scale => 8
803
- end
804
-
805
- add_index "postal_addresses", ["geo_country_id"], :name => "index_postal_addresses_on_geo_country_id"
806
- add_index "postal_addresses", ["geo_zone_id"], :name => "index_postal_addresses_on_geo_zone_id"
807
-
808
- create_table "preference_options", :force => true do |t|
809
- t.string "description"
810
- t.string "internal_identifier"
811
- t.string "value"
812
- t.datetime "created_at", :null => false
813
- t.datetime "updated_at", :null => false
814
- end
815
-
816
- create_table "preference_options_preference_types", :id => false, :force => true do |t|
817
- t.integer "preference_type_id"
818
- t.integer "preference_option_id"
819
- end
820
-
821
- add_index "preference_options_preference_types", ["preference_option_id"], :name => "pref_opt_pref_type_pref_opt_id_idx"
822
- add_index "preference_options_preference_types", ["preference_type_id"], :name => "pref_opt_pref_type_pref_type_id_idx"
823
-
824
- create_table "preference_types", :force => true do |t|
825
- t.string "description"
826
- t.string "internal_identifier"
827
- t.integer "default_pref_option_id"
828
- t.datetime "created_at", :null => false
829
- t.datetime "updated_at", :null => false
830
- end
831
-
832
- add_index "preference_types", ["default_pref_option_id"], :name => "index_preference_types_on_default_pref_option_id"
833
-
834
- create_table "preferences", :force => true do |t|
835
- t.integer "preference_option_id"
836
- t.integer "preference_type_id"
837
- t.datetime "created_at", :null => false
838
- t.datetime "updated_at", :null => false
839
- end
840
-
841
- add_index "preferences", ["preference_option_id"], :name => "index_preferences_on_preference_option_id"
842
- add_index "preferences", ["preference_type_id"], :name => "index_preferences_on_preference_type_id"
843
-
844
- create_table "published_elements", :force => true do |t|
845
- t.integer "published_website_id"
846
- t.integer "published_element_record_id"
847
- t.string "published_element_record_type"
848
- t.integer "version"
849
- t.integer "published_by_id"
850
- t.datetime "created_at", :null => false
851
- t.datetime "updated_at", :null => false
852
- end
853
-
854
- add_index "published_elements", ["published_by_id"], :name => "index_published_elements_on_published_by_id"
855
- add_index "published_elements", ["published_element_record_id", "published_element_record_type"], :name => "published_elm_idx"
856
- add_index "published_elements", ["published_website_id"], :name => "index_published_elements_on_published_website_id"
857
- add_index "published_elements", ["version"], :name => "index_published_elements_on_version"
858
-
859
- create_table "published_websites", :force => true do |t|
860
- t.integer "website_id"
861
- t.text "comment"
862
- t.decimal "version", :precision => 18, :scale => 6
863
- t.boolean "active"
864
- t.integer "published_by_id"
865
- t.datetime "created_at", :null => false
866
- t.datetime "updated_at", :null => false
867
- end
868
-
869
- add_index "published_websites", ["active"], :name => "index_published_websites_on_active"
870
- add_index "published_websites", ["published_by_id"], :name => "index_published_websites_on_published_by_id"
871
- add_index "published_websites", ["version"], :name => "index_published_websites_on_version"
872
- add_index "published_websites", ["website_id"], :name => "index_published_websites_on_website_id"
873
-
874
- create_table "relationship_types", :force => true do |t|
875
- t.integer "parent_id"
876
- t.integer "lft"
877
- t.integer "rgt"
878
- t.integer "valid_from_role_type_id"
879
- t.integer "valid_to_role_type_id"
880
- t.string "name"
881
- t.string "description"
882
- t.string "internal_identifier"
883
- t.string "external_identifier"
884
- t.string "external_id_source"
885
- t.datetime "created_at", :null => false
886
- t.datetime "updated_at", :null => false
887
- end
888
-
889
- add_index "relationship_types", ["valid_from_role_type_id"], :name => "index_relationship_types_on_valid_from_role_type_id"
890
- add_index "relationship_types", ["valid_to_role_type_id"], :name => "index_relationship_types_on_valid_to_role_type_id"
891
-
892
- create_table "role_types", :force => true do |t|
893
- t.integer "parent_id"
894
- t.integer "lft"
895
- t.integer "rgt"
896
- t.string "description"
897
- t.string "comments"
898
- t.string "internal_identifier"
899
- t.string "external_identifier"
900
- t.string "external_id_source"
901
- t.datetime "created_at", :null => false
902
- t.datetime "updated_at", :null => false
903
- end
904
-
905
- create_table "scope_types", :force => true do |t|
906
- t.string "description"
907
- t.string "internal_identifier"
908
- t.datetime "created_at", :null => false
909
- t.datetime "updated_at", :null => false
910
- end
911
-
912
- add_index "scope_types", ["internal_identifier"], :name => "index_scope_types_on_internal_identifier"
913
-
914
- create_table "security_roles", :force => true do |t|
915
- t.string "description"
916
- t.string "internal_identifier"
917
- t.string "external_identifier"
918
- t.string "external_id_source"
919
- t.datetime "created_at", :null => false
920
- t.datetime "updated_at", :null => false
921
- end
922
-
923
- create_table "sessions", :force => true do |t|
924
- t.string "session_id", :null => false
925
- t.text "data"
926
- t.datetime "created_at", :null => false
927
- t.datetime "updated_at", :null => false
928
- end
929
-
930
- add_index "sessions", ["session_id"], :name => "index_sessions_on_session_id"
931
- add_index "sessions", ["updated_at"], :name => "index_sessions_on_updated_at"
932
-
933
- create_table "status_applications", :force => true do |t|
934
- t.integer "tracked_status_type_id"
935
- t.integer "status_application_record_id"
936
- t.string "status_application_record_type"
937
- t.datetime "from_date"
938
- t.datetime "thru_date"
939
- t.datetime "created_at", :null => false
940
- t.datetime "updated_at", :null => false
941
- end
942
-
943
- add_index "status_applications", ["from_date"], :name => "from_date_idx"
944
- add_index "status_applications", ["status_application_record_id", "status_application_record_type"], :name => "status_applications_record_idx"
945
- add_index "status_applications", ["thru_date"], :name => "thru_date_idx"
946
- add_index "status_applications", ["tracked_status_type_id"], :name => "tracked_status_type_id_idx"
947
-
948
- create_table "taggings", :force => true do |t|
949
- t.integer "tag_id"
950
- t.integer "taggable_id"
951
- t.integer "tagger_id"
952
- t.string "tagger_type"
953
- t.string "taggable_type"
954
- t.string "context"
955
- t.datetime "created_at"
956
- end
957
-
958
- add_index "taggings", ["tag_id"], :name => "index_taggings_on_tag_id"
959
- add_index "taggings", ["taggable_id", "taggable_type", "context"], :name => "taggable_poly_idx"
960
-
961
- create_table "tags", :force => true do |t|
962
- t.string "name"
963
- end
964
-
965
- create_table "themes", :force => true do |t|
966
- t.integer "website_id"
967
- t.string "name"
968
- t.string "theme_id"
969
- t.string "author"
970
- t.integer "version"
971
- t.string "homepage"
972
- t.text "summary"
973
- t.integer "active"
974
- t.datetime "created_at", :null => false
975
- t.datetime "updated_at", :null => false
976
- end
977
-
978
- add_index "themes", ["active"], :name => "index_themes_on_active"
979
- add_index "themes", ["website_id"], :name => "index_themes_on_website_id"
980
-
981
- create_table "tickets", :force => true do |t|
982
- t.datetime "created_at", :null => false
983
- t.datetime "updated_at", :null => false
984
- end
985
-
986
- create_table "tracked_status_types", :force => true do |t|
987
- t.string "description"
988
- t.string "internal_identifier"
989
- t.string "external_identifier"
990
- t.datetime "created_at", :null => false
991
- t.datetime "updated_at", :null => false
992
- end
993
-
994
- add_index "tracked_status_types", ["internal_identifier"], :name => "tracked_status_types_iid_idx"
995
-
996
- create_table "tree_menu_node_defs", :force => true do |t|
997
- t.string "node_type"
998
- t.integer "parent_id"
999
- t.integer "lft"
1000
- t.integer "rgt"
1001
- t.string "menu_short_name"
1002
- t.string "menu_description"
1003
- t.string "text"
1004
- t.string "icon_url"
1005
- t.string "target_url"
1006
- t.string "resource_class"
1007
- t.datetime "created_at", :null => false
1008
- t.datetime "updated_at", :null => false
1009
- end
1010
-
1011
- add_index "tree_menu_node_defs", ["parent_id"], :name => "index_tree_menu_node_defs_on_parent_id"
1012
-
1013
- create_table "user_preferences", :force => true do |t|
1014
- t.integer "user_id"
1015
- t.integer "preference_id"
1016
- t.integer "preferenced_record_id"
1017
- t.string "preferenced_record_type"
1018
- t.datetime "created_at", :null => false
1019
- t.datetime "updated_at", :null => false
1020
- end
1021
-
1022
- add_index "user_preferences", ["preference_id"], :name => "index_user_preferences_on_preference_id"
1023
- add_index "user_preferences", ["preferenced_record_id"], :name => "index_user_preferences_on_preferenced_record_id"
1024
- add_index "user_preferences", ["preferenced_record_type"], :name => "index_user_preferences_on_preferenced_record_type"
1025
- add_index "user_preferences", ["user_id"], :name => "index_user_preferences_on_user_id"
1026
-
1027
- create_table "users", :force => true do |t|
1028
- t.string "username"
1029
- t.string "email"
1030
- t.integer "party_id"
1031
- t.string "type"
1032
- t.string "salt"
1033
- t.string "crypted_password"
1034
- t.datetime "last_login_at"
1035
- t.datetime "last_logout_at"
1036
- t.datetime "last_activity_at"
1037
- t.integer "failed_logins_count", :default => 0
1038
- t.datetime "lock_expires_at"
1039
- t.string "remember_me_token"
1040
- t.datetime "remember_me_token_expires_at"
1041
- t.string "reset_password_token"
1042
- t.datetime "reset_password_token_expires_at"
1043
- t.datetime "reset_password_email_sent_at"
1044
- t.string "activation_state"
1045
- t.string "activation_token"
1046
- t.datetime "activation_token_expires_at"
1047
- t.string "security_question_1"
1048
- t.string "security_answer_1"
1049
- t.string "security_question_2"
1050
- t.string "security_answer_2"
1051
- t.datetime "created_at", :null => false
1052
- t.datetime "updated_at", :null => false
1053
- end
1054
-
1055
- add_index "users", ["activation_token"], :name => "index_users_on_activation_token"
1056
- add_index "users", ["email"], :name => "index_users_on_email", :unique => true
1057
- add_index "users", ["last_logout_at", "last_activity_at"], :name => "activity_idx"
1058
- add_index "users", ["remember_me_token"], :name => "index_users_on_remember_me_token"
1059
- add_index "users", ["reset_password_token"], :name => "index_users_on_reset_password_token"
1060
- add_index "users", ["username"], :name => "index_users_on_username", :unique => true
1061
-
1062
- create_table "valid_configurations", :force => true do |t|
1063
- t.integer "configured_item_id"
1064
- t.string "configured_item_type"
1065
- t.integer "configuration_id"
1066
- t.datetime "created_at", :null => false
1067
- t.datetime "updated_at", :null => false
1068
- end
1069
-
1070
- add_index "valid_configurations", ["configuration_id"], :name => "index_valid_configurations_on_configuration_id"
1071
- add_index "valid_configurations", ["configured_item_id", "configured_item_type"], :name => "configured_item_poly_idx"
1072
-
1073
- create_table "valid_documents", :force => true do |t|
1074
- t.integer "document_id"
1075
- t.integer "documented_model_id"
1076
- t.string "documented_model_type"
1077
- end
1078
-
1079
- add_index "valid_documents", ["document_id"], :name => "index_valid_documents_on_document_id"
1080
- add_index "valid_documents", ["documented_model_id", "documented_model_type"], :name => "valid_documents_model_idx"
1081
-
1082
- create_table "valid_note_types", :force => true do |t|
1083
- t.integer "valid_note_type_record_id"
1084
- t.string "valid_note_type_record_type"
1085
- t.integer "note_type_id"
1086
- t.datetime "created_at", :null => false
1087
- t.datetime "updated_at", :null => false
1088
- end
1089
-
1090
- add_index "valid_note_types", ["note_type_id"], :name => "index_valid_note_types_on_note_type_id"
1091
- add_index "valid_note_types", ["valid_note_type_record_id", "valid_note_type_record_type"], :name => "valid_note_type_record_idx"
1092
-
1093
- create_table "valid_preference_types", :force => true do |t|
1094
- t.integer "preference_type_id"
1095
- t.integer "preferenced_record_id"
1096
- t.string "preferenced_record_type"
1097
- end
1098
-
1099
- create_table "view_types", :force => true do |t|
1100
- t.string "internal_identifier"
1101
- t.string "description"
1102
- t.datetime "created_at", :null => false
1103
- t.datetime "updated_at", :null => false
1104
- end
1105
-
1106
- create_table "website_hosts", :force => true do |t|
1107
- t.integer "website_id"
1108
- t.string "host"
1109
- t.datetime "created_at", :null => false
1110
- t.datetime "updated_at", :null => false
1111
- end
1112
-
1113
- add_index "website_hosts", ["website_id"], :name => "index_website_hosts_on_website_id"
1114
-
1115
- create_table "website_inquiries", :force => true do |t|
1116
- t.integer "website_id"
1117
- t.datetime "created_at", :null => false
1118
- t.datetime "updated_at", :null => false
1119
- end
1120
-
1121
- add_index "website_inquiries", ["website_id"], :name => "index_website_inquiries_on_website_id"
1122
-
1123
- create_table "website_nav_items", :force => true do |t|
1124
- t.integer "website_nav_id"
1125
- t.string "title"
1126
- t.string "url"
1127
- t.integer "position", :default => 0
1128
- t.integer "linked_to_item_id"
1129
- t.string "linked_to_item_type"
1130
- t.integer "parent_id"
1131
- t.integer "lft"
1132
- t.integer "rgt"
1133
- t.datetime "created_at", :null => false
1134
- t.datetime "updated_at", :null => false
1135
- end
1136
-
1137
- add_index "website_nav_items", ["lft"], :name => "index_website_nav_items_on_lft"
1138
- add_index "website_nav_items", ["linked_to_item_id", "linked_to_item_type"], :name => "linked_to_idx"
1139
- add_index "website_nav_items", ["parent_id"], :name => "index_website_nav_items_on_parent_id"
1140
- add_index "website_nav_items", ["position"], :name => "index_website_nav_items_on_position"
1141
- add_index "website_nav_items", ["rgt"], :name => "index_website_nav_items_on_rgt"
1142
- add_index "website_nav_items", ["website_nav_id"], :name => "index_website_nav_items_on_website_nav_id"
1143
-
1144
- create_table "website_navs", :force => true do |t|
1145
- t.integer "website_id"
1146
- t.string "name"
1147
- t.datetime "created_at", :null => false
1148
- t.datetime "updated_at", :null => false
1149
- end
1150
-
1151
- add_index "website_navs", ["website_id"], :name => "index_website_navs_on_website_id"
1152
-
1153
- create_table "website_party_roles", :force => true do |t|
1154
- t.integer "website_id"
1155
- t.integer "role_type_id"
1156
- t.integer "party_id"
1157
- t.datetime "created_at", :null => false
1158
- t.datetime "updated_at", :null => false
1159
- end
1160
-
1161
- add_index "website_party_roles", ["party_id"], :name => "index_website_party_roles_on_party_id"
1162
- add_index "website_party_roles", ["role_type_id"], :name => "index_website_party_roles_on_role_type_id"
1163
- add_index "website_party_roles", ["website_id"], :name => "index_website_party_roles_on_website_id"
1164
-
1165
- create_table "website_section_contents", :force => true do |t|
1166
- t.integer "website_section_id"
1167
- t.integer "content_id"
1168
- t.string "content_area"
1169
- t.integer "position", :default => 0
1170
- t.datetime "created_at", :null => false
1171
- t.datetime "updated_at", :null => false
1172
- end
1173
-
1174
- add_index "website_section_contents", ["content_area"], :name => "index_website_section_contents_on_content_area"
1175
- add_index "website_section_contents", ["content_id"], :name => "index_website_section_contents_on_content_id"
1176
- add_index "website_section_contents", ["position"], :name => "index_website_section_contents_on_position"
1177
- add_index "website_section_contents", ["website_section_id"], :name => "index_website_section_contents_on_website_section_id"
1178
-
1179
- create_table "website_section_versions", :force => true do |t|
1180
- t.integer "website_section_id"
1181
- t.integer "version"
1182
- t.string "title"
1183
- t.integer "website_id"
1184
- t.string "path"
1185
- t.string "permalink"
1186
- t.text "layout"
1187
- t.boolean "in_menu"
1188
- t.integer "position", :default => 0
1189
- t.string "internal_identifier"
1190
- t.boolean "render_base_layout", :default => true
1191
- t.datetime "created_at"
1192
- t.datetime "updated_at"
1193
- t.string "versioned_type"
1194
- end
1195
-
1196
- add_index "website_section_versions", ["website_section_id"], :name => "index_website_section_versions_on_website_section_id"
1197
-
1198
- create_table "website_sections", :force => true do |t|
1199
- t.string "title"
1200
- t.string "type"
1201
- t.integer "website_id"
1202
- t.string "path"
1203
- t.string "permalink"
1204
- t.text "layout"
1205
- t.boolean "in_menu"
1206
- t.integer "position", :default => 0
1207
- t.string "internal_identifier"
1208
- t.integer "version"
1209
- t.boolean "render_base_layout", :default => true
1210
- t.integer "parent_id"
1211
- t.integer "lft"
1212
- t.integer "rgt"
1213
- t.datetime "created_at", :null => false
1214
- t.datetime "updated_at", :null => false
1215
- t.boolean "use_markdown"
1216
- end
1217
-
1218
- add_index "website_sections", ["internal_identifier"], :name => "section_iid_idx"
1219
- add_index "website_sections", ["lft"], :name => "index_website_sections_on_lft"
1220
- add_index "website_sections", ["parent_id"], :name => "index_website_sections_on_parent_id"
1221
- add_index "website_sections", ["permalink"], :name => "index_website_sections_on_permalink"
1222
- add_index "website_sections", ["position"], :name => "index_website_sections_on_position"
1223
- add_index "website_sections", ["rgt"], :name => "index_website_sections_on_rgt"
1224
- add_index "website_sections", ["version"], :name => "index_website_sections_on_version"
1225
- add_index "website_sections", ["website_id"], :name => "index_website_sections_on_website_id"
1226
-
1227
- create_table "websites", :force => true do |t|
1228
- t.string "name"
1229
- t.string "title"
1230
- t.string "subtitle"
1231
- t.string "internal_identifier"
1232
- t.string "email"
1233
- t.boolean "auto_activate_publication"
1234
- t.boolean "email_inquiries"
1235
- t.datetime "created_at", :null => false
1236
- t.datetime "updated_at", :null => false
1237
- end
1238
-
1239
- create_table "widgets", :force => true do |t|
1240
- t.string "description"
1241
- t.string "internal_identifier"
1242
- t.string "icon"
1243
- t.string "xtype"
1244
- t.datetime "created_at", :null => false
1245
- t.datetime "updated_at", :null => false
1246
- end
1247
-
1248
- end