commonwealth-vlr-engine 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (361) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +91 -0
  3. data/.gitmodules +3 -0
  4. data/Gemfile +20 -0
  5. data/LICENSE +202 -0
  6. data/README.md +38 -0
  7. data/Rakefile +43 -0
  8. data/app/assets/images/commonwealth-vlr-engine/bplLoginButton.png +0 -0
  9. data/app/assets/images/commonwealth-vlr-engine/dc_audio-icon.png +0 -0
  10. data/app/assets/images/commonwealth-vlr-engine/dc_collection-icon.png +0 -0
  11. data/app/assets/images/commonwealth-vlr-engine/dc_image-icon.png +0 -0
  12. data/app/assets/images/commonwealth-vlr-engine/dc_institution-icon.png +0 -0
  13. data/app/assets/images/commonwealth-vlr-engine/dc_moving-image-icon.png +0 -0
  14. data/app/assets/images/commonwealth-vlr-engine/dc_text-icon.png +0 -0
  15. data/app/assets/images/commonwealth-vlr-engine/facebookLoginButton.png +0 -0
  16. data/app/assets/images/commonwealth-vlr-engine/loading-wdl-grid.gif +0 -0
  17. data/app/assets/images/commonwealth-vlr-engine/loading-wdl.gif +0 -0
  18. data/app/assets/images/commonwealth-vlr-engine/loading.gif +0 -0
  19. data/app/assets/images/commonwealth-vlr-engine/openseadragon/fullpage_grouphover.png +0 -0
  20. data/app/assets/images/commonwealth-vlr-engine/openseadragon/fullpage_hover.png +0 -0
  21. data/app/assets/images/commonwealth-vlr-engine/openseadragon/fullpage_pressed.png +0 -0
  22. data/app/assets/images/commonwealth-vlr-engine/openseadragon/fullpage_rest.png +0 -0
  23. data/app/assets/images/commonwealth-vlr-engine/openseadragon/home_grouphover.png +0 -0
  24. data/app/assets/images/commonwealth-vlr-engine/openseadragon/home_hover.png +0 -0
  25. data/app/assets/images/commonwealth-vlr-engine/openseadragon/home_pressed.png +0 -0
  26. data/app/assets/images/commonwealth-vlr-engine/openseadragon/home_rest.png +0 -0
  27. data/app/assets/images/commonwealth-vlr-engine/openseadragon/next_grouphover.png +0 -0
  28. data/app/assets/images/commonwealth-vlr-engine/openseadragon/next_hover.png +0 -0
  29. data/app/assets/images/commonwealth-vlr-engine/openseadragon/next_pressed.png +0 -0
  30. data/app/assets/images/commonwealth-vlr-engine/openseadragon/next_rest.png +0 -0
  31. data/app/assets/images/commonwealth-vlr-engine/openseadragon/previous_grouphover.png +0 -0
  32. data/app/assets/images/commonwealth-vlr-engine/openseadragon/previous_hover.png +0 -0
  33. data/app/assets/images/commonwealth-vlr-engine/openseadragon/previous_pressed.png +0 -0
  34. data/app/assets/images/commonwealth-vlr-engine/openseadragon/previous_rest.png +0 -0
  35. data/app/assets/images/commonwealth-vlr-engine/openseadragon/rotateleft_grouphover.png +0 -0
  36. data/app/assets/images/commonwealth-vlr-engine/openseadragon/rotateleft_hover.png +0 -0
  37. data/app/assets/images/commonwealth-vlr-engine/openseadragon/rotateleft_pressed.png +0 -0
  38. data/app/assets/images/commonwealth-vlr-engine/openseadragon/rotateleft_rest.png +0 -0
  39. data/app/assets/images/commonwealth-vlr-engine/openseadragon/rotateright_grouphover.png +0 -0
  40. data/app/assets/images/commonwealth-vlr-engine/openseadragon/rotateright_hover.png +0 -0
  41. data/app/assets/images/commonwealth-vlr-engine/openseadragon/rotateright_pressed.png +0 -0
  42. data/app/assets/images/commonwealth-vlr-engine/openseadragon/rotateright_rest.png +0 -0
  43. data/app/assets/images/commonwealth-vlr-engine/openseadragon/zoomin_grouphover.png +0 -0
  44. data/app/assets/images/commonwealth-vlr-engine/openseadragon/zoomin_hover.png +0 -0
  45. data/app/assets/images/commonwealth-vlr-engine/openseadragon/zoomin_pressed.png +0 -0
  46. data/app/assets/images/commonwealth-vlr-engine/openseadragon/zoomin_rest.png +0 -0
  47. data/app/assets/images/commonwealth-vlr-engine/openseadragon/zoomout_grouphover.png +0 -0
  48. data/app/assets/images/commonwealth-vlr-engine/openseadragon/zoomout_hover.png +0 -0
  49. data/app/assets/images/commonwealth-vlr-engine/openseadragon/zoomout_pressed.png +0 -0
  50. data/app/assets/images/commonwealth-vlr-engine/openseadragon/zoomout_rest.png +0 -0
  51. data/app/assets/images/commonwealth-vlr-engine/vlr_logo_img.png +0 -0
  52. data/app/assets/javascripts/blacklight_gallery.js +1 -0
  53. data/app/assets/javascripts/blacklight_google_analytics/blacklight_google_analytics.js.erb +165 -0
  54. data/app/assets/javascripts/bootstrap-accessibility-plugin/bootstrap-accessibility.js +586 -0
  55. data/app/assets/javascripts/commonwealth-vlr-engine.js +22 -0
  56. data/app/assets/javascripts/commonwealth-vlr-engine/collection_facets.js +5 -0
  57. data/app/assets/javascripts/commonwealth-vlr-engine/disable_dropdown_nav.js +21 -0
  58. data/app/assets/javascripts/commonwealth-vlr-engine/feedback_alerts.js.erb +19 -0
  59. data/app/assets/javascripts/commonwealth-vlr-engine/folder_tools.js +26 -0
  60. data/app/assets/javascripts/commonwealth-vlr-engine/multi_img_viewer.js.erb +20 -0
  61. data/app/assets/javascripts/commonwealth-vlr-engine/ocr_search_utils.js.erb +32 -0
  62. data/app/assets/javascripts/commonwealth-vlr-engine/volumes_list.js +5 -0
  63. data/app/assets/javascripts/openseadragon.js +2 -0
  64. data/app/assets/javascripts/respond/respond.min.js +6 -0
  65. data/app/assets/javascripts/wdl-viewer/fd-slider.js +1303 -0
  66. data/app/assets/javascripts/wdl-viewer/jquery-deparam.js +113 -0
  67. data/app/assets/javascripts/wdl-viewer/jquery.ba-throttle-debounce.min.js +9 -0
  68. data/app/assets/javascripts/wdl-viewer/jquery.hammer.min.js +7 -0
  69. data/app/assets/javascripts/wdl-viewer/modernizr-wdl.min.js +3 -0
  70. data/app/assets/javascripts/wdl-viewer/wdl-search.js +33 -0
  71. data/app/assets/javascripts/wdl-viewer/wdl-viewer_commonwealth.js +1147 -0
  72. data/app/assets/stylesheets/blacklight_advanced_search.css +5 -0
  73. data/app/assets/stylesheets/blacklight_gallery.css +1 -0
  74. data/app/assets/stylesheets/blacklight_maps.css +1 -0
  75. data/app/assets/stylesheets/bootstrap-accessibility-plugin/bootstrap-accessibility.css +105 -0
  76. data/app/assets/stylesheets/commonwealth-vlr-engine/advanced_search.scss +139 -0
  77. data/app/assets/stylesheets/commonwealth-vlr-engine/basic_search.scss +47 -0
  78. data/app/assets/stylesheets/commonwealth-vlr-engine/book_viewer.scss +576 -0
  79. data/app/assets/stylesheets/commonwealth-vlr-engine/carousel.scss +94 -0
  80. data/app/assets/stylesheets/commonwealth-vlr-engine/cmmnwlth_defaults.scss +45 -0
  81. data/app/assets/stylesheets/commonwealth-vlr-engine/cmmnwlth_shared.scss +75 -0
  82. data/app/assets/stylesheets/commonwealth-vlr-engine/collections.scss +563 -0
  83. data/app/assets/stylesheets/commonwealth-vlr-engine/commonwealth-vlr-engine.css +32 -0
  84. data/app/assets/stylesheets/commonwealth-vlr-engine/facets.scss +111 -0
  85. data/app/assets/stylesheets/commonwealth-vlr-engine/feedback.scss +10 -0
  86. data/app/assets/stylesheets/commonwealth-vlr-engine/folders.scss +276 -0
  87. data/app/assets/stylesheets/commonwealth-vlr-engine/footer.scss +47 -0
  88. data/app/assets/stylesheets/commonwealth-vlr-engine/header.scss +329 -0
  89. data/app/assets/stylesheets/commonwealth-vlr-engine/home.scss +269 -0
  90. data/app/assets/stylesheets/commonwealth-vlr-engine/index.scss +580 -0
  91. data/app/assets/stylesheets/commonwealth-vlr-engine/institutions.scss +246 -0
  92. data/app/assets/stylesheets/commonwealth-vlr-engine/pages.scss +31 -0
  93. data/app/assets/stylesheets/commonwealth-vlr-engine/search_inside.scss +172 -0
  94. data/app/assets/stylesheets/commonwealth-vlr-engine/searches.scss +55 -0
  95. data/app/assets/stylesheets/commonwealth-vlr-engine/show.scss +840 -0
  96. data/app/assets/stylesheets/commonwealth-vlr-engine/signin.scss +43 -0
  97. data/app/assets/stylesheets/commonwealth-vlr-engine/users.scss +18 -0
  98. data/app/assets/stylesheets/commonwealth-vlr-engine/vlr_dependencies.css +8 -0
  99. data/app/assets/stylesheets/ie_fixes.css +16 -0
  100. data/app/assets/stylesheets/openseadragon.css +1 -0
  101. data/app/assets/stylesheets/wdl-viewer/fd-slider.min.css +2 -0
  102. data/app/controllers/blacklight_advanced_search/advanced_controller.rb +66 -0
  103. data/app/controllers/bookmarks_controller.rb +38 -0
  104. data/app/controllers/collections_controller.rb +128 -0
  105. data/app/controllers/commonwealth_vlr_engine/application_controller.rb +8 -0
  106. data/app/controllers/feedback_controller.rb +39 -0
  107. data/app/controllers/folder_items_actions_controller.rb +72 -0
  108. data/app/controllers/folder_items_controller.rb +90 -0
  109. data/app/controllers/folders_controller.rb +132 -0
  110. data/app/controllers/iiif_manifest_controller.rb +74 -0
  111. data/app/controllers/image_viewer_controller.rb +34 -0
  112. data/app/controllers/institutions_controller.rb +62 -0
  113. data/app/controllers/ocr_search_controller.rb +78 -0
  114. data/app/controllers/pages_controller.rb +5 -0
  115. data/app/controllers/users/omniauth_callbacks_controller.rb +10 -0
  116. data/app/controllers/users/registrations_controller.rb +3 -0
  117. data/app/controllers/users/sessions_controller.rb +3 -0
  118. data/app/controllers/users_controller.rb +27 -0
  119. data/app/helpers/blacklight_maps_helper.rb +3 -0
  120. data/app/helpers/collections_helper.rb +3 -0
  121. data/app/helpers/commonwealth_vlr_engine/application_helper.rb +200 -0
  122. data/app/helpers/commonwealth_vlr_engine/blacklight_helper.rb +35 -0
  123. data/app/helpers/commonwealth_vlr_engine/blacklight_url_helper.rb +53 -0
  124. data/app/helpers/commonwealth_vlr_engine/catalog_helper.rb +414 -0
  125. data/app/helpers/commonwealth_vlr_engine/collections_helper_behavior.rb +19 -0
  126. data/app/helpers/commonwealth_vlr_engine/component_helper.rb +22 -0
  127. data/app/helpers/commonwealth_vlr_engine/facets_helper.rb +20 -0
  128. data/app/helpers/commonwealth_vlr_engine/feedback_helper_behavior.rb +14 -0
  129. data/app/helpers/commonwealth_vlr_engine/folders_helper_behavior.rb +9 -0
  130. data/app/helpers/commonwealth_vlr_engine/image_viewer_helper_behavior.rb +14 -0
  131. data/app/helpers/commonwealth_vlr_engine/institutions_helper_behavior.rb +31 -0
  132. data/app/helpers/commonwealth_vlr_engine/layout_helper.rb +22 -0
  133. data/app/helpers/commonwealth_vlr_engine/ocr_search_helper_behavior.rb +48 -0
  134. data/app/helpers/commonwealth_vlr_engine/pages_helper_behavior.rb +38 -0
  135. data/app/helpers/commonwealth_vlr_engine/vlr_blacklight_maps_helper_behavior.rb +59 -0
  136. data/app/helpers/feedback_helper.rb +3 -0
  137. data/app/helpers/folders_helper.rb +3 -0
  138. data/app/helpers/image_viewer_helper.rb +3 -0
  139. data/app/helpers/institutions_helper.rb +3 -0
  140. data/app/helpers/ocr_search_helper.rb +3 -0
  141. data/app/helpers/pages_helper.rb +3 -0
  142. data/app/mailers/notifier.rb +5 -0
  143. data/app/models/carousel_slide.rb +7 -0
  144. data/app/models/record_mailer.rb +18 -0
  145. data/app/models/user.rb +15 -0
  146. data/app/views/advanced/_advanced_search_date.html.erb +23 -0
  147. data/app/views/advanced/_advanced_search_facets.html.erb +5 -0
  148. data/app/views/advanced/_advanced_search_fields.html.erb +39 -0
  149. data/app/views/advanced/_advanced_search_form.html.erb +51 -0
  150. data/app/views/advanced/_advanced_search_help.html.erb +13 -0
  151. data/app/views/advanced/_facet_layout.html.erb +9 -0
  152. data/app/views/advanced/_facet_limit.html.erb +15 -0
  153. data/app/views/advanced/index.html.erb +29 -0
  154. data/app/views/blacklight_advanced_search/_facet_limit.html.erb +12 -0
  155. data/app/views/bookmarks/_tools.html.erb +25 -0
  156. data/app/views/bookmarks/index.html.erb +64 -0
  157. data/app/views/bookmarks/update.js.erb +1 -0
  158. data/app/views/bpluser/folders/_folder.html.erb +36 -0
  159. data/app/views/catalog/_add_this.html.erb +10 -0
  160. data/app/views/catalog/_az_links.html.erb +15 -0
  161. data/app/views/catalog/_basic_search.html.erb +67 -0
  162. data/app/views/catalog/_citation.html.erb +50 -0
  163. data/app/views/catalog/_constraints.html.erb +26 -0
  164. data/app/views/catalog/_document_collections_gallery.html.erb +7 -0
  165. data/app/views/catalog/_facet_limit_series.html.erb +21 -0
  166. data/app/views/catalog/_facets.html.erb +31 -0
  167. data/app/views/catalog/_facets_series.html.erb +4 -0
  168. data/app/views/catalog/_folder_item_control.html.erb +64 -0
  169. data/app/views/catalog/_index_collections_gallery.html.erb +12 -0
  170. data/app/views/catalog/_index_gallery.html.erb +11 -0
  171. data/app/views/catalog/_index_header_default.html.erb +22 -0
  172. data/app/views/catalog/_index_list_collection.html.erb +33 -0
  173. data/app/views/catalog/_index_list_default.html.erb +13 -0
  174. data/app/views/catalog/_index_map_institutions.html.erb +10 -0
  175. data/app/views/catalog/_index_masonry.html.erb +8 -0
  176. data/app/views/catalog/_index_slideshow.html.erb +18 -0
  177. data/app/views/catalog/_more_like_this.html.erb +9 -0
  178. data/app/views/catalog/_opengraph.html.erb +16 -0
  179. data/app/views/catalog/_previous_next_doc.html.erb +22 -0
  180. data/app/views/catalog/_results_pagination.html.erb +9 -0
  181. data/app/views/catalog/_search_form.html.erb +23 -0
  182. data/app/views/catalog/_search_header.html.erb +5 -0
  183. data/app/views/catalog/_show_default.html.erb +75 -0
  184. data/app/views/catalog/_show_main_content.html.erb +27 -0
  185. data/app/views/catalog/_show_more_like_this.html.erb +15 -0
  186. data/app/views/catalog/_show_partials/_show_book_viewer_link.html.erb +25 -0
  187. data/app/views/catalog/_show_partials/_show_default_img.html.erb +32 -0
  188. data/app/views/catalog/_show_partials/_show_default_metadata.html.erb +486 -0
  189. data/app/views/catalog/_show_partials/_show_default_simple_img_viewer.html.erb +45 -0
  190. data/app/views/catalog/_show_partials/_show_downloads.html.erb +14 -0
  191. data/app/views/catalog/_show_partials/_show_flagged_notice.html.erb +29 -0
  192. data/app/views/catalog/_show_partials/_show_multi_img.html.erb +42 -0
  193. data/app/views/catalog/_show_partials/_show_multi_img_pagination.html.erb +20 -0
  194. data/app/views/catalog/_show_partials/_show_oai_item_img.html.erb +5 -0
  195. data/app/views/catalog/_show_partials/_show_oai_item_link.html.erb +8 -0
  196. data/app/views/catalog/_show_partials/_show_prev_next_carousel_links.html.erb +17 -0
  197. data/app/views/catalog/_show_partials/_show_volumes.html.erb +52 -0
  198. data/app/views/catalog/_show_sidebar.html.erb +1 -0
  199. data/app/views/catalog/_show_tools.html.erb +42 -0
  200. data/app/views/catalog/_zero_results.html.erb +20 -0
  201. data/app/views/catalog/email.html.erb +6 -0
  202. data/app/views/catalog/index.html.erb +17 -0
  203. data/app/views/catalog/metadata_view.html.erb +7 -0
  204. data/app/views/catalog/show.html.erb +13 -0
  205. data/app/views/collections/_search_form_collection.html.erb +23 -0
  206. data/app/views/collections/index.html.erb +30 -0
  207. data/app/views/collections/show.html.erb +116 -0
  208. data/app/views/devise/confirmations/new.html.erb +14 -0
  209. data/app/views/devise/mailer/reset_password_instructions.html.erb +13 -0
  210. data/app/views/devise/passwords/edit.html.erb +33 -0
  211. data/app/views/devise/passwords/new.html.erb +31 -0
  212. data/app/views/devise/registrations/edit.html.erb +83 -0
  213. data/app/views/devise/registrations/new.html.erb +53 -0
  214. data/app/views/devise/sessions/new.html.erb +75 -0
  215. data/app/views/devise/shared/_links.erb +29 -0
  216. data/app/views/feedback/complete.html.erb +9 -0
  217. data/app/views/feedback/show.html.erb +61 -0
  218. data/app/views/folder_items/create.js.erb +1 -0
  219. data/app/views/folder_items/destroy.js.erb +1 -0
  220. data/app/views/folder_items/item_actions.js.erb +2 -0
  221. data/app/views/folder_items/update.js.erb +1 -0
  222. data/app/views/folders/_in_folder.html.erb +2 -0
  223. data/app/views/folders/_new_edit_form_fields.html.erb +36 -0
  224. data/app/views/folders/edit.html.erb +25 -0
  225. data/app/views/folders/index.html.erb +73 -0
  226. data/app/views/folders/new.html.erb +27 -0
  227. data/app/views/folders/public_list.html.erb +44 -0
  228. data/app/views/folders/show.html.erb +98 -0
  229. data/app/views/image_viewer/_book_viewer_help.html.erb +125 -0
  230. data/app/views/image_viewer/_render_book_viewer.html.erb +185 -0
  231. data/app/views/image_viewer/book_viewer.html.erb +57 -0
  232. data/app/views/image_viewer/show.js.erb +19 -0
  233. data/app/views/institutions/_intro_text.html.erb +1 -0
  234. data/app/views/institutions/_map_institutions_search.html.erb +9 -0
  235. data/app/views/institutions/_search_form_institution.html.erb +24 -0
  236. data/app/views/institutions/index.html.erb +31 -0
  237. data/app/views/institutions/show.html.erb +104 -0
  238. data/app/views/layouts/_google_analytics.html.erb +9 -0
  239. data/app/views/layouts/book_viewer.html.erb +37 -0
  240. data/app/views/layouts/commonwealth-vlr-engine.html.erb +59 -0
  241. data/app/views/notifier/feedback.text.erb +6 -0
  242. data/app/views/ocr_search/_index_ocr_list.html.erb +17 -0
  243. data/app/views/ocr_search/_search_form_ocr.html.erb +23 -0
  244. data/app/views/ocr_search/_snippets_more.html.erb +15 -0
  245. data/app/views/ocr_search/_zero_results_ocr.html.erb +9 -0
  246. data/app/views/ocr_search/index.html.erb +49 -0
  247. data/app/views/pages/_carousel.html.erb +46 -0
  248. data/app/views/pages/_home_partials/_banner.html.erb +23 -0
  249. data/app/views/pages/_home_partials/_browse.html.erb +55 -0
  250. data/app/views/pages/_home_partials/_context.html.erb +24 -0
  251. data/app/views/pages/_home_partials/_home_content.html.erb +14 -0
  252. data/app/views/pages/about.html.erb +10 -0
  253. data/app/views/pages/about_site.html.erb +6 -0
  254. data/app/views/pages/explore.html.erb +32 -0
  255. data/app/views/pages/home.html.erb +3 -0
  256. data/app/views/record_mailer/email_record.text.erb +7 -0
  257. data/app/views/saved_searches/index.html.erb +60 -0
  258. data/app/views/search_history/index.html.erb +59 -0
  259. data/app/views/shared/_error_messages.html.erb +9 -0
  260. data/app/views/shared/_flash_msg_maintenance.html.erb +6 -0
  261. data/app/views/shared/_folder_item_actions.html.erb +66 -0
  262. data/app/views/shared/_folder_tools.html.erb +4 -0
  263. data/app/views/shared/_footer.html.erb +14 -0
  264. data/app/views/shared/_header_navbar.html.erb +34 -0
  265. data/app/views/shared/_nav_links.html.erb +58 -0
  266. data/app/views/shared/_search_form_header.html.erb +16 -0
  267. data/app/views/shared/_tools.html.erb +14 -0
  268. data/app/views/shared/_user_util_links.html.erb +43 -0
  269. data/app/views/users/show.html.erb +33 -0
  270. data/commonwealth-vlr-engine.gemspec +47 -0
  271. data/config/initializers/patch_blacklight_advanced_search.rb +74 -0
  272. data/config/initializers/patch_blacklight_maps.rb +20 -0
  273. data/config/jetty.yml +7 -0
  274. data/config/locales/commonwealth-vlr-engine.en.yml +463 -0
  275. data/config/routes.rb +92 -0
  276. data/lib/commonwealth-vlr-engine.rb +55 -0
  277. data/lib/commonwealth-vlr-engine/commonwealth_search_builder.rb +66 -0
  278. data/lib/commonwealth-vlr-engine/controller.rb +69 -0
  279. data/lib/commonwealth-vlr-engine/controller_override.rb +238 -0
  280. data/lib/commonwealth-vlr-engine/engine.rb +40 -0
  281. data/lib/commonwealth-vlr-engine/finder.rb +285 -0
  282. data/lib/commonwealth-vlr-engine/iiif_manifest.rb +189 -0
  283. data/lib/commonwealth-vlr-engine/notifier.rb +33 -0
  284. data/lib/commonwealth-vlr-engine/pages.rb +33 -0
  285. data/lib/commonwealth-vlr-engine/render_constraints_override.rb +57 -0
  286. data/lib/commonwealth-vlr-engine/route_sets.rb +49 -0
  287. data/lib/commonwealth-vlr-engine/routes.rb +21 -0
  288. data/lib/commonwealth-vlr-engine/version.rb +3 -0
  289. data/lib/generators/commonwealth_vlr_engine/controller_generator.rb +92 -0
  290. data/lib/generators/commonwealth_vlr_engine/environment_generator.rb +49 -0
  291. data/lib/generators/commonwealth_vlr_engine/install_generator.rb +57 -0
  292. data/lib/generators/commonwealth_vlr_engine/localassets_generator.rb +29 -0
  293. data/lib/generators/commonwealth_vlr_engine/model_generator.rb +65 -0
  294. data/lib/generators/commonwealth_vlr_engine/routes_generator.rb +39 -0
  295. data/lib/generators/commonwealth_vlr_engine/templates/commonwealth_vlr_engine.css.scss +4 -0
  296. data/lib/generators/commonwealth_vlr_engine/templates/config/contact_emails.yml.sample +13 -0
  297. data/lib/generators/commonwealth_vlr_engine/templates/config/fedora.yml.sample +6 -0
  298. data/lib/generators/commonwealth_vlr_engine/templates/config/geojson_static_file.yml.sample +11 -0
  299. data/lib/generators/commonwealth_vlr_engine/templates/config/google_analytics.yml.sample +10 -0
  300. data/lib/generators/commonwealth_vlr_engine/templates/config/iiif_server.yml.sample +10 -0
  301. data/lib/generators/commonwealth_vlr_engine/templates/config/initializers/a_load_commonwealth_vlr_configs.rb +14 -0
  302. data/lib/generators/commonwealth_vlr_engine/templates/config/initializers/devise.rb +269 -0
  303. data/lib/generators/commonwealth_vlr_engine/templates/config/initializers/secret_token.rb +8 -0
  304. data/lib/generators/commonwealth_vlr_engine/templates/config/locales/blacklight.en.yml +44 -0
  305. data/lib/generators/commonwealth_vlr_engine/templates/config/locales/devise.en.yml +12 -0
  306. data/lib/generators/commonwealth_vlr_engine/templates/config/omniauth-facebook.yml.sample +14 -0
  307. data/lib/generators/commonwealth_vlr_engine/templates/config/omniauth-polaris.yml.sample +20 -0
  308. data/lib/generators/commonwealth_vlr_engine/templates/config/vlr.yml +13 -0
  309. data/lib/generators/commonwealth_vlr_engine/yml_generator.rb +29 -0
  310. data/lib/railties/commonwealth_vlr_engine.rake +6 -0
  311. data/solr_conf/conf/schema.xml +476 -0
  312. data/solr_conf/conf/solrconfig.xml +286 -0
  313. data/spec/controllers/catalog_controller_spec.rb +67 -0
  314. data/spec/controllers/collections_controller_spec.rb +127 -0
  315. data/spec/controllers/feedback_controller_spec.rb +51 -0
  316. data/spec/controllers/folder_items_actions_controller_spec.rb +99 -0
  317. data/spec/controllers/folder_items_controller_spec.rb +90 -0
  318. data/spec/controllers/folders_controller_spec.rb +368 -0
  319. data/spec/controllers/iiif_manifest_controller_spec.rb +85 -0
  320. data/spec/controllers/image_viewer_controller_spec.rb +50 -0
  321. data/spec/controllers/institutions_controller_spec.rb +64 -0
  322. data/spec/controllers/ocr_search_controller_spec.rb +71 -0
  323. data/spec/controllers/pages_controller_spec.rb +58 -0
  324. data/spec/controllers/users_controller_spec.rb +62 -0
  325. data/spec/features/catalog/_az_links_spec.rb +27 -0
  326. data/spec/features/catalog/_show_partials/_show_book_viewer_link_spec.rb +47 -0
  327. data/spec/features/catalog/_show_partials/_show_default_simple_img_viewer_spec.rb +19 -0
  328. data/spec/features/catalog/_show_partials/_show_flagged_notice_spec.rb +23 -0
  329. data/spec/features/catalog/_show_partials/_show_multi_img_spec.rb +18 -0
  330. data/spec/features/catalog/_show_partials/_show_volumes_spec.rb +24 -0
  331. data/spec/features/collections/index_spec.rb +35 -0
  332. data/spec/features/feedback/show_spec.rb +47 -0
  333. data/spec/features/image_viewer/book_viewer_spec.rb +67 -0
  334. data/spec/features/institutions/index_spec.rb +31 -0
  335. data/spec/features/institutions/map_view_spec.rb +37 -0
  336. data/spec/features/more_like_this_search_spec.rb +23 -0
  337. data/spec/features/ocr_search/index_spec.rb +89 -0
  338. data/spec/fixtures/sample_rss_feed.xml +56 -0
  339. data/spec/fixtures/sample_solr_documents.yml +2748 -0
  340. data/spec/helpers/application_helper_spec.rb +114 -0
  341. data/spec/helpers/catalog_helper_spec.rb +386 -0
  342. data/spec/helpers/collections_helper_spec.rb +28 -0
  343. data/spec/helpers/component_helper_spec.rb +34 -0
  344. data/spec/helpers/folders_helper_spec.rb +31 -0
  345. data/spec/helpers/image_viewer_helper_spec.rb +15 -0
  346. data/spec/helpers/institutions_helper_spec.rb +53 -0
  347. data/spec/helpers/ocr_search_helper_spec.rb +70 -0
  348. data/spec/helpers/pages_helper_spec.rb +21 -0
  349. data/spec/lib/commonwealth-vlr-engine/commonwealth_search_builder_spec.rb +101 -0
  350. data/spec/lib/commonwealth-vlr-engine/controller_override_spec.rb +41 -0
  351. data/spec/lib/commonwealth-vlr-engine/controller_spec.rb +33 -0
  352. data/spec/lib/commonwealth-vlr-engine/finder_spec.rb +140 -0
  353. data/spec/lib/commonwealth-vlr-engine/iiif_manifest_spec.rb +157 -0
  354. data/spec/lib/commonwealth-vlr-engine/render_constraints_override_spec.rb +97 -0
  355. data/spec/mailers/notifier_spec.rb +31 -0
  356. data/spec/models/carousel_slide_spec.rb +38 -0
  357. data/spec/spec_helper.rb +40 -0
  358. data/spec/tasks/vlr_engine_rake_spec.rb +28 -0
  359. data/spec/test_app_templates/lib/generators/test_app_generator.rb +23 -0
  360. data/tasks/vlr_engine.rake +46 -0
  361. metadata +788 -0
@@ -0,0 +1,43 @@
1
+ /* styles for signin/auth views */
2
+
3
+ #signin_wrapper {
4
+ padding-top:10px;
5
+
6
+ #alt_signins {
7
+ padding: 1em 0 2em 0;
8
+
9
+ .alt_signin_btn {
10
+ padding-right: 1em;
11
+ }
12
+
13
+ }
14
+
15
+ }
16
+
17
+ #signup_wrapper {
18
+ padding-top:10px;
19
+ }
20
+
21
+ #edit_account_wrapper {
22
+
23
+ #error_explanation {
24
+
25
+ h2 {
26
+ display:none;
27
+ }
28
+ }
29
+
30
+ }
31
+
32
+ #why_log_in {
33
+ margin-top: 42px;
34
+
35
+ ul {
36
+ padding-left: 20px;
37
+ }
38
+
39
+ }
40
+
41
+ #password_reset, #password_edit {
42
+ padding-top: 20px;
43
+ }
@@ -0,0 +1,18 @@
1
+ /* styles for users#show */
2
+
3
+ #user_account_links_list {
4
+
5
+ h4 {
6
+ margin:15px 0 2px 0;
7
+ }
8
+
9
+ }
10
+
11
+ .sidebar-right {
12
+ margin-top:30px;
13
+
14
+ ul {
15
+ padding-left: 20px;
16
+ }
17
+
18
+ }
@@ -0,0 +1,8 @@
1
+ /* various dependencies for commonwealth-vlr-engine */
2
+
3
+ @import 'blacklight_maps';
4
+ @import 'blacklight_gallery';
5
+ @import 'bootstrap-accessibility-plugin/bootstrap-accessibility';
6
+ @import 'blacklight_advanced_search';
7
+ @import 'font-awesome';
8
+ @import 'openseadragon';
@@ -0,0 +1,16 @@
1
+ /* fixes for IE8 */
2
+
3
+ /* can't use fixed navbar or dropdown menus won't work */
4
+ body.blacklight-institutions-index #header-navbar, body.blacklight-collections-index #header-navbar, body.blacklight-catalog-index #header-navbar {
5
+ position: relative;
6
+ z-index: inherit;
7
+ }
8
+
9
+ body.blacklight-institutions-index #main-containe, body.blacklight-collections-index #main-containe, body.blacklight-catalog-index #main-container {
10
+ padding-top: 10px;
11
+ }
12
+
13
+ /* helps dropdowns not be so wonky */
14
+ #main-container {
15
+ padding-top: 10px;
16
+ }
@@ -0,0 +1 @@
1
+ @import 'openseadragon/openseadragon';
@@ -0,0 +1,2 @@
1
+ /* fd-slider.min.css referencing individual .png images for IE6 and 7 */
2
+ .fd-form-element-hidden{display:none}.fd-slider{width:100%;height:20px;margin:0 0 10px 0}.fd-slider-vertical{width:20px;height:100%;margin:0 10px 10px 0}.fd-slider,.fd-slider-vertical{text-align:center;display:block;position:relative;cursor:pointer;text-decoration:none;border:0 none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.oldie .fd-slider,.oldie .fd-slider-vertical{*background:transparent url("blank.c4aa72cfb29d.gif") repeat}.fd-slider-wrapper{position:absolute;top:0;left:0;width:100%;height:100%}.oldie .fd-slider-vertical .fd-slider-wrapper{*clear:expression(style.height=parentNode.offsetHeight+'px',style.clear='none', 0);}.fd-slider-inner{display:none}.oldie .fd-slider-inner{position:absolute;height:2px;border:1px solid #bbf;background:#bbf;top:4px;bottom:none;left:4px;right:12px;z-index:2;margin:0;padding:0;overflow:hidden;line-height:4px;_right:auto;_width:expression((this.parentNode.offsetWidth - 8)+'px');filter:progid:DXImageTransform.Microsoft.Blur(pixelradius=3.5)}.oldie .fd-slider-vertical .fd-slider-inner{width:2px;height:auto;top:4px;bottom:12px;left:4px;right:auto;_bottom:auto;*clear:expression(style.height=(parentNode.offsetHeight - 8)+'px',style.clear='none',0)}.oldie .fd-slider-focused .fd-slider-inner{display:block}.fd-slider-bar{display:block;position:absolute;top:8px;right:10px;left:10px;z-index:2;height:2px;margin:0;padding:0;overflow:hidden;border:1px solid #bbb;border-bottom:1px solid #aaa;border-right:1px solid #aaa;border:1px solid rgba(187,187,187,.8);border-bottom:1px solid rgba(170,170,170,.8);border-right:1px solid rgba(170,170,170,.8);line-height:4px;background-color:#ddd;background-image:-webkit-gradient(linear,left top,left bottom,from(#ececec),to(#ccc));background-image:-webkit-linear-gradient(top,#ececec,#ccc);background-image:-moz-linear-gradient(top,#ececec,#ccc);background-image:-ms-linear-gradient(top,#ececec,#ccc);background-image:-o-linear-gradient(top,#ececec,#ccc);background-image:linear-gradient(to bottom,#ececec,#ccc);-webkit-border-radius:2px;-moz-border-radius:2px;border-radius:2px;-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box}.oldie .fd-slider-bar{_left:10px;_right:auto;_width:expression((this.parentNode.offsetWidth - 20)+'px');filter:progid:DXImageTransform.Microsoft.gradient(GradientType=1,startColorstr='#ffececec',endColorstr='#ffcccccc')}.fd-slider-vertical .fd-slider-bar{width:2px;top:10px;right:auto;bottom:10px;left:8px;height:auto;background-color:#ddd;background-image:-webkit-gradient(linear,left top,right top,from(#ececec),to(#ccc));background-image:-webkit-linear-gradient(left,#ececec,#ccc);background-image:-moz-linear-gradient(left,#ececec,#ccc);background-image:-ms-linear-gradient(left,#ececec,#ccc);background-image:-o-linear-gradient(left,#ececec,#ccc);background-image:linear-gradient(to right,#ececec,#ccc)}.oldie .fd-slider-vertical .fd-slider-bar{_bottom:auto;*clear:expression(style.height=(parentNode.offsetHeight - 20)+'px',style.clear='none',0);filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr='#ffececec',endColorstr='#ffcccccc')}.fd-slider-focused .fd-slider-bar{-webkit-box-shadow:0 0 6px rgba(10,130,170,0.7);-moz-box-shadow:0 0 6px rgba(10,130,170,0.7);box-shadow:0 0 6px rgba(10,130,170,0.7);-webkit-animation:fd-pulse 2s infinite;-moz-animation:fd-pulse 2s infinite;-ms-animation:fd-pulse 2s infinite;-o-animation:fd-pulse 2s infinite}.fd-slider-range{display:block;position:absolute;top:9px;left:11px;z-index:3;height:2px;margin:0;padding:0;overflow:hidden;line-height:2px;background-color:#4cc;background-image:-webkit-gradient(linear,left top,right top,from(#6cc),to(#3cf));background-image:-webkit-linear-gradient(left,#6cc,#3cf);background-image:-moz-linear-gradient(left,#6cc,#3cf);background-image:-ms-linear-gradient(left,#6cc,#3cf);background-image:-o-linear-gradient(left,#6cc,#3cf);background-image:linear-gradient(to right,#6cc,#3cf);-webkit-border-radius:2px;-moz-border-radius:2px;border-radius:2px;-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box}.oldie .fd-slider-range{_left:10px;filter:progid:DXImageTransform.Microsoft.gradient(GradientType=1,startColorstr='#ff66cccc',endColorstr='#ff33ccff')}.fd-slider-vertical .fd-slider-range{height:auto;width:2px;top:auto;right:auto;bottom:11px;left:9px;background-image:-webkit-gradient(linear,left top,left bottom,from(#3cf),to(#6cc));background-image:-webkit-linear-gradient(top,#3cf,#6cc);background-image:-moz-linear-gradient(top,#3cf,#6cc);background-image:-ms-linear-gradient(top,#3cf,#6cc);background-image:-o-linear-gradient(top,#3cf,#6cc);background-image:linear-gradient(to bottom,#3cf,#6cc)}.oldie .fd-slider-vertical .fd-slider-range{filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr='#ff66cccc',endColorstr='#ff33ccff')}.fd-slider-handle{position:absolute;display:block;padding:0;border:0 none;margin:0;z-index:3;top:0;left:0;width:20px;height:20px;outline:0 none;background-color:transparent;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAABQCAYAAAAZQFV3AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyBpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAg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S1V0HNOKoXDqbmI1fhXeOj2D+nqlUlU9xpHv99Y6u845qeyRGCcfl6pIv5NYva3u0LuqIm1cHPojqkTLhQAJGlvP1vvcnT5Bk3ipipYoVYkDzf7u0e0X+9FcLvPfuZKAVnBUn0QvIPJSFS1TqhLbjvheQsC/lgO0IWCAl6r0Q5Sq/DylSx8EaPkPS1XAU+GypapNT2PQdchS1ValUlUBZqeXoKmliZeqoEypiirhmYh5/0oB5mDk8r18c2ub3nkyUKFUtVa4MXyPp7UHml4exj6cy74/OL48fTcezmnUVKoCU6lqY/nK4Fjig0ufm4P8QSGAlQbq4dTZbuh//WtwPFQPgaCLl6p2YGYyBjev3oOpsU+xJ8Yib6UQIHAq+FCO8tZeDNsoLNFZ5W1uv+mVCwHFgobNRI0C3zO2TPWrEGBc/xZgAJyadcoLu6zuAAAAAElFTkSuQmCC);background-position:0 0;cursor:W-resize;line-height:20px;font-size:10px;-moz-outline:0 none;-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.oldie .fd-slider-handle{*background-image:url("fd-slider-sprite.f20141ce1cf3.png");_background-image:none;_filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled=true,sizingMethod=crop,src='fd-handle-normal.png');outline:expression(hideFocus='true')}.fd-slider-handle:focus{outline:0 none;border:0 none;-moz-user-focus:normal}.fd-slider-handle:focus::-moz-focus-inner{border-color:transparent}.fd-slider-focused .fd-slider-handle,.fd-slider-hover .fd-slider-handle,.fd-slider-active .fd-slider-handle{background-position:0 -20px}.oldie .fd-slider-focused .fd-slider-handle,.oldie .fd-slider-hover .fd-slider-handle,.oldie .fd-slider-active .fd-slider-handle{_filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled=true,sizingMethod=crop,src='fd-handle-glow.png')}.fd-slider-vertical .fd-slider-handle{cursor:N-resize}.fd-slider-no-value .fd-slider-handle{background-position:0 -59px}.oldie .fd-slider-no-value .fd-slider-handle{_filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled=true,sizingMethod=crop,src='fd-handle-no-value.png')}body.fd-slider-drag-horizontal,body.fd-slider-drag-horizontal *,body.fd-slider-drag-vertical,body.fd-slider-drag-vertical *{cursor:N-resize!important;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}body.fd-slider-drag-horizontal,body.fd-slider-drag-horizontal *{cursor:W-resize!important}.fd-slider-disabled{opacity:.8;cursor:default}.fd-slider-disabled .fd-slider-handle{cursor:default!important;background-position:0 -40px;opacity:1}.oldie .fd-slider-disabled .fd-slider-handle{_filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled=true,sizingMethod=crop,src='fd-handle-disabled.png')}.fd-slider-disabled .fd-slider-bar{cursor:auto!important;border:1px solid #888;border-bottom:1px solid #999;border-right:1px solid #999;border:1px solid rgba(136,136,136,.8);border-bottom:1px solid rgba(153,153,153,.8);border-right:1px solid rgba(153,153,153,.8);background-color:#555;background-image:-webkit-gradient(linear,left top,right top,from(#666),to(#333));background-image:-webkit-linear-gradient(left,#666,#333);background-image:-moz-linear-gradient(left,#666,#333);background-image:-ms-linear-gradient(left,#666,#333);background-image:-o-linear-gradient(left,#666,#333);background-image:linear-gradient(to right,#666,#333)}.fd-slider-vertical .fd-slider-disabled .fd-slider-bar{background-image:-webkit-gradient(linear,left top,right bottom,from(#333),to(#666));background-image:-webkit-linear-gradient(top,#333,#666);background-image:-moz-linear-gradient(top,#333,#666);background-image:-ms-linear-gradient(top,#333,#666);background-image:-o-linear-gradient(top,#333,#666);background-image:linear-gradient(to bottom,#333,#666)}.oldie .fd-slider-disabled .fd-slider-bar{filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr='#ff666666',endColorstr='#ff333333')}.oldie .fd-slider-vertical .fd-slider-disabled .fd-slider-bar{filter:progid:DXImageTransform.Microsoft.gradient(GradientType=1,startColorstr='#ff666666',endColorstr='#ff333333')}.fd-slider-disabled .fd-slider-range{cursor:auto!important;background-color:#222;background-image:-webkit-gradient(linear,left top,right top,from(#222),to(#000));background-image:-webkit-linear-gradient(left,#222,#000);background-image:-moz-linear-gradient(left,#222,#000);background-image:-ms-linear-gradient(left,#222,#000);background-image:-o-linear-gradient(left,#222,#000);background-image:linear-gradient(to right,#222,#000)}.oldie .fd-slider-disabled .fd-slider-range{filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr='#ff222222',endColorstr='#ff000000')}.fd-slider-vertical .fd-slider-disabled .fd-slider-range{background-image:-webkit-gradient(linear,left top,right bottom,from(#000),to(#222));background-image:-webkit-linear-gradient(top,#000,#222);background-image:-moz-linear-gradient(top,#000,#222);background-image:-ms-linear-gradient(top,#000,#222);background-image:-o-linear-gradient(top,#000,#222);background-image:linear-gradient(to bottom,#000,#222)}.oldie .fd-slider-vertical .fd-slider-disabled .fd-slider-range{filter:progid:DXImageTransform.Microsoft.gradient(GradientType=1,startColorstr='#ff222222',endColorstr='#ff000000')}@-webkit-keyframes fd-pulse{0%{box-shadow:0 0 3px rgba(100,130,170,0.55)}20%{box-shadow:0 0 4px rgba(70,130,170,0.6)}40%{box-shadow:0 0 5px rgba(40,130,170,0.65)}60%{box-shadow:0 0 6px rgba(10,130,170,0.7)}80%{box-shadow:0 0 5px rgba(40,130,170,0.65)}100%{box-shadow:0 0 4px rgba(70,130,170,0.6)}}@-moz-keyframes fd-pulse{0%{box-shadow:0 0 3px rgba(100,130,170,0.55)}20%{box-shadow:0 0 4px rgba(70,130,170,0.6)}40%{box-shadow:0 0 5px rgba(40,130,170,0.65)}60%{box-shadow:0 0 6px rgba(10,130,170,0.7)}80%{box-shadow:0 0 5px rgba(40,130,170,0.65)}100%{box-shadow:0 0 4px rgba(70,130,170,0.6)}}@-ms-keyframes fd-pulse{0%{box-shadow:0 0 3px rgba(100,130,170,0.55)}20%{box-shadow:0 0 4px rgba(70,130,170,0.6)}40%{box-shadow:0 0 5px rgba(40,130,170,0.65)}60%{box-shadow:0 0 6px rgba(10,130,170,0.7)}80%{box-shadow:0 0 5px rgba(40,130,170,0.65)}100%{box-shadow:0 0 4px rgba(70,130,170,0.6)}}@-o-keyframes fd-pulse{0%{box-shadow:0 0 3px rgba(100,130,170,0.55)}20%{box-shadow:0 0 4px rgba(70,130,170,0.6)}40%{box-shadow:0 0 5px rgba(40,130,170,0.65)}60%{box-shadow:0 0 6px rgba(10,130,170,0.7)}80%{box-shadow:0 0 5px rgba(40,130,170,0.65)}100%{box-shadow:0 0 4px rgba(70,130,170,0.6)}}
@@ -0,0 +1,66 @@
1
+ # Need to sub-class CatalogController so we get all other plugins behavior
2
+ # for our own "inside a search context" lookup of facets.
3
+ class BlacklightAdvancedSearch::AdvancedController < CatalogController
4
+ include AdvancedHelper # so we get the #advanced_search_context method
5
+
6
+ # Blacklight uses #search_action_url to figure out the right URL for
7
+ # the global search box
8
+ def search_action_url options = {}
9
+ catalog_index_url(options.except(:controller, :action))
10
+ end
11
+ helper_method :search_action_url
12
+
13
+ def index
14
+ @nav_li_active = 'search'
15
+ unless request.method==:post
16
+ @response = get_advanced_search_facets
17
+ end
18
+ end
19
+
20
+ protected
21
+ def get_advanced_search_facets
22
+
23
+ search_context_params = {}
24
+ if (advanced_search_context.length > 0 )
25
+ # We have a search context, need to fetch facets from within
26
+ # that context -- but we dont' want to search within any
27
+ # existing :q or ADVANCED facets, so we remove those params.
28
+ adv_keys = blacklight_config.search_fields.keys.map {|k| k.to_sym}
29
+ trimmed_params = params.except *adv_keys
30
+ trimmed_params.delete(:f_inclusive) # adv facets
31
+
32
+ search_context_params = solr_search_params(trimmed_params)
33
+
34
+ # Don't want to include the 'q' from basic search in our search
35
+ # context. Kind of hacky becuase solr_search_params insists on
36
+ # using controller.params, not letting us over-ride.
37
+ search_context_params.delete(:q)
38
+ search_context_params.delete("q")
39
+
40
+ # Also delete any facet-related params, or anything else
41
+ # we want to set ourselves
42
+ search_context_params.delete_if do |k, v|
43
+ k = k.to_s
44
+ (["facet.limit", "facet.sort", "f", "facets", "facet.fields", "per_page"].include?(k) ||
45
+ k =~ /f\..+\.facet\.limit/ ||
46
+ k =~ /f\..+\.facet\.sort/
47
+ )
48
+ end
49
+ end
50
+
51
+ input = HashWithIndifferentAccess.new
52
+ input.merge!( search_context_params )
53
+
54
+ input[:per_page] = 0 # force
55
+
56
+ # force if set
57
+ input[:qt] = blacklight_config.advanced_search[:qt] if blacklight_config.advanced_search[:qt]
58
+
59
+ input.merge!( blacklight_config.advanced_search[:form_solr_parameters] ) if blacklight_config.advanced_search[:form_solr_parameters]
60
+
61
+ # ensure empty query is all records, to fetch available facets on entire corpus
62
+ input[:q] ||= '{!lucene}*:*'
63
+
64
+ repository.search(input)
65
+ end
66
+ end
@@ -0,0 +1,38 @@
1
+ # -*- encoding : utf-8 -*-
2
+ class BookmarksController < CatalogController
3
+
4
+ include Blacklight::Bookmarks
5
+
6
+ # LOCAL OVERRIDE to render update.js.erb partial when bookmark created
7
+ def create
8
+ if params[:bookmarks]
9
+ @bookmarks = params[:bookmarks]
10
+ else
11
+ @bookmarks = [{ document_id: params[:id], document_type: blacklight_config.document_model.to_s }]
12
+ end
13
+
14
+ current_or_guest_user.save! unless current_or_guest_user.persisted?
15
+
16
+ success = @bookmarks.all? do |bookmark|
17
+ current_or_guest_user.bookmarks.where(bookmark).exists? || current_or_guest_user.bookmarks.create(bookmark)
18
+ end
19
+
20
+ if request.xhr?
21
+ # success ? render(json: { bookmarks: { count: current_or_guest_user.bookmarks.count }}) : render(:text => "", :status => "500")
22
+ success ? render(:update) : render(:text => "", :status => "500")
23
+ else
24
+ if @bookmarks.length > 0 && success
25
+ flash[:notice] = I18n.t('blacklight.bookmarks.add.success', :count => @bookmarks.length)
26
+ elsif @bookmarks.length > 0
27
+ flash[:error] = I18n.t('blacklight.bookmarks.add.failure', :count => @bookmarks.length)
28
+ end
29
+
30
+ redirect_to :back
31
+ end
32
+ end
33
+
34
+ def folder_item_actions
35
+ redirect_to :action => "index"
36
+ end
37
+
38
+ end
@@ -0,0 +1,128 @@
1
+ class CollectionsController < CatalogController
2
+
3
+ ##
4
+ # Give Bookmarks access to the CatalogController configuration
5
+ include Blacklight::Configurable
6
+ include Blacklight::SearchHelper
7
+
8
+ copy_blacklight_config_from(CatalogController)
9
+
10
+ # remove collection facet and collapse others
11
+ before_filter :relation_base_blacklight_config, :only => [:index, :show]
12
+ before_filter :add_series_facet, :only => :show
13
+ before_filter :collections_limit, :only => [:index, :facet]
14
+ before_filter :collapse_institution_facet, :only => :index
15
+
16
+ # Blacklight uses #search_action_url to figure out the right URL for
17
+ # the global search box
18
+ def search_action_url options = {}
19
+ catalog_index_url(options.except(:controller, :action))
20
+ end
21
+ helper_method :search_action_url
22
+
23
+ def index
24
+ @nav_li_active = 'explore'
25
+ (@response, @document_list) = search_results(params, search_params_logic)
26
+ params[:view] = 'list'
27
+ params[:sort] = 'title_info_primary_ssort asc'
28
+
29
+ respond_to do |format|
30
+ format.html
31
+ end
32
+ end
33
+
34
+ def show
35
+ @nav_li_active = 'explore'
36
+ @show_response, @document = fetch(params[:id])
37
+ @collection_title = @document[blacklight_config.index.title_field.to_sym]
38
+
39
+ # add params[:f] for proper facet links
40
+ params[:f] = set_collection_facet_params(@collection_title, @document)
41
+
42
+ # get the response for the facets representing items in collection
43
+ (@response, @document_list) = search_results({:f => params[:f]}, search_params_logic)
44
+
45
+ # get an image for the collection
46
+ if @document[:exemplary_image_ssi]
47
+ @collection_image_pid = @document[:exemplary_image_ssi]
48
+ @collection_image_info = get_collection_image_info(@collection_image_pid,
49
+ @document[:id])
50
+ end
51
+
52
+ respond_to do |format|
53
+ format.html
54
+ end
55
+
56
+ end
57
+
58
+ private
59
+
60
+ # show series facet
61
+ def add_series_facet
62
+ blacklight_config.facet_fields['related_item_series_ssim'].include_in_request = true
63
+ end
64
+
65
+ # collapse the institution facet, if Institutions supported
66
+ def collapse_institution_facet
67
+ return unless t('blacklight.home.browse.institutions.enabled')
68
+ blacklight_config.facet_fields['physical_location_ssim'].collapse = true
69
+ end
70
+
71
+ # filter out non-collection items
72
+ def collections_limit
73
+ self.search_params_logic += [:collections_filter]
74
+ end
75
+
76
+ # find the title and pid for the object representing the collection image
77
+ def get_collection_image_info(image_pid, collection_pid)
78
+ col_img_info = {title: '', pid: collection_pid, access_master: false}
79
+ col_img_file_doc = fetch(image_pid)[1]
80
+ if col_img_file_doc
81
+ col_img_info[:access_master] = true if col_img_file_doc[:is_image_of_ssim]
82
+ col_img_field = col_img_file_doc[:is_image_of_ssim].presence || col_img_file_doc[:is_file_of_ssim].presence
83
+ if col_img_field
84
+ col_img_obj_pid = col_img_field.first.gsub(/info:fedora\//,'')
85
+ col_img_obj_doc = fetch(col_img_obj_pid)[1]
86
+ if col_img_obj_doc
87
+ col_img_info[:title] = col_img_obj_doc[blacklight_config.index.title_field.to_sym]
88
+ col_img_info[:pid] = col_img_obj_pid
89
+ end
90
+ end
91
+ end
92
+ col_img_info
93
+ end
94
+
95
+ # find a representative image for a series
96
+ # TODO better exception handling for items which don't have exemplary_image
97
+ def get_series_image_obj(series_title,collection_title)
98
+ self.search_params_logic += [:flagged_filter] unless self.search_params_logic.include?(:flagged_filter)
99
+ series_doc_list = search_results(
100
+ {:f => {'related_item_series_ssim' => series_title,
101
+ blacklight_config.collection_field => collection_title},
102
+ :rows => 1},
103
+ search_params_logic)[1]
104
+ series_doc_list.first
105
+ end
106
+ helper_method :get_series_image_obj
107
+
108
+ # set the correct facet params for facets from the collection
109
+ def set_collection_facet_params(collection_title, document)
110
+ facet_params = {blacklight_config.collection_field => [collection_title]}
111
+ facet_params[blacklight_config.institution_field] = document[blacklight_config.institution_field.to_sym] if t('blacklight.home.browse.institutions.enabled')
112
+ facet_params
113
+ end
114
+
115
+ # Not using this for now
116
+ # find a representative image for a collection if none is assigned
117
+ # TODO better exception handling for items which don't have exemplary_image
118
+ #def get_collection_image_pid(collection_title)
119
+ # (@default_coll_img_resp, @default_coll_img_doc_list) = search_results(
120
+ # {:f => {blacklight_config.collection_field => collection_title,
121
+ # 'has_model_ssim' => 'info:fedora/afmodel:Bplmodels_ObjectBase'},
122
+ # :rows => 1
123
+ # })
124
+ # @default_coll_img_doc_list.first[:exemplary_image_ssi]
125
+ #end
126
+ #helper_method :get_collection_image_pid
127
+
128
+ end
@@ -0,0 +1,8 @@
1
+ module CommonwealthVlrEngine
2
+ class ApplicationController < ActionController::Base
3
+ helper Openseadragon::OpenseadragonHelper
4
+
5
+ layout 'commonwealth-vlr-engine'
6
+
7
+ end
8
+ end
@@ -0,0 +1,39 @@
1
+ # -*- encoding : utf-8 -*-
2
+ class FeedbackController < ApplicationController
3
+
4
+ # http://expressica.com/simple_captcha/
5
+ # include SimpleCaptcha::ControllerHelpers
6
+
7
+ # show the feedback form
8
+ def show
9
+ @nav_li_active = 'contact'
10
+ @errors=[]
11
+ if request.post?
12
+ if validate
13
+ Notifier.feedback(params).deliver_now
14
+ redirect_to feedback_complete_path
15
+ end
16
+ end
17
+ end
18
+
19
+ protected
20
+
21
+ # validates the incoming params
22
+ # returns either an empty array or an array with error messages
23
+ def validate
24
+ unless params[:name] =~ /\w+/
25
+ @errors << t('blacklight.feedback.valid_name')
26
+ end
27
+ unless params[:email] =~ /\A[\w+\-.]+@[a-z\d\-.]+\.[a-z]+\z/i
28
+ @errors << t('blacklight.feedback.valid_email')
29
+ end
30
+ unless params[:message] =~ /\w+/
31
+ @errors << t('blacklight.feedback.need_message')
32
+ end
33
+ #unless simple_captcha_valid?
34
+ # @errors << 'Captcha did not match'
35
+ #end
36
+ @errors.empty?
37
+ end
38
+
39
+ end
@@ -0,0 +1,72 @@
1
+ # use to share folder item actions (email, cite, delete) between folders and bookmarks
2
+ class FolderItemsActionsController < ApplicationController
3
+
4
+ def folder_item_actions
5
+ @folder = Bpluser::Folder.find(params[:id]) if params[:origin] == "folders"
6
+ @user = current_or_guest_user
7
+ if params[:selected]
8
+ sort = params[:sort] ? params[:sort] : ""
9
+ per_page = params[:per_page] ? params[:per_page] : ""
10
+ view = params[:view] ? params[:view] : ""
11
+ items = params[:selected]
12
+
13
+ case params[:commit]
14
+ # email
15
+ when t('blacklight.tools.email')
16
+ redirect_to email_catalog_path(:id => items)
17
+ # cite
18
+ when t('blacklight.tools.citation')
19
+ redirect_to citation_catalog_path(:id => items)
20
+ # remove
21
+ when t('blacklight.tools.remove')
22
+ if params[:origin] == "folders"
23
+ if @folder.folder_items.where(:document_id => items).delete_all
24
+ flash[:notice] = I18n.t('blacklight.folders.update_items.remove.success')
25
+ else
26
+ flash[:error] = I18n.t('blacklight.folders.update_items.remove.failure')
27
+ end
28
+ redirect_to folder_path(:id => @folder,
29
+ :sort => sort,
30
+ :per_page => per_page,
31
+ :view => view)
32
+ else
33
+ if current_or_guest_user.bookmarks.where(:document_id => items).delete_all
34
+ flash[:notice] = I18n.t('blacklight.folders.update_items.remove.success')
35
+ else
36
+ flash[:error] = I18n.t('blacklight.folders.update_items.remove.failure')
37
+ end
38
+ redirect_to bookmarks_path(:sort => sort,
39
+ :per_page => per_page,
40
+ :view => view)
41
+ end
42
+ # copy
43
+ when /#{t('blacklight.tools.copy_to')}/
44
+ destination = params[:commit].split(t('blacklight.tools.copy_to') + ' ')[1]
45
+ if destination == t('blacklight.bookmarks.title')
46
+ success = items.all? do |item_id|
47
+ current_or_guest_user.bookmarks.create(:document_id => item_id) unless current_or_guest_user.bookmarks.where(:document_id => item_id).exists?
48
+ end
49
+ else
50
+ folder_to_update = current_user.folders.find(destination)
51
+ success = items.all? do |item_id|
52
+ folder_to_update.folder_items.create!(:document_id => item_id) and folder_to_update.touch unless folder_to_update.has_folder_item(item_id)
53
+ end
54
+ end
55
+ redirect_to :back
56
+ if success
57
+ folder_display_name = destination == t('blacklight.bookmarks.title') ? t('blacklight.bookmarks.title') : folder_to_update.title
58
+ flash[:notice] = t('blacklight.folders.update_items.copy.success',
59
+ :folder_name => folder_display_name)
60
+ else
61
+ flash[:error] = t('blacklight.folders.update_items.copy.failure')
62
+ end
63
+ end
64
+
65
+ else
66
+ redirect_to :back
67
+ flash[:error] = I18n.t('blacklight.folders.update_items.remove.no_items')
68
+ end
69
+
70
+ end
71
+
72
+ end