enju_biblio 0.3.2 → 0.3.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/manifestations_controller.rb +1 -1
- data/app/jobs/agent_import_file_job.rb +1 -1
- data/app/jobs/resource_export_file_job.rb +1 -1
- data/app/jobs/resource_import_file_job.rb +1 -1
- data/app/mailers/agent_import_mailer.rb +17 -0
- data/app/mailers/resource_export_mailer.rb +17 -0
- data/app/mailers/resource_import_mailer.rb +17 -0
- data/app/models/agent.rb +4 -4
- data/app/models/agent_import_file.rb +13 -1
- data/app/models/agent_import_file_transition.rb +1 -1
- data/app/models/agent_import_result.rb +1 -1
- data/app/models/agent_merge.rb +1 -1
- data/app/models/agent_merge_list.rb +1 -1
- data/app/models/agent_relationship.rb +1 -1
- data/app/models/agent_relationship_type.rb +1 -1
- data/app/models/agent_type.rb +1 -1
- data/app/models/carrier_type.rb +1 -1
- data/app/models/content_type.rb +1 -1
- data/app/models/country.rb +1 -1
- data/app/models/create.rb +1 -1
- data/app/models/create_type.rb +1 -1
- data/app/models/donate.rb +1 -1
- data/app/models/form_of_work.rb +1 -1
- data/app/models/frequency.rb +1 -1
- data/app/models/identifier.rb +1 -1
- data/app/models/identifier_type.rb +1 -1
- data/app/models/import_request.rb +1 -1
- data/app/models/import_request_transition.rb +1 -1
- data/app/models/item.rb +3 -3
- data/app/models/language.rb +2 -18
- data/app/models/license.rb +1 -1
- data/app/models/manifestation.rb +16 -4
- data/app/models/manifestation_relationship.rb +1 -1
- data/app/models/manifestation_relationship_type.rb +1 -1
- data/app/models/medium_of_performance.rb +1 -1
- data/app/models/own.rb +1 -1
- data/app/models/picture_file.rb +1 -1
- data/app/models/produce.rb +1 -1
- data/app/models/produce_type.rb +1 -1
- data/app/models/realize.rb +1 -1
- data/app/models/realize_type.rb +1 -1
- data/app/models/resource_export_file.rb +6 -4
- data/app/models/resource_export_file_transition.rb +1 -1
- data/app/models/resource_import_file.rb +30 -6
- data/app/models/resource_import_file_transition.rb +1 -1
- data/app/models/resource_import_result.rb +1 -1
- data/app/models/series_statement.rb +1 -1
- data/app/models/series_statement_merge.rb +1 -1
- data/app/models/series_statement_merge_list.rb +1 -1
- data/app/views/agent_import_mailer/completed.en.text.erb +9 -0
- data/app/views/agent_import_mailer/completed.ja.text.erb +9 -0
- data/app/views/agent_import_mailer/failed.en.text +9 -0
- data/app/views/agent_import_mailer/failed.ja.text.erb +9 -0
- data/app/views/items/show.html+phone.erb +0 -9
- data/app/views/items/show.html.erb +0 -12
- data/app/views/manifestations/_manifestation.json.jbuilder +53 -0
- data/app/views/manifestations/index.json.jbuilder +6 -0
- data/app/views/picture_files/edit.html.erb +2 -22
- data/app/views/resource_export_mailer/completed.en.text.erb +9 -0
- data/app/views/resource_export_mailer/completed.ja.text.erb +9 -0
- data/app/views/resource_export_mailer/failed.en.text.erb +9 -0
- data/app/views/resource_export_mailer/failed.ja.text.erb +9 -0
- data/app/views/resource_import_mailer/completed.en.text.erb +9 -0
- data/app/views/resource_import_mailer/completed.ja.text.erb +9 -0
- data/app/views/resource_import_mailer/failed.en.text.erb +9 -0
- data/app/views/resource_import_mailer/failed.ja.text.erb +9 -0
- data/config/locales/translation_en.yml +11 -0
- data/config/locales/translation_ja.yml +11 -0
- data/lib/enju_biblio/version.rb +1 -1
- data/spec/controllers/items_controller_spec.rb +0 -37
- data/spec/dummy/app/jobs/application_job.rb +7 -0
- data/spec/dummy/app/mailers/application_mailer.rb +4 -0
- data/spec/dummy/app/models/application_record.rb +3 -0
- data/spec/dummy/app/models/user.rb +1 -7
- data/spec/dummy/config/application.rb +2 -1
- data/spec/dummy/db/migrate/029_create_subjects.rb +3 -6
- data/spec/dummy/db/migrate/032_create_checkins.rb +3 -6
- data/spec/dummy/db/migrate/033_create_checkouts.rb +6 -11
- data/spec/dummy/db/migrate/035_create_reserves.rb +4 -9
- data/spec/dummy/db/migrate/121_create_checked_items.rb +3 -4
- data/spec/dummy/db/migrate/129_create_item_has_use_restrictions.rb +2 -4
- data/spec/dummy/db/migrate/20081030023518_create_user_group_has_checkout_types.rb +2 -4
- data/spec/dummy/db/migrate/20081030023615_create_carrier_type_has_checkout_types.rb +2 -3
- data/spec/dummy/db/migrate/20081212075554_create_checkout_stat_has_manifestations.rb +2 -2
- data/spec/dummy/db/migrate/20081215094955_create_checkout_stat_has_users.rb +2 -4
- data/spec/dummy/db/migrate/20081216190517_create_reserve_stat_has_manifestations.rb +2 -2
- data/spec/dummy/db/migrate/20081220034117_create_reserve_stat_has_users.rb +2 -4
- data/spec/dummy/db/migrate/20090831220301_create_lending_policies.rb +3 -3
- data/spec/dummy/db/migrate/20100606065209_create_user_has_roles.rb +2 -4
- data/spec/dummy/db/migrate/20110627122938_add_number_of_day_to_notify_overdue_to_user_group.rb +2 -2
- data/spec/dummy/db/migrate/20111129044509_add_pickup_location_to_reserve.rb +6 -0
- data/spec/dummy/db/migrate/20120424103932_add_librarian_id_to_checked_item.rb +1 -1
- data/spec/dummy/db/migrate/20130221154434_add_additional_attributes_to_user.rb +1 -1
- data/spec/dummy/db/migrate/20140122054321_create_profiles.rb +4 -5
- data/spec/dummy/db/migrate/20140518050147_create_reserve_transitions.rb +1 -1
- data/spec/dummy/db/migrate/20140524074813_create_user_import_file_transitions.rb +1 -1
- data/spec/dummy/db/migrate/20140528045518_create_user_checkout_stat_transitions.rb +1 -1
- data/spec/dummy/db/migrate/20140528045539_create_user_reserve_stat_transitions.rb +1 -1
- data/spec/dummy/db/migrate/20140528045600_create_manifestation_checkout_stat_transitions.rb +1 -1
- data/spec/dummy/db/migrate/20140528045617_create_manifestation_reserve_stat_transitions.rb +1 -1
- data/spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb +1 -1
- data/spec/dummy/db/migrate/20140810061942_add_user_id_to_user_checkout_stat.rb +4 -8
- data/spec/dummy/db/migrate/20141014065831_add_shelf_id_to_checkout.rb +1 -2
- data/spec/dummy/db/migrate/20141020120523_add_library_id_to_checkout.rb +5 -0
- data/spec/dummy/db/migrate/20150106001709_create_demands.rb +11 -0
- data/spec/dummy/db/migrate/20150421023923_create_identities.rb +14 -0
- data/spec/dummy/db/migrate/20150923173139_add_url_to_classification.rb +5 -0
- data/spec/dummy/db/migrate/20150925092505_add_label_to_classification.rb +5 -0
- data/spec/dummy/db/migrate/20151126005552_add_provider_to_identity.rb +5 -0
- data/spec/dummy/db/migrate/20151213070943_add_translation_table_to_library_group.rb +4 -11
- data/spec/dummy/db/migrate/20180107160726_add_constraints_to_most_recent_for_user_import_file_transitions.rb +1 -1
- data/spec/dummy/db/migrate/20180107160740_add_constraints_to_most_recent_for_user_export_file_transitions.rb +1 -1
- data/spec/dummy/db/migrate/20180107161035_add_constraints_to_most_recent_for_reserve_transitions.rb +13 -0
- data/spec/dummy/db/migrate/20180107161951_add_constraints_to_most_recent_for_user_checkout_stat_transitions.rb +13 -0
- data/spec/dummy/db/migrate/20180107162009_add_constraints_to_most_recent_for_user_reserve_stat_transitions.rb +13 -0
- data/spec/dummy/db/migrate/20180107162029_add_constraints_to_most_recent_for_manifestation_checkout_stat_transitions.rb +13 -0
- data/spec/dummy/db/migrate/20180107162048_add_constraints_to_most_recent_for_manifestation_reserve_stat_transitions.rb +13 -0
- data/spec/dummy/db/schema.rb +51 -12
- data/spec/factories/agent.rb +1 -1
- data/spec/factories/identifier.rb +1 -0
- data/spec/factories/item.rb +0 -1
- data/spec/fixtures/reserve_transitions.yml +23 -7
- data/spec/mailers/agent_import_spec.rb +5 -0
- data/spec/mailers/previews/agent_import_preview.rb +4 -0
- data/spec/mailers/previews/resource_export_preview.rb +4 -0
- data/spec/mailers/previews/resource_import_preview.rb +4 -0
- data/spec/mailers/resource_export_spec.rb +5 -0
- data/spec/mailers/resource_import_spec.rb +5 -0
- data/spec/models/agent_spec.rb +1 -1
- data/spec/models/item_spec.rb +0 -41
- data/spec/models/manifestation_spec.rb +0 -32
- data/spec/models/resource_export_file_spec.rb +2 -26
- data/spec/models/resource_import_file_spec.rb +2 -2
- data/spec/policies/manifestation_policy_spec.rb +2 -5
- data/spec/views/items/index.html.erb_spec.rb +3 -10
- data/spec/views/manifestations/show.html.erb_spec.rb +1 -5
- metadata +121 -26
- data/spec/factories/checkout.rb +0 -9
- data/spec/fixtures/checked_items.yml +0 -35
- data/spec/fixtures/checkins.yml +0 -48
- data/spec/fixtures/checkouts.yml +0 -162
- data/spec/fixtures/item_has_use_restrictions.yml +0 -61
- data/spec/fixtures/lending_policies.yml +0 -92
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2888d4c10b1fd92841241ecba36a6d2f7ea687d4c9f667db6460ae1231503c76
|
4
|
+
data.tar.gz: 528744242fa80482bb5c08328619d916ee481b9a6fd5209d705cbfd0b6079d1a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4dfd6f2cc2000df1e14f289c191e11f7124b1587547fa4df7fc03876472f7797773cd15fd399ae8481b2dfc2a1394bf2345403f509b7555e13ccec4a19e7d452
|
7
|
+
data.tar.gz: a2f56218856579f419fa8759b4cf57c9b75aee8b43f4524b53fd0daab0b4289e9aac6ab76adf85ee98bce277c5b928f020b03e656ec100c3b3938e557d6f0875
|
@@ -0,0 +1,17 @@
|
|
1
|
+
class AgentImportMailer < ApplicationMailer
|
2
|
+
def completed(agent_import_file)
|
3
|
+
@agent_import_file = agent_import_file
|
4
|
+
@library_group = LibraryGroup.site_config
|
5
|
+
from = "#{LibraryGroup.system_name(agent_import_file.user.profile.locale)} <#{@library_group.user.email}>"
|
6
|
+
subject = "#{I18n.t('agent_import_mailer.completed.subject')}: #{@agent_import_file.id}"
|
7
|
+
mail(from: from, to: agent_import_file.user.email, subject: subject)
|
8
|
+
end
|
9
|
+
|
10
|
+
def failed(agent_import_file)
|
11
|
+
@agent_import_file = agent_import_file
|
12
|
+
@library_group = LibraryGroup.site_config
|
13
|
+
from = "#{LibraryGroup.system_name(agent_import_file.user.profile.locale)} <#{@library_group.user.email}>"
|
14
|
+
subject = "#{I18n.t('agent_import_mailer.failed.subject')}: #{@agent_import_file.id}"
|
15
|
+
mail(from: from, to: agent_import_file.user.email, subject: subject)
|
16
|
+
end
|
17
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
class ResourceExportMailer < ApplicationMailer
|
2
|
+
def completed(resource_export_file)
|
3
|
+
@resource_export_file = resource_export_file
|
4
|
+
@library_group = LibraryGroup.site_config
|
5
|
+
from = "#{LibraryGroup.system_name(resource_export_file.user.profile.locale)} <#{@library_group.user.email}>"
|
6
|
+
subject = "#{I18n.t('resource_export_mailer.completed.subject')}: #{@resource_export_file.id}"
|
7
|
+
mail(from: from, to: resource_export_file.user.email, subject: subject)
|
8
|
+
end
|
9
|
+
|
10
|
+
def failed(resource_export_file)
|
11
|
+
@resource_export_file = resource_export_file
|
12
|
+
@library_group = LibraryGroup.site_config
|
13
|
+
from = "#{LibraryGroup.system_name(resource_export_file.user.profile.locale)} <#{@library_group.user.email}>"
|
14
|
+
subject = "#{I18n.t('resource_export_mailer.failed.subject')}: #{@resource_export_file.id}"
|
15
|
+
mail(from: from, to: resource_export_file.user.email, subject: subject)
|
16
|
+
end
|
17
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
class ResourceImportMailer < ApplicationMailer
|
2
|
+
def completed(resource_import_file)
|
3
|
+
@resource_import_file = resource_import_file
|
4
|
+
@library_group = LibraryGroup.site_config
|
5
|
+
from = "#{LibraryGroup.system_name(resource_import_file.user.profile.locale)} <#{@library_group.user.email}>"
|
6
|
+
subject = "#{I18n.t('resource_import_mailer.completed.subject')}: #{@resource_import_file.id}"
|
7
|
+
mail(from: from, to: resource_import_file.user.email, subject: subject)
|
8
|
+
end
|
9
|
+
|
10
|
+
def failed(resource_import_file)
|
11
|
+
@resource_import_file = resource_import_file
|
12
|
+
@library_group = LibraryGroup.site_config
|
13
|
+
from = "#{LibraryGroup.system_name(resource_import_file.user.profile.locale)} <#{@library_group.user.email}>"
|
14
|
+
subject = "#{I18n.t('resource_import_mailer.failed.subject')}: #{@resource_import_file.id}"
|
15
|
+
mail(from: from, to: resource_import_file.user.email, subject: subject)
|
16
|
+
end
|
17
|
+
end
|
data/app/models/agent.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
class Agent <
|
1
|
+
class Agent < ApplicationRecord
|
2
2
|
scope :readable_by, lambda{ |user|
|
3
3
|
if user
|
4
4
|
where('required_role_id <= ?', user.try(:user_has_role).try(:role_id))
|
@@ -17,7 +17,7 @@ class Agent < ActiveRecord::Base
|
|
17
17
|
has_many :derived_agents, through: :children, source: :child
|
18
18
|
has_many :original_agents, through: :parents, source: :parent
|
19
19
|
has_many :picture_files, as: :picture_attachable, dependent: :destroy
|
20
|
-
has_many :donates
|
20
|
+
has_many :donates, dependent: :destroy
|
21
21
|
has_many :donated_items, through: :donates, source: :item
|
22
22
|
has_many :owns, dependent: :destroy
|
23
23
|
has_many :items, through: :owns
|
@@ -97,7 +97,7 @@ class Agent < ActiveRecord::Base
|
|
97
97
|
def set_date_of_birth
|
98
98
|
return if birth_date.blank?
|
99
99
|
begin
|
100
|
-
date = Time.zone.parse(
|
100
|
+
date = Time.zone.parse(birth_date.to_s)
|
101
101
|
rescue ArgumentError
|
102
102
|
begin
|
103
103
|
date = Time.zone.parse("#{birth_date}-01")
|
@@ -115,7 +115,7 @@ class Agent < ActiveRecord::Base
|
|
115
115
|
def set_date_of_death
|
116
116
|
return if death_date.blank?
|
117
117
|
begin
|
118
|
-
date = Time.zone.parse(
|
118
|
+
date = Time.zone.parse(death_date.to_s)
|
119
119
|
rescue ArgumentError
|
120
120
|
begin
|
121
121
|
date = Time.zone.parse("#{death_date}-01")
|
@@ -1,4 +1,4 @@
|
|
1
|
-
class AgentImportFile <
|
1
|
+
class AgentImportFile < ApplicationRecord
|
2
2
|
include Statesman::Adapters::ActiveRecordQueries
|
3
3
|
include ImportFile
|
4
4
|
default_scope { order('agent_import_files.id DESC') }
|
@@ -88,10 +88,14 @@ class AgentImportFile < ActiveRecord::Base
|
|
88
88
|
Sunspot.commit
|
89
89
|
rows.close
|
90
90
|
transition_to!(:completed)
|
91
|
+
mailer = AgentImportMailer.completed(self)
|
92
|
+
send_message(mailer)
|
91
93
|
return num
|
92
94
|
rescue => e
|
93
95
|
self.error_message = "line #{row_num}: #{e.message}"
|
94
96
|
transition_to!(:failed)
|
97
|
+
mailer = AgentImportMailer.failed(self)
|
98
|
+
send_message(mailer)
|
95
99
|
raise e
|
96
100
|
end
|
97
101
|
|
@@ -128,9 +132,13 @@ class AgentImportFile < ActiveRecord::Base
|
|
128
132
|
end
|
129
133
|
end
|
130
134
|
transition_to!(:completed)
|
135
|
+
mailer = AgentImportMailer.completed(self)
|
136
|
+
send_message(mailer)
|
131
137
|
rescue => e
|
132
138
|
self.error_message = "line #{row_num}: #{e.message}"
|
133
139
|
transition_to!(:failed)
|
140
|
+
mailer = AgentImportMailer.failed(self)
|
141
|
+
send_message(mailer)
|
134
142
|
raise e
|
135
143
|
end
|
136
144
|
|
@@ -151,9 +159,13 @@ class AgentImportFile < ActiveRecord::Base
|
|
151
159
|
end
|
152
160
|
end
|
153
161
|
transition_to!(:completed)
|
162
|
+
mailer = AgentImportMailer.completed(self)
|
163
|
+
send_message(mailer)
|
154
164
|
rescue => e
|
155
165
|
self.error_message = "line #{row_num}: #{e.message}"
|
156
166
|
transition_to!(:failed)
|
167
|
+
mailer = AgentImportMailer.failed(self)
|
168
|
+
send_message(mailer)
|
157
169
|
raise e
|
158
170
|
end
|
159
171
|
|
data/app/models/agent_merge.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
class AgentRelationship <
|
1
|
+
class AgentRelationship < ApplicationRecord
|
2
2
|
belongs_to :parent, foreign_key: 'parent_id', class_name: 'Agent'
|
3
3
|
belongs_to :child, foreign_key: 'child_id', class_name: 'Agent'
|
4
4
|
belongs_to :agent_relationship_type, optional: true
|
data/app/models/agent_type.rb
CHANGED
data/app/models/carrier_type.rb
CHANGED
data/app/models/content_type.rb
CHANGED
data/app/models/country.rb
CHANGED
data/app/models/create.rb
CHANGED
data/app/models/create_type.rb
CHANGED
data/app/models/donate.rb
CHANGED
data/app/models/form_of_work.rb
CHANGED
data/app/models/frequency.rb
CHANGED
data/app/models/identifier.rb
CHANGED
data/app/models/item.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
class Item <
|
1
|
+
class Item < ApplicationRecord
|
2
2
|
scope :on_shelf, -> { includes(:shelf).references(:shelf).where('shelves.name != ?', 'web') }
|
3
3
|
scope :on_web, -> { includes(:shelf).references(:shelf).where('shelves.name = ?', 'web') }
|
4
4
|
scope :available, -> {}
|
@@ -10,7 +10,7 @@ class Item < ActiveRecord::Base
|
|
10
10
|
delegate :display_name, to: :shelf, prefix: true
|
11
11
|
has_many :owns
|
12
12
|
has_many :agents, through: :owns
|
13
|
-
has_many :donates
|
13
|
+
has_many :donates, dependent: :destroy
|
14
14
|
has_many :donors, through: :donates, source: :agent
|
15
15
|
has_one :resource_import_result
|
16
16
|
belongs_to :manifestation, touch: true
|
@@ -90,7 +90,7 @@ class Item < ActiveRecord::Base
|
|
90
90
|
def removable?
|
91
91
|
if defined?(EnjuCirculation)
|
92
92
|
return false if circulation_status.name == 'Removed'
|
93
|
-
return false if checkouts.
|
93
|
+
return false if checkouts.exists?
|
94
94
|
true
|
95
95
|
else
|
96
96
|
true
|
data/app/models/language.rb
CHANGED
@@ -1,29 +1,13 @@
|
|
1
|
-
class Language <
|
1
|
+
class Language < ApplicationRecord
|
2
2
|
include MasterModel
|
3
|
-
default_scope { order('languages.position') }
|
4
3
|
# If you wish to change the field names for brevity, feel free to enable/modify these.
|
5
4
|
# alias_attribute :iso1, :iso_639_1
|
6
5
|
# alias_attribute :iso2, :iso_639_2
|
7
6
|
# alias_attribute :iso3, :iso_639_3
|
8
7
|
|
9
8
|
# Validations
|
10
|
-
|
9
|
+
validates :iso_639_1, :iso_639_2, :iso_639_3, presence: true
|
11
10
|
validates :name, presence: true, format: { with: /\A[0-9A-Za-z][0-9A-Za-z_\-\s,]*[0-9a-z]\Z/ }
|
12
|
-
after_save :clear_available_languages_cache
|
13
|
-
after_destroy :clear_available_languages_cache
|
14
|
-
|
15
|
-
def self.all_cache
|
16
|
-
if Rails.env == 'production'
|
17
|
-
Rails.cache.fetch('language_all'){Language.all.to_a}
|
18
|
-
else
|
19
|
-
Language.all
|
20
|
-
end
|
21
|
-
end
|
22
|
-
|
23
|
-
def clear_available_languages_cache
|
24
|
-
Rails.cache.delete('language_all')
|
25
|
-
Rails.cache.delete('available_languages')
|
26
|
-
end
|
27
11
|
|
28
12
|
def self.available_languages
|
29
13
|
Language.where(iso_639_1: I18n.available_locales.map{|l| l.to_s}).order(:position)
|
data/app/models/license.rb
CHANGED
data/app/models/manifestation.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
class Manifestation <
|
1
|
+
class Manifestation < ApplicationRecord
|
2
2
|
enju_manifestation_viewer if defined?(EnjuManifestationViewer)
|
3
3
|
enju_ndl_ndl_search if defined?(EnjuNdl)
|
4
4
|
enju_loc_search if defined?(EnjuLoc)
|
@@ -678,16 +678,28 @@ class Manifestation < ActiveRecord::Base
|
|
678
678
|
when :Administrator, :Librarian
|
679
679
|
item_lines << i.bookstore.try(:name)
|
680
680
|
item_lines << i.budget_type.try(:name)
|
681
|
-
|
681
|
+
if defined?(EnjuCirtulation)
|
682
|
+
item_lines << Checkout.where(item_id: i.id).count
|
683
|
+
else
|
684
|
+
item_lines << ''
|
685
|
+
end
|
686
|
+
end
|
687
|
+
if defined?(EnjuCirtulation)
|
688
|
+
item_lines << i.circulation_status.try(:name)
|
689
|
+
else
|
690
|
+
item_lines << ''
|
682
691
|
end
|
683
|
-
item_lines << i.circulation_status.try(:name)
|
684
692
|
item_lines << i.shelf.name
|
685
693
|
item_lines << i.shelf.library.name
|
686
694
|
item_lines << i.created_at
|
687
695
|
item_lines << i.updated_at
|
688
696
|
case options[:role].to_sym
|
689
697
|
when :Administrator, :Librarian
|
690
|
-
|
698
|
+
if defined?(EnjuCirtulation)
|
699
|
+
item_lines << i.use_restriction.try(:name)
|
700
|
+
else
|
701
|
+
item_lines << ''
|
702
|
+
end
|
691
703
|
end
|
692
704
|
lines << item_lines
|
693
705
|
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
class ManifestationRelationship <
|
1
|
+
class ManifestationRelationship < ApplicationRecord
|
2
2
|
belongs_to :parent, foreign_key: 'parent_id', class_name: 'Manifestation'
|
3
3
|
belongs_to :child, foreign_key: 'child_id', class_name: 'Manifestation'
|
4
4
|
belongs_to :manifestation_relationship_type, optional: true
|
data/app/models/own.rb
CHANGED
data/app/models/picture_file.rb
CHANGED