-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The low-hanging fruit: MISSING_C14_AGE, VERY_OLD_C14, MISSING_C14_ERROR, MISSING_D13C, MISSING_D13C_ERROR, MISSING_C14_METHOD, MISSING_C14_LAB_ID, and MISSING_C14_LAB
- Loading branch information
Showing
9 changed files
with
188 additions
and
27 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
class Issues::C14sController < IssuesController | ||
load_and_authorize_resource | ||
|
||
# GET /issues/c14s/:issue | ||
def index | ||
if params[:issue].present? | ||
@c14s = C14.send(params[:issue]) | ||
else | ||
@c14s = C14.all | ||
end | ||
|
||
if params.has_key?(:c14s_order_by) | ||
order = { params[:c14s_order_by] => params.fetch(:c14s_order, "asc") } | ||
else | ||
order = :id | ||
end | ||
@c14s = @c14s.reorder(order) | ||
|
||
respond_to do |format| | ||
format.html { @pagy, @c14s = pagy(@c14s) } | ||
end | ||
end | ||
|
||
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
<table class="table table-hover"> | ||
<thead> | ||
<tr> | ||
<th scope="col"> | ||
<%= link_to_order_by "ID", :id %> | ||
<% if ordered_by?(:id) %> | ||
<span class="text-muted"><%= order_indicator %></span> | ||
<% end %> | ||
</th> | ||
<th scope="col"> | ||
<%= link_to_order_by "Lab ID", :lab_identifier %> | ||
<% if ordered_by?(:lab_identifier) %> | ||
<span class="text-muted"><%= order_indicator %></span> | ||
<% end %> | ||
</th> | ||
<th scope="col"> | ||
<%= link_to_order_by "C14 Lab", :c14_lab_id %> | ||
<% if ordered_by?(:c14_lab_id) %> | ||
<span class="text-muted"><%= order_indicator %></span> | ||
<% end %> | ||
</th> | ||
<th scope="col">Method</th> | ||
<th scope="col">Age</th> | ||
<th scope="col">Error</th> | ||
<th scope="col">δ13C</th> | ||
<th scope="col">δ13C error</th> | ||
<th scope="col">Issues</th> | ||
</tr> | ||
</thead> | ||
|
||
<tbody> | ||
<% c14s.each do |c14| %> | ||
<tr> | ||
<td class="text-muted"><%= link_to c14.id, c14 %></td> | ||
<td><%= c14.lab_identifier %></td> | ||
<td><%= c14.c14_lab_id %></td> | ||
<td><%= c14.method %></td> | ||
<td><%= c14.bp %></td> | ||
<td><%= c14.std %></td> | ||
<td><%= c14.delta_c13 %></td> | ||
<td><%= c14.delta_c13_std %></td> | ||
<td><% c14.issues.each do |issue| %> | ||
<%= issue_badge(issue) %> | ||
<% end %></td> | ||
</tr> | ||
|
||
</tr> | ||
<% end %> | ||
</tbody> | ||
</table> |
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,12 @@ | ||
<% content_for :title, "Issues – Radiocarbon dates" %> | ||
<% content_for :help do %> | ||
<% end %> | ||
|
||
<h2 class="border-bottom">Radiocarbon dates</h2> | ||
|
||
<%= render "issues/nav", model: C14, base_path: issues_c14s_path %> | ||
|
||
<turbo-frame id="issues-c14s-table"> | ||
<%= render "table", c14s: @c14s %> | ||
<%== pagy_bootstrap_nav(@pagy) %> | ||
</turbo-frame> |
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