1 <div class="container">
4 <% if current_obj.uuid.nil? %>
5 No <%= current_obj.title %> has been submitted yet.
8 <% keys = [:uuid, :modified_by_user_uuid, :created_at, :started_at, :finished_at, :container_uuid, :priority] %>
9 <% keys << :outputs if @object.uuid == current_obj.uuid %>
10 <% keys.each do |k| %>
11 <% val = current_obj.send(k) if current_obj.respond_to?(k) %>
13 <% has_val = val.andand.any? if k == :outputs %>
16 <td style="padding-right: 1em">
21 <%= link_to_arvados_object_if_readable(val, val, link_text: val) %>
22 <% elsif k.to_s.end_with? 'uuid' %>
23 <%= link_to_arvados_object_if_readable(val, val, friendly_name: true) %>
24 <% elsif k.to_s.end_with? '_at' %>
25 <%= render_localized_date(val) %>
26 <% elsif k == :outputs and val.any? %>
27 <% if val.size == 1 %>
28 <%= link_to_arvados_object_if_readable(val[0], 'Output data not available', friendly_name: true) %>
30 <%= render partial: 'work_units/show_outputs', locals: {id: current_obj.uuid, outputs: val, align:""} %>
42 <div class="col-md-6">
44 <% # link to repo tree/file only if the repo is readable and the commit is a sha1
45 repo = (/^[0-9a-f]{40}$/ =~ current_obj.script_version and
46 object_for_dataclass(Repository, current_obj.repository, :by_name))
47 repo = nil unless repo.andand.http_fetch_url
49 <% [:script, :repository, :script_version, :supplied_script_version, :nondeterministic,
50 :command, :cwd, :environment, :mounts, :output_path].each do |k| %>
51 <% val = current_obj.send(k) if current_obj.respond_to?(k) %>
54 <td style="padding-right: 1em">
58 <% if repo and k == :repository %>
59 <%= link_to val, show_repository_tree_path(id: repo.uuid, commit: current_obj.script_version, path: '/') %>
60 <% elsif repo and k == :script %>
61 <%= link_to val, show_repository_blob_path(id: repo.uuid, commit: current_obj.script_version, path: 'crunch_scripts/'+current_obj.script) %>
62 <% elsif repo and k == :script_version %>
63 <%= link_to val, show_repository_commit_path(id: repo.uuid, commit: current_obj.script_version) %>
71 <% if current_obj.runtime_constraints.andand[:docker_image] and current_obj.docker_image %>
73 <td style="padding-right: 1em">
77 <%= current_obj.runtime_constraints[:docker_image] %>
81 <td style="padding-right: 1em">
85 <%= link_to_arvados_object_if_readable(current_obj.docker_image,
86 current_obj.docker_image, friendly_name: true) %>
89 <% elsif current_obj.docker_image %>
91 <td style="padding-right: 1em">
95 <%= link_to_arvados_object_if_readable(current_obj.docker_image,
96 current_obj.docker_image, friendly_name: true) %>
104 <% if current_obj.parameters and !current_obj.parameters.empty? %>
106 <div class="col-md-6">
107 <p>script_parameters:</p>
108 <pre><%= JSON.pretty_generate(current_obj.parameters) rescue nil %></pre>