enju_biblio 0.1.0.pre10 → 0.1.0.pre11
Sign up to get free protection for your applications and to get access to all the features.
- data/app/models/accept.rb +4 -3
- data/app/models/carrier_type.rb +4 -4
- data/app/models/content_type.rb +4 -4
- data/app/models/country.rb +2 -2
- data/app/models/create.rb +5 -6
- data/app/models/create_type.rb +3 -3
- data/app/models/donate.rb +5 -5
- data/app/models/exemplify.rb +5 -15
- data/app/models/extent.rb +4 -4
- data/app/models/form_of_work.rb +4 -4
- data/app/models/frequency.rb +4 -4
- data/app/models/import_request.rb +3 -3
- data/app/models/item.rb +13 -11
- data/app/models/language.rb +2 -2
- data/app/models/license.rb +4 -4
- data/app/models/manifestation.rb +55 -30
- data/app/models/manifestation_relationship.rb +3 -3
- data/app/models/manifestation_relationship_type.rb +4 -4
- data/app/models/medium_of_performance.rb +4 -4
- data/app/models/own.rb +5 -5
- data/app/models/patron.rb +10 -10
- data/app/models/patron_import_file.rb +11 -5
- data/app/models/patron_import_result.rb +3 -3
- data/app/models/patron_relationship.rb +3 -3
- data/app/models/patron_relationship_type.rb +4 -4
- data/app/models/patron_type.rb +4 -4
- data/app/models/picture_file.rb +3 -3
- data/app/models/produce.rb +5 -6
- data/app/models/produce_type.rb +3 -3
- data/app/models/realize.rb +5 -6
- data/app/models/realize_type.rb +3 -3
- data/app/models/resource_import_file.rb +64 -14
- data/app/models/resource_import_result.rb +3 -3
- data/app/models/series_has_manifestation.rb +3 -3
- data/app/models/series_statement.rb +16 -8
- data/app/models/series_statement_relationship.rb +13 -0
- data/db/migrate/20120516020924_add_online_isbn_to_manifestation.rb +5 -0
- data/db/migrate/20121116031206_add_fulltext_content_to_manifestation.rb +5 -0
- data/db/migrate/20121116033446_add_doi_to_manifestation.rb +6 -0
- data/db/migrate/20121119153944_add_manifestation_id_to_item.rb +5 -0
- data/lib/enju_biblio/version.rb +1 -1
- data/spec/dummy/db/development.sqlite3 +0 -0
- data/spec/dummy/db/migrate/20090831220301_create_lending_policies.rb +1 -1
- data/spec/dummy/db/schema.rb +13 -11
- data/spec/dummy/db/test.sqlite3 +0 -0
- data/spec/dummy/solr/data/test/index/segments.gen +0 -0
- data/spec/dummy/solr/data/test/index/segments_b72 +0 -0
- data/spec/fixtures/carrier_types.yml +4 -4
- data/spec/fixtures/content_types.yml +4 -4
- data/spec/fixtures/countries.yml +2 -2
- data/spec/fixtures/create_types.yml +3 -3
- data/spec/fixtures/creates.yml +5 -6
- data/spec/fixtures/donates.yml +5 -5
- data/spec/fixtures/exemplifies.yml +5 -6
- data/spec/fixtures/extents.yml +4 -4
- data/spec/fixtures/form_of_works.yml +4 -4
- data/spec/fixtures/frequencies.yml +4 -4
- data/spec/fixtures/import_requests.yml +3 -3
- data/spec/fixtures/items.yml +12 -10
- data/spec/fixtures/languages.yml +3 -3
- data/spec/fixtures/licenses.yml +4 -4
- data/spec/fixtures/manifestation_relationship_types.yml +4 -4
- data/spec/fixtures/manifestation_relationships.yml +3 -3
- data/spec/fixtures/manifestations.yml +17 -21
- data/spec/fixtures/medium_of_performances.yml +4 -4
- data/spec/fixtures/owns.yml +5 -5
- data/spec/fixtures/patron_import_files.yml +3 -3
- data/spec/fixtures/patron_import_results.yml +3 -3
- data/spec/fixtures/patron_relationship_types.yml +4 -4
- data/spec/fixtures/patron_relationships.yml +3 -3
- data/spec/fixtures/patron_types.yml +4 -4
- data/spec/fixtures/patrons.yml +10 -14
- data/spec/fixtures/picture_files.yml +3 -3
- data/spec/fixtures/produce_types.yml +3 -3
- data/spec/fixtures/produces.yml +5 -6
- data/spec/fixtures/realize_types.yml +3 -3
- data/spec/fixtures/realizes.yml +5 -6
- data/spec/fixtures/resource_import_files.yml +3 -3
- data/spec/fixtures/resource_import_results.yml +3 -3
- data/spec/fixtures/series_has_manifestations.yml +3 -3
- data/spec/fixtures/series_statements.yml +4 -5
- data/spec/fixtures/user_group_has_checkout_types.yml +1 -1
- data/spec/models/accept_spec.rb +4 -3
- data/spec/models/carrier_type_spec.rb +4 -4
- data/spec/models/content_type_spec.rb +4 -4
- data/spec/models/country_spec.rb +2 -2
- data/spec/models/create_spec.rb +5 -6
- data/spec/models/create_type_spec.rb +3 -3
- data/spec/models/donate_spec.rb +5 -5
- data/spec/models/exemplify_spec.rb +5 -5
- data/spec/models/extent_spec.rb +4 -4
- data/spec/models/form_of_work_spec.rb +4 -4
- data/spec/models/frequency_spec.rb +4 -4
- data/spec/models/import_request_spec.rb +3 -3
- data/spec/models/item_spec.rb +20 -10
- data/spec/models/language_spec.rb +2 -2
- data/spec/models/license_spec.rb +4 -4
- data/spec/models/manifestation_relationship_spec.rb +3 -3
- data/spec/models/manifestation_relationship_type_spec.rb +4 -4
- data/spec/models/manifestation_spec.rb +17 -14
- data/spec/models/medium_of_performance_spec.rb +4 -4
- data/spec/models/own_spec.rb +5 -5
- data/spec/models/patron_import_file_spec.rb +3 -3
- data/spec/models/patron_import_result_spec.rb +3 -3
- data/spec/models/patron_relationship_spec.rb +3 -3
- data/spec/models/patron_relationship_type_spec.rb +4 -4
- data/spec/models/patron_spec.rb +10 -15
- data/spec/models/patron_type_spec.rb +4 -4
- data/spec/models/picture_file_spec.rb +3 -3
- data/spec/models/produce_spec.rb +5 -6
- data/spec/models/produce_type_spec.rb +3 -3
- data/spec/models/realize_spec.rb +5 -6
- data/spec/models/realize_type_spec.rb +3 -3
- data/spec/models/resource_import_file_spec.rb +3 -3
- data/spec/models/resource_import_result_spec.rb +3 -3
- data/spec/models/series_has_manifestation_spec.rb +3 -3
- data/spec/models/series_statement_relationship_spec.rb +13 -0
- data/spec/models/series_statement_spec.rb +4 -5
- metadata +10 -6
- data/spec/dummy/solr/data/test/index/segments_8fm +0 -0
@@ -18,12 +18,12 @@ two:
|
|
18
18
|
#
|
19
19
|
# Table name: resource_import_results
|
20
20
|
#
|
21
|
-
# id :integer
|
21
|
+
# id :integer not null, primary key
|
22
22
|
# resource_import_file_id :integer
|
23
23
|
# manifestation_id :integer
|
24
24
|
# item_id :integer
|
25
25
|
# body :text
|
26
|
-
# created_at :datetime
|
27
|
-
# updated_at :datetime
|
26
|
+
# created_at :datetime not null
|
27
|
+
# updated_at :datetime not null
|
28
28
|
#
|
29
29
|
|
@@ -25,11 +25,11 @@ series_has_manifestation_00003:
|
|
25
25
|
#
|
26
26
|
# Table name: series_has_manifestations
|
27
27
|
#
|
28
|
-
# id :integer
|
28
|
+
# id :integer not null, primary key
|
29
29
|
# series_statement_id :integer
|
30
30
|
# manifestation_id :integer
|
31
31
|
# position :integer
|
32
|
-
# created_at :datetime
|
33
|
-
# updated_at :datetime
|
32
|
+
# created_at :datetime not null
|
33
|
+
# updated_at :datetime not null
|
34
34
|
#
|
35
35
|
|
@@ -21,24 +21,23 @@ three:
|
|
21
21
|
position: 3
|
22
22
|
root_manifestation_id: 201
|
23
23
|
|
24
|
-
|
25
24
|
# == Schema Information
|
26
25
|
#
|
27
26
|
# Table name: series_statements
|
28
27
|
#
|
29
|
-
# id :integer
|
28
|
+
# id :integer not null, primary key
|
30
29
|
# original_title :text
|
31
30
|
# numbering :text
|
32
31
|
# title_subseries :text
|
33
32
|
# numbering_subseries :text
|
34
33
|
# position :integer
|
35
|
-
# created_at :datetime
|
36
|
-
# updated_at :datetime
|
34
|
+
# created_at :datetime not null
|
35
|
+
# updated_at :datetime not null
|
37
36
|
# title_transcription :text
|
38
37
|
# title_alternative :text
|
39
38
|
# series_statement_identifier :string(255)
|
40
39
|
# issn :string(255)
|
41
|
-
# periodical :boolean
|
40
|
+
# periodical :boolean default(FALSE), not null
|
42
41
|
# root_manifestation_id :integer
|
43
42
|
# note :text
|
44
43
|
# title_subseries_transcription :text
|
data/spec/models/accept_spec.rb
CHANGED
@@ -8,15 +8,16 @@ describe Accept do
|
|
8
8
|
accept.item.circulation_status.name.should eq 'Available On Shelf'
|
9
9
|
end
|
10
10
|
end
|
11
|
+
|
11
12
|
# == Schema Information
|
12
13
|
#
|
13
14
|
# Table name: accepts
|
14
15
|
#
|
15
|
-
# id :integer
|
16
|
+
# id :integer not null, primary key
|
16
17
|
# basket_id :integer
|
17
18
|
# item_id :integer
|
18
19
|
# librarian_id :integer
|
19
|
-
# created_at :datetime
|
20
|
-
# updated_at :datetime
|
20
|
+
# created_at :datetime not null
|
21
|
+
# updated_at :datetime not null
|
21
22
|
#
|
22
23
|
|
@@ -14,12 +14,12 @@ end
|
|
14
14
|
#
|
15
15
|
# Table name: carrier_types
|
16
16
|
#
|
17
|
-
# id :integer
|
18
|
-
# name :string(255)
|
17
|
+
# id :integer not null, primary key
|
18
|
+
# name :string(255) not null
|
19
19
|
# display_name :text
|
20
20
|
# note :text
|
21
21
|
# position :integer
|
22
|
-
# created_at :datetime
|
23
|
-
# updated_at :datetime
|
22
|
+
# created_at :datetime not null
|
23
|
+
# updated_at :datetime not null
|
24
24
|
#
|
25
25
|
|
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: content_types
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# name :string(255)
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# name :string(255) not null
|
15
15
|
# display_name :text
|
16
16
|
# note :text
|
17
17
|
# position :integer
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
20
|
#
|
21
21
|
|
data/spec/models/country_spec.rb
CHANGED
@@ -10,8 +10,8 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: countries
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# name :string(255)
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# name :string(255) not null
|
15
15
|
# display_name :text
|
16
16
|
# alpha_2 :string(255)
|
17
17
|
# alpha_3 :string(255)
|
data/spec/models/create_spec.rb
CHANGED
@@ -6,17 +6,16 @@ describe Create do
|
|
6
6
|
|
7
7
|
end
|
8
8
|
|
9
|
-
|
10
9
|
# == Schema Information
|
11
10
|
#
|
12
11
|
# Table name: creates
|
13
12
|
#
|
14
|
-
# id :integer
|
15
|
-
# patron_id :integer
|
16
|
-
# work_id :integer
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# patron_id :integer not null
|
15
|
+
# work_id :integer not null
|
17
16
|
# position :integer
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
17
|
+
# created_at :datetime not null
|
18
|
+
# updated_at :datetime not null
|
20
19
|
# create_type_id :integer
|
21
20
|
#
|
22
21
|
|
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: create_types
|
12
12
|
#
|
13
|
-
# id :integer
|
13
|
+
# id :integer not null, primary key
|
14
14
|
# name :string(255)
|
15
15
|
# display_name :text
|
16
16
|
# note :text
|
17
17
|
# position :integer
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
20
|
#
|
21
21
|
|
data/spec/models/donate_spec.rb
CHANGED
@@ -10,10 +10,10 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: donates
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# patron_id :integer
|
15
|
-
# item_id :integer
|
16
|
-
# created_at :datetime
|
17
|
-
# updated_at :datetime
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# patron_id :integer not null
|
15
|
+
# item_id :integer not null
|
16
|
+
# created_at :datetime not null
|
17
|
+
# updated_at :datetime not null
|
18
18
|
#
|
19
19
|
|
@@ -19,11 +19,11 @@ end
|
|
19
19
|
#
|
20
20
|
# Table name: exemplifies
|
21
21
|
#
|
22
|
-
# id :integer
|
23
|
-
# manifestation_id :integer
|
24
|
-
# item_id :integer
|
22
|
+
# id :integer not null, primary key
|
23
|
+
# manifestation_id :integer not null
|
24
|
+
# item_id :integer not null
|
25
25
|
# position :integer
|
26
|
-
# created_at :datetime
|
27
|
-
# updated_at :datetime
|
26
|
+
# created_at :datetime not null
|
27
|
+
# updated_at :datetime not null
|
28
28
|
#
|
29
29
|
|
data/spec/models/extent_spec.rb
CHANGED
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: extents
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# name :string(255)
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# name :string(255) not null
|
15
15
|
# display_name :text
|
16
16
|
# note :text
|
17
17
|
# position :integer
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
20
|
#
|
21
21
|
|
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: form_of_works
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# name :string(255)
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# name :string(255) not null
|
15
15
|
# display_name :text
|
16
16
|
# note :text
|
17
17
|
# position :integer
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
20
|
#
|
21
21
|
|
@@ -13,12 +13,12 @@ end
|
|
13
13
|
#
|
14
14
|
# Table name: frequencies
|
15
15
|
#
|
16
|
-
# id :integer
|
17
|
-
# name :string(255)
|
16
|
+
# id :integer not null, primary key
|
17
|
+
# name :string(255) not null
|
18
18
|
# display_name :text
|
19
19
|
# note :text
|
20
20
|
# position :integer
|
21
|
-
# created_at :datetime
|
22
|
-
# updated_at :datetime
|
21
|
+
# created_at :datetime not null
|
22
|
+
# updated_at :datetime not null
|
23
23
|
#
|
24
24
|
|
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: import_requests
|
12
12
|
#
|
13
|
-
# id :integer
|
13
|
+
# id :integer not null, primary key
|
14
14
|
# isbn :string(255)
|
15
15
|
# state :string(255)
|
16
16
|
# manifestation_id :integer
|
17
17
|
# user_id :integer
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
20
|
#
|
21
21
|
|
data/spec/models/item_spec.rb
CHANGED
@@ -41,30 +41,40 @@ describe Item do
|
|
41
41
|
it "should not be able to checkout a removed item" do
|
42
42
|
Item.for_checkout.include?(items(:item_00023)).should be_false
|
43
43
|
end
|
44
|
+
|
45
|
+
it "should update lending policies" do
|
46
|
+
item = items(:item_00001)
|
47
|
+
item.checkout_type = CheckoutType.where(:name => 'serial').first
|
48
|
+
item.save
|
49
|
+
item.reload
|
50
|
+
item.lending_policies.where(:user_group_id => 1).first.loan_period.should eq 10
|
51
|
+
end
|
44
52
|
end
|
53
|
+
|
45
54
|
# == Schema Information
|
46
55
|
#
|
47
56
|
# Table name: items
|
48
57
|
#
|
49
|
-
# id :integer
|
58
|
+
# id :integer not null, primary key
|
50
59
|
# call_number :string(255)
|
51
60
|
# item_identifier :string(255)
|
52
|
-
# circulation_status_id :integer
|
53
|
-
# checkout_type_id :integer
|
54
|
-
# created_at :datetime
|
55
|
-
# updated_at :datetime
|
61
|
+
# circulation_status_id :integer default(5), not null
|
62
|
+
# checkout_type_id :integer default(1), not null
|
63
|
+
# created_at :datetime not null
|
64
|
+
# updated_at :datetime not null
|
56
65
|
# deleted_at :datetime
|
57
|
-
# shelf_id :integer
|
58
|
-
# include_supplements :boolean
|
66
|
+
# shelf_id :integer default(1), not null
|
67
|
+
# include_supplements :boolean default(FALSE), not null
|
59
68
|
# note :text
|
60
69
|
# url :string(255)
|
61
70
|
# price :integer
|
62
|
-
# lock_version :integer
|
63
|
-
# required_role_id :integer
|
71
|
+
# lock_version :integer default(0), not null
|
72
|
+
# required_role_id :integer default(1), not null
|
64
73
|
# state :string(255)
|
65
|
-
# required_score :integer
|
74
|
+
# required_score :integer default(0), not null
|
66
75
|
# acquired_at :datetime
|
67
76
|
# bookstore_id :integer
|
68
77
|
# budget_type_id :integer
|
78
|
+
# manifestation_id :integer
|
69
79
|
#
|
70
80
|
|
@@ -10,8 +10,8 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: languages
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# name :string(255)
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# name :string(255) not null
|
15
15
|
# native_name :string(255)
|
16
16
|
# display_name :text
|
17
17
|
# iso_639_1 :string(255)
|
data/spec/models/license_spec.rb
CHANGED
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: licenses
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# name :string(255)
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# name :string(255) not null
|
15
15
|
# display_name :string(255)
|
16
16
|
# note :text
|
17
17
|
# position :integer
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
20
|
#
|
21
21
|
|
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: manifestation_relationships
|
12
12
|
#
|
13
|
-
# id :integer
|
13
|
+
# id :integer not null, primary key
|
14
14
|
# parent_id :integer
|
15
15
|
# child_id :integer
|
16
16
|
# manifestation_relationship_type_id :integer
|
17
|
-
# created_at :datetime
|
18
|
-
# updated_at :datetime
|
17
|
+
# created_at :datetime not null
|
18
|
+
# updated_at :datetime not null
|
19
19
|
# position :integer
|
20
20
|
#
|
21
21
|
|
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: manifestation_relationship_types
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# name :string(255)
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# name :string(255) not null
|
15
15
|
# display_name :text
|
16
16
|
# note :text
|
17
17
|
# position :integer
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
20
|
#
|
21
21
|
|
@@ -235,21 +235,21 @@ end
|
|
235
235
|
#
|
236
236
|
# Table name: manifestations
|
237
237
|
#
|
238
|
-
# id :integer
|
239
|
-
# original_title :text
|
238
|
+
# id :integer not null, primary key
|
239
|
+
# original_title :text not null
|
240
240
|
# title_alternative :text
|
241
241
|
# title_transcription :text
|
242
242
|
# classification_number :string(255)
|
243
243
|
# manifestation_identifier :string(255)
|
244
244
|
# date_of_publication :datetime
|
245
245
|
# date_copyrighted :datetime
|
246
|
-
# created_at :datetime
|
247
|
-
# updated_at :datetime
|
246
|
+
# created_at :datetime not null
|
247
|
+
# updated_at :datetime not null
|
248
248
|
# deleted_at :datetime
|
249
249
|
# access_address :string(255)
|
250
|
-
# language_id :integer
|
251
|
-
# carrier_type_id :integer
|
252
|
-
# extent_id :integer
|
250
|
+
# language_id :integer default(1), not null
|
251
|
+
# carrier_type_id :integer default(1), not null
|
252
|
+
# extent_id :integer default(1), not null
|
253
253
|
# start_page :integer
|
254
254
|
# end_page :integer
|
255
255
|
# height :integer
|
@@ -269,13 +269,13 @@ end
|
|
269
269
|
# serial_number_string :string(255)
|
270
270
|
# edition :integer
|
271
271
|
# note :text
|
272
|
-
# repository_content :boolean
|
273
|
-
# lock_version :integer
|
274
|
-
# required_role_id :integer
|
272
|
+
# repository_content :boolean default(FALSE), not null
|
273
|
+
# lock_version :integer default(0), not null
|
274
|
+
# required_role_id :integer default(1), not null
|
275
275
|
# state :string(255)
|
276
|
-
# required_score :integer
|
277
|
-
# frequency_id :integer
|
278
|
-
# subscription_master :boolean
|
276
|
+
# required_score :integer default(0), not null
|
277
|
+
# frequency_id :integer default(1), not null
|
278
|
+
# subscription_master :boolean default(FALSE), not null
|
279
279
|
# attachment_file_name :string(255)
|
280
280
|
# attachment_content_type :string(255)
|
281
281
|
# attachment_file_size :integer
|
@@ -294,9 +294,12 @@ end
|
|
294
294
|
# issue_number :integer
|
295
295
|
# serial_number :integer
|
296
296
|
# ndc :string(255)
|
297
|
-
# content_type_id :integer
|
297
|
+
# content_type_id :integer default(1)
|
298
298
|
# year_of_publication :integer
|
299
299
|
# attachment_meta :text
|
300
300
|
# month_of_publication :integer
|
301
|
+
# online_isbn :string(255)
|
302
|
+
# fulltext_content :boolean
|
303
|
+
# doi :string(255)
|
301
304
|
#
|
302
305
|
|
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: medium_of_performances
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# name :string(255)
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# name :string(255) not null
|
15
15
|
# display_name :text
|
16
16
|
# note :text
|
17
17
|
# position :integer
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
20
|
#
|
21
21
|
|
data/spec/models/own_spec.rb
CHANGED
@@ -10,11 +10,11 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: owns
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# patron_id :integer
|
15
|
-
# item_id :integer
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# patron_id :integer not null
|
15
|
+
# item_id :integer not null
|
16
16
|
# position :integer
|
17
|
-
# created_at :datetime
|
18
|
-
# updated_at :datetime
|
17
|
+
# created_at :datetime not null
|
18
|
+
# updated_at :datetime not null
|
19
19
|
#
|
20
20
|
|
@@ -75,7 +75,7 @@ end
|
|
75
75
|
#
|
76
76
|
# Table name: patron_import_files
|
77
77
|
#
|
78
|
-
# id :integer
|
78
|
+
# id :integer not null, primary key
|
79
79
|
# parent_id :integer
|
80
80
|
# content_type :string(255)
|
81
81
|
# size :integer
|
@@ -87,8 +87,8 @@ end
|
|
87
87
|
# patron_import_content_type :string(255)
|
88
88
|
# patron_import_file_size :integer
|
89
89
|
# patron_import_updated_at :datetime
|
90
|
-
# created_at :datetime
|
91
|
-
# updated_at :datetime
|
90
|
+
# created_at :datetime not null
|
91
|
+
# updated_at :datetime not null
|
92
92
|
# patron_import_fingerprint :string(255)
|
93
93
|
# error_message :text
|
94
94
|
# edit_mode :string(255)
|
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: patron_import_results
|
12
12
|
#
|
13
|
-
# id :integer
|
13
|
+
# id :integer not null, primary key
|
14
14
|
# patron_import_file_id :integer
|
15
15
|
# patron_id :integer
|
16
16
|
# user_id :integer
|
17
17
|
# body :text
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
20
|
#
|
21
21
|
|
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: patron_relationships
|
12
12
|
#
|
13
|
-
# id :integer
|
13
|
+
# id :integer not null, primary key
|
14
14
|
# parent_id :integer
|
15
15
|
# child_id :integer
|
16
16
|
# patron_relationship_type_id :integer
|
17
|
-
# created_at :datetime
|
18
|
-
# updated_at :datetime
|
17
|
+
# created_at :datetime not null
|
18
|
+
# updated_at :datetime not null
|
19
19
|
# position :integer
|
20
20
|
#
|
21
21
|
|
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: patron_relationship_types
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# name :string(255)
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# name :string(255) not null
|
15
15
|
# display_name :text
|
16
16
|
# note :text
|
17
17
|
# position :integer
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
20
|
#
|
21
21
|
|
data/spec/models/patron_spec.rb
CHANGED
@@ -42,17 +42,11 @@ describe Patron do
|
|
42
42
|
end
|
43
43
|
end
|
44
44
|
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
45
|
# == Schema Information
|
52
46
|
#
|
53
47
|
# Table name: patrons
|
54
48
|
#
|
55
|
-
# id :integer
|
49
|
+
# id :integer not null, primary key
|
56
50
|
# user_id :integer
|
57
51
|
# last_name :string(255)
|
58
52
|
# middle_name :string(255)
|
@@ -65,8 +59,8 @@ end
|
|
65
59
|
# full_name :string(255)
|
66
60
|
# full_name_transcription :text
|
67
61
|
# full_name_alternative :text
|
68
|
-
# created_at :datetime
|
69
|
-
# updated_at :datetime
|
62
|
+
# created_at :datetime not null
|
63
|
+
# updated_at :datetime not null
|
70
64
|
# deleted_at :datetime
|
71
65
|
# zip_code_1 :string(255)
|
72
66
|
# zip_code_2 :string(255)
|
@@ -86,18 +80,19 @@ end
|
|
86
80
|
# region :text
|
87
81
|
# date_of_birth :datetime
|
88
82
|
# date_of_death :datetime
|
89
|
-
# language_id :integer
|
90
|
-
# country_id :integer
|
91
|
-
# patron_type_id :integer
|
92
|
-
# lock_version :integer
|
83
|
+
# language_id :integer default(1), not null
|
84
|
+
# country_id :integer default(1), not null
|
85
|
+
# patron_type_id :integer default(1), not null
|
86
|
+
# lock_version :integer default(0), not null
|
93
87
|
# note :text
|
94
|
-
# required_role_id :integer
|
95
|
-
# required_score :integer
|
88
|
+
# required_role_id :integer default(1), not null
|
89
|
+
# required_score :integer default(0), not null
|
96
90
|
# state :string(255)
|
97
91
|
# email :text
|
98
92
|
# url :text
|
99
93
|
# full_name_alternative_transcription :text
|
100
94
|
# birth_date :string(255)
|
101
95
|
# death_date :string(255)
|
96
|
+
# patron_identifier :string(255)
|
102
97
|
#
|
103
98
|
|
@@ -10,12 +10,12 @@ end
|
|
10
10
|
#
|
11
11
|
# Table name: patron_types
|
12
12
|
#
|
13
|
-
# id :integer
|
14
|
-
# name :string(255)
|
13
|
+
# id :integer not null, primary key
|
14
|
+
# name :string(255) not null
|
15
15
|
# display_name :text
|
16
16
|
# note :text
|
17
17
|
# position :integer
|
18
|
-
# created_at :datetime
|
19
|
-
# updated_at :datetime
|
18
|
+
# created_at :datetime not null
|
19
|
+
# updated_at :datetime not null
|
20
20
|
#
|
21
21
|
|