<% if @job.present? %>
See job #<%= @job.id %> execution progress at: <%= link_to job_url(@job), job_path(@job), target: :_blank %>
You need multi-threaded server to do that!
(Easiest workaraund: Include <%= link_to 'unicorn-rails', 'https://github.com/samuelkadolph/unicorn-rails', target: :_blank %> in your application)
<% end %>
- <%= t('.name') %>
- <%= @device.name %>
- <%= t('.parent') %>
- <%= @device.extfaceable.composite_id %>
- <%= t('.driver') %>
- <%= @device.driver_name %>
- <%= t('.created') %>
- <%= distance_of_time_in_words_to_now @device.created_at %> ago
- <%= t('.successful_jobs') %>
-
<%= @device.jobs.completed.count %>
<% if @device.jobs.completed.any? %>
(<%= t('.last') %>: <%= distance_of_time_in_words_to_now @device.jobs.maximum(:completed_at) %> ago)
<% end %>
- <%= t('.failures') %>
-
<%= @device.jobs.failed.count %>
<% if @device.jobs.failed.any? %>
(<%= t('.last') %>: <%= distance_of_time_in_words_to_now @device.jobs.maximum(:failed_at) %> ago)
<% end %>
- <%= t('.client_pull_url') %>
<%= extface.pull_url(@device.uuid) %>
<% if @device.print? %>
<%= button_to 'Print Test Page', test_page_device_path(@device), remote: true, name: :test_page, value: true, class: 'btn btn-warning' %>
<% end %>
Simulate push data from device
<%= link_to 'Push', extface.push_url(@device.uuid), id: :push, class: 'btn btn-warning'%>
Jobs
Id |
Created |
Description |
Error |
Failed |
Completed |
Connected |
<% @device.jobs.last(10).reverse.each do |job|%>
<%= job.id %> |
<%= job.created_at %> |
<%= job.description %> |
<%= job.error %> |
<%= job.failed_at %> |
<%= job.completed_at %> |
<%= job.connected_at %> |
<% end %>