Reloacate external_id for linked inventories [SCI-9849] (#6803)

This commit is contained in:
wandji 2023-12-13 15:13:15 +01:00 committed by GitHub
parent 795aba7c02
commit 03e1efe98e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 10 deletions

View file

@ -236,13 +236,13 @@ module RepositoryDatatableHelper
def linked_repository_default_columns(record)
{
'1': assigned_row(record),
'2': escape_input(record.external_id),
'3': record.code,
'4': escape_input(record.name),
'5': I18n.l(record.created_at, format: :full),
'6': escape_input(record.created_by.full_name),
'7': (record.archived_on ? I18n.l(record.archived_on, format: :full) : ''),
'8': escape_input(record.archived_by&.full_name)
'2': record.code,
'3': escape_input(record.name),
'4': I18n.l(record.created_at, format: :full),
'5': escape_input(record.created_by.full_name),
'6': (record.archived_on ? I18n.l(record.archived_on, format: :full) : ''),
'7': escape_input(record.archived_by&.full_name),
'8': escape_input(record.external_id)
}
end

View file

@ -35,15 +35,15 @@
</div>
</th>
<th id="assigned" data-unmanageable="true"><%= t("repositories.table.assigned") %></th>
<% if @repository.is_a?(LinkedRepository) %>
<th id="row-external-id"><%= t('repositories.table.external_id') %></th>
<% end %>
<th id="row-id"><%= t("repositories.table.id") %></th>
<th id="row-name"><%= t("repositories.table.row_name") %></th>
<th id="added-on" ><%= t("repositories.table.added_on") %></th>
<th id="added-by" ><%= t("repositories.table.added_by") %></th>
<th id="archived-on"><%= t("repositories.table.archived_on") %></th>
<th id="archived-by"><%= t("repositories.table.archived_by") %></th>
<% if @repository.is_a?(LinkedRepository) %>
<th id="row-external-id"><%= t('repositories.table.external_id') %></th>
<% end %>
<% repository.repository_columns.order(:id).each do |column| %>
<th
class="repository-column <%= 'row-stock item-stock' if column.data_type == 'RepositoryStockValue' %>"