Skip to content

Commit

Permalink
disable Related Accessions checkbox and give a message if unsupported…
Browse files Browse the repository at this point in the history
… in this AS instance
  • Loading branch information
jambun committed Jun 27, 2023
1 parent 9dc8070 commit 8b772e7
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,18 @@
].each do |value, label_key|
%>
<tr>
<% no_acc_link = value == 'update_select_related_accession' && !JSONModel(:archival_object).schema.dig('properties', 'accession_links') %>

<td class="checkbox-cell">
<input id="<%= value %>" name="<%= value %>" type="checkbox" checked="checked">
<input id="<%= value %>" name="<%= value %>" type="checkbox" <%= no_acc_link ? 'disabled="disabled"' : 'checked="checked"' %>>
</td>
<td class="label-cell">
<label for="<%= value %>"><%= I18n.t(label_key) %></label>

<% if no_acc_link %>
(Requires ArchivesSpace version 3.3.0 or greater, or this <a href="https://github.com/hudmol/as_accession_links">plugin</a>)
<% end %>

</td>
</tr>
<% end %>
Expand Down

0 comments on commit 8b772e7

Please sign in to comment.