-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #510 from geoblacklight/modify-routes
Modify routes to use exportable, and use rails rendering engine
- Loading branch information
Showing
12 changed files
with
59 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<b><%= t('geoblacklight.relations.ancestor') %></b> | ||
<% @relations.ancestors['docs'].each do |ancestor| %> | ||
<li> | ||
<%= link_to solr_document_path(ancestor['layer_slug_s']) do %> | ||
<span class='geoblacklight geoblacklight-relations-ancestor'></span> <%= ancestor['dc_title_s'] %> | ||
<% end %> | ||
</li> | ||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<b><%= t('geoblacklight.relations.descendant', count: @relations.descendants['numFound']) %></b> | ||
<% @relations.descendants['docs'][0..2].each do |descendant| %> | ||
<li> | ||
<%= link_to solr_document_path(descendant['layer_slug_s']) do %> | ||
<span class='geoblacklight geoblacklight-relations-descendant'></span> <%= descendant['dc_title_s'] %> | ||
<% end %> | ||
</li> | ||
<% end %> | ||
<% unless (@relations.descendants['numFound'].to_i <= 3) %> | ||
<li> | ||
<%= link_to search_catalog_path({f: {"#{Settings.FIELDS.SOURCE}" => [@relations.search_id]}}) do %> | ||
<%= t('geoblacklight.relations.browse_all', count: @relations.descendants['numFound']) %> | ||
<% end %> | ||
</li> | ||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<% unless @relations.empty? %> | ||
<div class="panel panel-default show-tools"> | ||
<div class="panel-heading"> | ||
<%= t('geoblacklight.relations.title') %> | ||
</div> | ||
<div class="panel-body"> | ||
<ul class="nav"> | ||
<%= render 'ancestors' unless @relations.ancestors['numFound'].to_i == 0 %> | ||
<%= render 'descendants' unless @relations.descendants['numFound'].to_i == 0 %> | ||
</ul> | ||
</div> | ||
</div> | ||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
json.ancestors@relations.ancestors | ||
json.descendants @relations.descendants | ||
json.current_doc @relations.search_id |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters