forked from External/greenlight
Added Google calendar button (#429)
* implement first version of the recording authentication, redirecting to the playback URL with the jwt token * set default recording visibility by environment variable * use the http header, if present, to determine the client ip address * fix email verification when disabled * revert playback component to link_to, change method to get * remove unnecessary variable * Added "Add to Google Calendar" button on Room page * Added Google Calendar button enable to env.sample * Updated CSS for the Google Calendar Button row * Added correct translation when copying room link * Fixed new Google Calendar button mobile display * GRN-80: Allow local accounts on multitenant (#428) * Changed the way the omniauth providers are declared * Allow local authentication for multitenant mode based on customer settings * Cleanead up code mandated by rubocop * Completed implementation for signin and added the one for signup * Fixed issue with rubocop * Renamed customer_name to lb_user * Renamed lb_user -> user_domain, fixed issue with signup controller, email verification WAS NOT implemented * Completed implementation of email_verification * Fixed rubocop issue * Final update * Fix for test with loadbalancer * Make sure loadbalancer mockup is only used when env defined * Fix for test on rooms_controller * Fixed most of the test failing on multitenant env * Fixed issue detected by rubocop * Fixed issue with activation tockens not working on resend * Fixed new issue found by rubocop * Updated travis script * Harcoded credentials for mockup * Updated expectation on start_session * Fixed issue with duplication of home room * Updated script for rubocop * Restored Gemfile * Update sample.env * Update sample.env
This commit is contained in:
parent
d7b9e7a322
commit
d8f6c3f872
|
@ -32,10 +32,10 @@ $(document).on('turbolinks:load', function(){
|
||||||
if (success) {
|
if (success) {
|
||||||
inviteURL.blur();
|
inviteURL.blur();
|
||||||
copy.addClass('btn-success');
|
copy.addClass('btn-success');
|
||||||
copy.html("<i class='fas fa-check'></i> Copy")
|
copy.html("<i class='fas fa-check'></i> <%= I18n.t("copied") %>")
|
||||||
setTimeout(function(){
|
setTimeout(function(){
|
||||||
copy.removeClass('btn-success');
|
copy.removeClass('btn-success');
|
||||||
copy.html("<i class='fas fa-copy'></i> Copy")
|
copy.html("<i class='fas fa-copy'></i> <%= I18n.t("copy") %>")
|
||||||
}, 2000)
|
}, 2000)
|
||||||
}
|
}
|
||||||
});
|
});
|
|
@ -105,7 +105,7 @@ a {
|
||||||
}
|
}
|
||||||
|
|
||||||
.invite-link-input {
|
.invite-link-input {
|
||||||
width: 45%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.no-border-top {
|
.no-border-top {
|
||||||
|
|
|
@ -17,4 +17,9 @@
|
||||||
# with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
|
# with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
module RoomsHelper
|
module RoomsHelper
|
||||||
|
# Helper to generate the path to a Google Calendar event creation
|
||||||
|
# It will have its title set as the room name, and the location as the URL to the room
|
||||||
|
def google_calendar_path
|
||||||
|
"http://calendar.google.com/calendar/r/eventedit?text=#{@room.name}&location=#{request.base_url + request.fullpath}"
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -15,8 +15,8 @@
|
||||||
|
|
||||||
<div class="background pb-1">
|
<div class="background pb-1">
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<div class="row pt-7">
|
<div class="row pt-9">
|
||||||
<div class="col-lg-9 col-sm-12">
|
<div class="col-lg-8 col-sm-12">
|
||||||
<div id="room-title" class="display-3 form-inline <%= 'edit_hover_class' if current_user.main_room != @room %>">
|
<div id="room-title" class="display-3 form-inline <%= 'edit_hover_class' if current_user.main_room != @room %>">
|
||||||
<h1 contenteditable=false id="user-text" class="display-3 text-left mb-3 font-weight-400"><%= @room.name %></h1>
|
<h1 contenteditable=false id="user-text" class="display-3 text-left mb-3 font-weight-400"><%= @room.name %></h1>
|
||||||
<% if current_user.main_room == @room %>
|
<% if current_user.main_room == @room %>
|
||||||
|
@ -27,20 +27,36 @@
|
||||||
</div>
|
</div>
|
||||||
<h4 class="text-left mb-6"><%= @room.sessions %> <%= t("room.sessions") %> | <%= @recordings.length %> <%= t("room.recordings") %></h4>
|
<h4 class="text-left mb-6"><%= @room.sessions %> <%= t("room.sessions") %> | <%= @recordings.length %> <%= t("room.recordings") %></h4>
|
||||||
<label class="form-label"><%= t("room.invite_participants") %></label>
|
<label class="form-label"><%= t("room.invite_participants") %></label>
|
||||||
<form class="form-inline">
|
<div class="row">
|
||||||
|
<div class="col-lg-5 col-md-12 mt-2 pr-0">
|
||||||
<div class="input-icon invite-link-input">
|
<div class="input-icon invite-link-input">
|
||||||
<span class="input-icon-addon">
|
<span class="input-icon-addon">
|
||||||
<i class="fas fa-link"></i>
|
<i class="fas fa-link"></i>
|
||||||
</span>
|
</span>
|
||||||
<input id="invite-url" type="text" class="form-control w-100" value="<%= request.base_url + @room.invite_path %>" readonly="">
|
<input id="invite-url" type="text" class="form-control w-100" value="<%= request.base_url + @room.invite_path %>" readonly="">
|
||||||
</div>
|
</div>
|
||||||
<div id="copy" class="btn btn-primary mx-2">
|
</div>
|
||||||
|
<div class="col-lg-7 col-md-12 pr-0">
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-6">
|
||||||
|
<a href="#" id="copy" class="btn btn-primary btn-block mt-2">
|
||||||
<i class="fas fa-copy"></i>
|
<i class="fas fa-copy"></i>
|
||||||
<%= t("copy") %>
|
<%= t("copy") %>
|
||||||
|
</a>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
<div class="col-sm-6 pl-0">
|
||||||
|
<% if Rails.configuration.enable_google_calendar_button %>
|
||||||
|
<a href="<%= google_calendar_path %>" target="__blank" id="schedule" class="btn btn-primary btn-block mt-2">
|
||||||
|
<i class="fas fa-calendar-plus"></i>
|
||||||
|
<%= t("add_to_google_calendar") %>
|
||||||
|
</a>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-3 col-sm-12 force-bottom mt-5">
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="offset-lg-1 col-lg-3 col-sm-12 force-bottom mt-5 pr-0">
|
||||||
<% if @is_running %>
|
<% if @is_running %>
|
||||||
<%= button_to t("room.join"), room_path(@room), class: "btn btn-primary btn-block px-7 start-button float-right" %>
|
<%= button_to t("room.join"), room_path(@room), class: "btn btn-primary btn-block px-7 start-button float-right" %>
|
||||||
<% else %>
|
<% else %>
|
||||||
|
|
|
@ -39,7 +39,7 @@
|
||||||
<% end %>
|
<% end %>
|
||||||
</td>
|
</td>
|
||||||
<% end %>
|
<% end %>
|
||||||
<td id="recording-length" class="text-left" data-full-length="<%=recording[:playbacks].first[:length]%>">
|
<td id="recording-length" class="text-left" data-full-length="<%= recording[:playbacks].empty? ? 0 : recording[:playbacks].first[:length]%>">
|
||||||
<%= recording_length(recording[:playbacks]) %>
|
<%= recording_length(recording[:playbacks]) %>
|
||||||
</td>
|
</td>
|
||||||
<td id="recording-users" class="text-left">
|
<td id="recording-users" class="text-left">
|
||||||
|
|
|
@ -111,5 +111,8 @@ module Greenlight
|
||||||
|
|
||||||
# Whether the user has defined the variables required for recaptcha
|
# Whether the user has defined the variables required for recaptcha
|
||||||
config.recaptcha_enabled = ENV['RECAPTCHA_SITE_KEY'].present? && ENV['RECAPTCHA_SECRET_KEY'].present?
|
config.recaptcha_enabled = ENV['RECAPTCHA_SITE_KEY'].present? && ENV['RECAPTCHA_SECRET_KEY'].present?
|
||||||
|
|
||||||
|
# Show/hide "Add to Google Calendar" button in the room page
|
||||||
|
config.enable_google_calendar_button = (ENV['ENABLE_GOOGLE_CALENDAR_BUTTON'] == "true")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -62,12 +62,14 @@ en:
|
||||||
uid: User ID
|
uid: User ID
|
||||||
username: Username
|
username: Username
|
||||||
title: Manage Users
|
title: Manage Users
|
||||||
|
add_to_google_calendar: "Add to Google Calendar"
|
||||||
bigbluebutton: BigBlueButton
|
bigbluebutton: BigBlueButton
|
||||||
bigbluebutton_exception: Oops, there was an error when starting the meeting!
|
bigbluebutton_exception: Oops, there was an error when starting the meeting!
|
||||||
cancel: Cancel
|
cancel: Cancel
|
||||||
cookies:
|
cookies:
|
||||||
cookie_info: Cookies help us deliver our services. By using our services, you agree to our use of cookies.
|
cookie_info: Cookies help us deliver our services. By using our services, you agree to our use of cookies.
|
||||||
cookie_button: I Agree
|
cookie_button: I Agree
|
||||||
|
copied: Copied
|
||||||
copy: Copy
|
copy: Copy
|
||||||
default_admin: You are still using the default password for this account. Please click <a href="%{edit_link}">here</a> to change it
|
default_admin: You are still using the default password for this account. Please click <a href="%{edit_link}">here</a> to change it
|
||||||
delete: Delete
|
delete: Delete
|
||||||
|
|
|
@ -139,6 +139,10 @@ PAGINATION_NUMBER=25
|
||||||
# Default is set to 10 rows
|
# Default is set to 10 rows
|
||||||
NUMBER_OF_ROWS=10
|
NUMBER_OF_ROWS=10
|
||||||
|
|
||||||
|
# Specify if you want to display the Google Calendar button
|
||||||
|
# ENABLE_GOOGLE_CALENDAR_BUTTON=true|false
|
||||||
|
ENABLE_GOOGLE_CALENDAR_BUTTON=
|
||||||
|
|
||||||
# Comment this out to send logs to STDOUT in production instead of log/production.log .
|
# Comment this out to send logs to STDOUT in production instead of log/production.log .
|
||||||
#
|
#
|
||||||
# RAILS_LOG_TO_STDOUT=true
|
# RAILS_LOG_TO_STDOUT=true
|
||||||
|
|
Loading…
Reference in New Issue