diff --git a/app/views/fm_archives/index.html.erb b/app/views/fm_archives/index.html.erb index 4e7b28c14b..ab6b2d3f40 100644 --- a/app/views/fm_archives/index.html.erb +++ b/app/views/fm_archives/index.html.erb @@ -30,6 +30,7 @@ FM ID Name + Key @@ -39,6 +40,7 @@ <%= link_to record.fm_id, fm_archive_path(record.fm_id, table: @selected), class: "text-primary hover:underline" %> <%= truncate(record.name, length: 100) %> + <%= record.fm_key_name %> <% end %> diff --git a/spec/requests/fm_archives_spec.rb b/spec/requests/fm_archives_spec.rb index 441ac14cd4..106595623a 100644 --- a/spec/requests/fm_archives_spec.rb +++ b/spec/requests/fm_archives_spec.rb @@ -384,6 +384,14 @@ expect(response.body).to include("Archie Coded") end + it "lists each record's key to the right of its name" do + FmRolodex.create!(fm_id: "ROL1", data: { "FirstName" => "Archie", "LastName" => "Coded" }) + + get fm_archives_path(table: "rolodexes") + + expect(response.body).to match(%r{>ROL1\s*\s*]*>Archie Coded\s*]*>ID}) + end + it "marks the selected table as the current page" do get fm_archives_path(table: "rolodexes")