sufia 1.3.0 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (163) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +0 -3
  3. data/Gemfile +1 -0
  4. data/Releasing_sufia.md +3 -0
  5. data/SUFIA_VERSION +1 -0
  6. data/app/assets/javascripts/sufia.js +22 -24
  7. data/app/assets/javascripts/sufia/batch_select_all.js +2 -0
  8. data/app/assets/javascripts/sufia/fileupload.js +6 -0
  9. data/app/assets/javascripts/sufia/uploader.js +165 -0
  10. data/app/assets/javascripts/terms_of_service.js +36 -30
  11. data/app/assets/stylesheets/{scholarsphere-bootstrap.css → application-bootstrap.css} +0 -0
  12. data/app/assets/stylesheets/sufia.css.scss +1 -1
  13. data/app/controllers/batch_controller.rb +1 -0
  14. data/app/controllers/concerns/sufia/users_controller_behavior.rb +2 -1
  15. data/app/helpers/generic_file_helper.rb +17 -0
  16. data/{lib/sufia → app}/jobs/content_delete_event_job.rb +0 -0
  17. data/{lib/sufia → app}/jobs/content_deposit_event_job.rb +0 -0
  18. data/{lib/sufia → app}/jobs/content_new_version_event_job.rb +0 -0
  19. data/{lib/sufia → app}/jobs/content_restored_version_event_job.rb +0 -0
  20. data/{lib/sufia → app}/jobs/content_update_event_job.rb +0 -0
  21. data/{lib/sufia → app}/jobs/event_job.rb +0 -0
  22. data/{lib/sufia → app}/jobs/user_edit_profile_event_job.rb +0 -0
  23. data/{lib/sufia → app}/jobs/user_follow_event_job.rb +0 -0
  24. data/{lib/sufia → app}/jobs/user_unfollow_event_job.rb +0 -0
  25. data/app/models/contact_form.rb +2 -2
  26. data/app/views/_ga.html.erb +2 -2
  27. data/app/views/batch_edits/_batch_edits_actions.html.erb +1 -0
  28. data/app/views/batch_edits/_check_all.html.erb +1 -2
  29. data/app/views/catalog/_sort_and_per_page.html.erb +1 -1
  30. data/app/views/dashboard/_batch_edits_actions.html.erb +2 -0
  31. data/app/views/dashboard/_sort_and_per_page.html.erb +1 -1
  32. data/app/views/generic_files/_breadcrumbs.html.erb +5 -1
  33. data/app/views/generic_files/_descriptions.html.erb +6 -4
  34. data/app/views/generic_files/_dropbox_import.html.erb +3 -0
  35. data/app/views/generic_files/_field_display.html.erb +12 -0
  36. data/app/views/generic_files/_field_form.html.erb +1 -1
  37. data/app/views/generic_files/_multiple_upload.html.erb +4 -135
  38. data/app/views/generic_files/_permission_form.html.erb +5 -5
  39. data/app/views/generic_files/_show_descriptions.html.erb +6 -14
  40. data/app/views/generic_files/_show_details.html.erb +2 -2
  41. data/app/views/generic_files/edit_fields/_resource_type.html.erb +9 -0
  42. data/app/views/generic_files/edit_fields/_rights.html.erb +1 -1
  43. data/app/views/generic_files/edit_fields/_type.html.erb +4 -1
  44. data/app/views/generic_files/new.html.erb +18 -1
  45. data/app/views/generic_files/show_fields/_default.html.erb +12 -0
  46. data/app/views/generic_files/upload/_agreement.html.erb +5 -0
  47. data/app/views/generic_files/upload/_alerts.html.erb +19 -0
  48. data/app/views/generic_files/upload/_dropbox_chooser.html.erb +39 -0
  49. data/app/views/generic_files/upload/_form.html.erb +6 -0
  50. data/app/views/generic_files/upload/_form_fields.html.erb +47 -0
  51. data/app/views/generic_files/upload/_script_templates.html.erb +61 -0
  52. data/app/views/generic_files/upload/_tos_checkbox.html.erb +3 -0
  53. data/app/views/layouts/_head-tag-content.html.erb +22 -0
  54. data/app/views/layouts/{hydra-head.html.erb → homepage.html.erb} +3 -44
  55. data/app/views/layouts/sufia-one-column.html.erb +43 -0
  56. data/app/views/layouts/sufia-two-column.html.erb +45 -0
  57. data/app/views/static/agreement.html.erb +12 -11
  58. data/app/views/static/mendeley.html.erb +2 -2
  59. data/app/views/static/terms.html.erb +11 -11
  60. data/app/views/static/zotero.html.erb +2 -2
  61. data/config/initializers/sufia_events.rb +3 -0
  62. data/config/locales/sufia.en.yml +3 -6
  63. data/features/step_definitions/{scholarsphere.rb → sufia.rb} +0 -0
  64. data/lib/generators/sufia/sufia_generator.rb +1 -1
  65. data/lib/generators/sufia/templates/config/resque_config.rb +1 -1
  66. data/lib/generators/sufia/templates/config/sufia.rb +3 -0
  67. data/lib/sufia.rb +1 -50
  68. data/lib/sufia/batch_edits_controller_behavior.rb +4 -0
  69. data/lib/sufia/controller.rb +13 -0
  70. data/lib/sufia/dashboard_controller_behavior.rb +3 -2
  71. data/lib/sufia/files_controller_behavior.rb +35 -12
  72. data/lib/sufia/version.rb +1 -1
  73. data/spec/controllers/batch_edits_controller_spec.rb +2 -2
  74. data/spec/controllers/generic_files_controller_spec.rb +37 -1
  75. data/spec/models/generic_file_spec.rb +6 -6
  76. data/spec/models/properties_datastream_spec.rb +8 -7
  77. data/spec/models/transcode_audio_job_spec.rb +1 -1
  78. data/spec/models/transcode_video_job_spec.rb +1 -1
  79. data/spec/views/batch_edits/check_all_spec.rb +22 -0
  80. data/sufia-models/.gitignore +17 -0
  81. data/sufia-models/Gemfile +4 -0
  82. data/sufia-models/LICENSE.md +177 -0
  83. data/sufia-models/README.md +39 -0
  84. data/sufia-models/Rakefile +1 -0
  85. data/{app → sufia-models/app}/models/batch.rb +2 -4
  86. data/{app → sufia-models/app}/models/checksum_audit_log.rb +3 -4
  87. data/{app → sufia-models/app}/models/datastreams/batch_rdf_datastream.rb +0 -0
  88. data/{app → sufia-models/app}/models/datastreams/file_content_datastream.rb +0 -0
  89. data/{app → sufia-models/app}/models/datastreams/fits_datastream.rb +0 -0
  90. data/{app → sufia-models/app}/models/datastreams/generic_file_rdf_datastream.rb +12 -12
  91. data/{app → sufia-models/app}/models/datastreams/paranoid_rights_datastream.rb +0 -15
  92. data/{app → sufia-models/app}/models/datastreams/properties_datastream.rb +1 -2
  93. data/{app → sufia-models/app}/models/domain_term.rb +0 -0
  94. data/{app → sufia-models/app}/models/follow.rb +0 -0
  95. data/{app → sufia-models/app}/models/generic_file.rb +0 -0
  96. data/{app → sufia-models/app}/models/geo_names_resource.rb +0 -0
  97. data/{app → sufia-models/app}/models/group.rb +0 -0
  98. data/{app → sufia-models/app}/models/local_authority.rb +0 -0
  99. data/{app → sufia-models/app}/models/local_authority_entry.rb +0 -0
  100. data/{app → sufia-models/app}/models/single_use_link.rb +0 -0
  101. data/{app → sufia-models/app}/models/subject_local_authority_entry.rb +0 -0
  102. data/{app → sufia-models/app}/models/trophy.rb +0 -0
  103. data/{app → sufia-models/app}/models/version_committer.rb +0 -0
  104. data/sufia-models/config/locales/sufia.en.yml +6 -0
  105. data/sufia-models/lib/sufia/models.rb +34 -0
  106. data/{lib/sufia → sufia-models/lib/sufia/models}/active_fedora/redis.rb +0 -0
  107. data/{lib/sufia → sufia-models/lib/sufia/models}/active_record/redis.rb +0 -0
  108. data/{lib → sufia-models/lib/sufia/models}/active_support/core_ext/marshal.rb +0 -0
  109. data/sufia-models/lib/sufia/models/engine.rb +61 -0
  110. data/sufia-models/lib/sufia/models/file_content.rb +9 -0
  111. data/{lib/sufia → sufia-models/lib/sufia/models}/file_content/extract_metadata.rb +2 -2
  112. data/{lib/sufia → sufia-models/lib/sufia/models}/file_content/versions.rb +0 -0
  113. data/{lib/sufia → sufia-models/lib/sufia/models}/generic_file.rb +3 -34
  114. data/{lib/sufia → sufia-models/lib/sufia/models}/generic_file/actions.rb +16 -1
  115. data/{lib/sufia → sufia-models/lib/sufia/models}/generic_file/audit.rb +1 -1
  116. data/{lib/sufia → sufia-models/lib/sufia/models}/generic_file/characterization.rb +1 -2
  117. data/{lib/sufia → sufia-models/lib/sufia/models}/generic_file/export.rb +0 -0
  118. data/{lib/sufia → sufia-models/lib/sufia/models}/generic_file/permissions.rb +0 -1
  119. data/{lib/sufia → sufia-models/lib/sufia/models}/generic_file/thumbnail.rb +3 -3
  120. data/sufia-models/lib/sufia/models/generic_file/web_form.rb +45 -0
  121. data/{lib/sufia → sufia-models/lib/sufia/models}/id_service.rb +11 -7
  122. data/{lib/sufia → sufia-models/lib/sufia/models}/jobs/audit_job.rb +0 -0
  123. data/{lib/sufia → sufia-models/lib/sufia/models}/jobs/batch_update_job.rb +0 -0
  124. data/{lib/sufia → sufia-models/lib/sufia/models}/jobs/characterize_job.rb +0 -0
  125. data/{lib/sufia → sufia-models/lib/sufia/models}/jobs/ffmpeg_transcode_job.rb +3 -3
  126. data/sufia-models/lib/sufia/models/jobs/import_url_job.rb +55 -0
  127. data/{lib/sufia → sufia-models/lib/sufia/models}/jobs/resolrize_job.rb +0 -0
  128. data/{lib/sufia → sufia-models/lib/sufia/models}/jobs/transcode_audio_job.rb +0 -0
  129. data/{lib/sufia → sufia-models/lib/sufia/models}/jobs/transcode_video_job.rb +0 -0
  130. data/{lib/sufia → sufia-models/lib/sufia/models}/jobs/unzip_job.rb +16 -4
  131. data/{lib/sufia → sufia-models/lib/sufia/models}/model_methods.rb +0 -0
  132. data/{lib/sufia → sufia-models/lib/sufia/models}/noid.rb +1 -1
  133. data/{lib/sufia/queue → sufia-models/lib/sufia/models}/resque.rb +0 -2
  134. data/{lib/sufia → sufia-models/lib/sufia/models}/solr_document_behavior.rb +0 -0
  135. data/{lib/sufia → sufia-models/lib/sufia/models}/user.rb +1 -1
  136. data/{lib/sufia → sufia-models/lib/sufia/models}/utils.rb +0 -0
  137. data/sufia-models/lib/sufia/models/version.rb +5 -0
  138. data/sufia-models/lib/tasks/sufia-models_tasks.rake +7 -0
  139. data/sufia-models/sufia-models.gemspec +44 -0
  140. data/sufia.gemspec +2 -12
  141. data/tasks/release.rake +90 -0
  142. data/tasks/sufia-dev.rake +1 -1
  143. data/tasks/sufia.rake +1 -3
  144. metadata +118 -238
  145. data/app/views/generic_files/show_fields/_based_near.html.erb +0 -12
  146. data/app/views/generic_files/show_fields/_contributor.html.erb +0 -12
  147. data/app/views/generic_files/show_fields/_creator.html.erb +0 -12
  148. data/app/views/generic_files/show_fields/_date_created.html.erb +0 -12
  149. data/app/views/generic_files/show_fields/_description.html.erb +0 -12
  150. data/app/views/generic_files/show_fields/_identifier.html.erb +0 -9
  151. data/app/views/generic_files/show_fields/_language.html.erb +0 -9
  152. data/app/views/generic_files/show_fields/_publisher.html.erb +0 -12
  153. data/app/views/generic_files/show_fields/_related_url.html.erb +0 -11
  154. data/app/views/generic_files/show_fields/_resource_type.html.erb +0 -9
  155. data/app/views/generic_files/show_fields/_rights.html.erb +0 -9
  156. data/app/views/generic_files/show_fields/_subject.html.erb +0 -12
  157. data/app/views/generic_files/show_fields/_tag.html.erb +0 -9
  158. data/app/views/generic_files/show_fields/_title.html.erb +0 -12
  159. data/lib/sufia/file_content.rb +0 -8
  160. data/lib/sufia/generic_file/web_form.rb +0 -15
  161. data/vendor/assets/javascripts/fileupload.js +0 -6
  162. data/vendor/assets/javascripts/fileupload/application.js +0 -185
  163. data/vendor/assets/javascripts/fileupload/jquery-ui-1.8.14.custom.min.js +0 -76
@@ -0,0 +1,19 @@
1
+
2
+ <div class="alert alert-info hide" id="success">
3
+ You have successfully uploaded some of your files. Either continue to upload or edit use the links below to abandon the rest of your added files.
4
+ <p>
5
+ <%= link_to 'Add Descriptions', sufia.batch_edit_path(@batch_noid), :class=>'btn' %>
6
+ </p>
7
+ </div>
8
+
9
+ <div class="alert hide" id="fail">
10
+ There was a problem during upload. Please click the &quot;Start Upload&quot; button or <%= link_to 'start over', sufia.new_generic_file_path %>
11
+ </div>
12
+
13
+ <div class="alert hide" id="partial_fail">
14
+ One or more files did not upload successfully. To continue using the files uploaded use one of the links below.<br />
15
+ <%= link_to 'Add Descriptions', sufia.batch_edit_path(@batch_noid), :class=>'btn' %>
16
+ </div>
17
+
18
+ <div class="alert hide" id="errmsg"> </div>
19
+
@@ -0,0 +1,39 @@
1
+ <script type="text/javascript" src="https://www.dropbox.com/static/api/1/dropins.js" id="dropboxjs" data-app-key="<%= Sufia.config.dropbox_api_key %>"></script>
2
+ <%= form_for(@generic_file, :url => sufia.generic_files_path, :html => {:id => 'new_generic_file_dropbox', :class => 'form-horizontal well'}) do |f| %>
3
+ <%= hidden_field_tag "file_coming_from", "dropbox" %>
4
+ <%= hidden_field_tag "dropbox_urls[]" %>
5
+ <%= hidden_field_tag(:batch_id, @batch_noid) %>
6
+ <%= render partial: 'generic_files/upload/tos_checkbox' %>
7
+ <div class="fileupload-buttonbar">
8
+ <span id="main_upload_start_span" class="activate-container" data-toggle="tooltip" data-title="<%= t('sufia.upload_tooltip') %>">
9
+ <button type="submit" class="activate-submit btn btn-primary start" id="main_import_start">
10
+ <i class="icon-upload icon-white"></i>
11
+ <span>Start import</span>
12
+ </button>
13
+ </span>
14
+ <button type="reset" class="btn btn-warning cancel">
15
+ <i class="icon-ban-circle icon-white"></i>
16
+ <span>Cancel import</span>
17
+ </button>
18
+ </div>
19
+ <br />
20
+ <input type="dropbox-chooser" id="db-chooser" name="selected-file" style="visibility: hidden;" data-multiselect="true" data-link-type="direct" />
21
+ <div>
22
+ <ul id="selected-files" class="unstyled">
23
+ </ul>
24
+ </div>
25
+ <% end %>
26
+ <script type="text/javascript">
27
+ $('#db-chooser').on("DbxChooserSuccess", function(e) {
28
+ e = e.originalEvent;
29
+ var items = [];
30
+ var dropbox_urls = [];
31
+ $.each(e.files, function(i, item) {
32
+ var mb = (item.bytes / (1024*1024)).toFixed(2);
33
+ items.push('<li><img src="'+item.icon+'"/>'+item.name+'(' + mb + ' MB)</li>')
34
+ dropbox_urls.push('<input type="hidden" name="dropbox_urls[]" value="'+item.link+'" />')
35
+ });
36
+ $('#selected-files').append( items.join('') );
37
+ $('#new_generic_file_dropbox').append(dropbox_urls);
38
+ });
39
+ </script>
@@ -0,0 +1,6 @@
1
+ <%= form_for(@generic_file, :url => sufia.generic_files_path, :html => {:multipart => true, :id => 'fileupload'}) do |f| %>
2
+ <div class="well">
3
+ <%= render partial: 'generic_files/upload/form_fields' %>
4
+ </div>
5
+ <% end %>
6
+
@@ -0,0 +1,47 @@
1
+ <!-- The file upload form used as target for the file upload widget -->
2
+ <%= hidden_field_tag(:total_upload_size, 0) %>
3
+ <%= hidden_field_tag(:relative_path) %>
4
+ <%= hidden_field_tag(:batch_id, @batch_noid) %>
5
+ <%= hidden_field_tag "file_coming_from", "local" %>
6
+ <%= render partial: 'generic_files/upload/tos_checkbox' %>
7
+ <!-- The fileupload-buttonbar contains buttons to add/delete files and start/cancel the upload -->
8
+ <div class="row fileupload-buttonbar">
9
+ <div class="span70">
10
+ <!-- The fileinput-button span is used to style the file input field as button -->
11
+ <span class="btn btn-success fileinput-button">
12
+ <i class="icon-plus icon-white"></i>
13
+ <span>Select files...</span>
14
+ <input type="file" name="files[]" multiple />
15
+ </span>
16
+ <% ua = request.env['HTTP_USER_AGENT'] %>
17
+ <% if !!(ua =~ /Chrome/) %>
18
+ <span class="btn btn-success fileinput-button">
19
+ <i class="icon-plus icon-white"></i>
20
+ <span>Select folder...</span>
21
+ <input type="file" name="files[]" directory webkitdirectory mozdirectory />
22
+ </span>
23
+ <% end %>
24
+ <span id="main_upload_start_span" class="activate-container" data-toggle="tooltip" data-title="<%= t('sufia.upload_tooltip') %>">
25
+ <button type="submit" class="activate-submit btn btn-primary start" id="main_upload_start">
26
+ <i class="icon-upload icon-white"></i>
27
+ <span>Start upload</span>
28
+ </button>
29
+ </span>
30
+ <button type="reset" class="btn btn-warning cancel">
31
+ <i class="icon-ban-circle icon-white"></i>
32
+ <span>Cancel upload</span>
33
+ </button>
34
+ </div>
35
+ <div class="span50">
36
+ <!-- The global progress bar -->
37
+ <div class="progress progress-success progress-striped active fade">
38
+ <div class="bar" style="width:0%;"></div>
39
+ </div>
40
+ </div>
41
+ </div>
42
+ <!-- The loading indicator is shown during image processing -->
43
+ <div class="fileupload-loading"></div>
44
+ <br />
45
+ <!-- The table listing the files available for upload/download -->
46
+ <table id="file-table" class="table table-striped"><tbody class="files" data-toggle="modal-gallery" data-target="#modal-gallery"></tbody></table>
47
+
@@ -0,0 +1,61 @@
1
+ <div class="alert alert-info hide" id="redirect-loc" type="text/x-jquery-tmpl">
2
+ <%-# Script redirects here once the uploads are complete %>
3
+ <%=sufia.batch_edit_path(@batch_noid)%>
4
+ </div>
5
+
6
+ <!-- The template to display files available for upload -->
7
+ <script id="template-upload" type="text/x-jquery-tmpl">
8
+ {% for (var i=0, file; file=o.files[i]; i++) { %}
9
+
10
+ <tr class="template-upload fade">
11
+ <td class="preview"><span class="fade"></span></td>
12
+ <td class="name"><span>{%=file.name%}</span></td>
13
+ <td class="size"><span>{%=o.formatFileSize(file.size)%}</span></td>
14
+ {% if (file.error) { %}
15
+ <td class="error" colspan="2"><span class="label label-important">{%=locale.fileupload.error%}</span> {%=locale.fileupload.errors[file.error] || file.error%}</td>
16
+ {% } else if (o.files.valid && !i) { %}
17
+ <td>
18
+ <div class="progress progress-success progress-striped active"><div class="bar" style="width:0%;"></div></div>
19
+ </td>
20
+ <td class="start">{% if (!o.options.autoUpload) { %}
21
+ <button class="btn btn-primary hide">
22
+ <i class="icon-upload icon-white"></i>
23
+ <span>{%=locale.fileupload.start%}</span>
24
+ </button>
25
+ {% } %}</td>
26
+ {% } else { %}
27
+ <td colspan="2"></td>
28
+ {% } %}
29
+ <td class="cancel">{% if (!i) { %}
30
+ <button class="btn btn-warning">
31
+ <i class="icon-ban-circle icon-white"></i>
32
+ <span>{%=locale.fileupload.cancel%}</span>
33
+ </button>
34
+ {% } %}</td>
35
+ </tr>
36
+ {% } %}
37
+ </script>
38
+ <!-- The template to display files available for download -->
39
+ <script id="template-download" type="text/x-jquery-tmpl">
40
+ {% for (var i=0, file; file=o.files[i]; i++) { %}
41
+ <tr class="template-download fade">
42
+ {% if (file.error) { %}
43
+ <td><span></span></td>
44
+ <td class="name"><span>{%=file.name%}</span></td>
45
+ <td class="size"><span>{%=o.formatFileSize(file.size)%}</span></td>
46
+ <td class="error" colspan="2"><span class="label label-important">{%=locale.fileupload.error%}</span> {%=locale.fileupload.errors[file.error] || file.error%}</td>
47
+ {% } else { %}
48
+ <td class="preview">
49
+ {% if (file.thumbnail_url) { %} <span class="label label-success">Success</span> {% } %}
50
+ </td>
51
+ <td class="name">
52
+ {%=file.name%}
53
+ <!--a href="{%=file.url%}" title="{%=file.name%}" rel="{%=file.thumbnail_url&&'gallery'%}" download="{%=file.name%}" target="_blank">{%=file.name%}</a-->
54
+ </td>
55
+ <td class="size"><span>{%=o.formatFileSize(file.size)%}</span></td>
56
+ <td colspan="2"></td>
57
+ {% } %}
58
+ </tr>
59
+ {% } %}
60
+ </script>
61
+
@@ -0,0 +1,3 @@
1
+ <label class="checkbox">
2
+ <%= check_box_tag 'terms_of_service', 1, nil, {"data-activate" => 'activate-submit'} %> I have read and do agree to <%= link_to t('sufia.deposit_agreement'), '/agreement/', :target => "_blank" %>.
3
+ </label>
@@ -0,0 +1,22 @@
1
+ <%= csrf_meta_tag %>
2
+
3
+ <meta charset="utf-8" />
4
+
5
+ <title><%= h(@page_title || application_name) %></title>
6
+ <!-- application css -->
7
+ <%= stylesheet_link_tag 'application' %>
8
+ <%= yield(:css_head) %>
9
+
10
+ <!-- application js -->
11
+ <%= javascript_include_tag 'application' %>
12
+
13
+ <!-- controller specific uploader -->
14
+ <%= yield(:js_head) %>
15
+
16
+ <script type="text/javascript">
17
+ $(function() {
18
+ <%= yield(:local_js) %>
19
+ });
20
+ </script>
21
+
22
+ <%= render :partial => '/ga', :formats => [:html] %>
@@ -17,38 +17,9 @@ limitations under the License.
17
17
  <!DOCTYPE html>
18
18
  <html>
19
19
  <head>
20
- <%= csrf_meta_tag %>
21
-
22
- <meta charset="utf-8" />
23
-
24
- <title><%= h(@page_title || application_name) %></title>
25
- <!-- application css -->
26
- <%= stylesheet_link_tag 'application' %>
27
- <%= yield(:css_head) %>
28
-
29
- <!-- application js -->
30
- <%= javascript_include_tag 'application' %>
31
-
32
- <!-- controller specific uploader -->
33
- <%= yield(:js_head) %>
34
-
35
- <script type="text/javascript">
36
- $(function() {
37
- <%= yield(:local_js) %>
38
- });
39
- </script>
40
-
41
- <%= render :partial => '/ga', :formats => [:html] %>
20
+ <%= render :partial => "layouts/head-tag-content"%>
42
21
  </head>
43
22
 
44
- <%# need a better way to determine if we are on the home page and using three col layout %>
45
- <% if params[:controller].eql?("catalog") and !has_search_parameters? %>
46
- <% column_class = "three" %>
47
- <% elsif not ['generic_files', 'batch', 'advanced', 'users', 'batch_edits'].include?(params[:controller]) %>
48
- <% column_class = "two" %>
49
- <% else %>
50
- <% column_class = "one" %>
51
- <% end %>
52
23
  <body>
53
24
  <div id="wrapper">
54
25
  <div class="container">
@@ -58,15 +29,9 @@ limitations under the License.
58
29
  <div id="content-wrapper">
59
30
  <div id="content" class="row">
60
31
  <!-- 110 rows -->
61
- <% if column_class == "one" %>
62
- <div class="span110">
63
- <%= yield %>
64
- </div>
65
- <% else %>
66
32
  <div class="span17">
67
33
  <%= yield :sidebar %>
68
34
  </div><!-- /.span17 -->
69
- <% if column_class == "three" %>
70
35
  <div class="span63">
71
36
  <%= yield %>
72
37
  </div><!-- /.span63 -->
@@ -79,13 +44,7 @@ limitations under the License.
79
44
  <h2 class="heading1">My Latest</h2>
80
45
  <%= render :partial=>'/catalog/recents', :locals => {:recent_documents=>@recent_user_documents, :display_thumbs=>false, :display_access=>true} %>
81
46
  </div> <!-- /.span30 -->
82
- <% else %>
83
- <div class="span93">
84
- <%= yield %>
85
- </div><!-- /.span93 -->
86
- <% end %>
87
- <% end %>
88
-
47
+
89
48
  </div><!-- /#content -->
90
49
  </div><!-- /#content-wrapper -->
91
50
  </div><!-- /#page-positioner -->
@@ -94,4 +53,4 @@ limitations under the License.
94
53
  <%= render partial: '/footer' %>
95
54
  <div id="ajax-modal" class="modal hide" tabindex="-1"></div>
96
55
  </body>
97
- </html>
56
+ </html>
@@ -0,0 +1,43 @@
1
+ <%#
2
+ Copyright © 2012 The Pennsylvania State University
3
+
4
+ Licensed under the Apache License, Version 2.0 (the "License");
5
+ you may not use this file except in compliance with the License.
6
+ You may obtain a copy of the License at
7
+
8
+ http://www.apache.org/licenses/LICENSE-2.0
9
+
10
+ Unless required by applicable law or agreed to in writing, software
11
+ distributed under the License is distributed on an "AS IS" BASIS,
12
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ See the License for the specific language governing permissions and
14
+ limitations under the License.
15
+ %>
16
+
17
+ <!DOCTYPE html>
18
+ <html>
19
+ <head>
20
+ <%= render :partial => "layouts/head-tag-content"%>
21
+ </head>
22
+
23
+ <body>
24
+ <div id="wrapper">
25
+ <div class="container">
26
+ <div id="page-positioner">
27
+ <%= render :partial => '/masthead', :formats => [:html] %>
28
+ <%= render :partial => '/flash_msg' %>
29
+ <div id="content-wrapper">
30
+ <div id="content" class="row">
31
+ <!-- 110 rows -->
32
+ <div class="span110">
33
+ <%= yield %>
34
+ </div>
35
+ </div><!-- /#content -->
36
+ </div><!-- /#content-wrapper -->
37
+ </div><!-- /#page-positioner -->
38
+ </div><!-- /.container -->
39
+ </div><!-- /#wrapper -->
40
+ <%= render partial: '/footer' %>
41
+ <div id="ajax-modal" class="modal hide" tabindex="-1"></div>
42
+ </body>
43
+ </html>
@@ -0,0 +1,45 @@
1
+ <%#
2
+ Copyright © 2012 The Pennsylvania State University
3
+
4
+ Licensed under the Apache License, Version 2.0 (the "License");
5
+ you may not use this file except in compliance with the License.
6
+ You may obtain a copy of the License at
7
+
8
+ http://www.apache.org/licenses/LICENSE-2.0
9
+
10
+ Unless required by applicable law or agreed to in writing, software
11
+ distributed under the License is distributed on an "AS IS" BASIS,
12
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ See the License for the specific language governing permissions and
14
+ limitations under the License.
15
+ %>
16
+
17
+ <!DOCTYPE html>
18
+ <html>
19
+ <head>
20
+ <%= render :partial => "layouts/head-tag-content"%>
21
+ </head>
22
+
23
+ <body>
24
+ <div id="wrapper">
25
+ <div class="container">
26
+ <div id="page-positioner">
27
+ <%= render :partial => '/masthead', :formats => [:html] %>
28
+ <%= render :partial => '/flash_msg' %>
29
+ <div id="content-wrapper">
30
+ <div id="content" class="row">
31
+ <div class="span17">
32
+ <%= yield :sidebar %>
33
+ </div><!-- /.span17 -->
34
+ <div class="span93">
35
+ <%= yield %>
36
+ </div><!-- /.span93 -->
37
+ </div><!-- /#content -->
38
+ </div><!-- /#content-wrapper -->
39
+ </div><!-- /#page-positioner -->
40
+ </div><!-- /.container -->
41
+ </div><!-- /#wrapper -->
42
+ <%= render partial: '/footer' %>
43
+ <div id="ajax-modal" class="modal hide" tabindex="-1"></div>
44
+ </body>
45
+ </html>
@@ -14,10 +14,11 @@ See the License for the specific language governing permissions and
14
14
  limitations under the License.
15
15
  %>
16
16
 
17
- <h1>ScholarSphere Deposit License</h1>
17
+ <h1><%= t('sufia.product_name') %> Deposit Agreement</h1>
18
18
 
19
19
  <p>
20
- To properly administer this repository and preserve the contents of ScholarSphere for future use, The Pennsylvania State University (Penn State) requires certain permissions from you, the author(s), or copyright owner. By accepting this license, you do not give up the copyright to your work. You do not give up the right to submit the work to publishers or other repositories. You grant to Penn State the non-exclusive right to store your work. You agree that Penn State may translate the submission to any medium or format and keep more than one copy for the purposes of security, back up and long-term preservation of the scholarly record. Penn State will not make any alteration, other than as allowed by this license, to your submission.
20
+ To properly administer this repository and preserve the contents of
21
+ <%= t('sufia.product_name') %> for future use, <%= t('sufia.institution_name_full') %> (<%= t('sufia.institution_name') %>) requires certain permissions from you, the author(s), or copyright owner. By accepting this license, you do not give up the copyright to your work. You do not give up the right to submit the work to publishers or other repositories. You grant to <%= t('sufia.institution_name') %> the non-exclusive right to store your work. You agree that <%= t('sufia.institution_name') %> may translate the submission to any medium or format and keep more than one copy for the purposes of security, back up and long-term preservation of the scholarly record. <%= t('sufia.institution_name') %> will not make any alteration, other than as allowed by this license, to your submission.
21
22
  </p>
22
23
 
23
24
  <p>
@@ -26,35 +27,35 @@ When you submit your file(s) you will have the option of selecting its degree of
26
27
 
27
28
  <h3>Visibility Level: <span class="label label-success">OPEN ACCESS</span></h3>
28
29
  <p>
29
- By choosing the Open Access option you are allowing anyone in the world to view your submission. You may choose to apply one of several Creative Commons licenses to your submission, which are explained on the submission form and in the FAQ. These licenses allow you to set your own terms of use for anyone accessing the submission. You authorize Penn State to distribute your content under the terms of that Creative Commons license and to allow users of ScholarSphere to do the same if your license choice permits that.
30
+ By choosing the Open Access option you are allowing anyone in the world to view your submission. You may choose to apply one of several Creative Commons licenses to your submission, which are explained on the submission form and in the FAQ. These licenses allow you to set your own terms of use for anyone accessing the submission. You authorize <%= t('sufia.institution_name') %> to distribute your content under the terms of that Creative Commons license and to allow users of <%= t('sufia.product_name') %> to do the same if your license choice permits that.
30
31
 
31
- If you do not choose a license, you grant to Penn State the non-exclusive right to distribute your submission (including the metadata and abstract) worldwide, in any format or medium for non-commercial, research, educational, or related academic purposes only. You also authorize Penn State to allow users of the repository to distribute your submission (including the metadata and abstract) worldwide, in any format or medium for non-commercial, research, educational, or related academic purposes only. Penn State will clearly identify your name(s) as the author(s) or owner(s) of the submission, and will not make any alteration, other than as allowed by this license, to your submission.
32
+ If you do not choose a license, you grant to <%= t('sufia.institution_name') %> the non-exclusive right to distribute your submission (including the metadata and abstract) worldwide, in any format or medium for non-commercial, research, educational, or related academic purposes only. You also authorize <%= t('sufia.institution_name') %> to allow users of the repository to distribute your submission (including the metadata and abstract) worldwide, in any format or medium for non-commercial, research, educational, or related academic purposes only. <%= t('sufia.institution_name') %> will clearly identify your name(s) as the author(s) or owner(s) of the submission, and will not make any alteration, other than as allowed by this license, to your submission.
32
33
  </p>
33
34
 
34
35
 
35
- <h3>Visibility Level: <span class="label label-info">PENN STATE</span></h3>
36
+ <h3>Visibility Level: <span class="label label-info"><%= t('sufia.institution_name').upcase %></span></h3>
36
37
 
37
38
  <p>
38
- If you select the Penn State access option, you have decided to restrict access only to users of Penn States network. Your deposit will not be accessible to colleagues or students at other universities or to members of the public. If you want your work to be accessible to the broader scholarly community, you should consider the regular Open Access option instead. If you choose, you may also further limit access to specific individuals or groups of individuals at Penn State.
39
+ If you select the <%= t('sufia.institution_name') %> access option, you have decided to restrict access only to users of <%= t('sufia.institution_name') %>'s network. Your deposit will not be accessible to colleagues or students at other universities or to members of the public. If you want your work to be accessible to the broader scholarly community, you should consider the regular Open Access option instead. If you choose, you may also further limit access to specific individuals or groups of individuals at <%= t('sufia.institution_name') %>.
39
40
  </p>
40
41
 
41
42
  <p>
42
- By clicking through this license, you grant to Penn State the non-exclusive right to reproduce and/or distribute your submission (including the metadata and abstract) to students, faculty, staff, and walk-in users of the Penn State libraries, in any format or medium for non-commercial, research, educational, or related academic purposes only. If you have limited access to specific individuals or groups, Penn State will distribute your submission ONLY to those users. You also authorize Penn State to allow Penn State community users of the repository to distribute your submission (including the metadata and abstract) in any format or medium for Penn State internal non-commercial, research, educational, or related academic purposes only. Penn State will clearly identify your name(s) as the author(s) or owner(s) of the submission, and will not make any alteration, other than as allowed by this license, to your submission.
43
+ By clicking through this license, you grant to <%= t('sufia.institution_name') %> the non-exclusive right to reproduce and/or distribute your submission (including the metadata and abstract) to students, faculty, staff, and walk-in users of the <%= t('sufia.institution_name') %> libraries, in any format or medium for non-commercial, research, educational, or related academic purposes only. If you have limited access to specific individuals or groups, <%= t('sufia.institution_name') %> will distribute your submission ONLY to those users. You also authorize <%= t('sufia.institution_name') %> to allow <%= t('sufia.institution_name') %> community users of the repository to distribute your submission (including the metadata and abstract) in any format or medium for <%= t('sufia.institution_name') %> internal non-commercial, research, educational, or related academic purposes only. <%= t('sufia.institution_name') %> will clearly identify your name(s) as the author(s) or owner(s) of the submission, and will not make any alteration, other than as allowed by this license, to your submission.
43
44
  </p>
44
45
 
45
46
  <h3>Visibility Level: <span class="label label-important">PRIVATE</span></h3>
46
47
 
47
48
  <p>
48
- If you have selected the PRIVATE access option in the ScholarSphere deposit process, you have decided to allow Penn State a more limited set of rights than those afforded under the Open Access license option. Your deposit will not be accessible to anyone other than yourself. If you want your work to be accessible to the broader scholarly community, you should consider the regular Open Access or Penn State settings instead.
49
+ If you have selected the PRIVATE access option in the <%= t('sufia.product_name') %> deposit process, you have decided to allow <%= t('sufia.institution_name') %> a more limited set of rights than those afforded under the Open Access license option. Your deposit will not be accessible to anyone other than yourself. If you want your work to be accessible to the broader scholarly community, you should consider the regular Open Access or <%= t('sufia.institution_name') %> settings instead.
49
50
  </p>
50
51
 
51
52
  <h2>The following terms apply to ALL submissions:</h2>
52
53
  <p>
53
- You agree that Penn State bears no responsibility for the contents of your submission. You represent that the submission is your original work, and/or that you have the right to grant the rights contained in this license. You also represent that your submission does not, to the best of your knowledge, infringe upon anyone's copyright. You also represent and warrant that the submission contains no libelous or other unlawful matter and makes no improper invasion of the privacy of any other person.
54
+ You agree that <%= t('sufia.institution_name') %> bears no responsibility for the contents of your submission. You represent that the submission is your original work, and/or that you have the right to grant the rights contained in this license. You also represent that your submission does not, to the best of your knowledge, infringe upon anyone's copyright. You also represent and warrant that the submission contains no libelous or other unlawful matter and makes no improper invasion of the privacy of any other person.
54
55
  </p>
55
56
  <p>
56
- If the submission contains material for which you do not hold copyright and that exceeds fair use, you represent that you have obtained the unrestricted permission of the copyright owner to grant Penn State the rights required by this license, and that such third-party owned material is clearly identified and acknowledged within the text or content of the submission.
57
+ If the submission contains material for which you do not hold copyright and that exceeds fair use, you represent that you have obtained the unrestricted permission of the copyright owner to grant <%= t('sufia.institution_name') %> the rights required by this license, and that such third-party owned material is clearly identified and acknowledged within the text or content of the submission.
57
58
  </p>
58
59
  <p>
59
- IF THE SUBMISSION IS BASED UPON WORK THAT HAS BEEN SPONSORED OR SUPPORTED BY AN AGENCY OR ORGANIZATION OTHER THAN PENN STATE SUCH AS, BUT NOT LIMITED TO, THE NATIONAL INSTITUTES OF HEALTH, THE NATIONAL SCIENCE FOUNDATION, OR A PRIVATE FUNDER, YOU REPRESENT THAT YOU HAVE FULFILLED ANY RIGHT OF REVIEW, CONFIDENTIALITY, OR OTHER OBLIGATIONS REQUIRED BY THAT CONTRACT OR AGREEMENT.
60
+ IF THE SUBMISSION IS BASED UPON WORK THAT HAS BEEN SPONSORED OR SUPPORTED BY AN AGENCY OR ORGANIZATION OTHER THAN <%= t('sufia.institution_name').upcase %> SUCH AS, BUT NOT LIMITED TO, THE NATIONAL INSTITUTES OF HEALTH, THE NATIONAL SCIENCE FOUNDATION, OR A PRIVATE FUNDER, YOU REPRESENT THAT YOU HAVE FULFILLED ANY RIGHT OF REVIEW, CONFIDENTIALITY, OR OTHER OBLIGATIONS REQUIRED BY THAT CONTRACT OR AGREEMENT.
60
61
  </p>
@@ -17,6 +17,6 @@ limitations under the License.
17
17
  <h1>Export to Mendeley</h1>
18
18
  <p>
19
19
  Exporting to Mendeley is supported via embedded metadata. If Mendeley
20
- does not automatically pick up metadata for files deposited in
21
- ScholarSphere, please report the issue via the <%= link_to 'Contact Form', contact_form_index_path %>.
20
+ does not automatically pick up metadata for deposited files, please
21
+ report the issue via the <%= link_to 'Contact Form', contact_form_index_path %>.
22
22
  </p>