erp_base_erp_svcs 3.1.5 → 4.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/app/controllers/erp_base_erp_svcs/shared/units_of_measurement_controller.rb +32 -0
- data/app/models/compass_ae_instance.rb +2 -0
- data/app/models/contact.rb +4 -0
- data/app/models/email_address.rb +4 -1
- data/app/models/facility.rb +12 -0
- data/app/models/facility_type.rb +8 -0
- data/app/models/fixed_asset.rb +8 -0
- data/app/models/fixed_asset_party_role.rb +8 -0
- data/app/models/fixed_asset_type.rb +9 -0
- data/app/models/individual.rb +10 -14
- data/app/models/party.rb +138 -51
- data/app/models/party_unit_of_measurement.rb +6 -0
- data/app/models/phone_number.rb +5 -1
- data/app/models/postal_address.rb +5 -1
- data/app/models/unit_of_measurement.rb +16 -0
- data/config/initializers/root_loader.rb +9 -0
- data/config/routes.rb +5 -0
- data/db/migrate/20080805000020_base_erp_services.rb +1 -29
- data/db/migrate/20130522125404_create_facilities.rb +114 -0
- data/db/migrate/20130621182047_create_unit_of_measurements.rb +18 -0
- data/db/migrate/20130909163912_add_iid_index_to_role_types.rb +9 -0
- data/db/migrate/20130926023541_add_domain_to_unit_of_measure.rb +13 -0
- data/db/migrate/20130929025342_add_type_semantics_to_uom.rb +54 -0
- data/db/migrate/20131112013047_add_primary_to_contacts.rb +13 -0
- data/db/migrate/20131112013048_add_erp_base_erp_svcs_missing_indexes.rb +33 -0
- data/db/migrate/20131211180831_add_postal_address_to_facility.rb +5 -0
- data/db/migrate/20140102154311_create_fixed_asset_party_roles.rb +12 -0
- data/db/migrate/20140401072612_add_custom_fields_to_party.rb +12 -0
- data/lib/erp_base_erp_svcs.rb +5 -5
- data/lib/erp_base_erp_svcs/engine.rb +5 -3
- data/lib/erp_base_erp_svcs/extensions.rb +3 -0
- data/lib/erp_base_erp_svcs/extensions/active_record/acts_as_facility.rb +54 -0
- data/lib/erp_base_erp_svcs/extensions/active_record/acts_as_fixed_asset.rb +54 -0
- data/lib/erp_base_erp_svcs/extensions/active_record/has_contact.rb +25 -12
- data/lib/erp_base_erp_svcs/extensions/active_record/has_notes.rb +25 -2
- data/lib/erp_base_erp_svcs/extensions/active_record/has_tracked_status.rb +58 -6
- data/lib/erp_base_erp_svcs/extensions/active_record/to_hash.rb +12 -12
- data/lib/erp_base_erp_svcs/extensions/core/acts_as_aspector_on.rb +73 -0
- data/lib/erp_base_erp_svcs/extensions/core/object.rb +7 -0
- data/lib/erp_base_erp_svcs/version.rb +7 -3
- data/lib/tasks/compass_backup.rake +11 -6
- data/lib/tasks/erp_base_erp_svcs_tasks.rake +22 -9
- data/spec/models/party_spec.rb +9 -1
- metadata +80 -113
- data/app/assets/javascripts/erp_base_erp_svcs/application.js +0 -9
- data/app/assets/stylesheets/erp_base_erp_svcs/application.css +0 -7
- data/app/controllers/erp_base_erp_svcs/application_controller.rb +0 -4
- data/app/views/layouts/erp_base_erp_svcs/application.html.erb +0 -14
- data/spec/dummy/db/data_migrations/20110525001935_add_usd_currency.erp_base_erp_svcs.rb +0 -12
- data/spec/dummy/db/data_migrations/20110609150135_add_iso_codes.erp_base_erp_svcs.rb +0 -19
- data/spec/dummy/db/data_migrations/20110913145838_setup_compass_ae_instance.erp_base_erp_svcs.rb +0 -12
- data/spec/dummy/db/data_migrations/20130422154233_upgrade_compass_ae_instances_data.erp_base_erp_svcs.rb +0 -19
- data/spec/dummy/db/data_migrations/20130422154234_add_guid_to_instances.erp_base_erp_svcs.rb +0 -10
- data/spec/dummy/db/migrate/20130105143821_base_erp_services.erp_base_erp_svcs.rb +0 -461
- data/spec/dummy/db/migrate/20130422154229_add_txn_status.erp_base_erp_svcs.rb +0 -37
- data/spec/dummy/db/migrate/20130422154230_upgrade_compass_ae_instances.erp_base_erp_svcs.rb +0 -34
- data/spec/dummy/db/migrate/20130422154231_add_uuid_compass_ae_instance.erp_base_erp_svcs.rb +0 -17
- data/spec/dummy/db/migrate/20130422154232_add_long_lat_to_address.erp_base_erp_svcs.rb +0 -16
- data/spec/dummy/db/schema.rb +0 -435
- 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
|
data/spec/dummy/db/schema.rb
DELETED
@@ -1,435 +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 => 20130422154232) do
|
15
|
-
|
16
|
-
create_table "categories", :force => true do |t|
|
17
|
-
t.string "description"
|
18
|
-
t.string "external_identifier"
|
19
|
-
t.datetime "from_date"
|
20
|
-
t.datetime "to_date"
|
21
|
-
t.string "internal_identifier"
|
22
|
-
t.integer "category_record_id"
|
23
|
-
t.string "category_record_type"
|
24
|
-
t.integer "parent_id"
|
25
|
-
t.integer "lft"
|
26
|
-
t.integer "rgt"
|
27
|
-
t.datetime "created_at", :null => false
|
28
|
-
t.datetime "updated_at", :null => false
|
29
|
-
end
|
30
|
-
|
31
|
-
add_index "categories", ["category_record_id", "category_record_type"], :name => "category_polymorphic"
|
32
|
-
|
33
|
-
create_table "category_classifications", :force => true do |t|
|
34
|
-
t.integer "category_id"
|
35
|
-
t.string "classification_type"
|
36
|
-
t.integer "classification_id"
|
37
|
-
t.datetime "from_date"
|
38
|
-
t.datetime "to_date"
|
39
|
-
t.datetime "created_at", :null => false
|
40
|
-
t.datetime "updated_at", :null => false
|
41
|
-
end
|
42
|
-
|
43
|
-
add_index "category_classifications", ["classification_id", "classification_type"], :name => "classification_polymorphic"
|
44
|
-
|
45
|
-
create_table "compass_ae_instance_party_roles", :force => true do |t|
|
46
|
-
t.string "description"
|
47
|
-
t.integer "compass_ae_instance_id"
|
48
|
-
t.integer "party_id"
|
49
|
-
t.integer "role_type_id"
|
50
|
-
t.datetime "created_at", :null => false
|
51
|
-
t.datetime "updated_at", :null => false
|
52
|
-
end
|
53
|
-
|
54
|
-
add_index "compass_ae_instance_party_roles", ["compass_ae_instance_id"], :name => "compass_ae_instance_id_idx"
|
55
|
-
add_index "compass_ae_instance_party_roles", ["party_id"], :name => "party_id_idx"
|
56
|
-
add_index "compass_ae_instance_party_roles", ["role_type_id"], :name => "role_type_id_idx"
|
57
|
-
|
58
|
-
create_table "compass_ae_instances", :force => true do |t|
|
59
|
-
t.decimal "version", :precision => 8, :scale => 3
|
60
|
-
t.datetime "created_at", :null => false
|
61
|
-
t.datetime "updated_at", :null => false
|
62
|
-
t.string "description"
|
63
|
-
t.string "internal_identifier"
|
64
|
-
t.string "type"
|
65
|
-
t.string "schema", :default => "public"
|
66
|
-
t.integer "parent_id"
|
67
|
-
t.string "guid"
|
68
|
-
end
|
69
|
-
|
70
|
-
add_index "compass_ae_instances", ["guid"], :name => "guid_idx"
|
71
|
-
add_index "compass_ae_instances", ["internal_identifier"], :name => "iid_idx"
|
72
|
-
add_index "compass_ae_instances", ["parent_id"], :name => "parent_id_idx"
|
73
|
-
add_index "compass_ae_instances", ["schema"], :name => "schema_idx"
|
74
|
-
add_index "compass_ae_instances", ["type"], :name => "type_idx"
|
75
|
-
|
76
|
-
create_table "contact_purposes", :force => true do |t|
|
77
|
-
t.integer "parent_id"
|
78
|
-
t.integer "lft"
|
79
|
-
t.integer "rgt"
|
80
|
-
t.string "description"
|
81
|
-
t.string "comments"
|
82
|
-
t.string "internal_identifier"
|
83
|
-
t.string "external_identifier"
|
84
|
-
t.string "external_id_source"
|
85
|
-
t.datetime "created_at", :null => false
|
86
|
-
t.datetime "updated_at", :null => false
|
87
|
-
end
|
88
|
-
|
89
|
-
add_index "contact_purposes", ["parent_id"], :name => "index_contact_purposes_on_parent_id"
|
90
|
-
|
91
|
-
create_table "contact_purposes_contacts", :id => false, :force => true do |t|
|
92
|
-
t.integer "contact_id"
|
93
|
-
t.integer "contact_purpose_id"
|
94
|
-
end
|
95
|
-
|
96
|
-
add_index "contact_purposes_contacts", ["contact_id", "contact_purpose_id"], :name => "contact_purposes_contacts_index"
|
97
|
-
|
98
|
-
create_table "contact_types", :force => true do |t|
|
99
|
-
t.integer "parent_id"
|
100
|
-
t.integer "lft"
|
101
|
-
t.integer "rgt"
|
102
|
-
t.string "description"
|
103
|
-
t.string "comments"
|
104
|
-
t.string "internal_identifier"
|
105
|
-
t.string "external_identifier"
|
106
|
-
t.string "external_id_source"
|
107
|
-
t.datetime "created_at", :null => false
|
108
|
-
t.datetime "updated_at", :null => false
|
109
|
-
end
|
110
|
-
|
111
|
-
add_index "contact_types", ["parent_id"], :name => "index_contact_types_on_parent_id"
|
112
|
-
|
113
|
-
create_table "contacts", :force => true do |t|
|
114
|
-
t.integer "party_id"
|
115
|
-
t.integer "contact_mechanism_id"
|
116
|
-
t.string "contact_mechanism_type"
|
117
|
-
t.string "external_identifier"
|
118
|
-
t.string "external_id_source"
|
119
|
-
t.datetime "created_at", :null => false
|
120
|
-
t.datetime "updated_at", :null => false
|
121
|
-
end
|
122
|
-
|
123
|
-
add_index "contacts", ["contact_mechanism_id", "contact_mechanism_type"], :name => "besi_2"
|
124
|
-
add_index "contacts", ["party_id"], :name => "index_contacts_on_party_id"
|
125
|
-
|
126
|
-
create_table "currencies", :force => true do |t|
|
127
|
-
t.string "name"
|
128
|
-
t.string "definition"
|
129
|
-
t.string "internal_identifier"
|
130
|
-
t.string "numeric_code"
|
131
|
-
t.string "major_unit_symbol"
|
132
|
-
t.string "minor_unit_symbol"
|
133
|
-
t.string "ratio_of_minor_unit_to_major_unit"
|
134
|
-
t.string "postfix_label"
|
135
|
-
t.datetime "introduction_date"
|
136
|
-
t.datetime "expiration_date"
|
137
|
-
t.datetime "created_at", :null => false
|
138
|
-
t.datetime "updated_at", :null => false
|
139
|
-
end
|
140
|
-
|
141
|
-
add_index "currencies", ["internal_identifier"], :name => "index_currencies_on_internal_identifier"
|
142
|
-
|
143
|
-
create_table "descriptive_assets", :force => true do |t|
|
144
|
-
t.integer "view_type_id"
|
145
|
-
t.string "internal_identifier"
|
146
|
-
t.text "description"
|
147
|
-
t.string "external_identifier"
|
148
|
-
t.string "external_id_source"
|
149
|
-
t.integer "described_record_id"
|
150
|
-
t.string "described_record_type"
|
151
|
-
t.datetime "created_at", :null => false
|
152
|
-
t.datetime "updated_at", :null => false
|
153
|
-
end
|
154
|
-
|
155
|
-
add_index "descriptive_assets", ["described_record_id", "described_record_type"], :name => "described_record_idx"
|
156
|
-
add_index "descriptive_assets", ["view_type_id"], :name => "index_descriptive_assets_on_view_type_id"
|
157
|
-
|
158
|
-
create_table "email_addresses", :force => true do |t|
|
159
|
-
t.string "email_address"
|
160
|
-
t.string "description"
|
161
|
-
t.datetime "created_at", :null => false
|
162
|
-
t.datetime "updated_at", :null => false
|
163
|
-
end
|
164
|
-
|
165
|
-
create_table "geo_countries", :force => true do |t|
|
166
|
-
t.string "name"
|
167
|
-
t.string "iso_code_2"
|
168
|
-
t.string "iso_code_3"
|
169
|
-
t.boolean "display", :default => true
|
170
|
-
t.integer "external_id"
|
171
|
-
t.datetime "created_at"
|
172
|
-
end
|
173
|
-
|
174
|
-
add_index "geo_countries", ["iso_code_2"], :name => "index_geo_countries_on_iso_code_2"
|
175
|
-
add_index "geo_countries", ["name"], :name => "index_geo_countries_on_name"
|
176
|
-
|
177
|
-
create_table "geo_zones", :force => true do |t|
|
178
|
-
t.integer "geo_country_id"
|
179
|
-
t.string "zone_code", :default => "2"
|
180
|
-
t.string "zone_name"
|
181
|
-
t.datetime "created_at"
|
182
|
-
end
|
183
|
-
|
184
|
-
add_index "geo_zones", ["geo_country_id"], :name => "index_geo_zones_on_geo_country_id"
|
185
|
-
add_index "geo_zones", ["zone_code"], :name => "index_geo_zones_on_zone_code"
|
186
|
-
add_index "geo_zones", ["zone_name"], :name => "index_geo_zones_on_zone_name"
|
187
|
-
|
188
|
-
create_table "individuals", :force => true do |t|
|
189
|
-
t.integer "party_id"
|
190
|
-
t.string "current_last_name"
|
191
|
-
t.string "current_first_name"
|
192
|
-
t.string "current_middle_name"
|
193
|
-
t.string "current_personal_title"
|
194
|
-
t.string "current_suffix"
|
195
|
-
t.string "current_nickname"
|
196
|
-
t.string "gender", :limit => 1
|
197
|
-
t.date "birth_date"
|
198
|
-
t.decimal "height", :precision => 5, :scale => 2
|
199
|
-
t.integer "weight"
|
200
|
-
t.string "mothers_maiden_name"
|
201
|
-
t.string "marital_status", :limit => 1
|
202
|
-
t.string "social_security_number"
|
203
|
-
t.integer "current_passport_number"
|
204
|
-
t.date "current_passport_expire_date"
|
205
|
-
t.integer "total_years_work_experience"
|
206
|
-
t.string "comments"
|
207
|
-
t.string "encrypted_ssn"
|
208
|
-
t.string "temp_ssn"
|
209
|
-
t.string "salt"
|
210
|
-
t.string "ssn_last_four"
|
211
|
-
t.datetime "created_at", :null => false
|
212
|
-
t.datetime "updated_at", :null => false
|
213
|
-
end
|
214
|
-
|
215
|
-
add_index "individuals", ["party_id"], :name => "index_individuals_on_party_id"
|
216
|
-
|
217
|
-
create_table "money", :force => true do |t|
|
218
|
-
t.string "description"
|
219
|
-
t.decimal "amount", :precision => 8, :scale => 2
|
220
|
-
t.integer "currency_id"
|
221
|
-
t.datetime "created_at", :null => false
|
222
|
-
t.datetime "updated_at", :null => false
|
223
|
-
end
|
224
|
-
|
225
|
-
add_index "money", ["currency_id"], :name => "index_money_on_currency_id"
|
226
|
-
|
227
|
-
create_table "note_types", :force => true do |t|
|
228
|
-
t.integer "parent_id"
|
229
|
-
t.integer "lft"
|
230
|
-
t.integer "rgt"
|
231
|
-
t.string "description"
|
232
|
-
t.string "internal_identifier"
|
233
|
-
t.string "external_identifier"
|
234
|
-
t.integer "note_type_record_id"
|
235
|
-
t.string "note_type_record_type"
|
236
|
-
t.datetime "created_at", :null => false
|
237
|
-
t.datetime "updated_at", :null => false
|
238
|
-
end
|
239
|
-
|
240
|
-
add_index "note_types", ["note_type_record_id", "note_type_record_type"], :name => "note_type_record_idx"
|
241
|
-
|
242
|
-
create_table "notes", :force => true do |t|
|
243
|
-
t.integer "created_by_id"
|
244
|
-
t.text "content"
|
245
|
-
t.integer "noted_record_id"
|
246
|
-
t.string "noted_record_type"
|
247
|
-
t.integer "note_type_id"
|
248
|
-
t.datetime "created_at", :null => false
|
249
|
-
t.datetime "updated_at", :null => false
|
250
|
-
end
|
251
|
-
|
252
|
-
add_index "notes", ["created_by_id"], :name => "index_notes_on_created_by_id"
|
253
|
-
add_index "notes", ["note_type_id"], :name => "index_notes_on_note_type_id"
|
254
|
-
add_index "notes", ["noted_record_id", "noted_record_type"], :name => "index_notes_on_noted_record_id_and_noted_record_type"
|
255
|
-
|
256
|
-
create_table "organizations", :force => true do |t|
|
257
|
-
t.string "description"
|
258
|
-
t.string "tax_id_number"
|
259
|
-
t.datetime "created_at", :null => false
|
260
|
-
t.datetime "updated_at", :null => false
|
261
|
-
end
|
262
|
-
|
263
|
-
create_table "parties", :force => true do |t|
|
264
|
-
t.string "description"
|
265
|
-
t.integer "business_party_id"
|
266
|
-
t.string "business_party_type"
|
267
|
-
t.integer "list_view_image_id"
|
268
|
-
t.string "enterprise_identifier"
|
269
|
-
t.datetime "created_at", :null => false
|
270
|
-
t.datetime "updated_at", :null => false
|
271
|
-
end
|
272
|
-
|
273
|
-
add_index "parties", ["business_party_id", "business_party_type"], :name => "besi_1"
|
274
|
-
|
275
|
-
create_table "party_relationships", :force => true do |t|
|
276
|
-
t.string "description"
|
277
|
-
t.integer "party_id_from"
|
278
|
-
t.integer "party_id_to"
|
279
|
-
t.integer "role_type_id_from"
|
280
|
-
t.integer "role_type_id_to"
|
281
|
-
t.integer "status_type_id"
|
282
|
-
t.integer "priority_type_id"
|
283
|
-
t.integer "relationship_type_id"
|
284
|
-
t.date "from_date"
|
285
|
-
t.date "thru_date"
|
286
|
-
t.string "external_identifier"
|
287
|
-
t.string "external_id_source"
|
288
|
-
t.datetime "created_at", :null => false
|
289
|
-
t.datetime "updated_at", :null => false
|
290
|
-
end
|
291
|
-
|
292
|
-
add_index "party_relationships", ["priority_type_id"], :name => "index_party_relationships_on_priority_type_id"
|
293
|
-
add_index "party_relationships", ["relationship_type_id"], :name => "index_party_relationships_on_relationship_type_id"
|
294
|
-
add_index "party_relationships", ["status_type_id"], :name => "index_party_relationships_on_status_type_id"
|
295
|
-
|
296
|
-
create_table "party_roles", :force => true do |t|
|
297
|
-
t.string "type"
|
298
|
-
t.integer "party_id"
|
299
|
-
t.integer "role_type_id"
|
300
|
-
t.datetime "created_at", :null => false
|
301
|
-
t.datetime "updated_at", :null => false
|
302
|
-
end
|
303
|
-
|
304
|
-
add_index "party_roles", ["party_id"], :name => "index_party_roles_on_party_id"
|
305
|
-
add_index "party_roles", ["role_type_id"], :name => "index_party_roles_on_role_type_id"
|
306
|
-
|
307
|
-
create_table "party_search_facts", :force => true do |t|
|
308
|
-
t.integer "party_id"
|
309
|
-
t.string "eid"
|
310
|
-
t.string "type"
|
311
|
-
t.text "roles"
|
312
|
-
t.string "party_description"
|
313
|
-
t.string "party_business_party_type"
|
314
|
-
t.string "user_login"
|
315
|
-
t.string "individual_current_last_name"
|
316
|
-
t.string "individual_current_first_name"
|
317
|
-
t.string "individual_current_middle_name"
|
318
|
-
t.string "individual_birth_date"
|
319
|
-
t.string "individual_ssn"
|
320
|
-
t.string "party_phone_number"
|
321
|
-
t.string "party_email_address"
|
322
|
-
t.string "party_address_1"
|
323
|
-
t.string "party_address_2"
|
324
|
-
t.string "party_primary_address_city"
|
325
|
-
t.string "party_primary_address_state"
|
326
|
-
t.string "party_primary_address_zip"
|
327
|
-
t.string "party_primary_address_country"
|
328
|
-
t.boolean "user_enabled"
|
329
|
-
t.string "user_type"
|
330
|
-
t.boolean "reindex"
|
331
|
-
t.datetime "created_at", :null => false
|
332
|
-
t.datetime "updated_at", :null => false
|
333
|
-
end
|
334
|
-
|
335
|
-
create_table "phone_numbers", :force => true do |t|
|
336
|
-
t.string "phone_number"
|
337
|
-
t.string "description"
|
338
|
-
t.datetime "created_at", :null => false
|
339
|
-
t.datetime "updated_at", :null => false
|
340
|
-
end
|
341
|
-
|
342
|
-
create_table "postal_addresses", :force => true do |t|
|
343
|
-
t.string "address_line_1"
|
344
|
-
t.string "address_line_2"
|
345
|
-
t.string "city"
|
346
|
-
t.string "state"
|
347
|
-
t.string "zip"
|
348
|
-
t.string "country"
|
349
|
-
t.string "description"
|
350
|
-
t.integer "geo_country_id"
|
351
|
-
t.integer "geo_zone_id"
|
352
|
-
t.datetime "created_at", :null => false
|
353
|
-
t.datetime "updated_at", :null => false
|
354
|
-
t.decimal "latitude", :precision => 12, :scale => 8
|
355
|
-
t.decimal "longitude", :precision => 12, :scale => 8
|
356
|
-
end
|
357
|
-
|
358
|
-
add_index "postal_addresses", ["geo_country_id"], :name => "index_postal_addresses_on_geo_country_id"
|
359
|
-
add_index "postal_addresses", ["geo_zone_id"], :name => "index_postal_addresses_on_geo_zone_id"
|
360
|
-
|
361
|
-
create_table "relationship_types", :force => true do |t|
|
362
|
-
t.integer "parent_id"
|
363
|
-
t.integer "lft"
|
364
|
-
t.integer "rgt"
|
365
|
-
t.integer "valid_from_role_type_id"
|
366
|
-
t.integer "valid_to_role_type_id"
|
367
|
-
t.string "name"
|
368
|
-
t.string "description"
|
369
|
-
t.string "internal_identifier"
|
370
|
-
t.string "external_identifier"
|
371
|
-
t.string "external_id_source"
|
372
|
-
t.datetime "created_at", :null => false
|
373
|
-
t.datetime "updated_at", :null => false
|
374
|
-
end
|
375
|
-
|
376
|
-
add_index "relationship_types", ["valid_from_role_type_id"], :name => "index_relationship_types_on_valid_from_role_type_id"
|
377
|
-
add_index "relationship_types", ["valid_to_role_type_id"], :name => "index_relationship_types_on_valid_to_role_type_id"
|
378
|
-
|
379
|
-
create_table "role_types", :force => true do |t|
|
380
|
-
t.integer "parent_id"
|
381
|
-
t.integer "lft"
|
382
|
-
t.integer "rgt"
|
383
|
-
t.string "description"
|
384
|
-
t.string "comments"
|
385
|
-
t.string "internal_identifier"
|
386
|
-
t.string "external_identifier"
|
387
|
-
t.string "external_id_source"
|
388
|
-
t.datetime "created_at", :null => false
|
389
|
-
t.datetime "updated_at", :null => false
|
390
|
-
end
|
391
|
-
|
392
|
-
create_table "status_applications", :force => true do |t|
|
393
|
-
t.integer "tracked_status_type_id"
|
394
|
-
t.integer "status_application_record_id"
|
395
|
-
t.string "status_application_record_type"
|
396
|
-
t.datetime "from_date"
|
397
|
-
t.datetime "thru_date"
|
398
|
-
t.datetime "created_at", :null => false
|
399
|
-
t.datetime "updated_at", :null => false
|
400
|
-
end
|
401
|
-
|
402
|
-
add_index "status_applications", ["from_date"], :name => "from_date_idx"
|
403
|
-
add_index "status_applications", ["status_application_record_id", "status_application_record_type"], :name => "status_applications_record_idx"
|
404
|
-
add_index "status_applications", ["thru_date"], :name => "thru_date_idx"
|
405
|
-
add_index "status_applications", ["tracked_status_type_id"], :name => "tracked_status_type_id_idx"
|
406
|
-
|
407
|
-
create_table "tracked_status_types", :force => true do |t|
|
408
|
-
t.string "description"
|
409
|
-
t.string "internal_identifier"
|
410
|
-
t.string "external_identifier"
|
411
|
-
t.datetime "created_at", :null => false
|
412
|
-
t.datetime "updated_at", :null => false
|
413
|
-
end
|
414
|
-
|
415
|
-
add_index "tracked_status_types", ["internal_identifier"], :name => "tracked_status_types_iid_idx"
|
416
|
-
|
417
|
-
create_table "valid_note_types", :force => true do |t|
|
418
|
-
t.integer "valid_note_type_record_id"
|
419
|
-
t.string "valid_note_type_record_type"
|
420
|
-
t.integer "note_type_id"
|
421
|
-
t.datetime "created_at", :null => false
|
422
|
-
t.datetime "updated_at", :null => false
|
423
|
-
end
|
424
|
-
|
425
|
-
add_index "valid_note_types", ["note_type_id"], :name => "index_valid_note_types_on_note_type_id"
|
426
|
-
add_index "valid_note_types", ["valid_note_type_record_id", "valid_note_type_record_type"], :name => "valid_note_type_record_idx"
|
427
|
-
|
428
|
-
create_table "view_types", :force => true do |t|
|
429
|
-
t.string "internal_identifier"
|
430
|
-
t.string "description"
|
431
|
-
t.datetime "created_at", :null => false
|
432
|
-
t.datetime "updated_at", :null => false
|
433
|
-
end
|
434
|
-
|
435
|
-
end
|