Merge pull request #8375 from andrej-scinote/aj_SCI_11735

Add form item to export form and print protocol [SCI-11735][SCI-11688]
This commit is contained in:
andrej-scinote 2025-03-31 09:42:52 +02:00 committed by GitHub
commit 2e5ed1bcb2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 1 deletions

View file

@ -26,7 +26,7 @@ class FormRepositoryRowsFieldValue < FormFieldValue
end
def formatted
value&.map { |i| "#{i['name']} (IT#{i['id']})" }&.join(' | ')
value&.map { |i| "#{i['name']} (#{RepositoryRow::ID_PREFIX}#{i['id']})" }&.join(' | ')
end
private

View file

@ -75,6 +75,8 @@
<% when 'ActionField' %>
<%= render partial: 'protocols/print/element/checkbox_button', locals: { value: field_value&.flag, description: I18n.t('forms.fields.mark_as_completed') } %>
<% when 'RepositoryRowsField'%>
<%= field_value&.formatted %>
<% end %>
<div class="flex items-center justify-end mt-4 gap-4">