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.
Files changed (144) hide show
  1. checksums.yaml +4 -4
  2. data/app/controllers/manifestations_controller.rb +1 -1
  3. data/app/jobs/agent_import_file_job.rb +1 -1
  4. data/app/jobs/resource_export_file_job.rb +1 -1
  5. data/app/jobs/resource_import_file_job.rb +1 -1
  6. data/app/mailers/agent_import_mailer.rb +17 -0
  7. data/app/mailers/resource_export_mailer.rb +17 -0
  8. data/app/mailers/resource_import_mailer.rb +17 -0
  9. data/app/models/agent.rb +4 -4
  10. data/app/models/agent_import_file.rb +13 -1
  11. data/app/models/agent_import_file_transition.rb +1 -1
  12. data/app/models/agent_import_result.rb +1 -1
  13. data/app/models/agent_merge.rb +1 -1
  14. data/app/models/agent_merge_list.rb +1 -1
  15. data/app/models/agent_relationship.rb +1 -1
  16. data/app/models/agent_relationship_type.rb +1 -1
  17. data/app/models/agent_type.rb +1 -1
  18. data/app/models/carrier_type.rb +1 -1
  19. data/app/models/content_type.rb +1 -1
  20. data/app/models/country.rb +1 -1
  21. data/app/models/create.rb +1 -1
  22. data/app/models/create_type.rb +1 -1
  23. data/app/models/donate.rb +1 -1
  24. data/app/models/form_of_work.rb +1 -1
  25. data/app/models/frequency.rb +1 -1
  26. data/app/models/identifier.rb +1 -1
  27. data/app/models/identifier_type.rb +1 -1
  28. data/app/models/import_request.rb +1 -1
  29. data/app/models/import_request_transition.rb +1 -1
  30. data/app/models/item.rb +3 -3
  31. data/app/models/language.rb +2 -18
  32. data/app/models/license.rb +1 -1
  33. data/app/models/manifestation.rb +16 -4
  34. data/app/models/manifestation_relationship.rb +1 -1
  35. data/app/models/manifestation_relationship_type.rb +1 -1
  36. data/app/models/medium_of_performance.rb +1 -1
  37. data/app/models/own.rb +1 -1
  38. data/app/models/picture_file.rb +1 -1
  39. data/app/models/produce.rb +1 -1
  40. data/app/models/produce_type.rb +1 -1
  41. data/app/models/realize.rb +1 -1
  42. data/app/models/realize_type.rb +1 -1
  43. data/app/models/resource_export_file.rb +6 -4
  44. data/app/models/resource_export_file_transition.rb +1 -1
  45. data/app/models/resource_import_file.rb +30 -6
  46. data/app/models/resource_import_file_transition.rb +1 -1
  47. data/app/models/resource_import_result.rb +1 -1
  48. data/app/models/series_statement.rb +1 -1
  49. data/app/models/series_statement_merge.rb +1 -1
  50. data/app/models/series_statement_merge_list.rb +1 -1
  51. data/app/views/agent_import_mailer/completed.en.text.erb +9 -0
  52. data/app/views/agent_import_mailer/completed.ja.text.erb +9 -0
  53. data/app/views/agent_import_mailer/failed.en.text +9 -0
  54. data/app/views/agent_import_mailer/failed.ja.text.erb +9 -0
  55. data/app/views/items/show.html+phone.erb +0 -9
  56. data/app/views/items/show.html.erb +0 -12
  57. data/app/views/manifestations/_manifestation.json.jbuilder +53 -0
  58. data/app/views/manifestations/index.json.jbuilder +6 -0
  59. data/app/views/picture_files/edit.html.erb +2 -22
  60. data/app/views/resource_export_mailer/completed.en.text.erb +9 -0
  61. data/app/views/resource_export_mailer/completed.ja.text.erb +9 -0
  62. data/app/views/resource_export_mailer/failed.en.text.erb +9 -0
  63. data/app/views/resource_export_mailer/failed.ja.text.erb +9 -0
  64. data/app/views/resource_import_mailer/completed.en.text.erb +9 -0
  65. data/app/views/resource_import_mailer/completed.ja.text.erb +9 -0
  66. data/app/views/resource_import_mailer/failed.en.text.erb +9 -0
  67. data/app/views/resource_import_mailer/failed.ja.text.erb +9 -0
  68. data/config/locales/translation_en.yml +11 -0
  69. data/config/locales/translation_ja.yml +11 -0
  70. data/lib/enju_biblio/version.rb +1 -1
  71. data/spec/controllers/items_controller_spec.rb +0 -37
  72. data/spec/dummy/app/jobs/application_job.rb +7 -0
  73. data/spec/dummy/app/mailers/application_mailer.rb +4 -0
  74. data/spec/dummy/app/models/application_record.rb +3 -0
  75. data/spec/dummy/app/models/user.rb +1 -7
  76. data/spec/dummy/config/application.rb +2 -1
  77. data/spec/dummy/db/migrate/029_create_subjects.rb +3 -6
  78. data/spec/dummy/db/migrate/032_create_checkins.rb +3 -6
  79. data/spec/dummy/db/migrate/033_create_checkouts.rb +6 -11
  80. data/spec/dummy/db/migrate/035_create_reserves.rb +4 -9
  81. data/spec/dummy/db/migrate/121_create_checked_items.rb +3 -4
  82. data/spec/dummy/db/migrate/129_create_item_has_use_restrictions.rb +2 -4
  83. data/spec/dummy/db/migrate/20081030023518_create_user_group_has_checkout_types.rb +2 -4
  84. data/spec/dummy/db/migrate/20081030023615_create_carrier_type_has_checkout_types.rb +2 -3
  85. data/spec/dummy/db/migrate/20081212075554_create_checkout_stat_has_manifestations.rb +2 -2
  86. data/spec/dummy/db/migrate/20081215094955_create_checkout_stat_has_users.rb +2 -4
  87. data/spec/dummy/db/migrate/20081216190517_create_reserve_stat_has_manifestations.rb +2 -2
  88. data/spec/dummy/db/migrate/20081220034117_create_reserve_stat_has_users.rb +2 -4
  89. data/spec/dummy/db/migrate/20090831220301_create_lending_policies.rb +3 -3
  90. data/spec/dummy/db/migrate/20100606065209_create_user_has_roles.rb +2 -4
  91. data/spec/dummy/db/migrate/20110627122938_add_number_of_day_to_notify_overdue_to_user_group.rb +2 -2
  92. data/spec/dummy/db/migrate/20111129044509_add_pickup_location_to_reserve.rb +6 -0
  93. data/spec/dummy/db/migrate/20120424103932_add_librarian_id_to_checked_item.rb +1 -1
  94. data/spec/dummy/db/migrate/20130221154434_add_additional_attributes_to_user.rb +1 -1
  95. data/spec/dummy/db/migrate/20140122054321_create_profiles.rb +4 -5
  96. data/spec/dummy/db/migrate/20140518050147_create_reserve_transitions.rb +1 -1
  97. data/spec/dummy/db/migrate/20140524074813_create_user_import_file_transitions.rb +1 -1
  98. data/spec/dummy/db/migrate/20140528045518_create_user_checkout_stat_transitions.rb +1 -1
  99. data/spec/dummy/db/migrate/20140528045539_create_user_reserve_stat_transitions.rb +1 -1
  100. data/spec/dummy/db/migrate/20140528045600_create_manifestation_checkout_stat_transitions.rb +1 -1
  101. data/spec/dummy/db/migrate/20140528045617_create_manifestation_reserve_stat_transitions.rb +1 -1
  102. data/spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb +1 -1
  103. data/spec/dummy/db/migrate/20140810061942_add_user_id_to_user_checkout_stat.rb +4 -8
  104. data/spec/dummy/db/migrate/20141014065831_add_shelf_id_to_checkout.rb +1 -2
  105. data/spec/dummy/db/migrate/20141020120523_add_library_id_to_checkout.rb +5 -0
  106. data/spec/dummy/db/migrate/20150106001709_create_demands.rb +11 -0
  107. data/spec/dummy/db/migrate/20150421023923_create_identities.rb +14 -0
  108. data/spec/dummy/db/migrate/20150923173139_add_url_to_classification.rb +5 -0
  109. data/spec/dummy/db/migrate/20150925092505_add_label_to_classification.rb +5 -0
  110. data/spec/dummy/db/migrate/20151126005552_add_provider_to_identity.rb +5 -0
  111. data/spec/dummy/db/migrate/20151213070943_add_translation_table_to_library_group.rb +4 -11
  112. data/spec/dummy/db/migrate/20180107160726_add_constraints_to_most_recent_for_user_import_file_transitions.rb +1 -1
  113. data/spec/dummy/db/migrate/20180107160740_add_constraints_to_most_recent_for_user_export_file_transitions.rb +1 -1
  114. data/spec/dummy/db/migrate/20180107161035_add_constraints_to_most_recent_for_reserve_transitions.rb +13 -0
  115. data/spec/dummy/db/migrate/20180107161951_add_constraints_to_most_recent_for_user_checkout_stat_transitions.rb +13 -0
  116. data/spec/dummy/db/migrate/20180107162009_add_constraints_to_most_recent_for_user_reserve_stat_transitions.rb +13 -0
  117. data/spec/dummy/db/migrate/20180107162029_add_constraints_to_most_recent_for_manifestation_checkout_stat_transitions.rb +13 -0
  118. data/spec/dummy/db/migrate/20180107162048_add_constraints_to_most_recent_for_manifestation_reserve_stat_transitions.rb +13 -0
  119. data/spec/dummy/db/schema.rb +51 -12
  120. data/spec/factories/agent.rb +1 -1
  121. data/spec/factories/identifier.rb +1 -0
  122. data/spec/factories/item.rb +0 -1
  123. data/spec/fixtures/reserve_transitions.yml +23 -7
  124. data/spec/mailers/agent_import_spec.rb +5 -0
  125. data/spec/mailers/previews/agent_import_preview.rb +4 -0
  126. data/spec/mailers/previews/resource_export_preview.rb +4 -0
  127. data/spec/mailers/previews/resource_import_preview.rb +4 -0
  128. data/spec/mailers/resource_export_spec.rb +5 -0
  129. data/spec/mailers/resource_import_spec.rb +5 -0
  130. data/spec/models/agent_spec.rb +1 -1
  131. data/spec/models/item_spec.rb +0 -41
  132. data/spec/models/manifestation_spec.rb +0 -32
  133. data/spec/models/resource_export_file_spec.rb +2 -26
  134. data/spec/models/resource_import_file_spec.rb +2 -2
  135. data/spec/policies/manifestation_policy_spec.rb +2 -5
  136. data/spec/views/items/index.html.erb_spec.rb +3 -10
  137. data/spec/views/manifestations/show.html.erb_spec.rb +1 -5
  138. metadata +121 -26
  139. data/spec/factories/checkout.rb +0 -9
  140. data/spec/fixtures/checked_items.yml +0 -35
  141. data/spec/fixtures/checkins.yml +0 -48
  142. data/spec/fixtures/checkouts.yml +0 -162
  143. data/spec/fixtures/item_has_use_restrictions.yml +0 -61
  144. data/spec/fixtures/lending_policies.yml +0 -92
@@ -1,4 +1,4 @@
1
- class Produce < ActiveRecord::Base
1
+ class Produce < ApplicationRecord
2
2
  belongs_to :agent
3
3
  belongs_to :manifestation, touch: true
4
4
  belongs_to :produce_type, optional: true
@@ -1,4 +1,4 @@
1
- class ProduceType < ActiveRecord::Base
1
+ class ProduceType < ApplicationRecord
2
2
  include MasterModel
3
3
  default_scope { order('produce_types.position') }
4
4
  end
@@ -1,4 +1,4 @@
1
- class Realize < ActiveRecord::Base
1
+ class Realize < ApplicationRecord
2
2
  belongs_to :agent
3
3
  belongs_to :expression, class_name: 'Manifestation', foreign_key: 'expression_id', touch: true
4
4
  belongs_to :realize_type, optional: true
@@ -1,4 +1,4 @@
1
- class RealizeType < ActiveRecord::Base
1
+ class RealizeType < ApplicationRecord
2
2
  include MasterModel
3
3
  default_scope { order('realize_types.position') }
4
4
  end
@@ -1,4 +1,4 @@
1
- class ResourceExportFile < ActiveRecord::Base
1
+ class ResourceExportFile < ApplicationRecord
2
2
  include Statesman::Adapters::ActiveRecordQueries
3
3
  include ExportFile
4
4
 
@@ -37,12 +37,14 @@ class ResourceExportFile < ActiveRecord::Base
37
37
  end
38
38
  tempfile.close
39
39
  self.resource_export = File.new(tempfile.path, "r")
40
- if save
41
- send_message
42
- end
40
+ save!
43
41
  transition_to!(:completed)
42
+ mailer = ResourceExportMailer.completed(self)
43
+ send_message(mailer)
44
44
  rescue => e
45
45
  transition_to!(:failed)
46
+ mailer = ResourceExportMailer.failed(self)
47
+ send_message(mailer)
46
48
  raise e
47
49
  end
48
50
 
@@ -1,4 +1,4 @@
1
- class ResourceExportFileTransition < ActiveRecord::Base
1
+ class ResourceExportFileTransition < ApplicationRecord
2
2
  include Statesman::Adapters::ActiveRecordTransition
3
3
 
4
4
 
@@ -1,4 +1,4 @@
1
- class ResourceImportFile < ActiveRecord::Base
1
+ class ResourceImportFile < ApplicationRecord
2
2
  include Statesman::Adapters::ActiveRecordQueries
3
3
  include ImportFile
4
4
  default_scope { order('resource_import_files.id DESC') }
@@ -216,13 +216,16 @@ class ResourceImportFile < ActiveRecord::Base
216
216
  Sunspot.commit
217
217
  rows.close
218
218
  transition_to!(:completed)
219
- send_message
219
+ mailer = ResourceImportMailer.completed(self)
220
+ send_message(mailer)
220
221
  Rails.cache.write("manifestation_search_total", Manifestation.search.total)
221
222
  num
222
223
  rescue => e
223
224
  self.error_message = "line #{row_num}: #{e.message}"
224
225
  save
225
226
  transition_to!(:failed)
227
+ mailer = ResourceImportMailer.failed(self)
228
+ send_message(mailer)
226
229
  raise e
227
230
  end
228
231
 
@@ -314,12 +317,16 @@ class ResourceImportFile < ActiveRecord::Base
314
317
  if item.manifestation
315
318
  fetch(row, edit_mode: 'update')
316
319
  end
320
+
321
+ if defined?(EnjuCirculation)
322
+ circulation_status = CirculationStatus.find_by(name: row['circulation_status'])
323
+ checkout_type = CheckoutType.find_by(name: row['checkout_type'])
324
+ use_restriction = UseRestriction.find_by(name: row['use_restriction'].to_s.strip)
325
+ end
326
+
317
327
  shelf = Shelf.find_by(name: row['shelf'].to_s.strip)
318
- circulation_status = CirculationStatus.find_by(name: row['circulation_status'])
319
- checkout_type = CheckoutType.find_by(name: row['checkout_type'])
320
328
  bookstore = Bookstore.find_by(name: row['bookstore'])
321
329
  required_role = Role.find_by(name: row['required_role'])
322
- use_restriction = UseRestriction.find_by(name: row['use_restriction'].to_s.strip)
323
330
 
324
331
  item.shelf = shelf if shelf
325
332
  item.circulation_status = circulation_status if circulation_status
@@ -371,10 +378,14 @@ class ResourceImportFile < ActiveRecord::Base
371
378
  import_result.save!
372
379
  end
373
380
  transition_to!(:completed)
381
+ mailer = ResourceImportMailer.completed(self)
382
+ send_message(mailer)
374
383
  rescue => e
375
384
  self.error_message = "line #{row_num}: #{e.message}"
376
385
  save
377
386
  transition_to!(:failed)
387
+ mailer = ResourceImportMailer.failed(self)
388
+ send_message(mailer)
378
389
  raise e
379
390
  end
380
391
 
@@ -393,10 +404,14 @@ class ResourceImportFile < ActiveRecord::Base
393
404
  end
394
405
  end
395
406
  transition_to!(:completed)
407
+ mailer = ResourceImportMailer.completed(self)
408
+ send_message(mailer)
396
409
  rescue => e
397
410
  self.error_message = "line #{row_num}: #{e.message}"
398
411
  save
399
412
  transition_to!(:failed)
413
+ mailer = ResourceImportMailer.failed(self)
414
+ send_message(mailer)
400
415
  raise e
401
416
  end
402
417
 
@@ -431,6 +446,15 @@ class ResourceImportFile < ActiveRecord::Base
431
446
  row_num += 1
432
447
  end
433
448
  transition_to!(:completed)
449
+ mailer = ResourceImportMailer.completed(self)
450
+ send_message(mailer)
451
+ rescue => e
452
+ self.error_message = "line #{row_num}: #{e.message}"
453
+ save
454
+ transition_to!(:failed)
455
+ mailer = ResourceImportMailer.failed(self)
456
+ send_message(mailer)
457
+ raise e
434
458
  end
435
459
 
436
460
  private
@@ -754,7 +778,7 @@ class ResourceImportFile < ActiveRecord::Base
754
778
  def set_identifier(row)
755
779
  identifiers = []
756
780
  %w(isbn issn doi jpno ncid).each do |id_type|
757
- if row["#{id_type}"].present?
781
+ if row[id_type.to_s].present?
758
782
  row[id_type].split(/\/\//).each do |identifier_s|
759
783
  import_id = Identifier.new(body: identifier_s)
760
784
  identifier_type = IdentifierType.find_by(name: id_type)
@@ -1,4 +1,4 @@
1
- class ResourceImportFileTransition < ActiveRecord::Base
1
+ class ResourceImportFileTransition < ApplicationRecord
2
2
  include Statesman::Adapters::ActiveRecordTransition
3
3
 
4
4
 
@@ -1,4 +1,4 @@
1
- class ResourceImportResult < ActiveRecord::Base
1
+ class ResourceImportResult < ApplicationRecord
2
2
  default_scope { order('resource_import_results.id') }
3
3
  scope :file_id, proc{|file_id| where(resource_import_file_id: file_id)}
4
4
  scope :failed, -> { where(manifestation_id: nil) }
@@ -1,4 +1,4 @@
1
- class SeriesStatement < ActiveRecord::Base
1
+ class SeriesStatement < ApplicationRecord
2
2
  has_many :series_statement_merges, dependent: :destroy
3
3
  has_many :series_statement_merge_lists, through: :series_statement_merges
4
4
  belongs_to :manifestation, touch: true, optional: true
@@ -1,4 +1,4 @@
1
- class SeriesStatementMerge < ActiveRecord::Base
1
+ class SeriesStatementMerge < ApplicationRecord
2
2
  belongs_to :series_statement
3
3
  belongs_to :series_statement_merge_list
4
4
  validates_presence_of :series_statement, :series_statement_merge_list
@@ -1,4 +1,4 @@
1
- class SeriesStatementMergeList < ActiveRecord::Base
1
+ class SeriesStatementMergeList < ApplicationRecord
2
2
  has_many :series_statement_merges, dependent: :destroy
3
3
  has_many :series_statements, through: :series_statement_merges
4
4
  validates_presence_of :title
@@ -0,0 +1,9 @@
1
+ The following import task is completed.
2
+
3
+ ID: <%= @agent_import_file.id %>
4
+ Created at: <%= @agent_import_file.created_at %>
5
+ Detail: <%= agent_import_file_url(@agent_import_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>
@@ -0,0 +1,9 @@
1
+ 以下の人物・団体のインポートが完了しました。
2
+
3
+ ID: <%= @agent_import_file.id %>
4
+ 作成時刻: <%= @agent_import_file.created_at %>
5
+ 詳細: <%= agent_import_file_url(@agent_import_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>
@@ -0,0 +1,9 @@
1
+ The following import task failed.
2
+
3
+ ID: <%= @agent_import_file.id %>
4
+ Created at: <%= @agent_import_file.created_at %>
5
+ Detail: <%= agent_import_file_url(@agent_import_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>
@@ -0,0 +1,9 @@
1
+ 以下の人物・団体のインポートに失敗しました。
2
+
3
+ ID: <%= @agent_import_file.id %>
4
+ 作成時刻: <%= @agent_import_file.created_at %>
5
+ 詳細: <%= agent_import_file_url(@agent_import_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>
@@ -20,15 +20,6 @@
20
20
  <%= @item.checkout_type.display_name.localize -%>
21
21
  </p>
22
22
 
23
- <p>
24
- <strong><%= t('activerecord.models.lending_policy') -%>:</strong>
25
- <ul>
26
- <%- @item.lending_policies.each do |lending_policy| -%>
27
- <li><%= lending_policy.user_group.display_name.localize -%></li>
28
- <%- end -%>
29
- </ul>
30
- </p>
31
-
32
23
  <p>
33
24
  <strong><%= t('activerecord.models.circulation_status') -%>:</strong>
34
25
  <%= @item.circulation_status.display_name.localize -%>
@@ -32,15 +32,6 @@
32
32
  <%= link_to @item.checkout_type.display_name.localize, @item.checkout_type -%>
33
33
  </p>
34
34
 
35
- <p>
36
- <strong><%= t('activerecord.models.lending_policy') -%>:</strong>
37
- <ul>
38
- <%- @item.lending_policies.each do |lending_policy| -%>
39
- <li><%= link_to lending_policy.user_group.display_name.localize, lending_policy -%></li>
40
- <%- end -%>
41
- </ul>
42
- </p>
43
-
44
35
  <p>
45
36
  <strong><%= t('activerecord.models.circulation_status') -%>:</strong>
46
37
  <%= link_to @item.circulation_status.display_name.localize, @item.circulation_status -%>
@@ -152,9 +143,6 @@
152
143
  <%- end -%>
153
144
  <% end %>
154
145
  <% if defined?(EnjuCirculation) %>
155
- <% if policy(LendingPolicy).index? %>
156
- <li><%= link_to t('page.listing', model: t('activerecord.models.lending_policy')), lending_policies_path(item_id: @item.id) -%></li>
157
- <% end %>
158
146
  <% if policy(Checkout).index? %>
159
147
  <li><%= link_to t('page.checkout_history'), checkouts_path(item_id: @item.id) -%></li>
160
148
  <% end %>
@@ -0,0 +1,53 @@
1
+ json.id manifestation.id
2
+ json.original_title manifestation.original_title
3
+ json.title_alternative manifestation.title_alternative
4
+ json.title_transcription manifestation.title_transcription
5
+ json.title_alternative_transcription manifestation.title_alternative_transcription
6
+ json.pub_date manifestation.pub_date
7
+ json.statement_of_responsibility manifestation.statement_of_responsibility
8
+ json.creators do
9
+ json.array!(manifestation.creators) do |creator|
10
+ json.full_name creator.full_name
11
+ end
12
+ end
13
+ json.contributors do
14
+ json.array!(manifestation.contributors) do |contributor|
15
+ json.full_name contributor.full_name
16
+ end
17
+ end
18
+ json.publishers do
19
+ json.array!(manifestation.publishers) do |publisher|
20
+ json.full_name publisher.full_name
21
+ end
22
+ end
23
+ json.publication_place manifestation.publication_place
24
+ json.extent manifestation.extent
25
+ json.dimensions manifestation.dimensions
26
+ json.identifiers do
27
+ json.array!(manifestation.identifiers) do |identifier|
28
+ json.identifier_type identifier.identifier_type.name
29
+ json.body identifier.body
30
+ end
31
+ end
32
+ json.subjects do
33
+ json.array!(manifestation.subjects) do |subject|
34
+ json.subject_heading_type subject.subject_heading_type.name
35
+ json.term subject.term
36
+ end
37
+ end
38
+ json.classfifications do
39
+ json.array!(manifestation.classifications) do |classification|
40
+ json.classification_type classification.classification_type.name
41
+ json.term classification.category
42
+ end
43
+ end
44
+ json.access_address manifestation.access_address
45
+ json.items do
46
+ json.array!(manifestation.items.available.on_shelf) do |item|
47
+ json.item_identifier item.item_identifier
48
+ json.shelf item.shelf.display_name
49
+ json.circulation_status item.circulation_status.display_name if defined?(EnjuCirculationStatus)
50
+ end
51
+ end
52
+ json.created_at manifestation.created_at
53
+ json.updated_at manifestation.updated_at
@@ -0,0 +1,6 @@
1
+ json.total_count @count[:query_result]
2
+ json.results do
3
+ json.array!(@manifestations) do |manifestation|
4
+ json.partial!(manifestation)
5
+ end
6
+ end
@@ -6,28 +6,8 @@
6
6
  <%= f.error_messages -%>
7
7
 
8
8
  <div class="field">
9
- <%= f.label :picture_attachable_type -%><br />
10
- <%= f.text_field :picture_attachable_type -%>
11
- </div>
12
-
13
- <div class="field">
14
- <%= f.label t('page.attachable') -%><br />
15
- <%= f.text_field :picture_attachable_id -%>
16
- </div>
17
-
18
- <div class="field">
19
- <%= f.label :picture_file_size -%><br />
20
- <%= f.text_field :picture_file_size -%>
21
- </div>
22
-
23
- <div class="field">
24
- <%= f.label :picture_content_type -%><br />
25
- <%= f.text_field :picture_content_type -%>
26
- </div>
27
-
28
- <div class="field">
29
- <%= f.label :picture_file_name -%><br />
30
- <%= f.text_field :picture_file_name -%>
9
+ <%= f.label t('page.file') -%><br />
10
+ <%= f.file_field :picture -%>
31
11
  </div>
32
12
 
33
13
  <div class="actions">
@@ -0,0 +1,9 @@
1
+ The following export task is completed.
2
+
3
+ ID: <%= @resource_export_file.id %>
4
+ Created at: <%= @resource_export_file.created_at %>
5
+ Detail: <%= resource_export_file_url(@resource_export_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>
@@ -0,0 +1,9 @@
1
+ 以下の資料のインポートが完了しました。
2
+
3
+ ID: <%= @resource_export_file.id %>
4
+ 作成時刻: <%= @resource_export_file.created_at %>
5
+ 詳細: <%= resource_export_file_url(@resource_export_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>
@@ -0,0 +1,9 @@
1
+ The following export task failed.
2
+
3
+ ID: <%= @resource_export_file.id %>
4
+ Created at: <%= @resource_export_file.created_at %>
5
+ Detail: <%= resource_export_file_url(@resource_export_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>
@@ -0,0 +1,9 @@
1
+ 以下の資料のインポートに失敗しました。
2
+
3
+ ID: <%= @resource_export_file.id %>
4
+ 作成時刻: <%= @resource_export_file.created_at %>
5
+ 詳細: <%= resource_export_file_url(@resource_export_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>
@@ -0,0 +1,9 @@
1
+ The following import task is completed.
2
+
3
+ ID: <%= @resource_import_file.id %>
4
+ Created at: <%= @resource_import_file.created_at %>
5
+ Detail: <%= resource_import_file_url(@resource_import_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>
@@ -0,0 +1,9 @@
1
+ 以下の資料のインポートが完了しました。
2
+
3
+ ID: <%= @resource_import_file.id %>
4
+ 作成時刻: <%= @resource_import_file.created_at %>
5
+ 詳細: <%= resource_import_file_url(@resource_import_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>
@@ -0,0 +1,9 @@
1
+ The following import task failed.
2
+
3
+ ID: <%= @resource_import_file.id %>
4
+ Created at: <%= @resource_import_file.created_at %>
5
+ Detail: <%= resource_import_file_url(@resource_import_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>
@@ -0,0 +1,9 @@
1
+ 以下の資料のインポートに失敗しました。
2
+
3
+ ID: <%= @resource_import_file.id %>
4
+ 作成時刻: <%= @resource_import_file.created_at %>
5
+ 詳細: <%= resource_import_file_url(@resource_import_file) %>
6
+
7
+ --
8
+ <%= @library_group.display_name %>
9
+ <%= root_url %>