Allow recordings to be 'unlisted'

Unlisted is a state between published and unpublished. They are still
published in the server, but will not appear to anyone other than the
user that created the recording.
It is done using a metadata attribute and required several changes in how
the application handles publishing and unpublishing.
This commit is contained in:
Leonardo Crauss Daronco
2016-12-06 12:03:53 -02:00
parent 40cbc8a575
commit b518458622
12 changed files with 111 additions and 53 deletions

View File

@ -24,6 +24,7 @@ json.recordings do
json.end_time recording[:endTime]
json.published recording[:published]
json.length recording[:length]
json.listed recording[:listed]
json.previews do
json.array!(recording[:previews]) do |preview|
json.partial! 'preview', preview: preview

View File

@ -50,6 +50,17 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
<%= t('no') %>
</button>
</div>
<div class="recording-visibility-popover">
<button type="button" class="btn btn-default btn-danger recording-update" data-visibility="inaccessible">
<%= t('innaccessible') %>
</button>
<button type="button" class="btn btn-default btn-warning recording-update" data-visibility="unlisted">
<%= t('unlisted') %>
</button>
<button type="button" class="btn btn-default btn-success recording-update" data-visibility="published">
<%= t('published') %>
</button>
</div>
<div class="alert-template">
<div class="alert alert-success alert-dismissible fade in" role="alert">
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
@ -59,12 +70,14 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
</div>
</div>
<div class="recording-actions">
<button type="button" class="btn btn-default recording-update bottom-tooltip" data-published="">
<i class="fa default" aria-hidden="true"></i>
<i class="fa hover" aria-hidden="true"></i>
<button type="button" class="btn btn-default has-popover recording-update-trigger"
data-placement="left" data-popover-body=".recording-visibility-popover"
data-popover-title="<%= t('change_recording_visibility') %>">
<i class="fa fa-eye" aria-hidden="true"></i>
</button>
<a tabindex="0" role="button" class="btn btn-default has-popover delete-tooltip"
data-placement="top">
data-placement="top" data-popover-body=".delete-popover-body"
data-popover-title="<%= t('are_you_sure') %>">
<i class="fa fa-trash-o" aria-hidden="true"></i>
</a>
</div>