hydra-head 4.0.0 → 4.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +5 -1
- data/Gemfile.lock +17 -3
- data/README.textile +32 -15
- data/app/assets/javascripts/jquery.form.js +932 -531
- data/app/helpers/hydra/facets_helper_behavior.rb +1 -1
- data/app/helpers/hydra/hydra_helper_behavior.rb +1 -1
- data/app/helpers/hydra/javascript_includes_helper_behavior.rb +0 -4
- data/app/models/ability.rb +1 -0
- data/app/models/common_metadata_asset.rb +7 -1
- data/app/models/generic_content.rb +5 -1
- data/app/models/generic_image.rb +7 -3
- data/app/models/hydra/ability.rb +2 -0
- data/app/models/hydra/datastream/common_mods_index_methods.rb +2 -0
- data/app/models/hydra/datastream/mods_article.rb +2 -0
- data/app/models/hydra/datastream/mods_dataset.rb +7 -0
- data/app/models/hydra/datastream/mods_generic_content.rb +2 -0
- data/app/models/hydra/datastream/mods_image.rb +1 -0
- data/app/models/hydra/datastream/properties.rb +6 -1
- data/app/models/hydra/datastream/rights_metadata.rb +1 -0
- data/app/models/hydra/role_mapper_behavior.rb +1 -0
- data/app/models/mods_asset.rb +1 -1
- data/app/models/role_mapper.rb +3 -0
- data/app/models/superuser.rb +6 -0
- data/app/models/user_attribute.rb +6 -0
- data/app/models/uses_default_partials.rb +8 -0
- data/app/views/catalog/_delete_partials/_default.html.erb +2 -9
- data/app/views/catalog/_edit_partials/_default.html.erb +0 -1
- data/app/views/catalog/show.html.erb +1 -1
- data/app/views/generic_content_objects/_edit_description.html.erb +1 -1
- data/app/views/generic_content_objects/_show_description.html.erb +0 -2
- data/app/views/generic_contents/_edit.html.erb +10 -1
- data/app/views/generic_contents/_show.html.erb +0 -2
- data/app/views/generic_images/_edit.html.erb +1 -3
- data/app/views/generic_images/_show.html.erb +0 -2
- data/app/views/hydra/file_assets/_result.html.erb +1 -2
- data/config/fedora.yml +1 -1
- data/fedora_conf/conf/development/fedora.fcfg +1 -1
- data/fedora_conf/conf/test/fedora.fcfg +1 -1
- data/hydra-head.gemspec +2 -1
- data/lib/application_helper.rb +1 -0
- data/lib/generators/hydra/templates/config/fedora.yml +1 -1
- data/lib/generators/hydra/templates/config/initializers/hydra_config.rb +1 -12
- data/lib/hydra-head/routes.rb +1 -1
- data/lib/hydra-head/version.rb +1 -1
- data/lib/hydra/access_controls_enforcement.rb +10 -3
- data/lib/hydra/access_controls_evaluation.rb +2 -1
- data/lib/hydra/assets.rb +3 -0
- data/lib/hydra/assets_controller_helper.rb +4 -0
- data/lib/hydra/catalog.rb +1 -0
- data/lib/hydra/common_mods_index_methods.rb +1 -1
- data/lib/hydra/controller.rb +1 -0
- data/lib/hydra/file_assets.rb +7 -5
- data/lib/hydra/file_assets_helper.rb +4 -32
- data/lib/hydra/generic_content.rb +1 -0
- data/lib/hydra/generic_image.rb +2 -0
- data/lib/hydra/generic_user_attributes.rb +5 -0
- data/lib/hydra/model_methods.rb +4 -3
- data/lib/hydra/model_mixins.rb +1 -0
- data/lib/hydra/model_mixins/common_metadata.rb +1 -0
- data/lib/hydra/model_mixins/mods_object.rb +1 -0
- data/lib/hydra/models/file_asset.rb +4 -0
- data/lib/hydra/mods_article.rb +1 -0
- data/lib/hydra/mods_dataset.rb +1 -0
- data/lib/hydra/mods_generic_content.rb +1 -0
- data/lib/hydra/mods_image.rb +1 -0
- data/lib/hydra/repository_controller.rb +2 -0
- data/lib/hydra/rights_metadata.rb +1 -0
- data/lib/hydra/submission_workflow.rb +1 -0
- data/lib/hydra/superuser_attributes.rb +6 -0
- data/lib/hydra/user.rb +1 -0
- data/lib/mediashelf/active_fedora_helper.rb +2 -0
- data/lib/prev_next_links.rb +6 -0
- data/lib/user_attributes_loader.rb +2 -0
- data/lib/uva/mods_index_methods.rb +1 -0
- data/tasks/hydra-head.rake +9 -1
- data/tasks/hyhead_rspec.rake +2 -2
- data/test_support/etc/Gemfile +2 -1
- data/test_support/features/button_delete_asset.feature +13 -0
- data/test_support/features/file_upload.feature +7 -0
- data/test_support/features/step_definitions/file_list_steps.rb +8 -0
- data/test_support/features/step_definitions/html_validity_steps.rb +42 -45
- data/test_support/spec/controllers/file_assets_controller_spec.rb +12 -17
- data/test_support/spec/helpers/access_controls_enforcement_spec.rb +27 -1
- data/test_support/spec/helpers/assets_controller_helper_spec.rb +3 -3
- data/test_support/spec/integration/file_asset_spec.rb +0 -44
- data/test_support/spec/models/hydra_rights_metadata_spec.rb +3 -1
- data/test_support/spec/spec_helper.rb +16 -0
- data/vendor/cache/factory_girl-2.6.4.gem +0 -0
- data/vendor/cache/jquery-rails-2.0.2.gem +0 -0
- metadata +26 -24
- data/BLACKLIGHT_CONFIG.textile +0 -76
- data/HOW_DO_I.textile +0 -107
- data/HOW_TO_GET_STARTED.textile +0 -588
- data/app/models/audio_asset.rb +0 -8
- data/app/models/image_asset.rb +0 -8
- data/app/models/video_asset.rb +0 -8
- data/fedora/conf/fedora.fcfg +0 -1021
- data/lib/application_controller.rb +0 -24
- data/lib/block_mapper.rb +0 -52
- data/lib/ead_mapper.rb +0 -7
- data/lib/field_maps.rb +0 -507
- data/lib/marc_mapper.rb +0 -131
- data/lib/marc_record_ext.rb +0 -97
- data/test_support/spec/models/audio_asset_spec.rb +0 -23
- data/test_support/spec/models/image_asset_spec.rb +0 -23
- data/test_support/spec/models/video_asset_spec.rb +0 -23
- data/vendor/cache/factory_girl-3.1.1.gem +0 -0
@@ -7,7 +7,7 @@ module Hydra
|
|
7
7
|
content_tag(:span, render_facet_value(facet_solr_field, item, :suppress_link => true), :class => "selected")
|
8
8
|
end
|
9
9
|
|
10
|
-
#
|
10
|
+
# Override to remove the label class (easier integration with bootstrap)
|
11
11
|
# and handles arrays
|
12
12
|
def render_facet_value(facet_solr_field, item, options ={})
|
13
13
|
if item.is_a? Array
|
@@ -74,10 +74,6 @@ module Hydra::JavascriptIncludesHelperBehavior
|
|
74
74
|
javascript_includes << ["jquery.jeditable.mini.js", "date-picker/js/datepicker", "jquery.form.js", 'custom', "catalog/edit", "jquery.hydraMetadata.js", "jquery.notice.js", {:plugin=>"hydra-head"}]
|
75
75
|
# For DatePicker
|
76
76
|
javascript_includes << ["jquery.ui.widget.js","jquery.ui.datepicker.js", "mediashelf.datepicker.js", {:plugin=>"hydra-head" }]
|
77
|
-
|
78
|
-
# For Fancybox
|
79
|
-
javascript_includes << ["fancybox/jquery.fancybox-1.3.1.pack.js", {:plugin=>"hydra-head"}]
|
80
|
-
stylesheet_links << ["/javascripts/fancybox/jquery.fancybox-1.3.1.css", {:plugin=>"hydra-head"}]
|
81
77
|
|
82
78
|
# For slider controls
|
83
79
|
javascript_includes << ["select_to_ui_slider/selectToUISlider.jQuery.js", {:plugin=>"hydra-head"}]
|
data/app/models/ability.rb
CHANGED
@@ -1,6 +1,12 @@
|
|
1
|
-
#
|
1
|
+
# @deprecated This is intended as an EXAMPLE of mixing in model behavior and will be moved to hydra-wiki documentation. This will be removed no later than 6.x
|
2
|
+
# EXAMPLE of a basic model that conforms to Hydra commonMetadata cModel and has basic MODS metadata (currently "Article" is the MODS exemplar)
|
2
3
|
class CommonMetadataAsset < ActiveFedora::Base
|
3
4
|
|
5
|
+
def initialize
|
6
|
+
ActiveSupport::Deprecation.warn("CommonMetadataAsset is deprecated and will be removed in release 5 or 6; this exemplar code has been moved into wiki documentation here: https://github.com/projecthydra/hydra-head/wiki/Models---Some-Examples")
|
7
|
+
super
|
8
|
+
end
|
9
|
+
|
4
10
|
# declares a rightsMetadata datastream with type Hydra::Datastream::RightsMetadata
|
5
11
|
# basically, it is another expression of
|
6
12
|
# has_metadata :name => "rightsMetadata", :type => Hydra::Datastream::RightsMetadata
|
@@ -1,12 +1,16 @@
|
|
1
|
+
# GenericContent: EXAMPLE Model that conforms to the Hydra genericContent and genericMetadata cModels
|
1
2
|
class GenericContent < ActiveFedora::Base
|
2
3
|
|
3
4
|
# Uses the Hydra Rights Metadata Schema for tracking access permissions & copyright
|
5
|
+
# FIXME: should this have "include Hydra::ModelMixins::CommonMetadata" instead?
|
4
6
|
has_metadata :name => "rightsMetadata", :type => Hydra::Datastream::RightsMetadata
|
5
7
|
|
8
|
+
# Uses the GenericContent mixin to conform to the Hydra genericContent cModel
|
6
9
|
include Hydra::GenericContent
|
10
|
+
|
7
11
|
has_metadata :name => "descMetadata", :type => Hydra::Datastream::ModsGenericContent
|
8
12
|
|
9
|
-
# A place to put extra metadata values
|
13
|
+
# A place to put extra metadata values, e.g. the user id of the object depositor (for permissions)
|
10
14
|
has_metadata :name => "properties", :type => Hydra::Datastream::Properties
|
11
15
|
|
12
16
|
# adds helpful methods for basic hydra objects.
|
data/app/models/generic_image.rb
CHANGED
@@ -1,4 +1,5 @@
|
|
1
|
-
# GenericImage
|
1
|
+
# GenericImage:
|
2
|
+
# EXAMPLE Model that conforms to the Hydra genericImage, genericMetadata and genericContent cModels
|
2
3
|
#
|
3
4
|
# Default content datastreams: content, original (optional), max, thumbnail, screen
|
4
5
|
#
|
@@ -41,16 +42,19 @@ require 'hydra'
|
|
41
42
|
|
42
43
|
class GenericImage < ActiveFedora::Base
|
43
44
|
|
45
|
+
# Uses the GenericImage mixin to conform to the Hydra genericImage cModel (auto-includes on GenericContent behaviors)
|
46
|
+
include Hydra::GenericImage
|
47
|
+
|
44
48
|
# adds helpful methods for basic hydra objects
|
45
49
|
include Hydra::ModelMethods
|
46
50
|
|
47
51
|
# Uses the Hydra Rights Metadata Schema for tracking access permissions & copyright
|
52
|
+
# FIXME: should this have "include Hydra::ModelMixins::CommonMetadata" instead?
|
48
53
|
has_metadata :name => "rightsMetadata", :type => Hydra::Datastream::RightsMetadata
|
49
54
|
|
50
|
-
include Hydra::GenericImage
|
51
55
|
has_metadata :name => "descMetadata", :type => Hydra::Datastream::ModsImage
|
52
56
|
|
53
|
-
# A place to put extra metadata values
|
57
|
+
# A place to put extra metadata values, e.g. the user id of the object depositor (for permissions)
|
54
58
|
has_metadata :name => "properties", :type => Hydra::Datastream::Properties
|
55
59
|
|
56
60
|
def initialize( attrs={} )
|
data/app/models/hydra/ability.rb
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
# @deprecated Leftover from Hydrangea. Please use Hydra::Datastream::ModsGenericContent instead. This will be removed no later than release 6.x
|
2
|
+
# this should be moved to documentation as an EXAMPLE
|
1
3
|
module Hydra
|
2
4
|
module Datastream
|
3
5
|
class ModsArticle < ActiveFedora::NokogiriDatastream
|
@@ -1,7 +1,14 @@
|
|
1
|
+
# @deprecated Leftover from Hydrangea work; this should be moved to documentation as an EXAMPLE, and will be removed no later than release 6.x
|
1
2
|
module Hydra
|
2
3
|
module Datastream
|
3
4
|
class ModsDataset < ActiveFedora::NokogiriDatastream
|
4
5
|
include Hydra::Datastream::CommonModsIndexMethods
|
6
|
+
|
7
|
+
def initialize
|
8
|
+
ActiveSupport::Deprecation.warn("Hydra:Datastream:ModsDataset is deprecated and will be removed in release 5 or 6. It has been moved into wiki documentation here: https://github.com/projecthydra/hydra-head/wiki/Models---Some-Examples")
|
9
|
+
super
|
10
|
+
end
|
11
|
+
|
5
12
|
set_terminology do |t|
|
6
13
|
t.root(:path=>"mods", :xmlns=>"http://www.loc.gov/mods/v3", :schema=>"http://www.loc.gov/standards/mods/v3/mods-3-2.xsd")
|
7
14
|
|
@@ -1,10 +1,15 @@
|
|
1
|
+
# properties datastream: catch-all for info that didn't have another home. Particularly depositor.
|
1
2
|
module Hydra::Datastream
|
2
3
|
class Properties < ActiveFedora::NokogiriDatastream
|
3
4
|
set_terminology do |t|
|
4
5
|
t.root(:path=>"fields", :xmlns => '', :namespace_prefix => nil)
|
5
6
|
|
6
|
-
|
7
|
+
# This is where we put the user id of the object depositor -- impacts permissions/access controls
|
7
8
|
t.depositor :xmlns => '', :namespace_prefix => nil
|
9
|
+
|
10
|
+
# @deprecated: Collection should be tracked in RELS-EXT RDF. collection term will be removed no later than release 6.x
|
11
|
+
t.collection :xmlns => '', :namespace_prefix => nil
|
12
|
+
# @deprecated: Title should be tracked in descMetadata. title term will be removed no later than release 6.x
|
8
13
|
t.title :xmlns => '', :namespace_prefix => nil
|
9
14
|
end
|
10
15
|
|
data/app/models/mods_asset.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
#
|
1
|
+
# An EXAMPLE Basic Model for Assets that conform to Hydra commonMetadata cModel and have basic MODS metadata (currently "Article" is the MODS exemplar)
|
2
2
|
class ModsAsset < ActiveFedora::Base
|
3
3
|
|
4
4
|
# declares a rightsMetadata datastream with type Hydra::Datastream::RightsMetadata
|
data/app/models/role_mapper.rb
CHANGED
@@ -1,3 +1,6 @@
|
|
1
|
+
# RoleMapper This is used by AccessControlsEnforcement to get users' Roles (used in access permissions)
|
2
|
+
# If you are using something like Shibboleth or LDAP to get users' Roles, you should override this Class.
|
3
|
+
# Your override should include a Module that implements the same behaviors as Hydra::RoleMapperBehavior
|
1
4
|
class RoleMapper
|
2
5
|
include Hydra::RoleMapperBehavior
|
3
6
|
end
|
data/app/models/superuser.rb
CHANGED
@@ -1,6 +1,12 @@
|
|
1
|
+
# @deprecated - we are moving away from this approach; this code will be removed no later than release 6.x
|
1
2
|
# To make a superuser record, look up the ID (not the login) of a previously created user,
|
2
3
|
# and then insert that id into the superusers table
|
3
4
|
class Superuser < ActiveRecord::Base
|
4
5
|
belongs_to :user
|
5
6
|
|
7
|
+
def initialize
|
8
|
+
ActiveSupport::Deprecation.warn("Superuser is deprecated and will be removed in release 5 or 6; we are moving away from this approach.")
|
9
|
+
super
|
10
|
+
end
|
11
|
+
|
6
12
|
end
|
@@ -1,6 +1,12 @@
|
|
1
|
+
# @deprecated - from the original implementation of UVA's Libra. This type of behavior should be application-specific. This will be removed no later than release 6.x
|
1
2
|
class UserAttribute < ActiveRecord::Base
|
2
3
|
belongs_to :user
|
3
4
|
|
5
|
+
def initialize
|
6
|
+
ActiveSupport::Deprecation.warn("UserAttribute is deprecated and will be removed in release 5 or 6; this behavior should be implemented at the app level.")
|
7
|
+
super
|
8
|
+
end
|
9
|
+
|
4
10
|
|
5
11
|
# Finds the user_attributes based on login
|
6
12
|
# @param [sting] login the login of the user
|
@@ -1,11 +1,19 @@
|
|
1
|
+
# TODO: Move TO test_support
|
1
2
|
# this model exists largely to exercise the default partials for models that don't have their own
|
2
3
|
# that is, if an (active)fedora object uses the ModsAsset model, then hydra-head will use partials in views/mods_assets to display those objects
|
3
4
|
# however, if an (active)fedora object uses a model without its own partials in the views folder, then hydra-head will use views/catalog/xxx to display those objects.
|
4
5
|
# a Fedora object for the Hypatia SET hydra content type
|
5
6
|
class UsesDefaultPartials < ActiveFedora::Base
|
6
7
|
|
8
|
+
def initialize
|
9
|
+
ActiveSupport::Deprecation.warn("UsesDefaultPartials is for testing only. It will be moved into test_support")
|
10
|
+
super
|
11
|
+
end
|
12
|
+
|
7
13
|
has_metadata :name => "descMetadata", :type => Hydra::Datastream::ModsGenericContent
|
8
14
|
|
15
|
+
# Uses the Hydra Rights Metadata Schema for tracking access permissions & copyright
|
16
|
+
# FIXME: should this have "include Hydra::ModelMixins::CommonMetadata" instead?
|
9
17
|
has_metadata :name => "rightsMetadata", :type => Hydra::Datastream::RightsMetadata
|
10
18
|
|
11
19
|
# adds helpful methods for basic hydra objects.
|
@@ -1,12 +1,5 @@
|
|
1
1
|
<%# default partial to delete display solr document fields in catalog show view -%>
|
2
2
|
|
3
|
-
<%- stylesheet_links << "../plugin_assets/hydra-head/javascripts/date-picker/css/datepicker" %>
|
4
|
-
<%- stylesheet_links << "../plugin_assets/hydra-head/javascripts/fancybox/jquery.fancybox-1.3.1.css" %>
|
5
|
-
<%- stylesheet_links << ["../plugin_assets/hydra-head/javascripts/select_to_ui_slider/css/ui.slider.extras.css"] %>
|
6
|
-
<%- stylesheet_links << ["slider", {:plugin=>"hydra-head"}] %>
|
7
|
-
|
8
|
-
|
9
|
-
|
10
3
|
<div class="document_viewer" id="cover_container">
|
11
4
|
<div id="delete_dialog">
|
12
5
|
<div id="delete_dialog_container">
|
@@ -18,8 +11,8 @@
|
|
18
11
|
</div>
|
19
12
|
|
20
13
|
<div>
|
21
|
-
<%= button_to("Delete",
|
22
|
-
<%= button_to("Withdraw", :
|
14
|
+
<%= button_to("Delete", hydra_asset_path(@document['id']), :confirm => 'Are you sure?', :method => :delete )%>
|
15
|
+
<%= button_to("Withdraw", withdraw_path(:id => @document['id']) ) %>
|
23
16
|
<%= button_to("Cancel", :action=>:edit, :controller => :catalog, :id => @document['id'] ) %>
|
24
17
|
|
25
18
|
</div>
|
@@ -1,7 +1,6 @@
|
|
1
1
|
<%# default partial to display solr document fields in catalog show view -%>
|
2
2
|
|
3
3
|
<%- stylesheet_links << "../plugin_assets/hydra-head/javascripts/date-picker/css/datepicker" %>
|
4
|
-
<%- stylesheet_links << "../plugin_assets/hydra-head/javascripts/fancybox/jquery.fancybox-1.3.1.css" %>
|
5
4
|
<%- stylesheet_links << ["../plugin_assets/hydra-head/javascripts/select_to_ui_slider/css/ui.slider.extras.css"] %>
|
6
5
|
<%- stylesheet_links << ["../plugin_assets/hydra-head/stylesheets/slider.css"] %>
|
7
6
|
|
@@ -35,6 +35,6 @@
|
|
35
35
|
</div>
|
36
36
|
<% if controller.action_name == "edit" %>
|
37
37
|
<div class="delete-asset">
|
38
|
-
<%= button_to("Delete This Item", {:action => :destroy, :controller => :assets, :id => @document_fedora.pid}, :confirm => 'Are you sure?', :method => :delete )%>
|
38
|
+
<%= button_to("Delete This Item", {:action => :destroy, :controller => :"hydra/assets", :id => @document_fedora.pid}, :confirm => 'Are you sure?', :method => :delete )%>
|
39
39
|
</div>
|
40
40
|
<% end %>
|
@@ -1,7 +1,7 @@
|
|
1
1
|
<input type="hidden" name="_method" value="put"/>
|
2
2
|
<input class="content_type" type="hidden" name="content_type" value="mods_asset" />
|
3
3
|
|
4
|
-
<p id="title_field" class="fedora-text-field"><%= fedora_field_label("descMetadata", [:title_info, :main_title], "Title:") %>
|
4
|
+
<p id="title_field" class="fedora-text-field"><%= fedora_field_label("descMetadata", [:title_info, :main_title], "Title: <span class=\"required-note\">required</span>".html_safe) %>
|
5
5
|
<%= fedora_text_field(@document_fedora,"descMetadata", [:title_info, :main_title], :multiple=>false, :required=>true) %></p>
|
6
6
|
<p id="language_field" class="fedora-text-field"><%= fedora_field_label("descMetadata", [:title_info, :language], "Language:") %>
|
7
7
|
<%= fedora_text_field(@document_fedora, "descMetadata", [:title_info, :language], :multiple=>false, :required=>false ) %></p>
|
@@ -1 +1,10 @@
|
|
1
|
-
|
1
|
+
<% if !session[:scripts] %>
|
2
|
+
<%= render_previous_workflow_steps.html_safe %>
|
3
|
+
<%= render_submission_workflow_step -%>
|
4
|
+
<% else %>
|
5
|
+
<%= render_all_workflow_steps.html_safe %>
|
6
|
+
<div class="all-steps-actions">
|
7
|
+
<button id="all_save_continue" name="all_save_continue">Save and Continue Editing</button>
|
8
|
+
<button id="all_save_finish" name="all_save_finish">Save and Finish</button>
|
9
|
+
</div>
|
10
|
+
<% end %>
|
@@ -5,8 +5,7 @@
|
|
5
5
|
<td>
|
6
6
|
|
7
7
|
<% if can? :edit, @document %>
|
8
|
-
<%= button_to("Delete", "/
|
9
|
-
|
8
|
+
<%= button_to("Delete", "/hydra/assets/#{result["id"]}/file_assets/#{result["id"]}?container_id=#{@document[:id]}", :confirm => "Are you sure you want to delete this file?", :method => :delete, :class => "delete-button") %>
|
10
9
|
<% end %>
|
11
10
|
</td>
|
12
11
|
</tr>
|
data/config/fedora.yml
CHANGED
@@ -156,7 +156,7 @@
|
|
156
156
|
context-appropriate DOReaders and DOWriters for reflecting on and
|
157
157
|
writing to the objects stored in the repository. It also provides
|
158
158
|
methods for reflecting on the contents of the repository as a whole..</comment>
|
159
|
-
<param name="pidNamespace" value="
|
159
|
+
<param name="pidNamespace" value="hydra">
|
160
160
|
<comment>This is the namespace id for pids of newly-created objects.
|
161
161
|
This should be unique for a repository. It can be from 1 to 17
|
162
162
|
characters, and may only contain A-Z, a-z, 0-9, '.', or '-' (dash).</comment>
|
@@ -156,7 +156,7 @@
|
|
156
156
|
context-appropriate DOReaders and DOWriters for reflecting on and
|
157
157
|
writing to the objects stored in the repository. It also provides
|
158
158
|
methods for reflecting on the contents of the repository as a whole..</comment>
|
159
|
-
<param name="pidNamespace" value="
|
159
|
+
<param name="pidNamespace" value="hydra">
|
160
160
|
<comment>This is the namespace id for pids of newly-created objects.
|
161
161
|
This should be unique for a repository. It can be from 1 to 17
|
162
162
|
characters, and may only contain A-Z, a-z, 0-9, '.', or '-' (dash).</comment>
|
data/hydra-head.gemspec
CHANGED
@@ -20,6 +20,7 @@ Gem::Specification.new do |s|
|
|
20
20
|
s.add_dependency 'block_helpers'
|
21
21
|
s.add_dependency 'sanitize'
|
22
22
|
s.add_dependency 'cancan'
|
23
|
+
s.add_dependency 'jquery-rails'
|
23
24
|
|
24
25
|
s.add_development_dependency 'sqlite3'
|
25
26
|
s.add_development_dependency 'yard'
|
@@ -27,7 +28,7 @@ Gem::Specification.new do |s|
|
|
27
28
|
s.add_development_dependency 'rspec-rails'
|
28
29
|
s.add_development_dependency 'mocha'
|
29
30
|
s.add_development_dependency 'cucumber-rails', '>=1.2.0'
|
30
|
-
s.add_development_dependency 'factory_girl'
|
31
|
+
s.add_development_dependency 'factory_girl', "~> 2.6.0"
|
31
32
|
s.add_development_dependency 'solrizer-fedora', '>=2.0.0'
|
32
33
|
|
33
34
|
|
data/lib/application_helper.rb
CHANGED
@@ -13,18 +13,7 @@ User.send(:include, Hydra::GenericUserAttributes)
|
|
13
13
|
|
14
14
|
if Hydra.respond_to?(:configure)
|
15
15
|
Hydra.configure(:shared) do |config|
|
16
|
-
|
17
|
-
# This is used as a reference by choose_model_by_filename in FileAssetsHelper
|
18
|
-
config[:file_asset_types] = {
|
19
|
-
# MZ -This can only be enabled if/when we adopt replacements for ImageAsset, AudioAsset, etc. as default primitives.
|
20
|
-
# :default => FileAsset,
|
21
|
-
# :extension_mappings => {
|
22
|
-
# AudioAsset => [".wav", ".mp3", ".aiff"] ,
|
23
|
-
# VideoAsset => [".mov", ".flv", ".mp4", ".m4v"] ,
|
24
|
-
# ImageAsset => [".jpeg", ".jpg", ".gif", ".png"]
|
25
|
-
# }
|
26
|
-
}
|
27
|
-
|
16
|
+
|
28
17
|
config[:submission_workflow] = {
|
29
18
|
:mods_assets => [{:name => "contributor", :edit_partial => "mods_assets/contributor_form", :show_partial => "mods_assets/show_contributors"},
|
30
19
|
{:name => "publication", :edit_partial => "mods_assets/publication_form", :show_partial => "mods_assets/show_publication"},
|