Skip to content
This repository has been archived by the owner on Sep 5, 2024. It is now read-only.

Commit

Permalink
add back the index to message list
Browse files Browse the repository at this point in the history
  • Loading branch information
wuminzhe committed Apr 10, 2024
1 parent 9f71a5f commit 437dffd
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
10 changes: 7 additions & 3 deletions app/views/messages/_message.html.erb
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
<tr id="message_<%= message.identifier %>" class="bg-white border-b dark:bg-gray-800 dark:border-gray-700">
<td class="whitespace-nowrap px-6 py-4 mono"><%= link_to short(message.msg_hash), message_by_tx_or_hash_path(message.msg_hash), class: 'underline' %></td>
<td class="whitespace-nowrap px-6 py-4 mono">
<%= link_to short(message.msg_hash), message_by_tx_or_hash_path(message.msg_hash), class: 'underline' %>
<%= link_to "##{message.index}", message_by_tx_or_hash_path(message.msg_hash), class: 'underline' %>
</td>
<td class="whitespace-nowrap px-6 py-4">
<%= link_to message.from_network.name, network_messages_path(message.from_network.name), class: 'underline' %> > <%= link_to message.to_network.name, network_messages_path('_', message.to_network.name), class: 'underline' %>
</td>
<td class="whitespace-nowrap px-6 py-4">
<div class="<%= status_style(message.status) %>" style="width: fit-content">
<%= link_to message.status_label, "#{request.path}?status=#{message.status}" %>
</div>
</td>
<td class="whitespace-nowrap px-6 py-4">
<%= link_to message.from_network.name, network_messages_path(message.from_network.name), class: 'underline' %> > <%= link_to message.to_network.name, network_messages_path('_', message.to_network.name), class: 'underline' %>
<td class="whitespace-nowrap px-6 py-4 text-left mono"><%= address_link_short(message.from_network, message.from) %></td>
<td class="whitespace-nowrap px-6 py-4 text-left mono"><%= address_link_short(message.to_network, message.to) %></td>
<td class="whitespace-nowrap px-6 py-4 text-left"><%= time_ago_in_words(message.block_timestamp) %> ago</td>
Expand Down
4 changes: 2 additions & 2 deletions app/views/messages/index.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
<table class="w-full text-left rtl:text-right text-gray-500 dark:text-gray-400">
<thead class="text-sm text-gray-700 uppercase dark:text-gray-400">
<tr>
<th scope="col" class="px-6 py-3">Hash</th>
<th scope="col" class="px-6 py-3">Status</th>
<th scope="col" class="px-6 py-3">Hash & Index</th>
<th scope="col" class="px-6 py-3">Direction</th>
<th scope="col" class="px-6 py-3">Status</th>
<th scope="col" class="px-6 py-3 text-left">From</th>
<th scope="col" class="px-6 py-3 text-left">To</th>
<th scope="col" class="px-6 py-3 text-left">Age</th>
Expand Down

0 comments on commit 437dffd

Please sign in to comment.