diff --git a/app/views/admin/auctions/show.html.erb b/app/views/admin/auctions/show.html.erb index 19c0d3365..8cabe2a2a 100644 --- a/app/views/admin/auctions/show.html.erb +++ b/app/views/admin/auctions/show.html.erb @@ -1,6 +1,6 @@ <% content_for :title, "#{t('.title')}: #{@auction.domain_name}" %> -
+
<%= component 'common/table', header_collection: [], options: { class: 'js-table-dt dataTable no-footer' } do %> <%= tag.tbody id: "auctions-table-body", class: 'contents' do %> @@ -13,14 +13,14 @@ <%= t('auctions.starts_at') %> <%= tag.td do %> - <%= auction.starts_at %> - <% end @auction.starts_at.present? %> + <%= @auction.starts_at %> + <% end if @auction.starts_at.present? %> <%= t('auctions.ends_at') %> <%= tag.td do %> - <%= auction.ends_at %> - <% end @auction.ends_at.present? %> + <%= @auction.ends_at %> + <% end if @auction.ends_at.present? %> <%- if @auction.offer_from_user(current_user).present? %> @@ -45,13 +45,15 @@ <%= component 'common/table', header_collection:, options: { class: 'js-table-dt' } do %> <%= tag.tbody id: "auctions-table-body", class: 'contents' do %> <%- if @offers.present? %> - - <%= t('offers.price_in_currency', price: offer.price) %> - <%= offer.user&.display_name || t(:deleted_user) %> - <%= I18n.l(offer.created_at) %> - <%= I18n.l(offer.updated_at) %> - <%= link_to t(:versions_name), admin_offer_versions_path(offer), class: "ui button primary" %> - + <% @offers.each do |offer| %> + + <%= t('offers.price_in_currency', price: offer.price) %> + <%= offer.user&.display_name || t(:deleted_user) %> + <%= I18n.l(offer.created_at) %> + <%= I18n.l(offer.updated_at) %> + <%= link_to t(:versions_name), admin_offer_versions_path(offer), class: "ui button primary" %> + + <% end %> <%- else %> <%= t(:no_offers) %> diff --git a/config/routes.rb b/config/routes.rb index b202d82f0..12b250650 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -44,7 +44,7 @@ end namespace :admin, constraints: Constraints::Administrator.new do - resources :auctions, concerns: %i[auditable], except: [:show] do + resources :auctions, concerns: %i[auditable] do collection do post 'bulk_starts_at', to: 'auctions#bulk_starts_at', as: 'bulk_starts_at' post 'apply_auction_participants', to: 'auctions#apply_auction_participants', as: 'apply_auction_participants'