enju_leaf 1.1.0.rc3 → 1.1.0.rc4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/javascripts/enju_leaf.js +0 -2
- data/app/controllers/page_controller.rb +2 -2
- data/app/controllers/users_controller.rb +7 -7
- data/app/views/layouts/patrons.html.erb +2 -2
- data/app/views/my_accounts/show.html.erb +9 -1
- data/app/views/page/_menu.html.erb +1 -1
- data/app/views/page/advanced_search.html.erb +2 -2
- data/app/views/page/configuration.html.erb +3 -3
- data/app/views/page/export.html.erb +2 -2
- data/app/views/page/import.html.erb +1 -1
- data/app/views/page/statistics.html.erb +2 -2
- data/app/views/users/index.html.erb +0 -11
- data/app/views/users/new.html.erb +4 -4
- data/app/views/users/show.html.erb +9 -1
- data/config/locales/translation_en.yml +13 -13
- data/config/locales/translation_ja.yml +13 -13
- data/lib/enju_leaf/user.rb +12 -12
- data/lib/enju_leaf/version.rb +1 -1
- data/lib/enju_leaf.rb +2 -2
- data/lib/generators/enju_leaf/setup/setup_generator.rb +10 -3
- data/spec/dummy/db/migrate/001_create_patrons.rb +7 -7
- data/spec/dummy/db/migrate/012_create_owns.rb +2 -2
- data/spec/dummy/db/migrate/015_create_creates.rb +2 -2
- data/spec/dummy/db/migrate/047_create_produces.rb +2 -2
- data/spec/dummy/db/migrate/125_create_donates.rb +2 -2
- data/spec/dummy/db/migrate/20080830154109_create_realizes.rb +2 -2
- data/spec/dummy/db/migrate/20080905191442_create_patron_types.rb +1 -1
- data/spec/dummy/db/migrate/20081028083142_create_patron_import_files.rb +8 -8
- data/spec/dummy/db/migrate/20090812151902_create_patron_relationship_types.rb +1 -1
- data/spec/dummy/db/migrate/20091012101112_add_dcndl_schema.rb +2 -2
- data/spec/dummy/db/migrate/20100606073747_create_patron_relationships.rb +4 -4
- data/spec/dummy/db/migrate/20100814091104_add_position_to_patron_relationship.rb +2 -2
- data/spec/dummy/db/migrate/20100925074559_create_patron_import_results.rb +3 -3
- data/spec/dummy/db/migrate/20110301121550_add_birth_date_and_death_date_to_patron.rb +4 -4
- data/spec/dummy/db/migrate/20120413161403_add_fingerprint_to_patron_import_file.rb +1 -1
- data/spec/dummy/db/migrate/20120413170720_add_error_message_to_patron_import_file.rb +1 -1
- data/spec/dummy/db/migrate/20120415060323_rename_patron_import_file_imported_at_to_executed_at.rb +2 -2
- data/spec/dummy/db/migrate/20120511072422_add_patron_identifier_to_patron.rb +2 -2
- data/spec/dummy/db/migrate/20120602141129_add_edit_mode_to_patron_import_file.rb +1 -1
- data/spec/dummy/db/schema.rb +129 -129
- data/spec/dummy/db/test.sqlite3 +0 -0
- data/spec/dummy/solr/data/test/index/{_6z.fdt → _7z.fdt} +0 -0
- data/spec/dummy/solr/data/test/index/{_6z.fdx → _7z.fdx} +0 -0
- data/spec/dummy/solr/data/test/index/{_6z.fnm → _7z.fnm} +0 -0
- data/spec/dummy/solr/data/test/index/{_6z.frq → _7z.frq} +0 -0
- data/spec/dummy/solr/data/test/index/{_6z.nrm → _7z.nrm} +0 -0
- data/spec/dummy/solr/data/test/index/{_6z.prx → _7z.prx} +0 -0
- data/spec/dummy/solr/data/test/index/{_6z.tii → _7z.tii} +0 -0
- data/spec/dummy/solr/data/test/index/{_6z.tis → _7z.tis} +0 -0
- data/spec/dummy/solr/data/test/index/segments.gen +0 -0
- data/spec/dummy/solr/data/test/index/segments_g1 +0 -0
- data/spec/factories/{patron.rb → agent.rb} +3 -3
- data/spec/factories/agent_relationship.rb +6 -0
- data/spec/factories/agent_relationship_type.rb +5 -0
- data/spec/factories/agent_type.rb +5 -0
- data/spec/factories/create.rb +1 -1
- data/spec/factories/donate.rb +1 -1
- data/spec/factories/own.rb +1 -1
- data/spec/factories/produce.rb +1 -1
- data/spec/factories/realize.rb +1 -1
- data/spec/fixtures/{patron_import_files.yml → agent_import_files.yml} +18 -18
- data/spec/fixtures/{patron_import_results.yml → agent_import_results.yml} +7 -7
- data/spec/fixtures/{patron_relationship_types.yml → agent_relationship_types.yml} +4 -4
- data/spec/fixtures/{patron_relationships.yml → agent_relationships.yml} +4 -4
- data/spec/fixtures/{patron_types.yml → agent_types.yml} +4 -4
- data/spec/fixtures/{patrons.yml → agents.yml} +47 -47
- data/spec/fixtures/creates.yml +8 -8
- data/spec/fixtures/donates.yml +4 -4
- data/spec/fixtures/owns.yml +3 -3
- data/spec/fixtures/produces.yml +20 -20
- data/spec/fixtures/realizes.yml +11 -11
- data/spec/spec_helper.rb +0 -2
- data/vendor/assets/javascripts/jquery.colorbox.js +70 -33
- data/vendor/assets/javascripts/jquery.ui.menubar.js +342 -187
- data/vendor/assets/stylesheets/jquery.ui.menubar.css +25 -5
- metadata +61 -76
- data/app/assets/stylesheets/images/ajax-loader.gif +0 -0
- data/app/assets/stylesheets/images/border.png +0 -0
- data/app/assets/stylesheets/images/controls.png +0 -0
- data/app/assets/stylesheets/images/icons-18-black.png +0 -0
- data/app/assets/stylesheets/images/icons-18-white.png +0 -0
- data/app/assets/stylesheets/images/icons-36-black.png +0 -0
- data/app/assets/stylesheets/images/icons-36-white.png +0 -0
- data/app/assets/stylesheets/images/ie6/borderBottomCenter.png +0 -0
- data/app/assets/stylesheets/images/ie6/borderBottomLeft.png +0 -0
- data/app/assets/stylesheets/images/ie6/borderBottomRight.png +0 -0
- data/app/assets/stylesheets/images/ie6/borderMiddleLeft.png +0 -0
- data/app/assets/stylesheets/images/ie6/borderMiddleRight.png +0 -0
- data/app/assets/stylesheets/images/ie6/borderTopCenter.png +0 -0
- data/app/assets/stylesheets/images/ie6/borderTopLeft.png +0 -0
- data/app/assets/stylesheets/images/ie6/borderTopRight.png +0 -0
- data/app/assets/stylesheets/images/loading.gif +0 -0
- data/app/assets/stylesheets/images/loading_background.png +0 -0
- data/app/assets/stylesheets/images/overlay.png +0 -0
- data/app/assets/stylesheets/images/spinner_bar.gif +0 -0
- data/spec/dummy/db/development.sqlite3 +0 -0
- data/spec/dummy/solr/data/test/index/segments_e1 +0 -0
- data/spec/factories/patron_relationship.rb +0 -6
- data/spec/factories/patron_relationship_type.rb +0 -5
- data/spec/factories/patron_type.rb +0 -5
- data/vendor/assets/stylesheets/images/ie6/borderBottomCenter.png +0 -0
- data/vendor/assets/stylesheets/images/ie6/borderBottomLeft.png +0 -0
- data/vendor/assets/stylesheets/images/ie6/borderBottomRight.png +0 -0
- data/vendor/assets/stylesheets/images/ie6/borderMiddleLeft.png +0 -0
- data/vendor/assets/stylesheets/images/ie6/borderMiddleRight.png +0 -0
- data/vendor/assets/stylesheets/images/ie6/borderTopCenter.png +0 -0
- data/vendor/assets/stylesheets/images/ie6/borderTopLeft.png +0 -0
- data/vendor/assets/stylesheets/images/ie6/borderTopRight.png +0 -0
@@ -1,12 +1,12 @@
|
|
1
1
|
class CreateDonates < ActiveRecord::Migration
|
2
2
|
def change
|
3
3
|
create_table :donates do |t|
|
4
|
-
t.integer :
|
4
|
+
t.integer :agent_id, :null => false
|
5
5
|
t.integer :item_id, :null => false
|
6
6
|
|
7
7
|
t.timestamps
|
8
8
|
end
|
9
|
-
add_index :donates, :
|
9
|
+
add_index :donates, :agent_id
|
10
10
|
add_index :donates, :item_id
|
11
11
|
end
|
12
12
|
end
|
@@ -1,13 +1,13 @@
|
|
1
1
|
class CreateRealizes < ActiveRecord::Migration
|
2
2
|
def change
|
3
3
|
create_table :realizes do |t|
|
4
|
-
t.references :
|
4
|
+
t.references :agent, :null => false
|
5
5
|
t.references :expression, :null => false
|
6
6
|
t.integer :position
|
7
7
|
|
8
8
|
t.timestamps
|
9
9
|
end
|
10
|
-
add_index :realizes, :
|
10
|
+
add_index :realizes, :agent_id
|
11
11
|
add_index :realizes, :expression_id
|
12
12
|
end
|
13
13
|
end
|
@@ -1,6 +1,6 @@
|
|
1
1
|
class CreatePatronImportFiles < ActiveRecord::Migration
|
2
2
|
def change
|
3
|
-
create_table :
|
3
|
+
create_table :agent_import_files do |t|
|
4
4
|
t.integer :parent_id
|
5
5
|
t.string :content_type
|
6
6
|
t.integer :size
|
@@ -8,15 +8,15 @@ class CreatePatronImportFiles < ActiveRecord::Migration
|
|
8
8
|
t.text :note
|
9
9
|
t.datetime :imported_at
|
10
10
|
t.string :state
|
11
|
-
t.string :
|
12
|
-
t.string :
|
13
|
-
t.integer :
|
14
|
-
t.datetime :
|
11
|
+
t.string :agent_import_file_name
|
12
|
+
t.string :agent_import_content_type
|
13
|
+
t.integer :agent_import_file_size
|
14
|
+
t.datetime :agent_import_updated_at
|
15
15
|
|
16
16
|
t.timestamps
|
17
17
|
end
|
18
|
-
add_index :
|
19
|
-
add_index :
|
20
|
-
add_index :
|
18
|
+
add_index :agent_import_files, :parent_id
|
19
|
+
add_index :agent_import_files, :user_id
|
20
|
+
add_index :agent_import_files, :state
|
21
21
|
end
|
22
22
|
end
|
@@ -1,7 +1,7 @@
|
|
1
1
|
class AddDcndlSchema < ActiveRecord::Migration
|
2
2
|
def self.up
|
3
3
|
add_column :manifestations, :title_alternative_transcription, :text
|
4
|
-
add_column :
|
4
|
+
add_column :agents, :full_name_alternative_transcription, :text
|
5
5
|
add_column :manifestations, :description, :text
|
6
6
|
add_column :manifestations, :abstract, :text
|
7
7
|
add_column :manifestations, :available_at, :timestamp
|
@@ -14,7 +14,7 @@ class AddDcndlSchema < ActiveRecord::Migration
|
|
14
14
|
|
15
15
|
def self.down
|
16
16
|
remove_column :manifestations, :title_alternative_transcription
|
17
|
-
remove_column :
|
17
|
+
remove_column :agents, :full_name_alternative_transcription
|
18
18
|
remove_column :manifestations, :description
|
19
19
|
remove_column :manifestations, :abstract
|
20
20
|
remove_column :manifestations, :available_at
|
@@ -1,13 +1,13 @@
|
|
1
1
|
class CreatePatronRelationships < ActiveRecord::Migration
|
2
2
|
def change
|
3
|
-
create_table :
|
3
|
+
create_table :agent_relationships do |t|
|
4
4
|
t.integer :parent_id
|
5
5
|
t.integer :child_id
|
6
|
-
t.integer :
|
6
|
+
t.integer :agent_relationship_type_id
|
7
7
|
|
8
8
|
t.timestamps
|
9
9
|
end
|
10
|
-
add_index :
|
11
|
-
add_index :
|
10
|
+
add_index :agent_relationships, :parent_id
|
11
|
+
add_index :agent_relationships, :child_id
|
12
12
|
end
|
13
13
|
end
|
@@ -1,11 +1,11 @@
|
|
1
1
|
class AddPositionToPatronRelationship < ActiveRecord::Migration
|
2
2
|
def self.up
|
3
3
|
add_column :manifestation_relationships, :position, :integer
|
4
|
-
add_column :
|
4
|
+
add_column :agent_relationships, :position, :integer
|
5
5
|
end
|
6
6
|
|
7
7
|
def self.down
|
8
|
-
remove_column :
|
8
|
+
remove_column :agent_relationships, :position
|
9
9
|
remove_column :manifestation_relationships, :position
|
10
10
|
end
|
11
11
|
end
|
@@ -1,8 +1,8 @@
|
|
1
1
|
class CreatePatronImportResults < ActiveRecord::Migration
|
2
2
|
def change
|
3
|
-
create_table :
|
4
|
-
t.integer :
|
5
|
-
t.integer :
|
3
|
+
create_table :agent_import_results do |t|
|
4
|
+
t.integer :agent_import_file_id
|
5
|
+
t.integer :agent_id
|
6
6
|
t.integer :user_id
|
7
7
|
t.text :body
|
8
8
|
|
@@ -1,11 +1,11 @@
|
|
1
1
|
class AddBirthDateAndDeathDateToPatron < ActiveRecord::Migration
|
2
2
|
def self.up
|
3
|
-
add_column :
|
4
|
-
add_column :
|
3
|
+
add_column :agents, :birth_date, :string
|
4
|
+
add_column :agents, :death_date, :string
|
5
5
|
end
|
6
6
|
|
7
7
|
def self.down
|
8
|
-
remove_column :
|
9
|
-
remove_column :
|
8
|
+
remove_column :agents, :death_date
|
9
|
+
remove_column :agents, :birth_date
|
10
10
|
end
|
11
11
|
end
|
data/spec/dummy/db/migrate/20120415060323_rename_patron_import_file_imported_at_to_executed_at.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
1
|
class RenamePatronImportFileImportedAtToExecutedAt < ActiveRecord::Migration
|
2
2
|
def up
|
3
|
-
rename_column :
|
3
|
+
rename_column :agent_import_files, :imported_at, :executed_at
|
4
4
|
end
|
5
5
|
|
6
6
|
def down
|
7
|
-
rename_column :
|
7
|
+
rename_column :agent_import_files, :executed_at, :imported_at
|
8
8
|
end
|
9
9
|
end
|
data/spec/dummy/db/schema.rb
CHANGED
@@ -24,6 +24,125 @@ ActiveRecord::Schema.define(:version => 20130221154434) do
|
|
24
24
|
add_index "accepts", ["basket_id"], :name => "index_accepts_on_basket_id"
|
25
25
|
add_index "accepts", ["item_id"], :name => "index_accepts_on_item_id"
|
26
26
|
|
27
|
+
create_table "agent_import_files", :force => true do |t|
|
28
|
+
t.integer "parent_id"
|
29
|
+
t.string "content_type"
|
30
|
+
t.integer "size"
|
31
|
+
t.integer "user_id"
|
32
|
+
t.text "note"
|
33
|
+
t.datetime "executed_at"
|
34
|
+
t.string "state"
|
35
|
+
t.string "agent_import_file_name"
|
36
|
+
t.string "agent_import_content_type"
|
37
|
+
t.integer "agent_import_file_size"
|
38
|
+
t.datetime "agent_import_updated_at"
|
39
|
+
t.datetime "created_at", :null => false
|
40
|
+
t.datetime "updated_at", :null => false
|
41
|
+
t.string "agent_import_fingerprint"
|
42
|
+
t.text "error_message"
|
43
|
+
t.string "edit_mode"
|
44
|
+
end
|
45
|
+
|
46
|
+
add_index "agent_import_files", ["parent_id"], :name => "index_agent_import_files_on_parent_id"
|
47
|
+
add_index "agent_import_files", ["state"], :name => "index_agent_import_files_on_state"
|
48
|
+
add_index "agent_import_files", ["user_id"], :name => "index_agent_import_files_on_user_id"
|
49
|
+
|
50
|
+
create_table "agent_import_results", :force => true do |t|
|
51
|
+
t.integer "agent_import_file_id"
|
52
|
+
t.integer "agent_id"
|
53
|
+
t.integer "user_id"
|
54
|
+
t.text "body"
|
55
|
+
t.datetime "created_at", :null => false
|
56
|
+
t.datetime "updated_at", :null => false
|
57
|
+
end
|
58
|
+
|
59
|
+
create_table "agent_relationship_types", :force => true do |t|
|
60
|
+
t.string "name", :null => false
|
61
|
+
t.text "display_name"
|
62
|
+
t.text "note"
|
63
|
+
t.integer "position"
|
64
|
+
t.datetime "created_at", :null => false
|
65
|
+
t.datetime "updated_at", :null => false
|
66
|
+
end
|
67
|
+
|
68
|
+
create_table "agent_relationships", :force => true do |t|
|
69
|
+
t.integer "parent_id"
|
70
|
+
t.integer "child_id"
|
71
|
+
t.integer "agent_relationship_type_id"
|
72
|
+
t.datetime "created_at", :null => false
|
73
|
+
t.datetime "updated_at", :null => false
|
74
|
+
t.integer "position"
|
75
|
+
end
|
76
|
+
|
77
|
+
add_index "agent_relationships", ["child_id"], :name => "index_agent_relationships_on_child_id"
|
78
|
+
add_index "agent_relationships", ["parent_id"], :name => "index_agent_relationships_on_parent_id"
|
79
|
+
|
80
|
+
create_table "agent_types", :force => true do |t|
|
81
|
+
t.string "name", :null => false
|
82
|
+
t.text "display_name"
|
83
|
+
t.text "note"
|
84
|
+
t.integer "position"
|
85
|
+
t.datetime "created_at", :null => false
|
86
|
+
t.datetime "updated_at", :null => false
|
87
|
+
end
|
88
|
+
|
89
|
+
create_table "agents", :force => true do |t|
|
90
|
+
t.integer "user_id"
|
91
|
+
t.string "last_name"
|
92
|
+
t.string "middle_name"
|
93
|
+
t.string "first_name"
|
94
|
+
t.string "last_name_transcription"
|
95
|
+
t.string "middle_name_transcription"
|
96
|
+
t.string "first_name_transcription"
|
97
|
+
t.string "corporate_name"
|
98
|
+
t.string "corporate_name_transcription"
|
99
|
+
t.string "full_name"
|
100
|
+
t.text "full_name_transcription"
|
101
|
+
t.text "full_name_alternative"
|
102
|
+
t.datetime "created_at", :null => false
|
103
|
+
t.datetime "updated_at", :null => false
|
104
|
+
t.datetime "deleted_at"
|
105
|
+
t.string "zip_code_1"
|
106
|
+
t.string "zip_code_2"
|
107
|
+
t.text "address_1"
|
108
|
+
t.text "address_2"
|
109
|
+
t.text "address_1_note"
|
110
|
+
t.text "address_2_note"
|
111
|
+
t.string "telephone_number_1"
|
112
|
+
t.string "telephone_number_2"
|
113
|
+
t.string "fax_number_1"
|
114
|
+
t.string "fax_number_2"
|
115
|
+
t.text "other_designation"
|
116
|
+
t.text "place"
|
117
|
+
t.string "postal_code"
|
118
|
+
t.text "street"
|
119
|
+
t.text "locality"
|
120
|
+
t.text "region"
|
121
|
+
t.datetime "date_of_birth"
|
122
|
+
t.datetime "date_of_death"
|
123
|
+
t.integer "language_id", :default => 1, :null => false
|
124
|
+
t.integer "country_id", :default => 1, :null => false
|
125
|
+
t.integer "agent_type_id", :default => 1, :null => false
|
126
|
+
t.integer "lock_version", :default => 0, :null => false
|
127
|
+
t.text "note"
|
128
|
+
t.integer "required_role_id", :default => 1, :null => false
|
129
|
+
t.integer "required_score", :default => 0, :null => false
|
130
|
+
t.string "state"
|
131
|
+
t.text "email"
|
132
|
+
t.text "url"
|
133
|
+
t.text "full_name_alternative_transcription"
|
134
|
+
t.string "birth_date"
|
135
|
+
t.string "death_date"
|
136
|
+
t.string "agent_identifier"
|
137
|
+
end
|
138
|
+
|
139
|
+
add_index "agents", ["agent_identifier"], :name => "index_agents_on_agent_identifier"
|
140
|
+
add_index "agents", ["country_id"], :name => "index_agents_on_country_id"
|
141
|
+
add_index "agents", ["full_name"], :name => "index_agents_on_full_name"
|
142
|
+
add_index "agents", ["language_id"], :name => "index_agents_on_language_id"
|
143
|
+
add_index "agents", ["required_role_id"], :name => "index_agents_on_required_role_id"
|
144
|
+
add_index "agents", ["user_id"], :name => "index_agents_on_user_id", :unique => true
|
145
|
+
|
27
146
|
create_table "baskets", :force => true do |t|
|
28
147
|
t.integer "user_id"
|
29
148
|
t.text "note"
|
@@ -100,7 +219,7 @@ ActiveRecord::Schema.define(:version => 20130221154434) do
|
|
100
219
|
end
|
101
220
|
|
102
221
|
create_table "creates", :force => true do |t|
|
103
|
-
t.integer "
|
222
|
+
t.integer "agent_id", :null => false
|
104
223
|
t.integer "work_id", :null => false
|
105
224
|
t.integer "position"
|
106
225
|
t.datetime "created_at", :null => false
|
@@ -108,18 +227,18 @@ ActiveRecord::Schema.define(:version => 20130221154434) do
|
|
108
227
|
t.integer "create_type_id"
|
109
228
|
end
|
110
229
|
|
111
|
-
add_index "creates", ["
|
230
|
+
add_index "creates", ["agent_id"], :name => "index_creates_on_agent_id"
|
112
231
|
add_index "creates", ["work_id"], :name => "index_creates_on_work_id"
|
113
232
|
|
114
233
|
create_table "donates", :force => true do |t|
|
115
|
-
t.integer "
|
234
|
+
t.integer "agent_id", :null => false
|
116
235
|
t.integer "item_id", :null => false
|
117
236
|
t.datetime "created_at", :null => false
|
118
237
|
t.datetime "updated_at", :null => false
|
119
238
|
end
|
120
239
|
|
240
|
+
add_index "donates", ["agent_id"], :name => "index_donates_on_agent_id"
|
121
241
|
add_index "donates", ["item_id"], :name => "index_donates_on_item_id"
|
122
|
-
add_index "donates", ["patron_id"], :name => "index_donates_on_patron_id"
|
123
242
|
|
124
243
|
create_table "exemplifies", :force => true do |t|
|
125
244
|
t.integer "manifestation_id", :null => false
|
@@ -377,134 +496,15 @@ ActiveRecord::Schema.define(:version => 20130221154434) do
|
|
377
496
|
end
|
378
497
|
|
379
498
|
create_table "owns", :force => true do |t|
|
380
|
-
t.integer "
|
499
|
+
t.integer "agent_id", :null => false
|
381
500
|
t.integer "item_id", :null => false
|
382
501
|
t.integer "position"
|
383
502
|
t.datetime "created_at", :null => false
|
384
503
|
t.datetime "updated_at", :null => false
|
385
504
|
end
|
386
505
|
|
506
|
+
add_index "owns", ["agent_id"], :name => "index_owns_on_agent_id"
|
387
507
|
add_index "owns", ["item_id"], :name => "index_owns_on_item_id"
|
388
|
-
add_index "owns", ["patron_id"], :name => "index_owns_on_patron_id"
|
389
|
-
|
390
|
-
create_table "patron_import_files", :force => true do |t|
|
391
|
-
t.integer "parent_id"
|
392
|
-
t.string "content_type"
|
393
|
-
t.integer "size"
|
394
|
-
t.integer "user_id"
|
395
|
-
t.text "note"
|
396
|
-
t.datetime "executed_at"
|
397
|
-
t.string "state"
|
398
|
-
t.string "patron_import_file_name"
|
399
|
-
t.string "patron_import_content_type"
|
400
|
-
t.integer "patron_import_file_size"
|
401
|
-
t.datetime "patron_import_updated_at"
|
402
|
-
t.datetime "created_at", :null => false
|
403
|
-
t.datetime "updated_at", :null => false
|
404
|
-
t.string "patron_import_fingerprint"
|
405
|
-
t.text "error_message"
|
406
|
-
t.string "edit_mode"
|
407
|
-
end
|
408
|
-
|
409
|
-
add_index "patron_import_files", ["parent_id"], :name => "index_patron_import_files_on_parent_id"
|
410
|
-
add_index "patron_import_files", ["state"], :name => "index_patron_import_files_on_state"
|
411
|
-
add_index "patron_import_files", ["user_id"], :name => "index_patron_import_files_on_user_id"
|
412
|
-
|
413
|
-
create_table "patron_import_results", :force => true do |t|
|
414
|
-
t.integer "patron_import_file_id"
|
415
|
-
t.integer "patron_id"
|
416
|
-
t.integer "user_id"
|
417
|
-
t.text "body"
|
418
|
-
t.datetime "created_at", :null => false
|
419
|
-
t.datetime "updated_at", :null => false
|
420
|
-
end
|
421
|
-
|
422
|
-
create_table "patron_relationship_types", :force => true do |t|
|
423
|
-
t.string "name", :null => false
|
424
|
-
t.text "display_name"
|
425
|
-
t.text "note"
|
426
|
-
t.integer "position"
|
427
|
-
t.datetime "created_at", :null => false
|
428
|
-
t.datetime "updated_at", :null => false
|
429
|
-
end
|
430
|
-
|
431
|
-
create_table "patron_relationships", :force => true do |t|
|
432
|
-
t.integer "parent_id"
|
433
|
-
t.integer "child_id"
|
434
|
-
t.integer "patron_relationship_type_id"
|
435
|
-
t.datetime "created_at", :null => false
|
436
|
-
t.datetime "updated_at", :null => false
|
437
|
-
t.integer "position"
|
438
|
-
end
|
439
|
-
|
440
|
-
add_index "patron_relationships", ["child_id"], :name => "index_patron_relationships_on_child_id"
|
441
|
-
add_index "patron_relationships", ["parent_id"], :name => "index_patron_relationships_on_parent_id"
|
442
|
-
|
443
|
-
create_table "patron_types", :force => true do |t|
|
444
|
-
t.string "name", :null => false
|
445
|
-
t.text "display_name"
|
446
|
-
t.text "note"
|
447
|
-
t.integer "position"
|
448
|
-
t.datetime "created_at", :null => false
|
449
|
-
t.datetime "updated_at", :null => false
|
450
|
-
end
|
451
|
-
|
452
|
-
create_table "patrons", :force => true do |t|
|
453
|
-
t.integer "user_id"
|
454
|
-
t.string "last_name"
|
455
|
-
t.string "middle_name"
|
456
|
-
t.string "first_name"
|
457
|
-
t.string "last_name_transcription"
|
458
|
-
t.string "middle_name_transcription"
|
459
|
-
t.string "first_name_transcription"
|
460
|
-
t.string "corporate_name"
|
461
|
-
t.string "corporate_name_transcription"
|
462
|
-
t.string "full_name"
|
463
|
-
t.text "full_name_transcription"
|
464
|
-
t.text "full_name_alternative"
|
465
|
-
t.datetime "created_at", :null => false
|
466
|
-
t.datetime "updated_at", :null => false
|
467
|
-
t.datetime "deleted_at"
|
468
|
-
t.string "zip_code_1"
|
469
|
-
t.string "zip_code_2"
|
470
|
-
t.text "address_1"
|
471
|
-
t.text "address_2"
|
472
|
-
t.text "address_1_note"
|
473
|
-
t.text "address_2_note"
|
474
|
-
t.string "telephone_number_1"
|
475
|
-
t.string "telephone_number_2"
|
476
|
-
t.string "fax_number_1"
|
477
|
-
t.string "fax_number_2"
|
478
|
-
t.text "other_designation"
|
479
|
-
t.text "place"
|
480
|
-
t.string "postal_code"
|
481
|
-
t.text "street"
|
482
|
-
t.text "locality"
|
483
|
-
t.text "region"
|
484
|
-
t.datetime "date_of_birth"
|
485
|
-
t.datetime "date_of_death"
|
486
|
-
t.integer "language_id", :default => 1, :null => false
|
487
|
-
t.integer "country_id", :default => 1, :null => false
|
488
|
-
t.integer "patron_type_id", :default => 1, :null => false
|
489
|
-
t.integer "lock_version", :default => 0, :null => false
|
490
|
-
t.text "note"
|
491
|
-
t.integer "required_role_id", :default => 1, :null => false
|
492
|
-
t.integer "required_score", :default => 0, :null => false
|
493
|
-
t.string "state"
|
494
|
-
t.text "email"
|
495
|
-
t.text "url"
|
496
|
-
t.text "full_name_alternative_transcription"
|
497
|
-
t.string "birth_date"
|
498
|
-
t.string "death_date"
|
499
|
-
t.string "patron_identifier"
|
500
|
-
end
|
501
|
-
|
502
|
-
add_index "patrons", ["country_id"], :name => "index_patrons_on_country_id"
|
503
|
-
add_index "patrons", ["full_name"], :name => "index_patrons_on_full_name"
|
504
|
-
add_index "patrons", ["language_id"], :name => "index_patrons_on_language_id"
|
505
|
-
add_index "patrons", ["patron_identifier"], :name => "index_patrons_on_patron_identifier"
|
506
|
-
add_index "patrons", ["required_role_id"], :name => "index_patrons_on_required_role_id"
|
507
|
-
add_index "patrons", ["user_id"], :name => "index_patrons_on_user_id", :unique => true
|
508
508
|
|
509
509
|
create_table "picture_files", :force => true do |t|
|
510
510
|
t.integer "picture_attachable_id"
|
@@ -535,7 +535,7 @@ ActiveRecord::Schema.define(:version => 20130221154434) do
|
|
535
535
|
end
|
536
536
|
|
537
537
|
create_table "produces", :force => true do |t|
|
538
|
-
t.integer "
|
538
|
+
t.integer "agent_id", :null => false
|
539
539
|
t.integer "manifestation_id", :null => false
|
540
540
|
t.integer "position"
|
541
541
|
t.datetime "created_at", :null => false
|
@@ -543,8 +543,8 @@ ActiveRecord::Schema.define(:version => 20130221154434) do
|
|
543
543
|
t.integer "produce_type_id"
|
544
544
|
end
|
545
545
|
|
546
|
+
add_index "produces", ["agent_id"], :name => "index_produces_on_agent_id"
|
546
547
|
add_index "produces", ["manifestation_id"], :name => "index_produces_on_manifestation_id"
|
547
|
-
add_index "produces", ["patron_id"], :name => "index_produces_on_patron_id"
|
548
548
|
|
549
549
|
create_table "realize_types", :force => true do |t|
|
550
550
|
t.string "name"
|
@@ -556,7 +556,7 @@ ActiveRecord::Schema.define(:version => 20130221154434) do
|
|
556
556
|
end
|
557
557
|
|
558
558
|
create_table "realizes", :force => true do |t|
|
559
|
-
t.integer "
|
559
|
+
t.integer "agent_id", :null => false
|
560
560
|
t.integer "expression_id", :null => false
|
561
561
|
t.integer "position"
|
562
562
|
t.datetime "created_at", :null => false
|
@@ -564,8 +564,8 @@ ActiveRecord::Schema.define(:version => 20130221154434) do
|
|
564
564
|
t.integer "realize_type_id"
|
565
565
|
end
|
566
566
|
|
567
|
+
add_index "realizes", ["agent_id"], :name => "index_realizes_on_agent_id"
|
567
568
|
add_index "realizes", ["expression_id"], :name => "index_realizes_on_expression_id"
|
568
|
-
add_index "realizes", ["patron_id"], :name => "index_realizes_on_patron_id"
|
569
569
|
|
570
570
|
create_table "request_status_types", :force => true do |t|
|
571
571
|
t.string "name", :null => false
|
data/spec/dummy/db/test.sqlite3
CHANGED
Binary file
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
Binary file
|
Binary file
|
@@ -1,13 +1,13 @@
|
|
1
1
|
FactoryGirl.define do
|
2
|
-
factory :
|
2
|
+
factory :agent do |f|
|
3
3
|
f.sequence(:full_name){|n| "full_name_#{n}"}
|
4
|
-
f.
|
4
|
+
f.agent_type_id{AgentType.find_by_name('Person').id}
|
5
5
|
f.country_id{Country.first.id}
|
6
6
|
f.language_id{Language.first.id}
|
7
7
|
end
|
8
8
|
end
|
9
9
|
|
10
10
|
FactoryGirl.define do
|
11
|
-
factory :
|
11
|
+
factory :invalid_agent, :class => Agent do |f|
|
12
12
|
end
|
13
13
|
end
|
data/spec/factories/create.rb
CHANGED
data/spec/factories/donate.rb
CHANGED
data/spec/factories/own.rb
CHANGED
data/spec/factories/produce.rb
CHANGED