erp_forms 2.0.5 → 2.0.6

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,858 +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 => 20120429130430) 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 "base_url"
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 "resource"
132
- t.integer "capability_type_id"
133
- t.datetime "created_at", :null => false
134
- t.datetime "updated_at", :null => false
135
- end
136
-
137
- add_index "capabilities", ["capability_type_id"], :name => "index_capabilities_on_capability_type_id"
138
-
139
- create_table "capabilities_capable_models", :id => false, :force => true do |t|
140
- t.integer "capable_model_id"
141
- t.integer "capability_id"
142
- end
143
-
144
- add_index "capabilities_capable_models", ["capability_id"], :name => "index_capabilities_capable_models_on_capability_id"
145
- add_index "capabilities_capable_models", ["capable_model_id"], :name => "index_capabilities_capable_models_on_capable_model_id"
146
-
147
- create_table "capability_types", :force => true do |t|
148
- t.string "internal_identifier"
149
- t.string "description"
150
- t.datetime "created_at", :null => false
151
- t.datetime "updated_at", :null => false
152
- end
153
-
154
- create_table "capable_models", :force => true do |t|
155
- t.integer "capable_model_record_id"
156
- t.string "capable_model_record_type"
157
- t.datetime "created_at", :null => false
158
- t.datetime "updated_at", :null => false
159
- end
160
-
161
- add_index "capable_models", ["capable_model_record_id", "capable_model_record_type"], :name => "capable_model_record_idx"
162
-
163
- create_table "categories", :force => true do |t|
164
- t.string "description"
165
- t.string "external_identifier"
166
- t.datetime "from_date"
167
- t.datetime "to_date"
168
- t.string "internal_identifier"
169
- t.integer "category_record_id"
170
- t.string "category_record_type"
171
- t.integer "parent_id"
172
- t.integer "lft"
173
- t.integer "rgt"
174
- t.datetime "created_at", :null => false
175
- t.datetime "updated_at", :null => false
176
- end
177
-
178
- add_index "categories", ["category_record_id", "category_record_type"], :name => "category_polymorphic"
179
-
180
- create_table "category_classifications", :force => true do |t|
181
- t.integer "category_id"
182
- t.string "classification_type"
183
- t.integer "classification_id"
184
- t.datetime "from_date"
185
- t.datetime "to_date"
186
- t.datetime "created_at", :null => false
187
- t.datetime "updated_at", :null => false
188
- end
189
-
190
- add_index "category_classifications", ["classification_id", "classification_type"], :name => "classification_polymorphic"
191
-
192
- create_table "compass_ae_instances", :force => true do |t|
193
- t.decimal "version"
194
- t.datetime "created_at", :null => false
195
- t.datetime "updated_at", :null => false
196
- end
197
-
198
- create_table "configuration_item_types", :force => true do |t|
199
- t.integer "parent_id"
200
- t.integer "lft"
201
- t.integer "rgt"
202
- t.string "description"
203
- t.string "internal_identifier"
204
- t.boolean "allow_user_defined_options", :default => false
205
- t.boolean "is_multi_optional", :default => false
206
- t.datetime "created_at", :null => false
207
- t.datetime "updated_at", :null => false
208
- end
209
-
210
- create_table "configuration_item_types_configuration_options", :force => true do |t|
211
- t.integer "configuration_item_type_id"
212
- t.integer "configuration_option_id"
213
- t.boolean "is_default", :default => false
214
- t.datetime "created_at", :null => false
215
- t.datetime "updated_at", :null => false
216
- end
217
-
218
- add_index "configuration_item_types_configuration_options", ["configuration_item_type_id"], :name => "conf_item_type_conf_opt_id_item_idx"
219
- add_index "configuration_item_types_configuration_options", ["configuration_option_id"], :name => "conf_item_type_conf_opt_id_opt_idx"
220
-
221
- create_table "configuration_item_types_configurations", :id => false, :force => true do |t|
222
- t.integer "configuration_item_type_id"
223
- t.integer "configuration_id"
224
- end
225
-
226
- add_index "configuration_item_types_configurations", ["configuration_id"], :name => "conf_id_idx"
227
- add_index "configuration_item_types_configurations", ["configuration_item_type_id", "configuration_id"], :name => "conf_config_type_uniq_idx", :unique => true
228
- add_index "configuration_item_types_configurations", ["configuration_item_type_id"], :name => "conf_conf_type_id_item_idx"
229
-
230
- create_table "configuration_items", :force => true do |t|
231
- t.integer "configuration_id"
232
- t.integer "configuration_item_type_id"
233
- t.integer "configuration_option_id"
234
- t.datetime "created_at", :null => false
235
- t.datetime "updated_at", :null => false
236
- end
237
-
238
- add_index "configuration_items", ["configuration_id"], :name => "index_configuration_items_on_configuration_id"
239
- add_index "configuration_items", ["configuration_item_type_id"], :name => "index_configuration_items_on_configuration_item_type_id"
240
- add_index "configuration_items", ["configuration_option_id"], :name => "index_configuration_items_on_configuration_option_id"
241
-
242
- create_table "configuration_items_configuration_options", :id => false, :force => true do |t|
243
- t.integer "configuration_item_id"
244
- t.integer "configuration_option_id"
245
- end
246
-
247
- add_index "configuration_items_configuration_options", ["configuration_item_id"], :name => "conf_item_conf_opt_id_item_idx"
248
- add_index "configuration_items_configuration_options", ["configuration_option_id"], :name => "conf_item_conf_opt_id_opt_idx"
249
-
250
- create_table "configuration_options", :force => true do |t|
251
- t.string "description"
252
- t.string "internal_identifier"
253
- t.string "value"
254
- t.text "comment"
255
- t.boolean "user_defined", :default => false
256
- t.datetime "created_at", :null => false
257
- t.datetime "updated_at", :null => false
258
- end
259
-
260
- add_index "configuration_options", ["internal_identifier"], :name => "index_configuration_options_on_internal_identifier"
261
- add_index "configuration_options", ["user_defined"], :name => "index_configuration_options_on_user_defined"
262
- add_index "configuration_options", ["value"], :name => "index_configuration_options_on_value"
263
-
264
- create_table "configurations", :force => true do |t|
265
- t.string "description"
266
- t.string "internal_identifier"
267
- t.boolean "active"
268
- t.datetime "created_at", :null => false
269
- t.datetime "updated_at", :null => false
270
- t.boolean "is_template", :default => false
271
- end
272
-
273
- create_table "contact_purposes", :force => true do |t|
274
- t.integer "parent_id"
275
- t.integer "lft"
276
- t.integer "rgt"
277
- t.string "description"
278
- t.string "comments"
279
- t.string "internal_identifier"
280
- t.string "external_identifier"
281
- t.string "external_id_source"
282
- t.datetime "created_at", :null => false
283
- t.datetime "updated_at", :null => false
284
- end
285
-
286
- add_index "contact_purposes", ["parent_id"], :name => "index_contact_purposes_on_parent_id"
287
-
288
- create_table "contact_purposes_contacts", :id => false, :force => true do |t|
289
- t.integer "contact_id"
290
- t.integer "contact_purpose_id"
291
- end
292
-
293
- add_index "contact_purposes_contacts", ["contact_id", "contact_purpose_id"], :name => "contact_purposes_contacts_index"
294
-
295
- create_table "contact_types", :force => true do |t|
296
- t.integer "parent_id"
297
- t.integer "lft"
298
- t.integer "rgt"
299
- t.string "description"
300
- t.string "comments"
301
- t.string "internal_identifier"
302
- t.string "external_identifier"
303
- t.string "external_id_source"
304
- t.datetime "created_at", :null => false
305
- t.datetime "updated_at", :null => false
306
- end
307
-
308
- add_index "contact_types", ["parent_id"], :name => "index_contact_types_on_parent_id"
309
-
310
- create_table "contacts", :force => true do |t|
311
- t.integer "party_id"
312
- t.integer "contact_mechanism_id"
313
- t.string "contact_mechanism_type"
314
- t.string "external_identifier"
315
- t.string "external_id_source"
316
- t.datetime "created_at", :null => false
317
- t.datetime "updated_at", :null => false
318
- end
319
-
320
- add_index "contacts", ["contact_mechanism_id", "contact_mechanism_type"], :name => "besi_2"
321
- add_index "contacts", ["party_id"], :name => "index_contacts_on_party_id"
322
-
323
- create_table "currencies", :force => true do |t|
324
- t.string "name"
325
- t.string "definition"
326
- t.string "internal_identifier"
327
- t.string "numeric_code"
328
- t.string "major_unit_symbol"
329
- t.string "minor_unit_symbol"
330
- t.string "ratio_of_minor_unit_to_major_unit"
331
- t.string "postfix_label"
332
- t.datetime "introduction_date"
333
- t.datetime "expiration_date"
334
- t.datetime "created_at", :null => false
335
- t.datetime "updated_at", :null => false
336
- end
337
-
338
- add_index "currencies", ["internal_identifier"], :name => "index_currencies_on_internal_identifier"
339
-
340
- create_table "delayed_jobs", :force => true do |t|
341
- t.integer "priority", :default => 0
342
- t.integer "attempts", :default => 0
343
- t.text "handler"
344
- t.text "last_error"
345
- t.datetime "run_at"
346
- t.datetime "locked_at"
347
- t.datetime "failed_at"
348
- t.string "locked_by"
349
- t.string "queue"
350
- t.datetime "created_at", :null => false
351
- t.datetime "updated_at", :null => false
352
- end
353
-
354
- add_index "delayed_jobs", ["priority", "run_at"], :name => "delayed_jobs_priority"
355
-
356
- create_table "descriptive_assets", :force => true do |t|
357
- t.integer "view_type_id"
358
- t.string "internal_identifier"
359
- t.text "description"
360
- t.string "external_identifier"
361
- t.string "external_id_source"
362
- t.integer "described_record_id"
363
- t.string "described_record_type"
364
- t.datetime "created_at", :null => false
365
- t.datetime "updated_at", :null => false
366
- end
367
-
368
- add_index "descriptive_assets", ["described_record_id", "described_record_type"], :name => "described_record_idx"
369
- add_index "descriptive_assets", ["view_type_id"], :name => "index_descriptive_assets_on_view_type_id"
370
-
371
- create_table "dynamic_data", :force => true do |t|
372
- t.string "reference_type"
373
- t.integer "reference_id"
374
- t.text "dynamic_attributes"
375
- t.integer "created_with_form_id"
376
- t.integer "updated_with_form_id"
377
- t.integer "created_by_id"
378
- t.integer "updated_by_id"
379
- t.datetime "created_at", :null => false
380
- t.datetime "updated_at", :null => false
381
- end
382
-
383
- add_index "dynamic_data", ["created_by_id"], :name => "index_dynamic_data_on_created_by_id"
384
- add_index "dynamic_data", ["created_with_form_id"], :name => "index_dynamic_data_on_created_with_form_id"
385
- add_index "dynamic_data", ["reference_id"], :name => "index_dynamic_data_on_reference_id"
386
- add_index "dynamic_data", ["reference_type"], :name => "index_dynamic_data_on_reference_type"
387
- add_index "dynamic_data", ["updated_by_id"], :name => "index_dynamic_data_on_updated_by_id"
388
- add_index "dynamic_data", ["updated_with_form_id"], :name => "index_dynamic_data_on_updated_with_form_id"
389
-
390
- create_table "dynamic_form_documents", :force => true do |t|
391
- t.integer "dynamic_form_model_id"
392
- t.string "type"
393
- t.datetime "created_at", :null => false
394
- t.datetime "updated_at", :null => false
395
- end
396
-
397
- add_index "dynamic_form_documents", ["dynamic_form_model_id"], :name => "index_dynamic_form_documents_on_dynamic_form_model_id"
398
- add_index "dynamic_form_documents", ["type"], :name => "index_dynamic_form_documents_on_type"
399
-
400
- create_table "dynamic_form_models", :force => true do |t|
401
- t.string "model_name"
402
- t.datetime "created_at", :null => false
403
- t.datetime "updated_at", :null => false
404
- end
405
-
406
- create_table "dynamic_forms", :force => true do |t|
407
- t.string "description"
408
- t.text "definition"
409
- t.integer "dynamic_form_model_id"
410
- t.string "model_name"
411
- t.string "internal_identifier"
412
- t.boolean "default"
413
- t.integer "created_by_id"
414
- t.integer "updated_by_id"
415
- t.datetime "created_at", :null => false
416
- t.datetime "updated_at", :null => false
417
- end
418
-
419
- add_index "dynamic_forms", ["created_by_id"], :name => "index_dynamic_forms_on_created_by_id"
420
- add_index "dynamic_forms", ["dynamic_form_model_id"], :name => "index_dynamic_forms_on_dynamic_form_model_id"
421
- add_index "dynamic_forms", ["internal_identifier"], :name => "index_dynamic_forms_on_internal_identifier"
422
- add_index "dynamic_forms", ["model_name"], :name => "index_dynamic_forms_on_model_name"
423
- add_index "dynamic_forms", ["updated_by_id"], :name => "index_dynamic_forms_on_updated_by_id"
424
-
425
- create_table "email_addresses", :force => true do |t|
426
- t.string "email_address"
427
- t.string "description"
428
- t.datetime "created_at", :null => false
429
- t.datetime "updated_at", :null => false
430
- end
431
-
432
- create_table "file_assets", :force => true do |t|
433
- t.integer "file_asset_holder_id"
434
- t.string "file_asset_holder_type"
435
- t.string "type"
436
- t.string "name"
437
- t.string "directory"
438
- t.string "data_file_name"
439
- t.string "data_content_type"
440
- t.integer "data_file_size"
441
- t.datetime "data_updated_at"
442
- t.datetime "created_at", :null => false
443
- t.datetime "updated_at", :null => false
444
- end
445
-
446
- add_index "file_assets", ["directory"], :name => "index_file_assets_on_directory"
447
- add_index "file_assets", ["file_asset_holder_id", "file_asset_holder_type"], :name => "file_asset_holder_idx"
448
- add_index "file_assets", ["name"], :name => "index_file_assets_on_name"
449
- add_index "file_assets", ["type"], :name => "index_file_assets_on_type"
450
-
451
- create_table "geo_countries", :force => true do |t|
452
- t.string "name"
453
- t.string "iso_code_2"
454
- t.string "iso_code_3"
455
- t.boolean "display", :default => true
456
- t.integer "external_id"
457
- t.datetime "created_at"
458
- end
459
-
460
- add_index "geo_countries", ["iso_code_2"], :name => "index_geo_countries_on_iso_code_2"
461
- add_index "geo_countries", ["name"], :name => "index_geo_countries_on_name"
462
-
463
- create_table "geo_zones", :force => true do |t|
464
- t.integer "geo_country_id"
465
- t.string "zone_code", :default => "2"
466
- t.string "zone_name"
467
- t.datetime "created_at"
468
- end
469
-
470
- add_index "geo_zones", ["geo_country_id"], :name => "index_geo_zones_on_geo_country_id"
471
- add_index "geo_zones", ["zone_code"], :name => "index_geo_zones_on_zone_code"
472
- add_index "geo_zones", ["zone_name"], :name => "index_geo_zones_on_zone_name"
473
-
474
- create_table "individuals", :force => true do |t|
475
- t.integer "party_id"
476
- t.string "current_last_name"
477
- t.string "current_first_name"
478
- t.string "current_middle_name"
479
- t.string "current_personal_title"
480
- t.string "current_suffix"
481
- t.string "current_nickname"
482
- t.string "gender", :limit => 1
483
- t.date "birth_date"
484
- t.decimal "height", :precision => 5, :scale => 2
485
- t.integer "weight"
486
- t.string "mothers_maiden_name"
487
- t.string "marital_status", :limit => 1
488
- t.string "social_security_number"
489
- t.integer "current_passport_number"
490
- t.date "current_passport_expire_date"
491
- t.integer "total_years_work_experience"
492
- t.string "comments"
493
- t.string "encrypted_ssn"
494
- t.string "temp_ssn"
495
- t.string "salt"
496
- t.string "ssn_last_four"
497
- t.datetime "created_at", :null => false
498
- t.datetime "updated_at", :null => false
499
- end
500
-
501
- add_index "individuals", ["party_id"], :name => "index_individuals_on_party_id"
502
-
503
- create_table "money", :force => true do |t|
504
- t.string "description"
505
- t.float "amount"
506
- t.integer "currency_id"
507
- t.datetime "created_at", :null => false
508
- t.datetime "updated_at", :null => false
509
- end
510
-
511
- add_index "money", ["currency_id"], :name => "index_money_on_currency_id"
512
-
513
- create_table "note_types", :force => true do |t|
514
- t.integer "parent_id"
515
- t.integer "lft"
516
- t.integer "rgt"
517
- t.string "description"
518
- t.string "internal_identifier"
519
- t.string "external_identifier"
520
- t.integer "note_type_record_id"
521
- t.string "note_type_record_type"
522
- t.datetime "created_at", :null => false
523
- t.datetime "updated_at", :null => false
524
- end
525
-
526
- add_index "note_types", ["note_type_record_id", "note_type_record_type"], :name => "note_type_record_idx"
527
-
528
- create_table "notes", :force => true do |t|
529
- t.integer "created_by_id"
530
- t.text "content"
531
- t.integer "noted_record_id"
532
- t.string "noted_record_type"
533
- t.integer "note_type_id"
534
- t.datetime "created_at", :null => false
535
- t.datetime "updated_at", :null => false
536
- end
537
-
538
- add_index "notes", ["created_by_id"], :name => "index_notes_on_created_by_id"
539
- add_index "notes", ["note_type_id"], :name => "index_notes_on_note_type_id"
540
- add_index "notes", ["noted_record_id", "noted_record_type"], :name => "index_notes_on_noted_record_id_and_noted_record_type"
541
-
542
- create_table "organizations", :force => true do |t|
543
- t.string "description"
544
- t.string "tax_id_number"
545
- t.datetime "created_at", :null => false
546
- t.datetime "updated_at", :null => false
547
- end
548
-
549
- create_table "parties", :force => true do |t|
550
- t.string "description"
551
- t.integer "business_party_id"
552
- t.string "business_party_type"
553
- t.integer "list_view_image_id"
554
- t.string "enterprise_identifier"
555
- t.datetime "created_at", :null => false
556
- t.datetime "updated_at", :null => false
557
- end
558
-
559
- add_index "parties", ["business_party_id", "business_party_type"], :name => "besi_1"
560
-
561
- create_table "party_relationships", :force => true do |t|
562
- t.string "description"
563
- t.integer "party_id_from"
564
- t.integer "party_id_to"
565
- t.integer "role_type_id_from"
566
- t.integer "role_type_id_to"
567
- t.integer "status_type_id"
568
- t.integer "priority_type_id"
569
- t.integer "relationship_type_id"
570
- t.date "from_date"
571
- t.date "thru_date"
572
- t.string "external_identifier"
573
- t.string "external_id_source"
574
- t.datetime "created_at", :null => false
575
- t.datetime "updated_at", :null => false
576
- end
577
-
578
- add_index "party_relationships", ["priority_type_id"], :name => "index_party_relationships_on_priority_type_id"
579
- add_index "party_relationships", ["relationship_type_id"], :name => "index_party_relationships_on_relationship_type_id"
580
- add_index "party_relationships", ["status_type_id"], :name => "index_party_relationships_on_status_type_id"
581
-
582
- create_table "party_roles", :force => true do |t|
583
- t.string "type"
584
- t.integer "party_id"
585
- t.integer "role_type_id"
586
- t.datetime "created_at", :null => false
587
- t.datetime "updated_at", :null => false
588
- end
589
-
590
- add_index "party_roles", ["party_id"], :name => "index_party_roles_on_party_id"
591
- add_index "party_roles", ["role_type_id"], :name => "index_party_roles_on_role_type_id"
592
-
593
- create_table "party_search_facts", :force => true do |t|
594
- t.integer "party_id"
595
- t.string "eid"
596
- t.string "type"
597
- t.text "roles"
598
- t.string "party_description"
599
- t.string "party_business_party_type"
600
- t.string "user_login"
601
- t.string "individual_current_last_name"
602
- t.string "individual_current_first_name"
603
- t.string "individual_current_middle_name"
604
- t.string "individual_birth_date"
605
- t.string "individual_ssn"
606
- t.string "party_phone_number"
607
- t.string "party_email_address"
608
- t.string "party_address_1"
609
- t.string "party_address_2"
610
- t.string "party_primary_address_city"
611
- t.string "party_primary_address_state"
612
- t.string "party_primary_address_zip"
613
- t.string "party_primary_address_country"
614
- t.boolean "user_enabled"
615
- t.string "user_type"
616
- t.boolean "reindex"
617
- t.datetime "created_at", :null => false
618
- t.datetime "updated_at", :null => false
619
- end
620
-
621
- create_table "phone_numbers", :force => true do |t|
622
- t.string "phone_number"
623
- t.string "description"
624
- t.datetime "created_at", :null => false
625
- t.datetime "updated_at", :null => false
626
- end
627
-
628
- create_table "postal_addresses", :force => true do |t|
629
- t.string "address_line_1"
630
- t.string "address_line_2"
631
- t.string "city"
632
- t.string "state"
633
- t.string "zip"
634
- t.string "country"
635
- t.string "description"
636
- t.integer "geo_country_id"
637
- t.integer "geo_zone_id"
638
- t.datetime "created_at", :null => false
639
- t.datetime "updated_at", :null => false
640
- end
641
-
642
- add_index "postal_addresses", ["geo_country_id"], :name => "index_postal_addresses_on_geo_country_id"
643
- add_index "postal_addresses", ["geo_zone_id"], :name => "index_postal_addresses_on_geo_zone_id"
644
-
645
- create_table "preference_options", :force => true do |t|
646
- t.string "description"
647
- t.string "internal_identifier"
648
- t.string "value"
649
- t.datetime "created_at", :null => false
650
- t.datetime "updated_at", :null => false
651
- end
652
-
653
- create_table "preference_options_preference_types", :id => false, :force => true do |t|
654
- t.integer "preference_type_id"
655
- t.integer "preference_option_id"
656
- end
657
-
658
- add_index "preference_options_preference_types", ["preference_option_id"], :name => "pref_opt_pref_type_pref_opt_id_idx"
659
- add_index "preference_options_preference_types", ["preference_type_id"], :name => "pref_opt_pref_type_pref_type_id_idx"
660
-
661
- create_table "preference_types", :force => true do |t|
662
- t.string "description"
663
- t.string "internal_identifier"
664
- t.integer "default_pref_option_id"
665
- t.datetime "created_at", :null => false
666
- t.datetime "updated_at", :null => false
667
- end
668
-
669
- add_index "preference_types", ["default_pref_option_id"], :name => "index_preference_types_on_default_pref_option_id"
670
-
671
- create_table "preferences", :force => true do |t|
672
- t.integer "preference_option_id"
673
- t.integer "preference_type_id"
674
- t.datetime "created_at", :null => false
675
- t.datetime "updated_at", :null => false
676
- end
677
-
678
- add_index "preferences", ["preference_option_id"], :name => "index_preferences_on_preference_option_id"
679
- add_index "preferences", ["preference_type_id"], :name => "index_preferences_on_preference_type_id"
680
-
681
- create_table "relationship_types", :force => true do |t|
682
- t.integer "parent_id"
683
- t.integer "lft"
684
- t.integer "rgt"
685
- t.integer "valid_from_role_type_id"
686
- t.integer "valid_to_role_type_id"
687
- t.string "name"
688
- t.string "description"
689
- t.string "internal_identifier"
690
- t.string "external_identifier"
691
- t.string "external_id_source"
692
- t.datetime "created_at", :null => false
693
- t.datetime "updated_at", :null => false
694
- end
695
-
696
- add_index "relationship_types", ["valid_from_role_type_id"], :name => "index_relationship_types_on_valid_from_role_type_id"
697
- add_index "relationship_types", ["valid_to_role_type_id"], :name => "index_relationship_types_on_valid_to_role_type_id"
698
-
699
- create_table "role_types", :force => true do |t|
700
- t.integer "parent_id"
701
- t.integer "lft"
702
- t.integer "rgt"
703
- t.string "description"
704
- t.string "comments"
705
- t.string "internal_identifier"
706
- t.string "external_identifier"
707
- t.string "external_id_source"
708
- t.datetime "created_at", :null => false
709
- t.datetime "updated_at", :null => false
710
- end
711
-
712
- create_table "roles", :force => true do |t|
713
- t.string "description"
714
- t.string "internal_identifier"
715
- t.string "external_identifier"
716
- t.string "external_id_source"
717
- t.datetime "created_at", :null => false
718
- t.datetime "updated_at", :null => false
719
- end
720
-
721
- create_table "roles_secured_models", :id => false, :force => true do |t|
722
- t.integer "secured_model_id"
723
- t.integer "role_id"
724
- end
725
-
726
- add_index "roles_secured_models", ["role_id"], :name => "index_roles_secured_models_on_role_id"
727
- add_index "roles_secured_models", ["secured_model_id"], :name => "index_roles_secured_models_on_secured_model_id"
728
-
729
- create_table "secured_models", :force => true do |t|
730
- t.integer "secured_record_id"
731
- t.string "secured_record_type"
732
- t.datetime "created_at", :null => false
733
- t.datetime "updated_at", :null => false
734
- end
735
-
736
- add_index "secured_models", ["secured_record_id", "secured_record_type"], :name => "secured_record_idx"
737
-
738
- create_table "sessions", :force => true do |t|
739
- t.string "session_id", :null => false
740
- t.text "data"
741
- t.datetime "created_at", :null => false
742
- t.datetime "updated_at", :null => false
743
- end
744
-
745
- add_index "sessions", ["session_id"], :name => "index_sessions_on_session_id"
746
- add_index "sessions", ["updated_at"], :name => "index_sessions_on_updated_at"
747
-
748
- create_table "tree_menu_node_defs", :force => true do |t|
749
- t.string "node_type"
750
- t.integer "parent_id"
751
- t.integer "lft"
752
- t.integer "rgt"
753
- t.string "menu_short_name"
754
- t.string "menu_description"
755
- t.string "text"
756
- t.string "icon_url"
757
- t.string "target_url"
758
- t.string "resource_class"
759
- t.datetime "created_at", :null => false
760
- t.datetime "updated_at", :null => false
761
- end
762
-
763
- add_index "tree_menu_node_defs", ["parent_id"], :name => "index_tree_menu_node_defs_on_parent_id"
764
-
765
- create_table "user_preferences", :force => true do |t|
766
- t.integer "user_id"
767
- t.integer "preference_id"
768
- t.integer "preferenced_record_id"
769
- t.string "preferenced_record_type"
770
- t.datetime "created_at", :null => false
771
- t.datetime "updated_at", :null => false
772
- end
773
-
774
- add_index "user_preferences", ["preference_id"], :name => "index_user_preferences_on_preference_id"
775
- add_index "user_preferences", ["preferenced_record_id"], :name => "index_user_preferences_on_preferenced_record_id"
776
- add_index "user_preferences", ["preferenced_record_type"], :name => "index_user_preferences_on_preferenced_record_type"
777
- add_index "user_preferences", ["user_id"], :name => "index_user_preferences_on_user_id"
778
-
779
- create_table "users", :force => true do |t|
780
- t.string "username"
781
- t.string "email"
782
- t.integer "party_id"
783
- t.string "type"
784
- t.string "salt"
785
- t.string "crypted_password"
786
- t.datetime "last_login_at"
787
- t.datetime "last_logout_at"
788
- t.datetime "last_activity_at"
789
- t.integer "failed_logins_count", :default => 0
790
- t.datetime "lock_expires_at"
791
- t.string "remember_me_token"
792
- t.datetime "remember_me_token_expires_at"
793
- t.string "reset_password_token"
794
- t.datetime "reset_password_token_expires_at"
795
- t.datetime "reset_password_email_sent_at"
796
- t.string "activation_state"
797
- t.string "activation_token"
798
- t.datetime "activation_token_expires_at"
799
- t.string "security_question_1"
800
- t.string "security_answer_1"
801
- t.string "security_question_2"
802
- t.string "security_answer_2"
803
- t.datetime "created_at", :null => false
804
- t.datetime "updated_at", :null => false
805
- end
806
-
807
- add_index "users", ["activation_token"], :name => "index_users_on_activation_token"
808
- add_index "users", ["email"], :name => "index_users_on_email", :unique => true
809
- add_index "users", ["last_logout_at", "last_activity_at"], :name => "activity_idx"
810
- add_index "users", ["remember_me_token"], :name => "index_users_on_remember_me_token"
811
- add_index "users", ["reset_password_token"], :name => "index_users_on_reset_password_token"
812
- add_index "users", ["username"], :name => "index_users_on_username", :unique => true
813
-
814
- create_table "valid_configurations", :force => true do |t|
815
- t.integer "configured_item_id"
816
- t.string "configured_item_type"
817
- t.integer "configuration_id"
818
- t.datetime "created_at", :null => false
819
- t.datetime "updated_at", :null => false
820
- end
821
-
822
- add_index "valid_configurations", ["configuration_id"], :name => "index_valid_configurations_on_configuration_id"
823
- add_index "valid_configurations", ["configured_item_id", "configured_item_type"], :name => "configured_item_poly_idx"
824
-
825
- create_table "valid_note_types", :force => true do |t|
826
- t.integer "valid_note_type_record_id"
827
- t.string "valid_note_type_record_type"
828
- t.integer "note_type_id"
829
- t.datetime "created_at", :null => false
830
- t.datetime "updated_at", :null => false
831
- end
832
-
833
- add_index "valid_note_types", ["note_type_id"], :name => "index_valid_note_types_on_note_type_id"
834
- add_index "valid_note_types", ["valid_note_type_record_id", "valid_note_type_record_type"], :name => "valid_note_type_record_idx"
835
-
836
- create_table "valid_preference_types", :force => true do |t|
837
- t.integer "preference_type_id"
838
- t.integer "preferenced_record_id"
839
- t.string "preferenced_record_type"
840
- end
841
-
842
- create_table "view_types", :force => true do |t|
843
- t.string "internal_identifier"
844
- t.string "description"
845
- t.datetime "created_at", :null => false
846
- t.datetime "updated_at", :null => false
847
- end
848
-
849
- create_table "widgets", :force => true do |t|
850
- t.string "description"
851
- t.string "internal_identifier"
852
- t.string "icon"
853
- t.string "xtype"
854
- t.datetime "created_at", :null => false
855
- t.datetime "updated_at", :null => false
856
- end
857
-
858
- end