enju_biblio 0.1.0.pre55 → 0.1.0.pre56
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/agent_import_files_controller.rb +11 -11
- data/app/controllers/agent_import_results_controller.rb +1 -1
- data/app/controllers/agent_relationship_types_controller.rb +0 -1
- data/app/controllers/agent_relationships_controller.rb +2 -2
- data/app/controllers/agent_types_controller.rb +0 -1
- data/app/controllers/agents_controller.rb +22 -23
- data/app/controllers/carrier_types_controller.rb +11 -11
- data/app/controllers/content_types_controller.rb +0 -1
- data/app/controllers/countries_controller.rb +1 -1
- data/app/controllers/create_types_controller.rb +0 -1
- data/app/controllers/creates_controller.rb +13 -14
- data/app/controllers/donates_controller.rb +10 -10
- data/app/controllers/extents_controller.rb +1 -1
- data/app/controllers/form_of_works_controller.rb +1 -1
- data/app/controllers/frequencies_controller.rb +1 -1
- data/app/controllers/identifier_types_controller.rb +10 -10
- data/app/controllers/import_requests_controller.rb +12 -12
- data/app/controllers/items_controller.rb +25 -26
- data/app/controllers/languages_controller.rb +1 -1
- data/app/controllers/licenses_controller.rb +0 -1
- data/app/controllers/manifestation_relationship_types_controller.rb +0 -1
- data/app/controllers/manifestation_relationships_controller.rb +2 -2
- data/app/controllers/manifestations_controller.rb +64 -59
- data/app/controllers/medium_of_performances_controller.rb +0 -1
- data/app/controllers/owns_controller.rb +12 -13
- data/app/controllers/picture_files_controller.rb +13 -14
- data/app/controllers/produce_types_controller.rb +0 -1
- data/app/controllers/produces_controller.rb +15 -16
- data/app/controllers/realize_types_controller.rb +0 -1
- data/app/controllers/realizes_controller.rb +13 -14
- data/app/controllers/resource_export_files_controller.rb +11 -11
- data/app/controllers/resource_import_files_controller.rb +26 -11
- data/app/controllers/resource_import_results_controller.rb +2 -2
- data/app/controllers/series_statements_controller.rb +13 -14
- data/app/helpers/manifestations_helper.rb +1 -1
- data/app/models/agent.rb +44 -41
- data/app/models/agent_import_file.rb +12 -58
- data/app/models/agent_import_result.rb +3 -4
- data/app/models/agent_relationship.rb +3 -3
- data/app/models/agent_relationship_type.rb +1 -1
- data/app/models/agent_sweeper.rb +0 -1
- data/app/models/agent_type.rb +1 -1
- data/app/models/carrier_type.rb +4 -4
- data/app/models/content_type.rb +1 -1
- data/app/models/country.rb +1 -1
- data/app/models/create.rb +3 -3
- data/app/models/create_type.rb +1 -1
- data/app/models/donate.rb +2 -2
- data/app/models/enju_biblio/ability.rb +2 -13
- data/app/models/exemplify.rb +1 -1
- data/app/models/extent.rb +1 -1
- data/app/models/form_of_work.rb +1 -1
- data/app/models/frequency.rb +1 -1
- data/app/models/identifier.rb +3 -3
- data/app/models/identifier_type.rb +2 -2
- data/app/models/import_request.rb +2 -2
- data/app/models/item.rb +48 -48
- data/app/models/item_sweeper.rb +0 -1
- data/app/models/language.rb +1 -1
- data/app/models/license.rb +1 -1
- data/app/models/manifestation.rb +72 -66
- data/app/models/manifestation_relationship.rb +3 -3
- data/app/models/manifestation_relationship_type.rb +1 -1
- data/app/models/manifestation_sweeper.rb +0 -1
- data/app/models/medium_of_performance.rb +1 -1
- data/app/models/own.rb +4 -4
- data/app/models/page_sweeper.rb +0 -1
- data/app/models/picture_file.rb +6 -6
- data/app/models/produce.rb +3 -3
- data/app/models/produce_type.rb +1 -1
- data/app/models/realize.rb +3 -3
- data/app/models/realize_type.rb +1 -1
- data/app/models/resource_export_file.rb +4 -11
- data/app/models/resource_import_file.rb +148 -100
- data/app/models/resource_import_result.rb +1 -1
- data/app/models/series_statement.rb +7 -5
- data/app/views/agent_import_files/edit.html.erb +1 -1
- data/app/views/agent_import_files/index.html.erb +4 -4
- data/app/views/agent_import_files/new.html.erb +12 -12
- data/app/views/agent_import_files/show.html.erb +4 -4
- data/app/views/agent_import_results/index.html.erb +6 -8
- data/app/views/agent_import_results/{index.tsv.erb → index.txt.erb} +0 -0
- data/app/views/agent_import_results/show.html.erb +1 -6
- data/app/views/agent_relationship_types/edit.html.erb +1 -1
- data/app/views/agent_relationship_types/index.html.erb +20 -12
- data/app/views/agent_relationship_types/new.html.erb +1 -1
- data/app/views/agent_relationship_types/show.html.erb +1 -1
- data/app/views/agent_relationships/edit.html.erb +1 -1
- data/app/views/agent_relationships/index.html.erb +3 -3
- data/app/views/agent_relationships/new.html.erb +1 -1
- data/app/views/agent_relationships/show.html.erb +1 -1
- data/app/views/agent_types/edit.html.erb +1 -1
- data/app/views/agent_types/index.html.erb +19 -11
- data/app/views/agent_types/new.html.erb +1 -1
- data/app/views/agent_types/show.html.erb +1 -1
- data/app/views/agents/_agent.html.erb +1 -1
- data/app/views/agents/_expression_list.html.erb +2 -2
- data/app/views/agents/_form.html.erb +8 -8
- data/app/views/agents/_form_family_name_first.html.erb +4 -4
- data/app/views/agents/_form_family_name_last.html.erb +4 -4
- data/app/views/agents/_index.html.erb +4 -4
- data/app/views/agents/_index_agent.html.erb +7 -11
- data/app/views/agents/_index_expression.html.erb +5 -5
- data/app/views/agents/_index_manifestation.html.erb +11 -11
- data/app/views/agents/_index_work.html.erb +5 -5
- data/app/views/agents/_manifestation_list.html.erb +2 -2
- data/app/views/agents/_work_list.html.erb +2 -2
- data/app/views/agents/edit.html.erb +2 -2
- data/app/views/agents/index.atom.builder +2 -2
- data/app/views/agents/index.html.erb +1 -1
- data/app/views/agents/index.mobile.erb +3 -3
- data/app/views/agents/index.rss.builder +6 -6
- data/app/views/agents/new.html.erb +1 -1
- data/app/views/agents/show.html.erb +11 -22
- data/app/views/agents/show.mobile.erb +3 -9
- data/app/views/carrier_types/_form.html.erb +2 -2
- data/app/views/carrier_types/edit.html.erb +1 -1
- data/app/views/carrier_types/index.html.erb +15 -9
- data/app/views/carrier_types/new.html.erb +1 -1
- data/app/views/carrier_types/show.html.erb +17 -1
- data/app/views/content_types/_form.html.erb +5 -5
- data/app/views/content_types/edit.html.erb +1 -1
- data/app/views/content_types/index.html.erb +14 -8
- data/app/views/content_types/new.html.erb +1 -1
- data/app/views/content_types/show.html.erb +6 -1
- data/app/views/countries/_form.html.erb +5 -5
- data/app/views/countries/edit.html.erb +1 -1
- data/app/views/countries/index.html.erb +10 -8
- data/app/views/countries/new.html.erb +1 -1
- data/app/views/countries/show.html.erb +1 -1
- data/app/views/create_types/edit.html.erb +1 -1
- data/app/views/create_types/index.html.erb +20 -12
- data/app/views/create_types/new.html.erb +1 -1
- data/app/views/create_types/show.html.erb +1 -1
- data/app/views/creates/_index.html.erb +3 -3
- data/app/views/creates/_index_agent.html.erb +5 -6
- data/app/views/creates/_index_work.html.erb +4 -4
- data/app/views/creates/edit.html.erb +1 -1
- data/app/views/creates/new.html.erb +3 -3
- data/app/views/creates/show.html.erb +3 -3
- data/app/views/donates/edit.html.erb +1 -1
- data/app/views/donates/index.html.erb +4 -4
- data/app/views/donates/new.html.erb +1 -1
- data/app/views/donates/show.html.erb +1 -1
- data/app/views/extents/edit.html.erb +1 -1
- data/app/views/extents/index.html.erb +12 -8
- data/app/views/extents/new.html.erb +1 -1
- data/app/views/extents/show.html.erb +1 -1
- data/app/views/form_of_works/_form.html.erb +2 -2
- data/app/views/form_of_works/edit.html.erb +1 -1
- data/app/views/form_of_works/index.html.erb +15 -9
- data/app/views/form_of_works/new.html.erb +1 -1
- data/app/views/form_of_works/show.html.erb +1 -1
- data/app/views/frequencies/edit.html.erb +1 -1
- data/app/views/frequencies/index.html.erb +16 -8
- data/app/views/frequencies/new.html.erb +1 -1
- data/app/views/frequencies/show.html.erb +6 -1
- data/app/views/identifier_types/_form.html.erb +5 -5
- data/app/views/identifier_types/edit.html.erb +1 -1
- data/app/views/identifier_types/index.html.erb +3 -3
- data/app/views/identifier_types/new.html.erb +1 -1
- data/app/views/identifier_types/show.html.erb +6 -1
- data/app/views/import_requests/edit.html.erb +2 -2
- data/app/views/import_requests/index.html.erb +4 -4
- data/app/views/import_requests/new.html.erb +3 -3
- data/app/views/import_requests/show.html.erb +2 -2
- data/app/views/items/_form.html.erb +27 -16
- data/app/views/items/_shelf_picture.html.erb +1 -1
- data/app/views/items/_shelf_picture.mobile.erb +1 -1
- data/app/views/items/edit.html.erb +5 -5
- data/app/views/items/index.html.erb +10 -10
- data/app/views/items/index.mobile.erb +5 -5
- data/app/views/items/index.txt.erb +4 -0
- data/app/views/items/new.html.erb +4 -4
- data/app/views/items/show.html.erb +35 -21
- data/app/views/items/show.mobile.erb +3 -3
- data/app/views/languages/_form.html.erb +4 -4
- data/app/views/languages/edit.html.erb +1 -1
- data/app/views/languages/index.html.erb +2 -2
- data/app/views/languages/new.html.erb +1 -1
- data/app/views/languages/show.html.erb +1 -1
- data/app/views/layouts/agents.html.erb +2 -2
- data/app/views/layouts/manifestations.html.erb +2 -2
- data/app/views/licenses/_form.html.erb +2 -2
- data/app/views/licenses/edit.html.erb +1 -1
- data/app/views/licenses/index.html.erb +12 -7
- data/app/views/licenses/new.html.erb +1 -1
- data/app/views/licenses/show.html.erb +1 -1
- data/app/views/manifestation_relationship_types/edit.html.erb +1 -1
- data/app/views/manifestation_relationship_types/index.html.erb +20 -12
- data/app/views/manifestation_relationship_types/new.html.erb +1 -1
- data/app/views/manifestation_relationship_types/show.html.erb +1 -1
- data/app/views/manifestation_relationships/edit.html.erb +1 -1
- data/app/views/manifestation_relationships/index.html.erb +3 -3
- data/app/views/manifestation_relationships/new.html.erb +1 -1
- data/app/views/manifestation_relationships/show.html.erb +1 -1
- data/app/views/manifestations/_attachment_file.html.erb +1 -1
- data/app/views/manifestations/_edit_detail.html.erb +3 -3
- data/app/views/manifestations/_form.html.erb +47 -28
- data/app/views/manifestations/_holding.html.erb +1 -1
- data/app/views/manifestations/_index_form.html.erb +2 -2
- data/app/views/manifestations/_index_form_contributor.html.erb +2 -2
- data/app/views/manifestations/_index_form_creator.html.erb +2 -2
- data/app/views/manifestations/_index_form_item.html.erb +2 -2
- data/app/views/manifestations/_index_form_manifestation.html.erb +2 -2
- data/app/views/manifestations/_index_form_parent.html.erb +9 -3
- data/app/views/manifestations/_index_form_publisher.html.erb +2 -2
- data/app/views/manifestations/_index_form_series_statement.html.erb +3 -3
- data/app/views/manifestations/_manifestation.html.erb +7 -7
- data/app/views/manifestations/_manifestation_list.html.erb +2 -2
- data/app/views/manifestations/_paginate_id_link.html.erb +2 -2
- data/app/views/manifestations/_pickup.html.erb +4 -4
- data/app/views/manifestations/_search_engine.html.erb +1 -1
- data/app/views/manifestations/_show.mods.builder +2 -2
- data/app/views/manifestations/_show.rdf.builder +2 -2
- data/app/views/manifestations/_show_creators.html.erb +2 -2
- data/app/views/manifestations/_show_creators.mobile.erb +2 -2
- data/app/views/manifestations/_show_detail_librarian.html.erb +13 -9
- data/app/views/manifestations/_show_detail_user.html.erb +13 -9
- data/app/views/manifestations/_show_holding.html.erb +8 -6
- data/app/views/manifestations/_show_holding.mobile.erb +1 -1
- data/app/views/manifestations/_show_index.html.erb +7 -5
- data/app/views/manifestations/_show_index.mobile.erb +3 -3
- data/app/views/manifestations/_show_parent_form.html.erb +12 -0
- data/app/views/manifestations/_show_series_index.html.erb +6 -3
- data/app/views/manifestations/_submenu_parent.html.erb +1 -1
- data/app/views/manifestations/_tab_list.html.erb +3 -3
- data/app/views/manifestations/_tab_menu.html.erb +2 -2
- data/app/views/manifestations/_title.html.erb +9 -6
- data/app/views/manifestations/_title.mobile.erb +6 -6
- data/app/views/manifestations/edit.html.erb +3 -3
- data/app/views/manifestations/index.atom.builder +2 -2
- data/app/views/manifestations/index.html.erb +8 -7
- data/app/views/manifestations/index.mobile.erb +4 -4
- data/app/views/manifestations/index.mods.builder +1 -1
- data/app/views/manifestations/index.opds.builder +4 -4
- data/app/views/manifestations/index.rdf.builder +4 -4
- data/app/views/manifestations/index.rss.builder +6 -6
- data/app/views/manifestations/index.sru.builder +1 -1
- data/app/views/manifestations/{index.csv.erb → index.txt.erb} +0 -0
- data/app/views/manifestations/new.html.erb +1 -1
- data/app/views/manifestations/show.html.erb +14 -14
- data/app/views/manifestations/show.mobile.erb +3 -3
- data/app/views/manifestations/show.mods.builder +1 -1
- data/app/views/manifestations/show.rdf.builder +1 -1
- data/app/views/medium_of_performances/edit.html.erb +1 -1
- data/app/views/medium_of_performances/index.html.erb +16 -9
- data/app/views/medium_of_performances/new.html.erb +1 -1
- data/app/views/medium_of_performances/show.html.erb +1 -1
- data/app/views/notifier/manifestation_info.en.text.erb +2 -2
- data/app/views/notifier/manifestation_info.ja.text.erb +2 -2
- data/app/views/owns/edit.html.erb +1 -1
- data/app/views/owns/index.html.erb +4 -4
- data/app/views/owns/new.html.erb +1 -1
- data/app/views/owns/show.html.erb +3 -3
- data/app/views/picture_files/_index.html.erb +7 -7
- data/app/views/picture_files/_index_agent.html.erb +4 -4
- data/app/views/picture_files/_index_event.html.erb +4 -4
- data/app/views/picture_files/_index_manifestation.html.erb +4 -4
- data/app/views/picture_files/_index_shelf.html.erb +4 -4
- data/app/views/picture_files/_link.html.erb +1 -1
- data/app/views/picture_files/_link.mobile.erb +1 -1
- data/app/views/picture_files/edit.html.erb +1 -1
- data/app/views/picture_files/index.html.erb +1 -1
- data/app/views/picture_files/new.html.erb +2 -2
- data/app/views/picture_files/show.html.erb +7 -7
- data/app/views/picture_files/show.mobile.erb +2 -2
- data/app/views/produce_types/edit.html.erb +1 -1
- data/app/views/produce_types/index.html.erb +20 -12
- data/app/views/produce_types/new.html.erb +1 -1
- data/app/views/produce_types/show.html.erb +1 -1
- data/app/views/produces/_index.html.erb +3 -3
- data/app/views/produces/_index_agent.html.erb +3 -3
- data/app/views/produces/_index_manifestation.html.erb +5 -5
- data/app/views/produces/edit.html.erb +1 -1
- data/app/views/produces/index.html.erb +1 -1
- data/app/views/produces/new.html.erb +3 -3
- data/app/views/produces/show.html.erb +3 -3
- data/app/views/realize_types/edit.html.erb +1 -1
- data/app/views/realize_types/index.html.erb +20 -12
- data/app/views/realize_types/new.html.erb +1 -1
- data/app/views/realize_types/show.html.erb +1 -1
- data/app/views/realizes/_index.html.erb +3 -3
- data/app/views/realizes/_index_agent.html.erb +3 -3
- data/app/views/realizes/_index_expression.html.erb +5 -5
- data/app/views/realizes/edit.html.erb +1 -1
- data/app/views/realizes/new.html.erb +3 -3
- data/app/views/realizes/show.html.erb +3 -3
- data/app/views/resource_export_files/index.html.erb +3 -3
- data/app/views/resource_export_files/new.html.erb +2 -2
- data/app/views/resource_export_files/show.html.erb +1 -1
- data/app/views/resource_import_files/_observe_field.html.erb +7 -0
- data/app/views/resource_import_files/edit.html.erb +1 -1
- data/app/views/resource_import_files/index.html.erb +30 -25
- data/app/views/resource_import_files/new.html.erb +21 -13
- data/app/views/resource_import_files/show.html.erb +9 -4
- data/app/views/resource_import_results/index.html.erb +6 -6
- data/app/views/resource_import_results/{index.tsv.erb → index.txt.erb} +0 -0
- data/app/views/resource_import_results/show.html.erb +1 -1
- data/app/views/series_statements/_form.html.erb +2 -2
- data/app/views/series_statements/_index.html.erb +5 -5
- data/app/views/series_statements/_index_manifestation.html.erb +5 -5
- data/app/views/series_statements/_index_series_statement_merge_list.html.erb +5 -5
- data/app/views/series_statements/_merge.html.erb +2 -2
- data/app/views/series_statements/_refine_search_form.html.erb +2 -2
- data/app/views/series_statements/edit.html.erb +1 -1
- data/app/views/series_statements/new.html.erb +1 -1
- data/app/views/series_statements/show.html.erb +2 -2
- data/config/locales/translation_en.yml +13 -9
- data/config/locales/translation_ja.yml +16 -9
- data/config/routes.rb +5 -14
- data/db/migrate/001_create_agents.rb +0 -2
- data/db/migrate/006_create_items.rb +0 -2
- data/db/migrate/20100925074559_create_agent_import_results.rb +0 -1
- data/db/migrate/20140720140916_add_binding_item_identifier_to_item.rb +8 -0
- data/db/migrate/20140721151416_add_default_shelf_id_to_resource_import_file.rb +5 -0
- data/db/migrate/20140802082007_add_manifestation_id_to_item.rb +6 -0
- data/db/migrate/20140813182425_add_publication_place_to_manifestation.rb +5 -0
- data/lib/enju_biblio/biblio_helper.rb +4 -4
- data/lib/enju_biblio/engine.rb +0 -1
- data/lib/enju_biblio/version.rb +1 -1
- data/lib/generators/enju_biblio/setup/setup_generator.rb +2 -0
- data/lib/generators/enju_biblio/setup/templates/db/fixtures/agent_relationship_types.yml +3 -3
- data/lib/generators/enju_biblio/setup/templates/db/fixtures/agent_types.yml +2 -2
- data/lib/generators/enju_biblio/setup/templates/db/fixtures/carrier_types.yml +12 -10
- data/lib/generators/enju_biblio/setup/templates/db/fixtures/content_types.yml +70 -7
- data/lib/generators/enju_biblio/setup/templates/db/fixtures/manifestation_relationship_types.yml +2 -2
- data/lib/tasks/carrier_type.rb +26 -0
- data/lib/tasks/content_type.rb +19 -0
- data/lib/tasks/enju_biblio_tasks.rake +14 -0
- data/lib/tasks/item.rb +7 -0
- data/spec/cassette_library/ResourceImportFile/should_import_in_background.yml +433 -0
- data/spec/cassette_library/ResourceImportFile/when_its_mode_is_create_/when_it_has_only_isbn/should_be_imported.yml +363 -326
- data/spec/cassette_library/ResourceImportFile/when_its_mode_is_create_/when_it_is_written_in_shift_jis/should_be_imported.yml +166 -180
- data/spec/cassette_library/ResourceImportFile/when_its_mode_is_create_/when_it_is_written_in_utf-8/should_be_imported.yml +166 -180
- data/spec/controllers/agent_import_files_controller_spec.rb +20 -60
- data/spec/controllers/agent_import_results_controller_spec.rb +6 -18
- data/spec/controllers/agent_relationship_types_controller_spec.rb +21 -21
- data/spec/controllers/agent_relationships_controller_spec.rb +21 -21
- data/spec/controllers/agent_types_controller_spec.rb +2 -1
- data/spec/controllers/carrier_types_controller_spec.rb +1 -1
- data/spec/controllers/content_types_controller_spec.rb +2 -1
- data/spec/controllers/countries_controller_spec.rb +22 -23
- data/spec/controllers/create_types_controller_spec.rb +2 -2
- data/spec/controllers/creates_controller_spec.rb +22 -22
- data/spec/controllers/donates_controller_spec.rb +21 -21
- data/spec/controllers/extents_controller_spec.rb +2 -1
- data/spec/controllers/form_of_works_controller_spec.rb +2 -2
- data/spec/controllers/frequencies_controller_spec.rb +2 -1
- data/spec/controllers/identifier_types_controller_spec.rb +1 -1
- data/spec/controllers/import_requests_controller_spec.rb +21 -21
- data/spec/controllers/items_controller_spec.rb +24 -24
- data/spec/controllers/languages_controller_spec.rb +12 -12
- data/spec/controllers/licenses_controller_spec.rb +2 -1
- data/spec/controllers/manifestation_relationship_types_controller_spec.rb +21 -21
- data/spec/controllers/manifestation_relationships_controller_spec.rb +21 -21
- data/spec/controllers/manifestations_controller_spec.rb +22 -22
- data/spec/controllers/medium_of_performances_controller_spec.rb +2 -1
- data/spec/controllers/owns_controller_spec.rb +22 -22
- data/spec/controllers/picture_files_controller_spec.rb +21 -21
- data/spec/controllers/produce_types_controller_spec.rb +2 -1
- data/spec/controllers/produces_controller_spec.rb +22 -22
- data/spec/controllers/realize_types_controller_spec.rb +2 -1
- data/spec/controllers/realizes_controller_spec.rb +23 -23
- data/spec/controllers/resource_export_files_controller_spec.rb +18 -18
- data/spec/controllers/resource_import_files_controller_spec.rb +18 -18
- data/spec/controllers/resource_import_results_controller_spec.rb +9 -9
- data/spec/dummy/app/models/user.rb +4 -79
- data/spec/dummy/config/environments/test.rb +3 -2
- data/spec/dummy/db/development.sqlite3 +0 -0
- data/spec/dummy/db/migrate/20111201155456_devise_create_users.rb +42 -0
- data/spec/dummy/db/migrate/20130221154434_add_additional_attributes_to_user.rb +26 -0
- data/spec/dummy/db/migrate/20140110122216_create_user_import_files.rb +18 -0
- data/spec/dummy/db/migrate/20140110131010_create_user_import_results.rb +11 -0
- data/spec/dummy/db/migrate/20140122054321_create_profiles.rb +20 -0
- data/spec/dummy/db/migrate/20140518050147_create_reserve_transitions.rb +14 -0
- data/spec/dummy/db/migrate/20140518111006_create_message_transitions.rb +14 -0
- data/spec/dummy/db/migrate/20140518135713_create_message_request_transitions.rb +14 -0
- data/spec/dummy/db/migrate/20140524074813_create_user_import_file_transitions.rb +14 -0
- data/spec/dummy/db/migrate/20140528045518_create_user_checkout_stat_transitions.rb +14 -0
- data/spec/dummy/db/migrate/20140528045539_create_user_reserve_stat_transitions.rb +14 -0
- data/spec/dummy/db/migrate/20140528045600_create_manifestation_checkout_stat_transitions.rb +14 -0
- data/spec/dummy/db/migrate/20140528045617_create_manifestation_reserve_stat_transitions.rb +14 -0
- data/spec/dummy/db/migrate/20140610123439_drop_email_unique_constraint_enju_leaf_rc10.rb +11 -0
- data/spec/dummy/db/migrate/20140628072217_add_user_encoding_to_user_import_file.rb +5 -0
- data/spec/dummy/db/migrate/20140709113413_create_user_export_files.rb +11 -0
- data/spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb +14 -0
- data/spec/dummy/db/migrate/20140720170714_add_default_library_id_to_user_import_file.rb +5 -0
- data/spec/dummy/db/migrate/20140720170735_add_default_user_group_id_to_user_import_file.rb +5 -0
- data/spec/dummy/db/migrate/20140810061942_add_user_id_to_user_checkout_stat.rb +12 -0
- data/spec/dummy/db/migrate/20140810091231_add_checkout_icalendar_token_to_profile.rb +6 -0
- data/spec/dummy/db/migrate/20140810091417_add_save_checkout_history_to_profile.rb +5 -0
- data/spec/dummy/db/migrate/20140811031145_add_expired_at_to_profile.rb +5 -0
- data/spec/dummy/db/schema.rb +218 -24
- data/spec/dummy/db/test.sqlite3 +0 -0
- data/spec/dummy/private/system/agent_import_files/agent_imports/000/000/004/original/agent_import_file_sample1.tsv +5 -5
- data/spec/dummy/private/system/agent_import_files/agent_imports/000/000/004/original/agent_import_file_sample2.tsv +8 -8
- data/spec/dummy/private/system/agent_import_files/agent_imports/000/000/004/original/agent_import_file_sample3.tsv +5 -5
- data/spec/dummy/private/system/resource_import_files/resource_imports/000/000/004/original/item_update_file.tsv +5 -4
- data/spec/dummy/private/system/resource_import_files/resource_imports/000/000/004/original/resource_import_file_sample1.tsv +19 -19
- data/spec/dummy/private/system/resource_import_files/resource_imports/000/000/004/original/resource_import_file_sample2.tsv +19 -19
- data/spec/dummy/public/system/resource_export_files/resource_exports/000/000/004/original/resource_export_file_20140702-50651-14mi4s9.txt +147 -0
- data/spec/dummy/public/system/resource_export_files/resource_exports/000/000/004/original/resource_export_file_20140702-50742-1fdbjo6.txt +147 -0
- data/spec/dummy/public/system/resource_export_files/resource_exports/000/000/004/original/resource_export_file_20140704-12784-ozvvo.txt +147 -0
- data/spec/dummy/public/system/resource_export_files/resource_exports/000/000/004/original/resource_export_file_20140705-18550-cc3qx2.txt +147 -0
- data/spec/dummy/public/system/resource_export_files/resource_exports/000/000/004/original/resource_export_file_20140705-19313-rlc624.txt +147 -0
- data/spec/dummy/public/system/resource_export_files/resource_exports/000/000/004/original/resource_export_file_20140705-20440-1o0htch.txt +147 -0
- data/spec/dummy/public/system/resource_export_files/resource_exports/000/000/004/original/{resource_export_file_20140705-26819-14hii8j.txt → resource_export_file_20140705-28145-o9qcd4.txt} +0 -0
- data/spec/dummy/public/system/resource_export_files/resource_exports/000/000/004/original/{resource_export_file_20140705-43608-i7uus1.txt → resource_export_file_20140722-98727-1jesse9.txt} +0 -0
- data/spec/dummy/public/system/resource_export_files/resource_exports/000/000/004/original/resource_export_file_20140816-17115-1c1tv13.txt +147 -0
- data/spec/dummy/public/system/resource_export_files/resource_exports/000/000/004/original/resource_export_file_20140816-18348-14d01b3.txt +147 -0
- data/spec/dummy/solr/test/data/index/_20i.fdt +0 -0
- data/spec/dummy/solr/test/data/index/_20i.fdx +0 -0
- data/spec/dummy/solr/test/data/index/_20i.fnm +0 -0
- data/spec/dummy/solr/test/data/index/_20i.nvd +0 -0
- data/spec/dummy/solr/test/data/index/_20i.nvm +0 -0
- data/spec/dummy/solr/test/data/index/_20i.si +0 -0
- data/spec/dummy/solr/test/data/index/_20i_Lucene41_0.doc +0 -0
- data/spec/dummy/solr/test/data/index/_20i_Lucene41_0.pos +0 -0
- data/spec/dummy/solr/test/data/index/_20i_Lucene41_0.tim +0 -0
- data/spec/dummy/solr/test/data/index/_20i_Lucene41_0.tip +0 -0
- data/spec/dummy/solr/test/data/index/_20j.fdt +0 -0
- data/spec/dummy/solr/test/data/index/_20j.fdx +0 -0
- data/spec/dummy/solr/test/data/index/_20j.fnm +0 -0
- data/spec/dummy/solr/test/data/index/_20j.nvd +0 -0
- data/spec/dummy/solr/test/data/index/_20j.nvm +0 -0
- data/spec/dummy/solr/test/data/index/_20j.si +0 -0
- data/spec/dummy/solr/test/data/index/_20j_Lucene41_0.doc +0 -0
- data/spec/dummy/solr/test/data/index/_20j_Lucene41_0.pos +0 -0
- data/spec/dummy/solr/test/data/index/_20j_Lucene41_0.tim +0 -0
- data/spec/dummy/solr/test/data/index/_20j_Lucene41_0.tip +0 -0
- data/spec/dummy/solr/test/data/index/_20k.fdt +0 -0
- data/spec/dummy/solr/test/data/index/_20k.fdx +0 -0
- data/spec/dummy/solr/test/data/index/_20k.fnm +0 -0
- data/spec/dummy/solr/test/data/index/_20k.nvd +0 -0
- data/spec/dummy/solr/test/data/index/_20k.nvm +0 -0
- data/spec/dummy/solr/test/data/index/_20k.si +0 -0
- data/spec/dummy/solr/test/data/index/_20k_Lucene41_0.doc +0 -0
- data/spec/dummy/solr/test/data/index/_20k_Lucene41_0.pos +0 -0
- data/spec/dummy/solr/test/data/index/_20k_Lucene41_0.tim +0 -0
- data/spec/dummy/solr/test/data/index/_20k_Lucene41_0.tip +0 -0
- data/spec/dummy/solr/test/data/index/segments.gen +0 -0
- data/spec/dummy/solr/test/data/index/segments_2uc +0 -0
- data/spec/dummy/solr/test/data/tlog/{tlog.0000000000000000492 → tlog.0000000000000003680} +0 -0
- data/spec/dummy/solr/test/data/tlog/tlog.0000000000000003681 +0 -0
- data/spec/dummy/solr/test/data/tlog/{tlog.0000000000000000494 → tlog.0000000000000003682} +0 -0
- data/spec/dummy/test/integration/resource_export_file_test.rb +7 -0
- data/spec/dummy/tmp/cache/4F7/F90/default_role +0 -0
- data/spec/dummy/tmp/cache/6E4/420/search_engine_all +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/01c388ec88c5fa6d00409d725549a506 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0440b81b0aae840cf287a686585a8cec +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0483120d2ec851526d1beb322a87b34d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0c0062cfb97ef1437ab0020e724876c6 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0c8f59d97121b79a2e2a0d009d6da9c3 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0d8876cd5c35974067b09df39826ad64 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0dfa4223643dd4c4e2f977989012a78f +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0e3e358e4fe4601ba5e435f6d0c86f12 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/13fe41fee1fe35b49d145bcc06610705 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/1572dfd6f1e555f4be1aa60ddc3cb0c0 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/15aaed1a5a5f4f98d5c8d19084d7980d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/16262df7c7e382ef78b21f453750ea94 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/173711a319dbf01f35a2ad8e1efe08b9 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/19a44bc29c5173edea456f9416243854 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/1c1fbab93e4552626da626e0dbe70c74 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/1d0caee819e97b6e819aff48d160ba0e +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/1eeeee88b80ad204f61af2154ab097db +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/24051f5752691433a5a205b04a62fca1 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/267e026cf7dcb8ed5ca66aa83dff1a87 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/2b35ad8fee7e1228e205669278e2adda +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/2d65b40e585725207fd52ce4cf5134f4 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/2f5173deea6c795b8fdde723bb4b63af +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/305729f8ea45e96c3a7e75df920aa125 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/3417713460df81bb2349531adec5f348 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/357970feca3ac29060c1e3861e2c0953 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/36fe3bdb5b7a6e84e23515bca1842154 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/3ed0e4936463665c59155042a650dfa5 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/3fc2b4de95dbb94dfe82ccfc97265cc4 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/40e90f0c329b14292a9ff1a2fe907b39 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/45adf514664dd4134fb290b1938c56d8 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/45f3c74e1e31b58d9bda6908d5623290 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/46ed442c54e0ad50ed9cbff91bca2c03 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/479d8a0e6643a473b785734c1fb0655b +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/4aa18096a209e515f5f1df487622cdf4 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/4db7c7b5ea13aacccd89ea32460e2de0 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/4facb9d4adad5d1f55e19897f19ff502 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/51df74c0fa7fbfa41670caa0f4268d54 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/53ce49f7cb73ec18bfefea19be486fd5 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/55de678ed3c84c51b3a4b4cf473da823 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/5686725a34a5b152399098fe6811dfcc +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/5762cca052dd5d3eb8bb35e2ed9a59b8 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/59d9f2ec47e055feaa8deb88dd230fd9 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/5d30286c45c334a3e08806b2713ddbcd +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/5f084c5c398edfb6e223c67ec8fbf80d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/60d030b3fef398bd6c75b5342c1e6951 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/6273ac5ec2eeeb08808c520e45e7c353 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/64513343a4d1500f6642a9797f2d6caf +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/64ee480e95febf6b404c1264755ea42e +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/6580b1bd3cb606ae0cc6a660e43ee91d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/66e8ff0ee49363fdd0e1866807515228 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/67ef1f14c3ad48997b6d2971949a9974 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/6cf8b3b420dc28c045daec27150ade0a +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/7395823b7ae60934b3053f26fdb362d4 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/74c056fa2e48770cba3499207a5027f5 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/796cd029cd1ff06c3212795cdcc5a7c4 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/7de140ed6f303b9d00d8d703cced3349 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/7ef97a0c04f996570fa8d054e77614e4 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/80348afae86df384b25e1e3bff21b13e +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/814bc1bed3effa0bb4588eb8b75ab92a +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/8488002e0e6035b7d00c3800c2c0e27e +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/84c8a64682205dba3f8edd60fc1ec8e5 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/86dfe8a3e156aeb6ebcd456b2251fab7 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/89c9228bae34e0ff18fd8fe7f6eb5847 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/8e2bf5102d77a2cff3dda27a5617a79d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/9411c91747cff7187d3b5eb3d5401758 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/98d02556564ee10aef4c3397bb94d5b9 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/994c519d4fdf48cadf8846c64a7c217d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/9a11ac4cf3c8597981773b8ea1c36659 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/a2474b74df12470fb37c668b85b562c6 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/a2ee8688f63b884277632a234086f7df +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/a3cea75f1356ef55329e78f86b4c72b1 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/a5ff35005a82346756c8a2d9b564aa8e +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/a72fe28675ab93fbb5f1fab49703e8b8 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/aa2e1ada35daa496bb08e85fcb817536 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/b0e11c6d89683eaa7256a44a164a2a12 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/b530f21ccf5882027bf2aff5502dc79e +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/b62c2d32477b85c1a8e33a4b3ba86483 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/b817a9a61cc21da35abec9d0dfb2a143 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/b9ad765321d7527b38c851119d4d6f41 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/bc086c9c936e5b91659a438d35126a90 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/bf17ca8affe2a1febca7f2a4e37cd77b +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c21a9a8a5166b51d4c2737ad4b99c16b +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c36b7431da1ae91722b1c4091e4ba084 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c3e87e99d52cd8082c8548a7aa63b9da +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c40786442706ae0cc6c793c6ee2500d3 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c42ec68313928d1544e733ae8383ef6d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c488c91e58a235d36a0ff8058e5a1004 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c4dbc19d89022a35885f5621f6b86eb3 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c6bbf5ca5c9b58807ba226fde0ccc60f +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c7b0db461dfcfc1108bf9a6a87fb909d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c9d565eb8899b86408d9fd06fbf039be +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/cfeee09fa6b6ec2344a7b44bf0676028 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/cffd775d018f68ce5dba1ee0d951a994 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/d771ace226fc8215a3572e0aa35bb0d6 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/d8d8b7e606faf0fa1c22a6c2ebc2b58f +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/d8e283e15fd77782ae12f9b18e5be456 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/d909adefad62117a3e85463b83954827 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/e1fcfb0faa3c12467a1c35251e04c8b1 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/e22f9546f5d75bd3549886e979dcb96e +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/e577e9ce00153ad2e59111f761d0fb15 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/e58908ad0ccad6546faf9bcab669b0cd +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/e8f801eeda49cba4a03cfd9e2a4562ae +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/ea6fdf5f7aa83bf540d26f1ae12159a8 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/eef93e7d091d8118419fb96adf80387b +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/efd104c04916854411c86a5440ba30e0 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/f32a42f77e45018f7748de516be3c393 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/f7cbd26ba1d28d48de824f0e94586655 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/fb91323d4585f2e27d281cdb4193beb1 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/fd080bad11122c7c3147a3fe1964c396 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/fd88f9f1128cbff14dd2fa00800cfa10 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/fe5bcfd29764185be3d476dee4108595 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/ff64e9ded481959dfa8c78718e59e607 +0 -0
- data/spec/dummy/tmp/cache/stdout +3579 -87
- data/spec/dummy/tmp/pids/redis-test.pid +1 -1
- data/spec/factories/agent.rb +1 -1
- data/spec/factories/profile.rb +10 -0
- data/spec/factories/user.rb +21 -12
- data/spec/fixtures/agent_relationship_types.yml +3 -3
- data/spec/fixtures/agent_types.yml +3 -3
- data/spec/fixtures/agents.yml +0 -7
- data/spec/fixtures/carrier_types.yml +2 -2
- data/spec/fixtures/items.yml +46 -19
- data/spec/fixtures/manifestations.yml +1 -0
- data/spec/fixtures/message_requests.yml +3 -4
- data/spec/fixtures/message_templates.yml +51 -16
- data/spec/fixtures/profiles.yml +98 -0
- data/spec/fixtures/reserve_transitions.yml +88 -0
- data/spec/fixtures/resource_import_files.yml +1 -1
- data/spec/fixtures/user_groups.yml +3 -3
- data/spec/models/agent_import_file_spec.rb +0 -3
- data/spec/models/agent_spec.rb +0 -1
- data/spec/models/item_spec.rb +36 -26
- data/spec/models/manifestation_spec.rb +7 -0
- data/spec/models/resource_export_file_spec.rb +3 -0
- data/spec/models/resource_import_file_spec.rb +63 -34
- data/spec/spec_helper.rb +0 -1
- data/spec/support/resque.rb +3 -2
- data/spec/views/agent_types/index.html.erb_spec.rb +2 -2
- data/spec/views/create_types/index.html.erb_spec.rb +2 -2
- data/spec/views/produce_types/index.html.erb_spec.rb +2 -2
- data/spec/views/realize_types/index.html.erb_spec.rb +2 -2
- metadata +391 -67
- data/app/controllers/exemplifies_controller.rb +0 -103
- data/app/views/exemplifies/_form.html.erb +0 -27
- data/app/views/exemplifies/edit.html.erb +0 -13
- data/app/views/exemplifies/index.html.erb +0 -38
- data/app/views/exemplifies/new.html.erb +0 -12
- data/app/views/exemplifies/show.html.erb +0 -24
- data/app/views/items/index.csv.erb +0 -4
- data/app/views/manifestations/_question_list.html.erb +0 -13
- data/lib/generators/enju_biblio/setup/templates/db/fixtures/request_status_types.yml +0 -37
- data/lib/generators/enju_biblio/setup/templates/db/fixtures/request_types.yml +0 -29
- data/spec/controllers/exemplifies_controller_spec.rb +0 -446
- data/spec/dummy/db/migrate/20111201155456_create_users.rb +0 -16
- data/spec/dummy/db/migrate/20111201155513_add_devise_to_users.rb +0 -44
- data/spec/dummy/solr/test/data/index/segments_dv +0 -0
- data/spec/dummy/solr/test/data/tlog/tlog.0000000000000000493 +0 -0
- data/spec/dummy/solr/test/data/tlog/tlog.0000000000000000495 +0 -0
- data/spec/dummy/solr/test/data/tlog/tlog.0000000000000000496 +0 -0
- data/spec/dummy/solr/test/data/tlog/tlog.0000000000000000497 +0 -0
- data/spec/views/exemplifies/edit.html.erb_spec.rb +0 -22
- data/spec/views/exemplifies/index.html.erb_spec.rb +0 -25
- data/spec/views/exemplifies/new.html.erb_spec.rb +0 -22
- data/spec/views/exemplifies/show.html.erb_spec.rb +0 -19
@@ -1,17 +1,16 @@
|
|
1
1
|
# -*- encoding: utf-8 -*-
|
2
2
|
class ItemsController < ApplicationController
|
3
3
|
load_and_authorize_resource
|
4
|
-
before_filter :get_agent, :get_manifestation, :get_shelf, :
|
4
|
+
before_filter :get_agent, :get_manifestation, :get_shelf, except: [:create, :update, :destroy]
|
5
5
|
if defined?(EnjuInventory)
|
6
6
|
before_filter :get_inventory_file
|
7
7
|
end
|
8
|
-
before_filter :get_library, :get_item, :
|
9
|
-
before_filter :prepare_options, :
|
10
|
-
before_filter :get_version, :
|
8
|
+
before_filter :get_library, :get_item, except: [:create, :update, :destroy]
|
9
|
+
before_filter :prepare_options, only: [:new, :edit]
|
10
|
+
before_filter :get_version, only: [:show]
|
11
11
|
#before_filter :store_location
|
12
|
-
after_filter :solr_commit, :
|
13
|
-
after_filter :convert_charset, :
|
14
|
-
cache_sweeper :item_sweeper, :only => [:create, :update, :destroy]
|
12
|
+
after_filter :solr_commit, only: [:create, :update, :destroy]
|
13
|
+
after_filter :convert_charset, only: :index
|
15
14
|
|
16
15
|
# GET /items
|
17
16
|
# GET /items.json
|
@@ -21,7 +20,7 @@ class ItemsController < ApplicationController
|
|
21
20
|
@count = {}
|
22
21
|
if user_signed_in?
|
23
22
|
if current_user.has_role?('Librarian')
|
24
|
-
if params[:format] == '
|
23
|
+
if params[:format] == 'txt'
|
25
24
|
per_page = 65534
|
26
25
|
elsif params[:mode] == 'barcode'
|
27
26
|
per_page = 40
|
@@ -112,7 +111,7 @@ class ItemsController < ApplicationController
|
|
112
111
|
|
113
112
|
if defined?(EnjuBarcode)
|
114
113
|
if params[:mode] == 'barcode'
|
115
|
-
render :
|
114
|
+
render action: 'barcode', layout: false
|
116
115
|
return
|
117
116
|
end
|
118
117
|
end
|
@@ -121,8 +120,8 @@ class ItemsController < ApplicationController
|
|
121
120
|
|
122
121
|
respond_to do |format|
|
123
122
|
format.html # index.html.erb
|
124
|
-
format.json { render :
|
125
|
-
format.
|
123
|
+
format.json { render json: @items }
|
124
|
+
format.txt { render layout: false }
|
126
125
|
format.atom
|
127
126
|
end
|
128
127
|
end
|
@@ -135,7 +134,7 @@ class ItemsController < ApplicationController
|
|
135
134
|
|
136
135
|
respond_to do |format|
|
137
136
|
format.html # show.html.erb
|
138
|
-
format.json { render :
|
137
|
+
format.json { render json: @item }
|
139
138
|
end
|
140
139
|
end
|
141
140
|
|
@@ -157,22 +156,22 @@ class ItemsController < ApplicationController
|
|
157
156
|
@item.manifestation_id = @manifestation.id
|
158
157
|
if defined?(EnjuCirculation)
|
159
158
|
@circulation_statuses = CirculationStatus.where(
|
160
|
-
:
|
159
|
+
name: [
|
161
160
|
'In Process',
|
162
161
|
'Available For Pickup',
|
163
162
|
'Available On Shelf',
|
164
163
|
'Claimed Returned Or Never Borrowed',
|
165
164
|
'Not Available']
|
166
165
|
).order(:position)
|
167
|
-
@item.circulation_status = CirculationStatus.where(:
|
166
|
+
@item.circulation_status = CirculationStatus.where(name: 'In Process').first
|
168
167
|
@item.checkout_type = @manifestation.carrier_type.checkout_types.first
|
169
168
|
@item.item_has_use_restriction = ItemHasUseRestriction.new
|
170
|
-
@item.item_has_use_restriction.use_restriction = UseRestriction.where(:
|
169
|
+
@item.item_has_use_restriction.use_restriction = UseRestriction.where(name: 'Not For Loan').first
|
171
170
|
end
|
172
171
|
|
173
172
|
respond_to do |format|
|
174
173
|
format.html # new.html.erb
|
175
|
-
format.json { render :
|
174
|
+
format.json { render json: @item }
|
176
175
|
end
|
177
176
|
end
|
178
177
|
|
@@ -182,7 +181,7 @@ class ItemsController < ApplicationController
|
|
182
181
|
if defined?(EnjuCirculation)
|
183
182
|
unless @item.use_restriction
|
184
183
|
@item.build_item_has_use_restriction
|
185
|
-
@item.item_has_use_restriction.use_restriction = UseRestriction.where(:
|
184
|
+
@item.item_has_use_restriction.use_restriction = UseRestriction.where(name: 'Not For Loan').first
|
186
185
|
end
|
187
186
|
end
|
188
187
|
end
|
@@ -204,12 +203,12 @@ class ItemsController < ApplicationController
|
|
204
203
|
end
|
205
204
|
end
|
206
205
|
end
|
207
|
-
format.html { redirect_to(@item, :
|
208
|
-
format.json { render :
|
206
|
+
format.html { redirect_to(@item, notice: t('controller.successfully_created', model: t('activerecord.models.item'))) }
|
207
|
+
format.json { render json: @item, status: :created, location: @item }
|
209
208
|
else
|
210
209
|
prepare_options
|
211
|
-
format.html { render :
|
212
|
-
format.json { render :
|
210
|
+
format.html { render action: "new" }
|
211
|
+
format.json { render json: @item.errors, status: :unprocessable_entity }
|
213
212
|
end
|
214
213
|
end
|
215
214
|
end
|
@@ -219,12 +218,12 @@ class ItemsController < ApplicationController
|
|
219
218
|
def update
|
220
219
|
respond_to do |format|
|
221
220
|
if @item.update_attributes(params[:item])
|
222
|
-
format.html { redirect_to @item, :
|
221
|
+
format.html { redirect_to @item, notice: t('controller.successfully_updated', model: t('activerecord.models.item')) }
|
223
222
|
format.json { head :no_content }
|
224
223
|
else
|
225
224
|
prepare_options
|
226
|
-
format.html { render :
|
227
|
-
format.json { render :
|
225
|
+
format.html { render action: "edit" }
|
226
|
+
format.json { render json: @item.errors, status: :unprocessable_entity }
|
228
227
|
end
|
229
228
|
end
|
230
229
|
end
|
@@ -236,9 +235,9 @@ class ItemsController < ApplicationController
|
|
236
235
|
@item.destroy
|
237
236
|
|
238
237
|
respond_to do |format|
|
239
|
-
flash[:notice] = t('controller.successfully_deleted', :
|
238
|
+
flash[:notice] = t('controller.successfully_deleted', model: t('activerecord.models.item'))
|
240
239
|
if @item.manifestation
|
241
|
-
format.html { redirect_to
|
240
|
+
format.html { redirect_to items_url(manifestation_id: manifestation.id) }
|
242
241
|
format.json { head :no_content }
|
243
242
|
else
|
244
243
|
format.html { redirect_to items_url }
|
@@ -1,8 +1,8 @@
|
|
1
1
|
class ManifestationRelationshipsController < InheritedResources::Base
|
2
2
|
respond_to :html, :json
|
3
|
-
has_scope :page, :
|
3
|
+
has_scope :page, default: 1
|
4
4
|
load_and_authorize_resource
|
5
|
-
before_filter :prepare_options, :
|
5
|
+
before_filter :prepare_options, except: [:index, :destroy]
|
6
6
|
|
7
7
|
def new
|
8
8
|
@manifestation_relationship = ManifestationRelationship.new(params[:manifestation_relationship])
|
@@ -1,20 +1,19 @@
|
|
1
1
|
# -*- encoding: utf-8 -*-
|
2
2
|
class ManifestationsController < ApplicationController
|
3
|
-
load_and_authorize_resource :
|
4
|
-
authorize_resource :
|
5
|
-
before_filter :authenticate_user!, :
|
6
|
-
before_filter :get_agent, :get_manifestation, :
|
7
|
-
before_filter :get_expression, :
|
3
|
+
load_and_authorize_resource except: :index
|
4
|
+
authorize_resource only: :index
|
5
|
+
before_filter :authenticate_user!, only: :edit
|
6
|
+
before_filter :get_agent, :get_manifestation, except: [:create, :update, :destroy]
|
7
|
+
before_filter :get_expression, only: :new
|
8
8
|
if defined?(EnjuSubject)
|
9
|
-
before_filter :get_subject, :
|
9
|
+
before_filter :get_subject, except: [:create, :update, :destroy]
|
10
10
|
end
|
11
|
-
before_filter :get_series_statement, :
|
12
|
-
before_filter :get_item, :get_libraries, :
|
13
|
-
before_filter :prepare_options, :
|
14
|
-
before_filter :get_version, :
|
15
|
-
after_filter :solr_commit, :
|
16
|
-
after_filter :convert_charset, :
|
17
|
-
cache_sweeper :manifestation_sweeper, :only => [:create, :update, :destroy]
|
11
|
+
before_filter :get_series_statement, only: [:index, :new, :edit]
|
12
|
+
before_filter :get_item, :get_libraries, only: :index
|
13
|
+
before_filter :prepare_options, only: [:new, :edit]
|
14
|
+
before_filter :get_version, only: [:show]
|
15
|
+
after_filter :solr_commit, only: :destroy
|
16
|
+
after_filter :convert_charset, only: :index
|
18
17
|
include EnjuOai::OaiController if defined?(EnjuOai)
|
19
18
|
include EnjuSearchLog if defined?(EnjuSearchLog)
|
20
19
|
|
@@ -54,10 +53,10 @@ class ManifestationsController < ApplicationController
|
|
54
53
|
@manifestation = Manifestation.find_by_oai_identifier(params[:identifier])
|
55
54
|
rescue ActiveRecord::RecordNotFound
|
56
55
|
@oai[:errors] << "idDoesNotExist"
|
57
|
-
render :formats => :oai, :
|
56
|
+
render :formats => :oai, layout: false
|
58
57
|
return
|
59
58
|
end
|
60
|
-
render :
|
59
|
+
render template: 'manifestations/show', :formats => :oai, layout: false
|
61
60
|
return
|
62
61
|
end
|
63
62
|
end
|
@@ -68,7 +67,7 @@ class ManifestationsController < ApplicationController
|
|
68
67
|
manifestations, sort, @count = {}, {}, {}
|
69
68
|
query = ""
|
70
69
|
|
71
|
-
if params[:format] == '
|
70
|
+
if params[:format] == 'txt'
|
72
71
|
per_page = 65534
|
73
72
|
end
|
74
73
|
|
@@ -78,7 +77,7 @@ class ManifestationsController < ApplicationController
|
|
78
77
|
query = sru.cql.to_sunspot
|
79
78
|
sort = sru.sort_by
|
80
79
|
else
|
81
|
-
render :
|
80
|
+
render template: 'manifestations/explain', layout: false
|
82
81
|
return
|
83
82
|
end
|
84
83
|
else
|
@@ -225,7 +224,7 @@ class ManifestationsController < ApplicationController
|
|
225
224
|
#bookmark_ids = Bookmark.where(:manifestation_id => flash[:manifestation_ids]).limit(1000).pluck(:id)
|
226
225
|
bookmark_ids = Bookmark.where(:manifestation_id => @manifestation_ids).limit(1000).pluck(:id)
|
227
226
|
@tags = Tag.bookmarked(bookmark_ids)
|
228
|
-
render :
|
227
|
+
render partial: 'manifestations/tag_cloud'
|
229
228
|
return
|
230
229
|
end
|
231
230
|
end
|
@@ -320,28 +319,28 @@ class ManifestationsController < ApplicationController
|
|
320
319
|
format.html
|
321
320
|
format.mobile
|
322
321
|
format.xml { render :xml => @manifestations }
|
323
|
-
format.sru { render :
|
324
|
-
format.rss { render :
|
325
|
-
format.
|
326
|
-
format.rdf { render :
|
322
|
+
format.sru { render layout: false }
|
323
|
+
format.rss { render layout: false }
|
324
|
+
format.txt { render layout: false }
|
325
|
+
format.rdf { render layout: false }
|
327
326
|
format.atom
|
328
327
|
format.mods
|
329
|
-
format.json { render :
|
328
|
+
format.json { render json: @manifestations }
|
330
329
|
format.js
|
331
330
|
if defined?(EnjuOai)
|
332
331
|
format.oai {
|
333
332
|
case params[:verb]
|
334
333
|
when 'Identify'
|
335
|
-
render :
|
334
|
+
render template: 'manifestations/identify'
|
336
335
|
when 'ListMetadataFormats'
|
337
|
-
render :
|
336
|
+
render template: 'manifestations/list_metadata_formats'
|
338
337
|
when 'ListSets'
|
339
338
|
@series_statements = SeriesStatement.select([:id, :original_title])
|
340
|
-
render :
|
339
|
+
render template: 'manifestations/list_sets'
|
341
340
|
when 'ListIdentifiers'
|
342
|
-
render :
|
341
|
+
render template: 'manifestations/list_identifiers'
|
343
342
|
when 'ListRecords'
|
344
|
-
render :
|
343
|
+
render template: 'manifestations/list_records'
|
345
344
|
end
|
346
345
|
}
|
347
346
|
end
|
@@ -402,27 +401,27 @@ class ManifestationsController < ApplicationController
|
|
402
401
|
format.xml {
|
403
402
|
case params[:mode]
|
404
403
|
when 'related'
|
405
|
-
render :
|
404
|
+
render template: 'manifestations/related'
|
406
405
|
else
|
407
406
|
render :xml => @manifestation
|
408
407
|
end
|
409
408
|
}
|
410
409
|
format.rdf
|
411
410
|
format.mods
|
412
|
-
format.json { render :
|
413
|
-
#format.atom { render :
|
411
|
+
format.json { render json: @manifestation }
|
412
|
+
#format.atom { render template: 'manifestations/oai_ore' }
|
414
413
|
#format.js
|
415
414
|
format.download {
|
416
415
|
if @manifestation.attachment.path
|
417
416
|
if Setting.uploaded_file.storage == :s3
|
418
|
-
send_data @manifestation.attachment.data, :
|
417
|
+
send_data @manifestation.attachment.data, filename: File.basename(@manifestation.attachment_file_name), type: 'application/octet-stream'
|
419
418
|
else
|
420
419
|
if File.exist?(file) and File.file?(file)
|
421
|
-
send_file file, :
|
420
|
+
send_file file, filename: File.basename(@manifestation.attachment_file_name), type: 'application/octet-stream'
|
422
421
|
end
|
423
422
|
end
|
424
423
|
else
|
425
|
-
render :
|
424
|
+
render template: 'page/404', status: 404
|
426
425
|
end
|
427
426
|
}
|
428
427
|
if defined?(EnjuOai)
|
@@ -436,17 +435,17 @@ class ManifestationsController < ApplicationController
|
|
436
435
|
def new
|
437
436
|
@manifestation = Manifestation.new
|
438
437
|
@manifestation.language = Language.where(:iso_639_1 => @locale).first
|
439
|
-
parent = Manifestation.where(:id => params[:parent_id]).first if params[:parent_id].present?
|
440
|
-
if parent
|
441
|
-
@manifestation.parent_id = parent.id
|
442
|
-
@manifestation.original_title = parent.original_title
|
443
|
-
@manifestation.title_transcription = parent.title_transcription
|
444
|
-
@manifestation.periodical = true if parent.periodical
|
438
|
+
@parent = Manifestation.where(:id => params[:parent_id]).first if params[:parent_id].present?
|
439
|
+
if @parent
|
440
|
+
@manifestation.parent_id = @parent.id
|
441
|
+
@manifestation.original_title = @parent.original_title
|
442
|
+
@manifestation.title_transcription = @parent.title_transcription
|
443
|
+
@manifestation.periodical = true if @parent.periodical
|
445
444
|
end
|
446
445
|
|
447
446
|
respond_to do |format|
|
448
447
|
format.html # new.html.erb
|
449
|
-
format.json { render :
|
448
|
+
format.json { render json: @manifestation }
|
450
449
|
end
|
451
450
|
end
|
452
451
|
|
@@ -460,7 +459,7 @@ class ManifestationsController < ApplicationController
|
|
460
459
|
if defined?(EnjuBookmark)
|
461
460
|
if params[:mode] == 'tag_edit'
|
462
461
|
@bookmark = current_user.bookmarks.where(:manifestation_id => @manifestation.id).first if @manifestation rescue nil
|
463
|
-
render :
|
462
|
+
render partial: 'manifestations/tag_edit', locals: {manifestation: @manifestation}
|
464
463
|
end
|
465
464
|
store_location unless params[:mode] == 'tag_edit'
|
466
465
|
end
|
@@ -484,12 +483,12 @@ class ManifestationsController < ApplicationController
|
|
484
483
|
end
|
485
484
|
Sunspot.commit
|
486
485
|
|
487
|
-
format.html { redirect_to @manifestation, :
|
488
|
-
format.json { render :
|
486
|
+
format.html { redirect_to @manifestation, notice: t('controller.successfully_created', model: t('activerecord.models.manifestation')) }
|
487
|
+
format.json { render json: @manifestation, status: :created, location: @manifestation }
|
489
488
|
else
|
490
489
|
prepare_options
|
491
|
-
format.html { render :
|
492
|
-
format.json { render :
|
490
|
+
format.html { render action: "new" }
|
491
|
+
format.json { render json: @manifestation.errors, status: :unprocessable_entity }
|
493
492
|
end
|
494
493
|
end
|
495
494
|
end
|
@@ -500,12 +499,12 @@ class ManifestationsController < ApplicationController
|
|
500
499
|
respond_to do |format|
|
501
500
|
if @manifestation.update_attributes(params[:manifestation])
|
502
501
|
Sunspot.commit
|
503
|
-
format.html { redirect_to @manifestation, :
|
502
|
+
format.html { redirect_to @manifestation, notice: t('controller.successfully_updated', model: t('activerecord.models.manifestation')) }
|
504
503
|
format.json { head :no_content }
|
505
504
|
else
|
506
505
|
prepare_options
|
507
|
-
format.html { render :
|
508
|
-
format.json { render :
|
506
|
+
format.html { render action: "edit" }
|
507
|
+
format.json { render json: @manifestation.errors, status: :unprocessable_entity }
|
509
508
|
end
|
510
509
|
end
|
511
510
|
end
|
@@ -513,10 +512,16 @@ class ManifestationsController < ApplicationController
|
|
513
512
|
# DELETE /manifestations/1
|
514
513
|
# DELETE /manifestations/1.json
|
515
514
|
def destroy
|
515
|
+
# workaround
|
516
|
+
@manifestation.identifiers.destroy_all
|
517
|
+
@manifestation.creators.destroy_all
|
518
|
+
@manifestation.publishers.destroy_all
|
519
|
+
@manifestation.bookmarks.destroy_all if defined?(EnjuBookmark)
|
520
|
+
@manifestation.reload
|
516
521
|
@manifestation.destroy
|
517
522
|
|
518
523
|
respond_to do |format|
|
519
|
-
format.html { redirect_to manifestations_url, :
|
524
|
+
format.html { redirect_to manifestations_url, notice: t('controller.successfully_deleted', model: t('activerecord.models.manifestation')) }
|
520
525
|
format.json { head :no_content }
|
521
526
|
end
|
522
527
|
end
|
@@ -645,31 +650,31 @@ class ManifestationsController < ApplicationController
|
|
645
650
|
def render_mode(mode)
|
646
651
|
case mode
|
647
652
|
when 'holding'
|
648
|
-
render :
|
653
|
+
render partial: 'manifestations/show_holding', locals: {manifestation: @manifestation}
|
649
654
|
when 'barcode'
|
650
655
|
if defined?(EnjuBarcode)
|
651
656
|
barcode = Barby::QrCode.new(@manifestation.id)
|
652
|
-
send_data(barcode.to_svg, :disposition => 'inline', :
|
657
|
+
send_data(barcode.to_svg, :disposition => 'inline', type: 'image/svg+xml')
|
653
658
|
end
|
654
659
|
when 'tag_edit'
|
655
660
|
if defined?(EnjuBookmark)
|
656
|
-
render :
|
661
|
+
render partial: 'manifestations/tag_edit', locals: {manifestation: @manifestation}
|
657
662
|
end
|
658
663
|
when 'tag_list'
|
659
664
|
if defined?(EnjuBookmark)
|
660
|
-
render :
|
665
|
+
render partial: 'manifestations/tag_list', locals: {manifestation: @manifestation}
|
661
666
|
end
|
662
667
|
when 'show_index'
|
663
|
-
render :
|
668
|
+
render partial: 'manifestations/show_index', locals: {manifestation: @manifestation}
|
664
669
|
when 'show_creators'
|
665
|
-
render :
|
670
|
+
render partial: 'manifestations/show_creators', locals: {manifestation: @manifestation}
|
666
671
|
when 'show_all_creators'
|
667
|
-
render :
|
672
|
+
render partial: 'manifestations/show_creators', locals: {manifestation: @manifestation}
|
668
673
|
when 'pickup'
|
669
|
-
render :
|
674
|
+
render partial: 'manifestations/pickup', locals: {manifestation: @manifestation}
|
670
675
|
when 'calil_list'
|
671
676
|
if defined?(EnjuCalil)
|
672
|
-
render :
|
677
|
+
render partial: 'manifestations/calil_list', locals: {manifestation: @manifestation}
|
673
678
|
end
|
674
679
|
else
|
675
680
|
false
|
@@ -1,8 +1,7 @@
|
|
1
1
|
class OwnsController < ApplicationController
|
2
2
|
load_and_authorize_resource
|
3
3
|
before_filter :get_agent, :get_item
|
4
|
-
after_filter :solr_commit, :
|
5
|
-
cache_sweeper :page_sweeper, :only => [:create, :update, :destroy]
|
4
|
+
after_filter :solr_commit, only: [:create, :update, :destroy]
|
6
5
|
|
7
6
|
# GET /owns
|
8
7
|
# GET /owns.json
|
@@ -17,7 +16,7 @@ class OwnsController < ApplicationController
|
|
17
16
|
|
18
17
|
respond_to do |format|
|
19
18
|
format.html # index.html.erb
|
20
|
-
format.json { render :
|
19
|
+
format.json { render json: @owns }
|
21
20
|
end
|
22
21
|
end
|
23
22
|
|
@@ -26,7 +25,7 @@ class OwnsController < ApplicationController
|
|
26
25
|
def show
|
27
26
|
respond_to do |format|
|
28
27
|
format.html # show.html.erb
|
29
|
-
format.json { render :
|
28
|
+
format.json { render json: @own }
|
30
29
|
end
|
31
30
|
end
|
32
31
|
|
@@ -56,11 +55,11 @@ class OwnsController < ApplicationController
|
|
56
55
|
|
57
56
|
respond_to do |format|
|
58
57
|
if @own.save
|
59
|
-
format.html { redirect_to @own, :
|
60
|
-
format.json { render :
|
58
|
+
format.html { redirect_to @own, notice: t('controller.successfully_created', model: t('activerecord.models.own')) }
|
59
|
+
format.json { render json: @own, status: :created, location: @own }
|
61
60
|
else
|
62
|
-
format.html { render :
|
63
|
-
format.json { render :
|
61
|
+
format.html { render action: "new" }
|
62
|
+
format.json { render json: @own.errors, status: :unprocessable_entity }
|
64
63
|
end
|
65
64
|
end
|
66
65
|
end
|
@@ -70,17 +69,17 @@ class OwnsController < ApplicationController
|
|
70
69
|
def update
|
71
70
|
if @item and params[:move]
|
72
71
|
move_position(@own, params[:move], false)
|
73
|
-
redirect_to
|
72
|
+
redirect_to owns_url(item_id: @own.item_id)
|
74
73
|
return
|
75
74
|
end
|
76
75
|
|
77
76
|
respond_to do |format|
|
78
77
|
if @own.update_attributes(params[:own])
|
79
|
-
format.html { redirect_to @own, :
|
78
|
+
format.html { redirect_to @own, notice: t('controller.successfully_updated', model: t('activerecord.models.own')) }
|
80
79
|
format.json { head :no_content }
|
81
80
|
else
|
82
|
-
format.html { render :
|
83
|
-
format.json { render :
|
81
|
+
format.html { render action: "edit" }
|
82
|
+
format.json { render json: @own.errors, status: :unprocessable_entity }
|
84
83
|
end
|
85
84
|
end
|
86
85
|
end
|
@@ -92,7 +91,7 @@ class OwnsController < ApplicationController
|
|
92
91
|
|
93
92
|
respond_to do |format|
|
94
93
|
format.html {
|
95
|
-
flash[:notice] = t('controller.successfully_deleted', :
|
94
|
+
flash[:notice] = t('controller.successfully_deleted', model: t('activerecord.models.own'))
|
96
95
|
case
|
97
96
|
when @agent
|
98
97
|
redirect_to agent_owns_url(@agent)
|
@@ -1,7 +1,6 @@
|
|
1
1
|
class PictureFilesController < ApplicationController
|
2
2
|
load_and_authorize_resource
|
3
|
-
before_filter :get_attachable, :
|
4
|
-
cache_sweeper :page_sweeper, :only => [:create, :update, :destroy]
|
3
|
+
before_filter :get_attachable, only: [:index, :new]
|
5
4
|
|
6
5
|
# GET /picture_files
|
7
6
|
# GET /picture_files.json
|
@@ -14,7 +13,7 @@ class PictureFilesController < ApplicationController
|
|
14
13
|
|
15
14
|
respond_to do |format|
|
16
15
|
format.html # index.html.erb
|
17
|
-
format.json { render :
|
16
|
+
format.json { render json: @picture_files }
|
18
17
|
end
|
19
18
|
end
|
20
19
|
|
@@ -40,7 +39,7 @@ class PictureFilesController < ApplicationController
|
|
40
39
|
|
41
40
|
respond_to do |format|
|
42
41
|
format.html # show.html.erb
|
43
|
-
format.json { render :
|
42
|
+
format.json { render json: @picture_file }
|
44
43
|
format.mobile {
|
45
44
|
if params[:format] == 'download'
|
46
45
|
render_image(file)
|
@@ -65,7 +64,7 @@ class PictureFilesController < ApplicationController
|
|
65
64
|
|
66
65
|
respond_to do |format|
|
67
66
|
format.html # new.html.erb
|
68
|
-
format.json { render :
|
67
|
+
format.json { render json: @picture_file }
|
69
68
|
end
|
70
69
|
end
|
71
70
|
|
@@ -80,11 +79,11 @@ class PictureFilesController < ApplicationController
|
|
80
79
|
|
81
80
|
respond_to do |format|
|
82
81
|
if @picture_file.save
|
83
|
-
format.html { redirect_to @picture_file, :
|
84
|
-
format.json { render :
|
82
|
+
format.html { redirect_to @picture_file, notice: t('controller.successfully_created', model: t('activerecord.models.picture_file')) }
|
83
|
+
format.json { render json: @picture_file, status: :created, location: @picture_file }
|
85
84
|
else
|
86
|
-
format.html { render :
|
87
|
-
format.json { render :
|
85
|
+
format.html { render action: "new" }
|
86
|
+
format.json { render json: @picture_file.errors, status: :unprocessable_entity }
|
88
87
|
end
|
89
88
|
end
|
90
89
|
end
|
@@ -108,11 +107,11 @@ class PictureFilesController < ApplicationController
|
|
108
107
|
|
109
108
|
respond_to do |format|
|
110
109
|
if @picture_file.update_attributes(params[:picture_file])
|
111
|
-
format.html { redirect_to @picture_file, :
|
110
|
+
format.html { redirect_to @picture_file, notice: t('controller.successfully_updated', model: t('activerecord.models.picture_file')) }
|
112
111
|
format.json { head :no_content }
|
113
112
|
else
|
114
|
-
format.html { render :
|
115
|
-
format.json { render :
|
113
|
+
format.html { render action: "edit" }
|
114
|
+
format.json { render json: @picture_file.errors, status: :unprocessable_entity }
|
116
115
|
end
|
117
116
|
end
|
118
117
|
end
|
@@ -167,10 +166,10 @@ class PictureFilesController < ApplicationController
|
|
167
166
|
|
168
167
|
if @picture_file.picture.path
|
169
168
|
if Setting.uploaded_file.storage == :s3
|
170
|
-
send_data file, :
|
169
|
+
send_data file, filename: File.basename(@picture_file.picture_file_name), type: @picture_file.picture_content_type, :disposition => disposition
|
171
170
|
else
|
172
171
|
if File.exist?(file) and File.file?(file)
|
173
|
-
send_file file, :
|
172
|
+
send_file file, filename: File.basename(@picture_file.picture_file_name), type: @picture_file.picture_content_type, :disposition => disposition
|
174
173
|
end
|
175
174
|
end
|
176
175
|
end
|