2018-08-01 09:45:12 -04:00
|
|
|
<%
|
|
|
|
# BigBlueButton open source conferencing system - http://www.bigbluebutton.org/.
|
|
|
|
# Copyright (c) 2018 BigBlueButton Inc. and by respective authors (see below).
|
|
|
|
# This program is free software; you can redistribute it and/or modify it under the
|
|
|
|
# terms of the GNU Lesser General Public License as published by the Free Software
|
|
|
|
# Foundation; either version 3.0 of the License, or (at your option) any later
|
|
|
|
# version.
|
|
|
|
#
|
|
|
|
# BigBlueButton is distributed in the hope that it will be useful, but WITHOUT ANY
|
|
|
|
# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
|
|
|
# PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
|
|
|
|
# You should have received a copy of the GNU Lesser General Public License along
|
|
|
|
# with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
|
|
|
|
%>
|
|
|
|
|
2018-05-31 16:54:48 -04:00
|
|
|
<div class="header py-4">
|
2018-05-24 16:59:20 -04:00
|
|
|
<div class="container">
|
|
|
|
<div class="d-flex">
|
2018-07-11 15:33:35 -04:00
|
|
|
<%= link_to (current_user ? current_user.main_room : root_path), class: "header-brand" do %>
|
2019-02-04 10:19:11 -05:00
|
|
|
<%= image_tag(Rails.configuration.branding_image,class: "header-brand-img") %>
|
2018-05-29 15:28:29 -04:00
|
|
|
<% end %>
|
2018-07-04 15:22:59 -04:00
|
|
|
|
2018-05-31 22:15:18 -04:00
|
|
|
<div class="d-flex ml-auto">
|
2018-05-24 16:59:20 -04:00
|
|
|
<% if current_user %>
|
2019-02-06 11:08:19 -05:00
|
|
|
<a id="create-room" class="px-5 ml-2 mt-1" href="" data-toggle="modal" data-target="#createRoomModal">
|
2018-07-17 11:57:49 -04:00
|
|
|
<i class="fas fa-plus"></i> <%= t("header.create_room") %>
|
2018-05-28 18:10:20 -04:00
|
|
|
</a>
|
2018-05-24 16:59:20 -04:00
|
|
|
<div class="dropdown">
|
2018-05-31 22:15:18 -04:00
|
|
|
<a href="#" class="nav-link pr-0" data-toggle="dropdown">
|
2018-06-12 17:28:02 -04:00
|
|
|
<% if current_user.image.blank? %>
|
2018-05-25 11:55:48 -04:00
|
|
|
<span class="avatar"><%= current_user.name.first %></span>
|
|
|
|
<% else %>
|
|
|
|
<span class="avatar" style="background-image: url(<%= current_user.image %>)"></span>
|
|
|
|
<% end %>
|
2018-05-24 16:59:20 -04:00
|
|
|
<span class="ml-2 d-none d-lg-block">
|
2018-06-12 14:36:35 -04:00
|
|
|
<span class="text-default username"><%= current_user.name %></span>
|
2018-05-24 16:59:20 -04:00
|
|
|
</span>
|
|
|
|
</a>
|
2018-06-13 15:51:10 -04:00
|
|
|
<div class="dropdown-menu dropdown-menu-right dropdown-menu-arrow" x-placement="bottom-end">
|
2018-05-31 22:15:18 -04:00
|
|
|
<%= link_to current_user.main_room, class: "dropdown-item" do %>
|
2018-07-17 11:57:49 -04:00
|
|
|
<i class="dropdown-icon fas fa-home"></i> <%= t("header.dropdown.home") %>
|
2018-05-31 22:15:18 -04:00
|
|
|
<% end %>
|
2019-02-04 11:21:42 -05:00
|
|
|
<%= link_to get_user_recordings_path(current_user), class: "dropdown-item" do %>
|
|
|
|
<i class="dropdown-icon fas fa-video"></i> <%= t("room.recordings") %>
|
|
|
|
<% end %>
|
2018-06-04 15:58:59 -04:00
|
|
|
<%= link_to edit_user_path(current_user), class: "dropdown-item" do %>
|
2018-07-17 11:57:49 -04:00
|
|
|
<i class="dropdown-icon fas fa-cog"></i> <%= t("header.dropdown.settings") %>
|
2018-05-29 15:28:29 -04:00
|
|
|
<% end %>
|
|
|
|
<div class="dropdown-divider"></div>
|
2018-07-20 14:20:14 -04:00
|
|
|
<a class="dropdown-item" href="http://docs.bigbluebutton.org/install/greenlight-v2.html" target="_blank">
|
2018-07-17 11:57:49 -04:00
|
|
|
<i class="dropdown-icon far fa-question-circle"></i> <%= t("header.dropdown.help") %>
|
2018-05-29 15:28:29 -04:00
|
|
|
</a>
|
|
|
|
<%= link_to logout_path, class: "dropdown-item" do %>
|
2018-07-17 11:57:49 -04:00
|
|
|
<i class="dropdown-icon fas fa-sign-out-alt"></i> <%= t("header.dropdown.signout") %>
|
2018-05-29 15:28:29 -04:00
|
|
|
<% end %>
|
|
|
|
</div>
|
2018-05-24 16:59:20 -04:00
|
|
|
</div>
|
2019-04-09 11:22:55 -04:00
|
|
|
<% else %>
|
|
|
|
<% allow_greenlight_accounts = allow_greenlight_accounts? %>
|
2019-04-05 14:54:36 -04:00
|
|
|
<% if Rails.configuration.omniauth_ldap %>
|
|
|
|
<%= link_to t("login"), omniauth_login_url(:ldap), :class => "btn btn-pill btn-outline-primary mx-2" %>
|
2019-04-09 11:22:55 -04:00
|
|
|
<% elsif allow_greenlight_accounts %>
|
2018-07-17 11:57:49 -04:00
|
|
|
<%= link_to t("login"), "#loginModal", :class => "btn btn-pill btn-outline-primary mx-2", "data-toggle": "modal" %>
|
2019-04-05 14:54:36 -04:00
|
|
|
<% else %>
|
|
|
|
<%= link_to t("login"), omniauth_login_url(:bn_launcher), :class => "btn btn-pill btn-outline-primary mx-2" %>
|
2018-07-09 13:17:23 -04:00
|
|
|
<% end %>
|
2018-06-11 17:32:08 -04:00
|
|
|
|
2019-04-09 11:22:55 -04:00
|
|
|
<% if allow_user_signup? && allow_greenlight_accounts %>
|
2019-04-05 14:54:36 -04:00
|
|
|
<%= link_to t("signup.title"), signup_path, :class => "btn btn-pill btn-outline-primary mx-2" %>
|
|
|
|
<% end %>
|
2018-07-04 15:22:59 -04:00
|
|
|
|
2019-04-05 14:54:36 -04:00
|
|
|
<%= render "shared/modals/login_modal" %>
|
2019-04-09 11:22:55 -04:00
|
|
|
<% end %>
|
2019-04-05 14:54:36 -04:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2018-05-24 16:59:20 -04:00
|
|
|
</div>
|