forked from External/greenlight
GRN2-xx: General bug fixes and improvements for 2.3 (#701)
* General bug fixes and improvements for 2.3 * Removed mins change * Removed mins change rspec
This commit is contained in:
parent
58201d5763
commit
5f237194b1
|
@ -179,8 +179,10 @@ class AdminsController < ApplicationController
|
||||||
# POST /admins/default_recording_visibility
|
# POST /admins/default_recording_visibility
|
||||||
def default_recording_visibility
|
def default_recording_visibility
|
||||||
@settings.update_value("Default Recording Visibility", params[:visibility])
|
@settings.update_value("Default Recording Visibility", params[:visibility])
|
||||||
redirect_to admins_path, flash: { success: I18n.t("administrator.flash.settings") + ". " +
|
redirect_to admin_site_settings_path, flash: {
|
||||||
I18n.t("administrator.site_settings.recording_visibility.warning") }
|
success: I18n.t("administrator.flash.settings") + ". " +
|
||||||
|
I18n.t("administrator.site_settings.recording_visibility.warning")
|
||||||
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
private
|
private
|
||||||
|
|
|
@ -58,9 +58,9 @@ module AdminsHelper
|
||||||
def recording_default_visibility_string
|
def recording_default_visibility_string
|
||||||
if Setting.find_or_create_by!(provider: user_settings_provider)
|
if Setting.find_or_create_by!(provider: user_settings_provider)
|
||||||
.get_value("Default Recording Visibility") == "public"
|
.get_value("Default Recording Visibility") == "public"
|
||||||
I18n.t("administrator.site_settings.recording_visibility.public")
|
I18n.t("recording.visibility.public")
|
||||||
else
|
else
|
||||||
I18n.t("administrator.site_settings.recording_visibility.private")
|
I18n.t("recording.visibility.unlisted")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -110,10 +110,10 @@
|
||||||
</button>
|
</button>
|
||||||
<div class="dropdown-menu" aria-labelledby="room-auth">
|
<div class="dropdown-menu" aria-labelledby="room-auth">
|
||||||
<%= button_to admin_recording_visibility_path(visibility: "public"), class: "dropdown-item" do %>
|
<%= button_to admin_recording_visibility_path(visibility: "public"), class: "dropdown-item" do %>
|
||||||
<%= t("administrator.site_settings.recording_visibility.public") %>
|
<%= t("recording.visibility.public") %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<%= button_to admin_recording_visibility_path(visibility: "private"), class: "dropdown-item" do %>
|
<%= button_to admin_recording_visibility_path(visibility: "private"), class: "dropdown-item" do %>
|
||||||
<%= t("administrator.site_settings.recording_visibility.private") %>
|
<%= t("recording.visibility.unlisted") %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -49,8 +49,6 @@ en:
|
||||||
lighten: Lighten
|
lighten: Lighten
|
||||||
darken: Darken
|
darken: Darken
|
||||||
recording_visibility:
|
recording_visibility:
|
||||||
public: Public
|
|
||||||
private: Private
|
|
||||||
info: Set the default recording visbility for new recordings
|
info: Set the default recording visbility for new recordings
|
||||||
title: Recording Default Visibility
|
title: Recording Default Visibility
|
||||||
warning: This setting will only be applied to rooms that aren't running
|
warning: This setting will only be applied to rooms that aren't running
|
||||||
|
|
|
@ -327,7 +327,7 @@ describe AdminsController, type: :controller do
|
||||||
feature = Setting.find_by(provider: "provider1").features.find_by(name: "Default Recording Visibility")
|
feature = Setting.find_by(provider: "provider1").features.find_by(name: "Default Recording Visibility")
|
||||||
|
|
||||||
expect(feature[:value]).to eq("public")
|
expect(feature[:value]).to eq("public")
|
||||||
expect(response).to redirect_to(admins_path)
|
expect(response).to redirect_to(admin_site_settings_path)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue