add ability to change recording visibility

This commit is contained in:
Josh
2018-06-18 14:25:30 -04:00
parent b2b2c641da
commit 5d5cfd1b7d
5 changed files with 58 additions and 11 deletions

View File

@ -0,0 +1,42 @@
<tr>
<td>
<div><%= recording[:name] %></div>
<div class="small text-muted">
Recorded on <%= recording_date(recording[:startTime]) %>
</div>
</td>
<td>
<% p = recording[:playbacks].find do |p| p[:type] == "presentation" end %>
<% if p %>
<% p[:preview][:images][:image].each do |img| %>
<%= image_tag(img[:content].strip, class: "thumbnail px-2") %>
<% end %>
<% end %>
</td>
<td class="text-left">
<div class="small text-muted text-uppercase">
Length
</div>
<%= recording_length(recording[:startTime], recording[:endTime]) %>
</td>
<td class="text-left">
<div class="small text-muted text-uppercase">
Users
</div>
<%= recording[:participants] %>
</td>
<td class="text-left">
<div class="dropdown">
<% if recording[:metadata][:"gl-listed"] == "true" %>
<i class="dropdown-icon fe fe-globe px-2"></i> Public
<% else %>
<i class="dropdown-icon fe fe-link px-2"></i> Unlisted
<% end %>
</div>
</td>
<td>
<% recording[:playbacks].each do |p| %>
<%= link_to p[:type].capitalize, p[:url], class: "btn btn-sm btn-primary", target: "_blank" %>
<% end %>
</td>
</tr>

View File

@ -9,7 +9,7 @@
<% p = recording[:playbacks].find do |p| p[:type] == "presentation" end %>
<% if p %>
<% p[:preview][:images][:image].each do |img| %>
<%= image_tag(img[:content], class: "thumbnail px-2") %>
<%= image_tag(img[:content].strip, class: "thumbnail px-2") %>
<% end %>
<% end %>
</td>
@ -27,7 +27,7 @@
</td>
<td class="text-left">
<div class="dropdown">
<% if recording[:metadata]["gl-listed"] %>
<% if recording[:metadata][:"gl-listed"] == "true" %>
<button class="btn btn-sm btn-secondary dropdown-toggle" data-toggle="dropdown"><i class="dropdown-icon fe fe-globe px-2"></i> Public</button>
<% else %>
<button class="btn btn-sm btn-secondary dropdown-toggle" data-toggle="dropdown"><i class="dropdown-icon fe fe-link px-2"></i> Unlisted</button>