debshots/app/views/admin/logs.slim
2018-08-09 18:24:28 +02:00

27 lines
692 B
Text

// Paginator and search bar
.grid-x
.small-6.medium-8.large-9.cell
// Paginator
= render 'admin/logs/paginator'
.small-6.medium-4.large-3.cell
// Search form
= form_tag url_for, :method=>'GET'
= text_field_tag(:search, params[:search], placeholder: "Search...", maxlength: 50, size: 20, autofocus: true)
// List of log messages
.grid-x
- if @logs.length>0
table
tr
th Timestamp
th Message
- @logs.each do |log|
tr
td =log.created_at
td =log.message
- else
p No logs found. Crazy.
// Second paginator at the bottom so the user does not have to scroll up again
= render 'admin/logs/paginator'